From a09a0652939128be976405682999d836bbd5ff5a Mon Sep 17 00:00:00 2001 From: Owl Bot Date: Thu, 27 Jun 2024 01:57:53 +0000 Subject: [PATCH 1/2] feat: added cloud provider field to list findings response feat: added http configuration rule to ResourceValueConfig and ValuedResource API methods feat: added toxic combination field to finding docs: Updated comments for ResourceValueConfig PiperOrigin-RevId: 647117058 Source-Link: https://github.com/googleapis/googleapis/commit/efae79d0ba30034f2dd075d0213d09e93ebeccff Source-Link: https://github.com/googleapis/googleapis-gen/commit/daa5c0c61544616372983e26d39f96a61c3d96fa Copy-Tag: eyJwIjoiU2VjdXJpdHlDZW50ZXIvLk93bEJvdC55YW1sIiwiaCI6ImRhYTVjMGM2MTU0NDYxNjM3Mjk4M2UyNmQzOWY5NmE2MWMzZDk2ZmEifQ== --- .../Google/Cloud/Securitycenter/V1/Access.php | 45 + .../Cloud/Securitycenter/V1/Application.php | 30 + .../Google/Cloud/Securitycenter/V1/Asset.php | 60 + .../V1/BackupDisasterRecovery.php | 40 + .../Securitycenter/V1/BigqueryExport.php | 40 + .../Cloud/Securitycenter/V1/CloudArmor.php | 54 + .../Securitycenter/V1/CloudDlpDataProfile.php | Bin 0 -> 1395 bytes .../Securitycenter/V1/CloudDlpInspection.php | 35 + .../Cloud/Securitycenter/V1/Compliance.php | 32 + .../Cloud/Securitycenter/V1/Connection.php | Bin 0 -> 1150 bytes .../Securitycenter/V1/ContactDetails.php | 31 + .../Cloud/Securitycenter/V1/Container.php | 35 + .../Cloud/Securitycenter/V1/Database.php | 34 + ...iveSecurityHealthAnalyticsCustomModule.php | Bin 0 -> 2124 bytes .../Cloud/Securitycenter/V1/Exfiltration.php | 35 + .../Securitycenter/V1/ExternalSystem.php | 52 + .../Google/Cloud/Securitycenter/V1/File.php | 38 + .../Cloud/Securitycenter/V1/Finding.php | Bin 0 -> 8589 bytes .../Google/Cloud/Securitycenter/V1/Folder.php | 30 + .../Securitycenter/V1/GroupMembership.php | Bin 0 -> 1104 bytes .../Cloud/Securitycenter/V1/IamBinding.php | Bin 0 -> 1059 bytes .../Cloud/Securitycenter/V1/Indicator.php | Bin 0 -> 1746 bytes .../Cloud/Securitycenter/V1/KernelRootkit.php | 37 + .../Cloud/Securitycenter/V1/Kubernetes.php | Bin 0 -> 2621 bytes .../Google/Cloud/Securitycenter/V1/Label.php | 31 + .../Cloud/Securitycenter/V1/LoadBalancer.php | 29 + .../Cloud/Securitycenter/V1/LogEntry.php | Bin 0 -> 1183 bytes .../Cloud/Securitycenter/V1/MitreAttack.php | Bin 0 -> 3195 bytes .../Cloud/Securitycenter/V1/MuteConfig.php | 40 + .../Cloud/Securitycenter/V1/Notebook.php | 33 + .../Securitycenter/V1/NotificationConfig.php | Bin 0 -> 1674 bytes .../Securitycenter/V1/NotificationMessage.php | Bin 0 -> 1310 bytes .../Cloud/Securitycenter/V1/OrgPolicy.php | 31 + .../V1/OrganizationSettings.php | Bin 0 -> 1504 bytes .../Cloud/Securitycenter/V1/Process.php | 44 + .../Cloud/Securitycenter/V1/Resource.php | 38 + .../V1/RunAssetDiscoveryResponse.php | Bin 0 -> 1217 bytes .../SecurityHealthAnalyticsCustomConfig.php | Bin 0 -> 1709 bytes .../SecurityHealthAnalyticsCustomModule.php | Bin 0 -> 2505 bytes .../Cloud/Securitycenter/V1/SecurityMarks.php | 37 + .../Securitycenter/V1/SecurityPosture.php | 41 + .../V1/SecuritycenterService.php | 383 ++ .../Google/Cloud/Securitycenter/V1/Source.php | 34 + .../Securitycenter/V1/ToxicCombination.php | 30 + .../Cloud/Securitycenter/V1/Vulnerability.php | Bin 0 -> 3436 bytes .../Google/Cloud/SecurityCenter/V1/Access.php | 521 ++ .../SecurityCenter/V1/AdaptiveProtection.php | 84 + .../Cloud/SecurityCenter/V1/Application.php | 109 + .../Google/Cloud/SecurityCenter/V1/Asset.php | 412 ++ .../SecurityCenter/V1/Asset/IamPolicy.php | 81 + .../V1/Asset/SecurityCenterProperties.php | 379 ++ .../Google/Cloud/SecurityCenter/V1/Attack.php | 135 + .../V1/BackupDisasterRecovery.php | 495 ++ .../SecurityCenter/V1/BigQueryExport.php | 449 ++ .../V1/BulkMuteFindingsRequest.php | 227 + .../V1/BulkMuteFindingsResponse.php | 33 + .../Cloud/SecurityCenter/V1/CloudArmor.php | 323 ++ .../SecurityCenter/V1/CloudDlpDataProfile.php | 106 + .../V1/CloudDlpDataProfile/ParentType.php | 64 + .../SecurityCenter/V1/CloudDlpInspection.php | 187 + .../SecurityCenter/V1/CloudLoggingEntry.php | 196 + .../Cloud/SecurityCenter/V1/Compliance.php | 140 + .../Cloud/SecurityCenter/V1/Connection.php | 211 + .../SecurityCenter/V1/Connection/Protocol.php | 85 + .../Cloud/SecurityCenter/V1/Contact.php | 67 + .../SecurityCenter/V1/ContactDetails.php | 67 + .../Cloud/SecurityCenter/V1/Container.php | 221 + .../V1/CreateBigQueryExportRequest.php | 188 + .../V1/CreateFindingRequest.php | 183 + .../V1/CreateMuteConfigRequest.php | 206 + .../V1/CreateNotificationConfigRequest.php | 218 + ...rityHealthAnalyticsCustomModuleRequest.php | 152 + .../SecurityCenter/V1/CreateSourceRequest.php | 137 + .../Cloud/SecurityCenter/V1/CustomConfig.php | 297 + .../V1/CustomConfig/CustomOutputSpec.php | 73 + .../CustomOutputSpec/Property.php | 122 + .../V1/CustomConfig/ResourceSelector.php | 70 + .../V1/CustomConfig/Severity.php | 78 + .../Google/Cloud/SecurityCenter/V1/Cve.php | 330 ++ .../V1/Cve/ExploitationActivity.php | 87 + .../SecurityCenter/V1/Cve/RiskRating.php | 83 + .../Google/Cloud/SecurityCenter/V1/Cvssv3.php | 391 ++ .../V1/Cvssv3/AttackComplexity.php | 71 + .../SecurityCenter/V1/Cvssv3/AttackVector.php | 84 + .../Cloud/SecurityCenter/V1/Cvssv3/Impact.php | 73 + .../V1/Cvssv3/PrivilegesRequired.php | 79 + .../Cloud/SecurityCenter/V1/Cvssv3/Scope.php | 67 + .../V1/Cvssv3/UserInteraction.php | 67 + .../Cloud/SecurityCenter/V1/Database.php | 287 + .../V1/DeleteBigQueryExportRequest.php | 96 + .../V1/DeleteMuteConfigRequest.php | 96 + .../V1/DeleteNotificationConfigRequest.php | 96 + ...rityHealthAnalyticsCustomModuleRequest.php | 101 + ...iveSecurityHealthAnalyticsCustomModule.php | 223 + .../EnablementState.php | 64 + .../SecurityCenter/V1/EnvironmentVariable.php | 102 + .../Cloud/SecurityCenter/V1/ExfilResource.php | 121 + .../Cloud/SecurityCenter/V1/Exfiltration.php | 150 + .../SecurityCenter/V1/ExternalSystem.php | 485 ++ .../V1/ExternalSystem/TicketInfo.php | 255 + .../Google/Cloud/SecurityCenter/V1/File.php | 298 + .../Cloud/SecurityCenter/V1/File/DiskPath.php | 112 + .../Cloud/SecurityCenter/V1/Finding.php | 2170 +++++++ .../V1/Finding/FindingClass.php | 105 + .../Cloud/SecurityCenter/V1/Finding/Mute.php | 71 + .../SecurityCenter/V1/Finding/Severity.php | 116 + .../Cloud/SecurityCenter/V1/Finding/State.php | 65 + .../Google/Cloud/SecurityCenter/V1/Folder.php | 106 + .../Cloud/SecurityCenter/V1/Geolocation.php | 67 + .../V1/GetBigQueryExportRequest.php | 96 + ...rityHealthAnalyticsCustomModuleRequest.php | 102 + .../V1/GetMuteConfigRequest.php | 96 + .../V1/GetNotificationConfigRequest.php | 96 + .../V1/GetOrganizationSettingsRequest.php | 86 + ...rityHealthAnalyticsCustomModuleRequest.php | 101 + .../SecurityCenter/V1/GetSourceRequest.php | 86 + .../SecurityCenter/V1/GroupAssetsRequest.php | 643 +++ .../SecurityCenter/V1/GroupAssetsResponse.php | 191 + .../V1/GroupFindingsRequest.php | 695 +++ .../V1/GroupFindingsResponse.php | 191 + .../SecurityCenter/V1/GroupMembership.php | 102 + .../V1/GroupMembership/GroupType.php | 57 + .../Cloud/SecurityCenter/V1/GroupResult.php | 101 + .../Cloud/SecurityCenter/V1/IamBinding.php | 144 + .../SecurityCenter/V1/IamBinding/Action.php | 64 + .../Cloud/SecurityCenter/V1/Indicator.php | 177 + .../V1/Indicator/ProcessSignature.php | 145 + .../ProcessSignature/MemoryHashSignature.php | 108 + .../MemoryHashSignature/Detection.php | 112 + .../ProcessSignature/SignatureType.php | 64 + .../ProcessSignature/YaraRuleSignature.php | 70 + .../Cloud/SecurityCenter/V1/KernelRootkit.php | 367 ++ .../Cloud/SecurityCenter/V1/Kubernetes.php | 319 + .../V1/Kubernetes/AccessReview.php | 289 + .../SecurityCenter/V1/Kubernetes/Binding.php | 186 + .../SecurityCenter/V1/Kubernetes/Node.php | 74 + .../SecurityCenter/V1/Kubernetes/NodePool.php | 104 + .../SecurityCenter/V1/Kubernetes/Object.php | 220 + .../SecurityCenter/V1/Kubernetes/Pod.php | 176 + .../SecurityCenter/V1/Kubernetes/Role.php | 138 + .../V1/Kubernetes/Role/Kind.php | 64 + .../SecurityCenter/V1/Kubernetes/Subject.php | 138 + .../V1/Kubernetes/Subject/AuthType.php | 71 + .../Google/Cloud/SecurityCenter/V1/Label.php | 104 + .../SecurityCenter/V1/ListAssetsRequest.php | 719 +++ .../SecurityCenter/V1/ListAssetsResponse.php | 183 + .../ListAssetsResponse/ListAssetsResult.php | 114 + .../ListAssetsResult/StateChange.php | 75 + .../V1/ListBigQueryExportsRequest.php | 184 + .../V1/ListBigQueryExportsResponse.php | 105 + ...ityHealthAnalyticsCustomModulesRequest.php | 169 + ...tyHealthAnalyticsCustomModulesResponse.php | 106 + ...ityHealthAnalyticsCustomModulesRequest.php | 169 + ...tyHealthAnalyticsCustomModulesResponse.php | 106 + .../SecurityCenter/V1/ListFindingsRequest.php | 735 +++ .../V1/ListFindingsResponse.php | 183 + .../ListFindingsResult.php | 158 + .../ListFindingsResult/Resource.php | 321 ++ .../ListFindingsResult/StateChange.php | 87 + .../V1/ListMuteConfigsRequest.php | 184 + .../V1/ListMuteConfigsResponse.php | 105 + .../V1/ListNotificationConfigsRequest.php | 171 + .../V1/ListNotificationConfigsResponse.php | 105 + ...ityHealthAnalyticsCustomModulesRequest.php | 168 + ...tyHealthAnalyticsCustomModulesResponse.php | 105 + .../SecurityCenter/V1/ListSourcesRequest.php | 171 + .../SecurityCenter/V1/ListSourcesResponse.php | 105 + .../Cloud/SecurityCenter/V1/LoadBalancer.php | 68 + .../Cloud/SecurityCenter/V1/LogEntry.php | 75 + .../Cloud/SecurityCenter/V1/MitreAttack.php | 228 + .../SecurityCenter/V1/MitreAttack/Tactic.php | 149 + .../V1/MitreAttack/Technique.php | 458 ++ .../Cloud/SecurityCenter/V1/MuteConfig.php | 401 ++ .../Cloud/SecurityCenter/V1/Notebook.php | 181 + .../SecurityCenter/V1/NotificationConfig.php | 241 + .../V1/NotificationConfig/StreamingConfig.php | 131 + .../SecurityCenter/V1/NotificationMessage.php | 156 + .../Cloud/SecurityCenter/V1/OrgPolicy.php | 75 + .../V1/OrganizationSettings.php | 170 + .../AssetDiscoveryConfig.php | 142 + .../AssetDiscoveryConfig/InclusionMode.php | 74 + .../Cloud/SecurityCenter/V1/Package.php | 169 + .../Cloud/SecurityCenter/V1/Process.php | 409 ++ .../Cloud/SecurityCenter/V1/Reference.php | 105 + .../Cloud/SecurityCenter/V1/Requests.php | 177 + .../Cloud/SecurityCenter/V1/Resource.php | 317 + .../V1/RunAssetDiscoveryRequest.php | 86 + .../V1/RunAssetDiscoveryResponse.php | 111 + .../V1/RunAssetDiscoveryResponse/State.php | 72 + .../SecurityCenter/V1/SecurityBulletin.php | 149 + .../SecurityHealthAnalyticsCustomModule.php | 355 ++ .../EnablementState.php | 73 + .../Cloud/SecurityCenter/V1/SecurityMarks.php | 206 + .../SecurityCenter/V1/SecurityPolicy.php | 149 + .../SecurityCenter/V1/SecurityPosture.php | 325 ++ .../V1/SecurityPosture/PolicyDriftDetails.php | 151 + .../V1/ServiceAccountDelegationInfo.php | 125 + .../V1/SetFindingStateRequest.php | 189 + .../SecurityCenter/V1/SetMuteRequest.php | 143 + ...rityHealthAnalyticsCustomModuleRequest.php | 193 + .../SimulatedResource.php | 168 + ...ityHealthAnalyticsCustomModuleResponse.php | 78 + .../SimulatedResult.php | 147 + .../Google/Cloud/SecurityCenter/V1/Source.php | 244 + .../SecurityCenter/V1/ToxicCombination.php | 123 + .../V1/UpdateBigQueryExportRequest.php | 141 + .../V1/UpdateExternalSystemRequest.php | 142 + .../V1/UpdateFindingRequest.php | 175 + .../V1/UpdateMuteConfigRequest.php | 141 + .../V1/UpdateNotificationConfigRequest.php | 155 + .../V1/UpdateOrganizationSettingsRequest.php | 138 + ...rityHealthAnalyticsCustomModuleRequest.php | 136 + .../V1/UpdateSecurityMarksRequest.php | 202 + .../SecurityCenter/V1/UpdateSourceRequest.php | 138 + .../Cloud/SecurityCenter/V1/Vulnerability.php | 213 + .../bulk_mute_findings.php | 86 + .../create_big_query_export.php | 81 + .../SecurityCenterClient/create_finding.php | 80 + .../create_mute_config.php | 106 + .../create_notification_config.php | 81 + ...ecurity_health_analytics_custom_module.php | 79 + .../V1/SecurityCenterClient/create_source.php | 74 + .../delete_big_query_export.php | 72 + .../delete_mute_config.php | 72 + .../delete_notification_config.php | 75 + ...ecurity_health_analytics_custom_module.php | 78 + .../get_big_query_export.php | 74 + ...ecurity_health_analytics_custom_module.php | 78 + .../SecurityCenterClient/get_iam_policy.php | 71 + .../SecurityCenterClient/get_mute_config.php | 74 + .../get_notification_config.php | 77 + .../get_organization_settings.php | 72 + ...ecurity_health_analytics_custom_module.php | 78 + .../V1/SecurityCenterClient/get_source.php | 72 + .../V1/SecurityCenterClient/group_assets.php | 99 + .../SecurityCenterClient/group_findings.php | 105 + .../V1/SecurityCenterClient/list_assets.php | 80 + .../list_big_query_exports.php | 82 + ...curity_health_analytics_custom_modules.php | 81 + ...curity_health_analytics_custom_modules.php | 82 + .../V1/SecurityCenterClient/list_findings.php | 85 + .../list_mute_configs.php | 78 + .../list_notification_configs.php | 78 + ...curity_health_analytics_custom_modules.php | 81 + .../V1/SecurityCenterClient/list_sources.php | 78 + .../run_asset_discovery.php | 89 + .../set_finding_state.php | 83 + .../SecurityCenterClient/set_iam_policy.php | 73 + .../V1/SecurityCenterClient/set_mute.php | 80 + ...ecurity_health_analytics_custom_module.php | 86 + .../test_iam_permissions.php | 78 + .../update_big_query_export.php | 59 + .../update_external_system.php | 59 + .../SecurityCenterClient/update_finding.php | 60 + .../update_mute_config.php | 91 + .../update_notification_config.php | 61 + .../update_organization_settings.php | 59 + ...ecurity_health_analytics_custom_module.php | 63 + .../update_security_marks.php | 59 + .../V1/SecurityCenterClient/update_source.php | 59 + .../v1/src/V1/Client/SecurityCenterClient.php | 2617 +++++++++ .../V1/Gapic/SecurityCenterGapicClient.php | 5120 +++++++++++++++++ .../v1/src/V1/SecurityCenterClient.php | 34 + .../v1/src/V1/gapic_metadata.json | 243 + .../security_center_client_config.json | 293 + .../security_center_descriptor_config.php | 739 +++ .../security_center_rest_client_config.php | 1033 ++++ .../V1/Client/SecurityCenterClientTest.php | 3616 ++++++++++++ .../Unit/V1/SecurityCenterClientTest.php | 3289 +++++++++++ .../Cloud/Securitycenter/V1P1Beta1/Asset.php | 60 + .../Securitycenter/V1P1Beta1/Finding.php | Bin 0 -> 2387 bytes .../Cloud/Securitycenter/V1P1Beta1/Folder.php | 30 + .../V1P1Beta1/NotificationConfig.php | Bin 0 -> 1738 bytes .../V1P1Beta1/NotificationMessage.php | Bin 0 -> 1381 bytes .../V1P1Beta1/OrganizationSettings.php | Bin 0 -> 1581 bytes .../Securitycenter/V1P1Beta1/Resource.php | 36 + .../V1P1Beta1/RunAssetDiscoveryResponse.php | Bin 0 -> 1287 bytes .../V1P1Beta1/SecurityMarks.php | 37 + .../V1P1Beta1/SecuritycenterService.php | Bin 0 -> 15636 bytes .../Cloud/Securitycenter/V1P1Beta1/Source.php | 34 + .../Cloud/SecurityCenter/V1p1beta1/Asset.php | 412 ++ .../V1p1beta1/Asset/IamPolicy.php | 81 + .../Asset/SecurityCenterProperties.php | 379 ++ .../V1p1beta1/CreateFindingRequest.php | 153 + .../CreateNotificationConfigRequest.php | 161 + .../V1p1beta1/CreateSourceRequest.php | 119 + .../DeleteNotificationConfigRequest.php | 71 + .../SecurityCenter/V1p1beta1/Finding.php | 603 ++ .../V1p1beta1/Finding/Severity.php | 79 + .../V1p1beta1/Finding/State.php | 65 + .../Cloud/SecurityCenter/V1p1beta1/Folder.php | 106 + .../GetNotificationConfigRequest.php | 71 + .../GetOrganizationSettingsRequest.php | 71 + .../V1p1beta1/GetSourceRequest.php | 71 + .../V1p1beta1/GroupAssetsRequest.php | 643 +++ .../V1p1beta1/GroupAssetsResponse.php | 191 + .../V1p1beta1/GroupFindingsRequest.php | 627 ++ .../V1p1beta1/GroupFindingsResponse.php | 191 + .../SecurityCenter/V1p1beta1/GroupResult.php | 101 + .../V1p1beta1/ListAssetsRequest.php | 711 +++ .../V1p1beta1/ListAssetsResponse.php | 183 + .../ListAssetsResponse/ListAssetsResult.php | 114 + .../ListAssetsResult/StateChange.php | 75 + .../V1p1beta1/ListFindingsRequest.php | 695 +++ .../V1p1beta1/ListFindingsResponse.php | 183 + .../ListFindingsResult.php | 158 + .../ListFindingsResult/Resource.php | 253 + .../ListFindingsResult/StateChange.php | 87 + .../ListNotificationConfigsRequest.php | 151 + .../ListNotificationConfigsResponse.php | 105 + .../V1p1beta1/ListSourcesRequest.php | 155 + .../V1p1beta1/ListSourcesResponse.php | 105 + .../V1p1beta1/NotificationConfig.php | 268 + .../NotificationConfig/EventType.php | 57 + .../NotificationConfig/StreamingConfig.php | 131 + .../V1p1beta1/NotificationMessage.php | 156 + .../V1p1beta1/OrganizationSettings.php | 170 + .../AssetDiscoveryConfig.php | 142 + .../AssetDiscoveryConfig/InclusionMode.php | 74 + .../SecurityCenter/V1p1beta1/Resource.php | 249 + .../V1p1beta1/RunAssetDiscoveryRequest.php | 71 + .../V1p1beta1/RunAssetDiscoveryResponse.php | 111 + .../RunAssetDiscoveryResponse/State.php | 72 + .../V1p1beta1/SecurityMarks.php | 206 + .../V1p1beta1/SetFindingStateRequest.php | 157 + .../Cloud/SecurityCenter/V1p1beta1/Source.php | 243 + .../V1p1beta1/UpdateFindingRequest.php | 157 + .../UpdateNotificationConfigRequest.php | 125 + .../UpdateOrganizationSettingsRequest.php | 125 + .../V1p1beta1/UpdateSecurityMarksRequest.php | 185 + .../V1p1beta1/UpdateSourceRequest.php | 125 + .../SecurityCenterClient/create_finding.php | 73 + .../create_notification_config.php | 78 + .../SecurityCenterClient/create_source.php | 70 + .../delete_notification_config.php | 68 + .../SecurityCenterClient/get_iam_policy.php | 66 + .../get_notification_config.php | 70 + .../get_organization_settings.php | 67 + .../SecurityCenterClient/get_source.php | 67 + .../SecurityCenterClient/group_assets.php | 93 + .../SecurityCenterClient/group_findings.php | 99 + .../SecurityCenterClient/list_assets.php | 73 + .../SecurityCenterClient/list_findings.php | 80 + .../list_notification_configs.php | 72 + .../SecurityCenterClient/list_sources.php | 73 + .../run_asset_discovery.php | 84 + .../set_finding_state.php | 76 + .../SecurityCenterClient/set_iam_policy.php | 69 + .../test_iam_permissions.php | 74 + .../SecurityCenterClient/update_finding.php | 57 + .../update_notification_config.php | 57 + .../update_organization_settings.php | 56 + .../update_security_marks.php | 56 + .../SecurityCenterClient/update_source.php | 56 + .../Gapic/SecurityCenterGapicClient.php | 2807 +++++++++ .../src/V1p1beta1/SecurityCenterClient.php | 36 + .../src/V1p1beta1/gapic_metadata.json | 133 + .../security_center_client_config.json | 183 + .../security_center_descriptor_config.php | 98 + .../security_center_rest_client_config.php | 460 ++ .../V1p1beta1/SecurityCenterClientTest.php | 1692 ++++++ .../Google/Cloud/Securitycenter/V2/Access.php | 46 + .../Cloud/Securitycenter/V2/Application.php | 30 + .../Securitycenter/V2/AttackExposure.php | Bin 0 -> 1462 bytes .../Cloud/Securitycenter/V2/AttackPath.php | Bin 0 -> 2341 bytes .../V2/BackupDisasterRecovery.php | 40 + .../Securitycenter/V2/BigqueryExport.php | 40 + .../Cloud/Securitycenter/V2/CloudArmor.php | 54 + .../Securitycenter/V2/CloudDlpDataProfile.php | Bin 0 -> 1395 bytes .../Securitycenter/V2/CloudDlpInspection.php | 35 + .../Cloud/Securitycenter/V2/Compliance.php | 32 + .../Cloud/Securitycenter/V2/Connection.php | Bin 0 -> 1150 bytes .../Securitycenter/V2/ContactDetails.php | 31 + .../Cloud/Securitycenter/V2/Container.php | 35 + .../Cloud/Securitycenter/V2/Database.php | 34 + .../Cloud/Securitycenter/V2/Exfiltration.php | 35 + .../Securitycenter/V2/ExternalSystem.php | 52 + .../Google/Cloud/Securitycenter/V2/File.php | 38 + .../Cloud/Securitycenter/V2/Finding.php | Bin 0 -> 9093 bytes .../Google/Cloud/Securitycenter/V2/Folder.php | 30 + .../Securitycenter/V2/GroupMembership.php | Bin 0 -> 1104 bytes .../Cloud/Securitycenter/V2/IamBinding.php | Bin 0 -> 1059 bytes .../Cloud/Securitycenter/V2/Indicator.php | Bin 0 -> 1746 bytes .../Cloud/Securitycenter/V2/KernelRootkit.php | 37 + .../Cloud/Securitycenter/V2/Kubernetes.php | Bin 0 -> 2621 bytes .../Google/Cloud/Securitycenter/V2/Label.php | 31 + .../Cloud/Securitycenter/V2/LoadBalancer.php | 29 + .../Cloud/Securitycenter/V2/LogEntry.php | Bin 0 -> 1183 bytes .../Cloud/Securitycenter/V2/MitreAttack.php | Bin 0 -> 3313 bytes .../Cloud/Securitycenter/V2/MuteConfig.php | Bin 0 -> 1908 bytes .../Cloud/Securitycenter/V2/Notebook.php | 33 + .../Securitycenter/V2/NotificationConfig.php | Bin 0 -> 1778 bytes .../Securitycenter/V2/NotificationMessage.php | Bin 0 -> 1310 bytes .../Cloud/Securitycenter/V2/OrgPolicy.php | 31 + .../Cloud/Securitycenter/V2/Process.php | 44 + .../Cloud/Securitycenter/V2/Resource.php | Bin 0 -> 3212 bytes .../Securitycenter/V2/ResourceValueConfig.php | Bin 0 -> 2522 bytes .../Cloud/Securitycenter/V2/SecurityMarks.php | 37 + .../Securitycenter/V2/SecurityPosture.php | 41 + .../V2/SecuritycenterService.php | Bin 0 -> 28020 bytes .../Cloud/Securitycenter/V2/Simulation.php | 40 + .../Google/Cloud/Securitycenter/V2/Source.php | 34 + .../Securitycenter/V2/ToxicCombination.php | 30 + .../Securitycenter/V2/ValuedResource.php | Bin 0 -> 1720 bytes .../Cloud/Securitycenter/V2/Vulnerability.php | Bin 0 -> 3436 bytes .../Google/Cloud/SecurityCenter/V2/Access.php | 521 ++ .../SecurityCenter/V2/AdaptiveProtection.php | 84 + .../Cloud/SecurityCenter/V2/Application.php | 109 + .../Google/Cloud/SecurityCenter/V2/Attack.php | 135 + .../SecurityCenter/V2/AttackExposure.php | 313 + .../V2/AttackExposure/State.php | 64 + .../Cloud/SecurityCenter/V2/AttackPath.php | 139 + .../V2/AttackPath/AttackPathEdge.php | 105 + .../V2/AttackPath/AttackPathNode.php | 256 + .../AttackPathNode/AttackStepNode.php | 206 + .../V2/AttackPath/AttackPathNode/NodeType.php | 78 + .../PathNodeAssociatedFinding.php | 142 + .../Cloud/SecurityCenter/V2/AwsMetadata.php | 160 + .../V2/AwsMetadata/AwsAccount.php | 104 + .../V2/AwsMetadata/AwsOrganization.php | 80 + .../V2/AwsMetadata/AwsOrganizationalUnit.php | 122 + .../Cloud/SecurityCenter/V2/AzureMetadata.php | 160 + .../V2/AzureMetadata/AzureManagementGroup.php | 108 + .../V2/AzureMetadata/AzureResourceGroup.php | 70 + .../V2/AzureMetadata/AzureSubscription.php | 108 + .../V2/BackupDisasterRecovery.php | 495 ++ ...BatchCreateResourceValueConfigsRequest.php | 127 + ...atchCreateResourceValueConfigsResponse.php | 67 + .../SecurityCenter/V2/BigQueryExport.php | 457 ++ .../V2/BulkMuteFindingsRequest.php | 215 + .../V2/BulkMuteFindingsResponse.php | 33 + .../Cloud/SecurityCenter/V2/CloudArmor.php | 323 ++ .../SecurityCenter/V2/CloudDlpDataProfile.php | 106 + .../V2/CloudDlpDataProfile/ParentType.php | 64 + .../SecurityCenter/V2/CloudDlpInspection.php | 187 + .../SecurityCenter/V2/CloudLoggingEntry.php | 196 + .../Cloud/SecurityCenter/V2/CloudProvider.php | 68 + .../Cloud/SecurityCenter/V2/Compliance.php | 140 + .../Cloud/SecurityCenter/V2/Connection.php | 211 + .../SecurityCenter/V2/Connection/Protocol.php | 85 + .../Cloud/SecurityCenter/V2/Contact.php | 67 + .../SecurityCenter/V2/ContactDetails.php | 67 + .../Cloud/SecurityCenter/V2/Container.php | 221 + .../V2/CreateBigQueryExportRequest.php | 193 + .../V2/CreateFindingRequest.php | 203 + .../V2/CreateMuteConfigRequest.php | 193 + .../V2/CreateNotificationConfigRequest.php | 203 + .../V2/CreateResourceValueConfigRequest.php | 111 + .../SecurityCenter/V2/CreateSourceRequest.php | 137 + .../Google/Cloud/SecurityCenter/V2/Cve.php | 330 ++ .../V2/Cve/ExploitationActivity.php | 87 + .../SecurityCenter/V2/Cve/RiskRating.php | 83 + .../Google/Cloud/SecurityCenter/V2/Cvssv3.php | 391 ++ .../V2/Cvssv3/AttackComplexity.php | 71 + .../SecurityCenter/V2/Cvssv3/AttackVector.php | 84 + .../Cloud/SecurityCenter/V2/Cvssv3/Impact.php | 73 + .../V2/Cvssv3/PrivilegesRequired.php | 79 + .../Cloud/SecurityCenter/V2/Cvssv3/Scope.php | 67 + .../V2/Cvssv3/UserInteraction.php | 67 + .../Cloud/SecurityCenter/V2/Database.php | 287 + .../V2/DeleteBigQueryExportRequest.php | 107 + .../V2/DeleteMuteConfigRequest.php | 123 + .../V2/DeleteNotificationConfigRequest.php | 117 + .../V2/DeleteResourceValueConfigRequest.php | 81 + .../SecurityCenter/V2/EnvironmentVariable.php | 102 + .../Cloud/SecurityCenter/V2/ExfilResource.php | 121 + .../Cloud/SecurityCenter/V2/Exfiltration.php | 150 + .../SecurityCenter/V2/ExternalSystem.php | 513 ++ .../V2/ExternalSystem/TicketInfo.php | 255 + .../Google/Cloud/SecurityCenter/V2/File.php | 298 + .../Cloud/SecurityCenter/V2/File/DiskPath.php | 112 + .../Cloud/SecurityCenter/V2/Finding.php | 2302 ++++++++ .../V2/Finding/FindingClass.php | 103 + .../Cloud/SecurityCenter/V2/Finding/Mute.php | 71 + .../SecurityCenter/V2/Finding/Severity.php | 116 + .../Cloud/SecurityCenter/V2/Finding/State.php | 65 + .../Google/Cloud/SecurityCenter/V2/Folder.php | 106 + .../Cloud/SecurityCenter/V2/GcpMetadata.php | 246 + .../Cloud/SecurityCenter/V2/Geolocation.php | 67 + .../V2/GetBigQueryExportRequest.php | 107 + .../V2/GetMuteConfigRequest.php | 123 + .../V2/GetNotificationConfigRequest.php | 117 + .../V2/GetResourceValueConfigRequest.php | 86 + .../V2/GetSimulationRequest.php | 99 + .../SecurityCenter/V2/GetSourceRequest.php | 86 + .../V2/GetValuedResourceRequest.php | 92 + .../V2/GroupFindingsRequest.php | 473 ++ .../V2/GroupFindingsResponse.php | 147 + .../SecurityCenter/V2/GroupMembership.php | 102 + .../V2/GroupMembership/GroupType.php | 57 + .../Cloud/SecurityCenter/V2/GroupResult.php | 101 + .../Cloud/SecurityCenter/V2/IamBinding.php | 144 + .../SecurityCenter/V2/IamBinding/Action.php | 64 + .../Cloud/SecurityCenter/V2/Indicator.php | 177 + .../V2/Indicator/ProcessSignature.php | 145 + .../ProcessSignature/MemoryHashSignature.php | 108 + .../MemoryHashSignature/Detection.php | 112 + .../ProcessSignature/SignatureType.php | 64 + .../ProcessSignature/YaraRuleSignature.php | 70 + .../Cloud/SecurityCenter/V2/KernelRootkit.php | 367 ++ .../Cloud/SecurityCenter/V2/Kubernetes.php | 319 + .../V2/Kubernetes/AccessReview.php | 289 + .../SecurityCenter/V2/Kubernetes/Binding.php | 186 + .../SecurityCenter/V2/Kubernetes/Node.php | 74 + .../SecurityCenter/V2/Kubernetes/NodePool.php | 104 + .../SecurityCenter/V2/Kubernetes/Object.php | 220 + .../SecurityCenter/V2/Kubernetes/Pod.php | 176 + .../SecurityCenter/V2/Kubernetes/Role.php | 138 + .../V2/Kubernetes/Role/Kind.php | 64 + .../SecurityCenter/V2/Kubernetes/Subject.php | 138 + .../V2/Kubernetes/Subject/AuthType.php | 71 + .../Google/Cloud/SecurityCenter/V2/Label.php | 104 + .../V2/ListAttackPathsRequest.php | 230 + .../V2/ListAttackPathsResponse.php | 106 + .../V2/ListBigQueryExportsRequest.php | 189 + .../V2/ListBigQueryExportsResponse.php | 105 + .../SecurityCenter/V2/ListFindingsRequest.php | 572 ++ .../V2/ListFindingsResponse.php | 139 + .../ListFindingsResult.php | 124 + .../ListFindingsResult/Resource.php | 467 ++ .../V2/ListMuteConfigsRequest.php | 200 + .../V2/ListMuteConfigsResponse.php | 105 + .../V2/ListNotificationConfigsRequest.php | 181 + .../V2/ListNotificationConfigsResponse.php | 105 + .../V2/ListResourceValueConfigsRequest.php | 191 + .../V2/ListResourceValueConfigsResponse.php | 105 + .../SecurityCenter/V2/ListSourcesRequest.php | 171 + .../SecurityCenter/V2/ListSourcesResponse.php | 105 + .../V2/ListValuedResourcesRequest.php | 298 + .../V2/ListValuedResourcesResponse.php | 139 + .../Cloud/SecurityCenter/V2/LoadBalancer.php | 68 + .../Cloud/SecurityCenter/V2/LogEntry.php | 75 + .../Cloud/SecurityCenter/V2/MitreAttack.php | 228 + .../SecurityCenter/V2/MitreAttack/Tactic.php | 149 + .../V2/MitreAttack/Technique.php | 486 ++ .../Cloud/SecurityCenter/V2/MuteConfig.php | 420 ++ .../V2/MuteConfig/MuteConfigType.php | 63 + .../Cloud/SecurityCenter/V2/Notebook.php | 181 + .../SecurityCenter/V2/NotificationConfig.php | 253 + .../V2/NotificationConfig/StreamingConfig.php | 131 + .../SecurityCenter/V2/NotificationMessage.php | 156 + .../Cloud/SecurityCenter/V2/OrgPolicy.php | 75 + .../Cloud/SecurityCenter/V2/Package.php | 169 + .../Cloud/SecurityCenter/V2/Process.php | 409 ++ .../Cloud/SecurityCenter/V2/Reference.php | 105 + .../Cloud/SecurityCenter/V2/Requests.php | 177 + .../Cloud/SecurityCenter/V2/Resource.php | 463 ++ .../Cloud/SecurityCenter/V2/ResourcePath.php | 72 + .../V2/ResourcePath/ResourcePathNode.php | 139 + .../V2/ResourcePath/ResourcePathNodeType.php | 113 + .../Cloud/SecurityCenter/V2/ResourceValue.php | 75 + .../SecurityCenter/V2/ResourceValueConfig.php | 506 ++ .../SensitiveDataProtectionMapping.php | 114 + .../V2/ResourceValueConfigMetadata.php | 67 + .../SecurityCenter/V2/SecurityBulletin.php | 149 + .../Cloud/SecurityCenter/V2/SecurityMarks.php | 250 + .../SecurityCenter/V2/SecurityPolicy.php | 149 + .../SecurityCenter/V2/SecurityPosture.php | 325 ++ .../V2/SecurityPosture/PolicyDriftDetails.php | 151 + .../V2/ServiceAccountDelegationInfo.php | 125 + .../V2/SetFindingStateRequest.php | 184 + .../SecurityCenter/V2/SetMuteRequest.php | 184 + .../Cloud/SecurityCenter/V2/Simulation.php | 187 + .../Google/Cloud/SecurityCenter/V2/Source.php | 244 + .../SecurityCenter/V2/ToxicCombination.php | 124 + .../V2/UpdateBigQueryExportRequest.php | 141 + .../V2/UpdateExternalSystemRequest.php | 142 + .../V2/UpdateFindingRequest.php | 183 + .../V2/UpdateMuteConfigRequest.php | 141 + .../V2/UpdateNotificationConfigRequest.php | 142 + .../V2/UpdateResourceValueConfigRequest.php | 157 + .../V2/UpdateSecurityMarksRequest.php | 152 + .../SecurityCenter/V2/UpdateSourceRequest.php | 142 + .../SecurityCenter/V2/ValuedResource.php | 307 + .../V2/ValuedResource/ResourceValue.php | 71 + .../Cloud/SecurityCenter/V2/Vulnerability.php | 213 + .../batch_create_resource_value_configs.php | 102 + .../bulk_mute_findings.php | 94 + .../create_big_query_export.php | 82 + .../SecurityCenterClient/create_finding.php | 84 + .../create_mute_config.php | 113 + .../create_notification_config.php | 82 + .../V2/SecurityCenterClient/create_source.php | 74 + .../delete_big_query_export.php | 79 + .../delete_mute_config.php | 79 + .../delete_notification_config.php | 81 + .../delete_resource_value_config.php | 72 + .../get_big_query_export.php | 81 + .../SecurityCenterClient/get_iam_policy.php | 71 + .../SecurityCenterClient/get_mute_config.php | 81 + .../get_notification_config.php | 83 + .../get_resource_value_config.php | 75 + .../SecurityCenterClient/get_simulation.php | 76 + .../V2/SecurityCenterClient/get_source.php | 72 + .../get_valued_resource.php | 78 + .../SecurityCenterClient/group_findings.php | 114 + .../list_attack_paths.php | 88 + .../list_big_query_exports.php | 83 + .../V2/SecurityCenterClient/list_findings.php | 103 + .../list_mute_configs.php | 82 + .../list_notification_configs.php | 80 + .../list_resource_value_configs.php | 78 + .../V2/SecurityCenterClient/list_sources.php | 78 + .../list_valued_resources.php | 81 + .../set_finding_state.php | 90 + .../SecurityCenterClient/set_iam_policy.php | 73 + .../V2/SecurityCenterClient/set_mute.php | 90 + .../test_iam_permissions.php | 78 + .../update_big_query_export.php | 59 + .../update_external_system.php | 60 + .../SecurityCenterClient/update_finding.php | 61 + .../update_mute_config.php | 97 + .../update_notification_config.php | 60 + .../update_resource_value_config.php | 76 + .../update_security_marks.php | 61 + .../V2/SecurityCenterClient/update_source.php | 59 + .../v2/src/V2/Client/SecurityCenterClient.php | 2791 +++++++++ .../v2/src/V2/gapic_metadata.json | 218 + .../security_center_client_config.json | 226 + .../security_center_descriptor_config.php | 672 +++ .../security_center_rest_client_config.php | 1125 ++++ .../V2/Client/SecurityCenterClientTest.php | 3152 ++++++++++ 622 files changed, 113651 insertions(+) create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Access.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Application.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Asset.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/BackupDisasterRecovery.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/BigqueryExport.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudArmor.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudDlpDataProfile.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudDlpInspection.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Compliance.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Connection.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ContactDetails.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Container.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Database.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/EffectiveSecurityHealthAnalyticsCustomModule.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Exfiltration.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ExternalSystem.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/File.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Finding.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Folder.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/GroupMembership.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/IamBinding.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Indicator.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/KernelRootkit.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Kubernetes.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Label.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/LoadBalancer.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/LogEntry.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/MitreAttack.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/MuteConfig.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Notebook.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/NotificationConfig.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/NotificationMessage.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/OrgPolicy.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/OrganizationSettings.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Process.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Resource.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/RunAssetDiscoveryResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityHealthAnalyticsCustomConfig.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityHealthAnalyticsCustomModule.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityMarks.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityPosture.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecuritycenterService.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Source.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ToxicCombination.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Vulnerability.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Access.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/AdaptiveProtection.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Application.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset/IamPolicy.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset/SecurityCenterProperties.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Attack.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BackupDisasterRecovery.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BigQueryExport.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BulkMuteFindingsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BulkMuteFindingsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudArmor.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpDataProfile.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpDataProfile/ParentType.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpInspection.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudLoggingEntry.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Compliance.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Connection.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Connection/Protocol.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Contact.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ContactDetails.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Container.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateBigQueryExportRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateFindingRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateMuteConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateNotificationConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateSecurityHealthAnalyticsCustomModuleRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateSourceRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/CustomOutputSpec.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/CustomOutputSpec/Property.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/ResourceSelector.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/Severity.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve/ExploitationActivity.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve/RiskRating.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/AttackComplexity.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/AttackVector.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/Impact.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/PrivilegesRequired.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/Scope.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/UserInteraction.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Database.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteBigQueryExportRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteMuteConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteNotificationConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteSecurityHealthAnalyticsCustomModuleRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EffectiveSecurityHealthAnalyticsCustomModule.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EffectiveSecurityHealthAnalyticsCustomModule/EnablementState.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EnvironmentVariable.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExfilResource.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Exfiltration.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExternalSystem.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExternalSystem/TicketInfo.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/File.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/File/DiskPath.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/FindingClass.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/Mute.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/Severity.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/State.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Folder.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Geolocation.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetBigQueryExportRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetEffectiveSecurityHealthAnalyticsCustomModuleRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetMuteConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetNotificationConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetOrganizationSettingsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetSecurityHealthAnalyticsCustomModuleRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetSourceRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupAssetsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupAssetsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupFindingsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupFindingsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupMembership.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupMembership/GroupType.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupResult.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/IamBinding.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/IamBinding/Action.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/MemoryHashSignature.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/MemoryHashSignature/Detection.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/SignatureType.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/YaraRuleSignature.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/KernelRootkit.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/AccessReview.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Binding.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Node.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/NodePool.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Object.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Pod.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Role.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Role/Kind.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Subject.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Subject/AuthType.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Label.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse/ListAssetsResult.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse/ListAssetsResult/StateChange.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListBigQueryExportsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListBigQueryExportsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListDescendantSecurityHealthAnalyticsCustomModulesRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListDescendantSecurityHealthAnalyticsCustomModulesResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListEffectiveSecurityHealthAnalyticsCustomModulesRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListEffectiveSecurityHealthAnalyticsCustomModulesResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult/Resource.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult/StateChange.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListMuteConfigsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListMuteConfigsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListNotificationConfigsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListNotificationConfigsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSecurityHealthAnalyticsCustomModulesRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSecurityHealthAnalyticsCustomModulesResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSourcesRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSourcesResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/LoadBalancer.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/LogEntry.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack/Tactic.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack/Technique.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MuteConfig.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Notebook.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationConfig.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationConfig/StreamingConfig.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationMessage.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrgPolicy.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings/AssetDiscoveryConfig.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings/AssetDiscoveryConfig/InclusionMode.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Package.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Process.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Reference.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Requests.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Resource.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryResponse/State.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityBulletin.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityHealthAnalyticsCustomModule.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityHealthAnalyticsCustomModule/EnablementState.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityMarks.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPolicy.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPosture.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPosture/PolicyDriftDetails.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ServiceAccountDelegationInfo.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SetFindingStateRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SetMuteRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleRequest/SimulatedResource.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleResponse/SimulatedResult.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Source.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ToxicCombination.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateBigQueryExportRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateExternalSystemRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateFindingRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateMuteConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateNotificationConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateOrganizationSettingsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSecurityHealthAnalyticsCustomModuleRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSecurityMarksRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSourceRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Vulnerability.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/bulk_mute_findings.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_big_query_export.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_finding.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_mute_config.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_notification_config.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_security_health_analytics_custom_module.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_source.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_big_query_export.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_mute_config.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_notification_config.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_security_health_analytics_custom_module.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_big_query_export.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_effective_security_health_analytics_custom_module.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_iam_policy.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_mute_config.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_notification_config.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_organization_settings.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_security_health_analytics_custom_module.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_source.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/group_assets.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/group_findings.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_assets.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_big_query_exports.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_descendant_security_health_analytics_custom_modules.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_effective_security_health_analytics_custom_modules.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_findings.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_mute_configs.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_notification_configs.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_security_health_analytics_custom_modules.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_sources.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/run_asset_discovery.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_finding_state.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_iam_policy.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_mute.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/simulate_security_health_analytics_custom_module.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/test_iam_permissions.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_big_query_export.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_external_system.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_finding.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_mute_config.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_notification_config.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_organization_settings.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_security_health_analytics_custom_module.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_security_marks.php create mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_source.php create mode 100644 owl-bot-staging/SecurityCenter/v1/src/V1/Client/SecurityCenterClient.php create mode 100644 owl-bot-staging/SecurityCenter/v1/src/V1/Gapic/SecurityCenterGapicClient.php create mode 100644 owl-bot-staging/SecurityCenter/v1/src/V1/SecurityCenterClient.php create mode 100644 owl-bot-staging/SecurityCenter/v1/src/V1/gapic_metadata.json create mode 100644 owl-bot-staging/SecurityCenter/v1/src/V1/resources/security_center_client_config.json create mode 100644 owl-bot-staging/SecurityCenter/v1/src/V1/resources/security_center_descriptor_config.php create mode 100644 owl-bot-staging/SecurityCenter/v1/src/V1/resources/security_center_rest_client_config.php create mode 100644 owl-bot-staging/SecurityCenter/v1/tests/Unit/V1/Client/SecurityCenterClientTest.php create mode 100644 owl-bot-staging/SecurityCenter/v1/tests/Unit/V1/SecurityCenterClientTest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Asset.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Finding.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Folder.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/NotificationConfig.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/NotificationMessage.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/OrganizationSettings.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Resource.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/RunAssetDiscoveryResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/SecurityMarks.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/SecuritycenterService.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Source.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset/IamPolicy.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset/SecurityCenterProperties.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateFindingRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateNotificationConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateSourceRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/DeleteNotificationConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding/Severity.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding/State.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Folder.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetNotificationConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetOrganizationSettingsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetSourceRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupAssetsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupAssetsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupFindingsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupFindingsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupResult.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse/ListAssetsResult.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse/ListAssetsResult/StateChange.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult/Resource.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult/StateChange.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListNotificationConfigsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListNotificationConfigsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListSourcesRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListSourcesResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig/EventType.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig/StreamingConfig.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationMessage.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings/AssetDiscoveryConfig.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings/AssetDiscoveryConfig/InclusionMode.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Resource.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryResponse/State.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/SecurityMarks.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/SetFindingStateRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Source.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateFindingRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateNotificationConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateOrganizationSettingsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateSecurityMarksRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateSourceRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_finding.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_notification_config.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_source.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/delete_notification_config.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_iam_policy.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_notification_config.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_organization_settings.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_source.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/group_assets.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/group_findings.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_assets.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_findings.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_notification_configs.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_sources.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/run_asset_discovery.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/set_finding_state.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/set_iam_policy.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/test_iam_permissions.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_finding.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_notification_config.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_organization_settings.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_security_marks.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_source.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/Gapic/SecurityCenterGapicClient.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/SecurityCenterClient.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/gapic_metadata.json create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/resources/security_center_client_config.json create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/resources/security_center_descriptor_config.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/resources/security_center_rest_client_config.php create mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/tests/Unit/V1p1beta1/SecurityCenterClientTest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Access.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Application.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/AttackExposure.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/AttackPath.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/BackupDisasterRecovery.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/BigqueryExport.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudArmor.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudDlpDataProfile.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudDlpInspection.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Compliance.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Connection.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ContactDetails.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Container.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Database.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Exfiltration.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ExternalSystem.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/File.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Finding.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Folder.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/GroupMembership.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/IamBinding.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Indicator.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/KernelRootkit.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Kubernetes.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Label.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/LoadBalancer.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/LogEntry.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/MitreAttack.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/MuteConfig.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Notebook.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/NotificationConfig.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/NotificationMessage.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/OrgPolicy.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Process.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Resource.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ResourceValueConfig.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecurityMarks.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecurityPosture.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecuritycenterService.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Simulation.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Source.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ToxicCombination.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ValuedResource.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Vulnerability.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Access.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AdaptiveProtection.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Application.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Attack.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackExposure.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackExposure/State.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathEdge.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/AttackStepNode.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/NodeType.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/PathNodeAssociatedFinding.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsAccount.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsOrganization.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsOrganizationalUnit.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureManagementGroup.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureResourceGroup.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureSubscription.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BackupDisasterRecovery.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BatchCreateResourceValueConfigsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BatchCreateResourceValueConfigsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BigQueryExport.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BulkMuteFindingsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BulkMuteFindingsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudArmor.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpDataProfile.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpDataProfile/ParentType.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpInspection.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudLoggingEntry.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudProvider.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Compliance.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Connection.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Connection/Protocol.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Contact.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ContactDetails.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Container.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateBigQueryExportRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateFindingRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateMuteConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateNotificationConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateResourceValueConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateSourceRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve/ExploitationActivity.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve/RiskRating.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/AttackComplexity.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/AttackVector.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/Impact.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/PrivilegesRequired.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/Scope.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/UserInteraction.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Database.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteBigQueryExportRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteMuteConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteNotificationConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteResourceValueConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/EnvironmentVariable.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExfilResource.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Exfiltration.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExternalSystem.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExternalSystem/TicketInfo.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/File.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/File/DiskPath.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/FindingClass.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/Mute.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/Severity.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/State.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Folder.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GcpMetadata.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Geolocation.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetBigQueryExportRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetMuteConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetNotificationConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetResourceValueConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetSimulationRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetSourceRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetValuedResourceRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupFindingsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupFindingsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupMembership.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupMembership/GroupType.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupResult.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/IamBinding.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/IamBinding/Action.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/MemoryHashSignature.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/MemoryHashSignature/Detection.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/SignatureType.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/YaraRuleSignature.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/KernelRootkit.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/AccessReview.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Binding.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Node.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/NodePool.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Object.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Pod.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Role.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Role/Kind.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Subject.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Subject/AuthType.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Label.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListAttackPathsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListAttackPathsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListBigQueryExportsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListBigQueryExportsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse/ListFindingsResult.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse/ListFindingsResult/Resource.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListMuteConfigsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListMuteConfigsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListNotificationConfigsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListNotificationConfigsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListResourceValueConfigsRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListResourceValueConfigsResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListSourcesRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListSourcesResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListValuedResourcesRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListValuedResourcesResponse.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/LoadBalancer.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/LogEntry.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack/Tactic.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack/Technique.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MuteConfig.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MuteConfig/MuteConfigType.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Notebook.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationConfig.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationConfig/StreamingConfig.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationMessage.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/OrgPolicy.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Package.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Process.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Reference.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Requests.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Resource.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourcePath.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourcePath/ResourcePathNode.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourcePath/ResourcePathNodeType.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValue.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfig.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfig/SensitiveDataProtectionMapping.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfigMetadata.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityBulletin.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityMarks.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPolicy.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPosture.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPosture/PolicyDriftDetails.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ServiceAccountDelegationInfo.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SetFindingStateRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SetMuteRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Simulation.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Source.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ToxicCombination.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateBigQueryExportRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateExternalSystemRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateFindingRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateMuteConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateNotificationConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateResourceValueConfigRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateSecurityMarksRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateSourceRequest.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ValuedResource.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ValuedResource/ResourceValue.php create mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Vulnerability.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/batch_create_resource_value_configs.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/bulk_mute_findings.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_big_query_export.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_finding.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_mute_config.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_notification_config.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_source.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_big_query_export.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_mute_config.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_notification_config.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_resource_value_config.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_big_query_export.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_iam_policy.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_mute_config.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_notification_config.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_resource_value_config.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_simulation.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_source.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_valued_resource.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/group_findings.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_attack_paths.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_big_query_exports.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_findings.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_mute_configs.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_notification_configs.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_resource_value_configs.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_sources.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_valued_resources.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_finding_state.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_iam_policy.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_mute.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/test_iam_permissions.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_big_query_export.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_external_system.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_finding.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_mute_config.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_notification_config.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_resource_value_config.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_security_marks.php create mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_source.php create mode 100644 owl-bot-staging/SecurityCenter/v2/src/V2/Client/SecurityCenterClient.php create mode 100644 owl-bot-staging/SecurityCenter/v2/src/V2/gapic_metadata.json create mode 100644 owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_client_config.json create mode 100644 owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_descriptor_config.php create mode 100644 owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_rest_client_config.php create mode 100644 owl-bot-staging/SecurityCenter/v2/tests/Unit/V2/Client/SecurityCenterClientTest.php diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Access.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Access.php new file mode 100644 index 000000000000..878958841e81 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Access.php @@ -0,0 +1,45 @@ +internalAddGeneratedFile( + ' +Á ++google/cloud/securitycenter/v1/access.protogoogle.cloud.securitycenter.v1"‰ +Access +principal_email (  + caller_ip ( B + caller_ip_geo ( 2+.google.cloud.securitycenter.v1.Geolocation +user_agent_family (  + +user_agent (  + service_name (  + method_name (  +principal_subject (  +service_account_key_name ( e +service_account_delegation_info ( 2<.google.cloud.securitycenter.v1.ServiceAccountDelegationInfo + user_name ( "R +ServiceAccountDelegationInfo +principal_email (  +principal_subject ( "" + Geolocation + region_code ( Bå +"com.google.cloud.securitycenter.v1B AccessProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Application.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Application.php new file mode 100644 index 000000000000..ac621b34fd25 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Application.php @@ -0,0 +1,30 @@ +internalAddGeneratedFile( + ' +ú +0google/cloud/securitycenter/v1/application.protogoogle.cloud.securitycenter.v1"1 + Application +base_uri (  +full_uri ( Bê +"com.google.cloud.securitycenter.v1BApplicationProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Asset.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Asset.php new file mode 100644 index 000000000000..71df8833b9fd --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Asset.php @@ -0,0 +1,60 @@ +internalAddGeneratedFile( + ' +ü +*google/cloud/securitycenter/v1/asset.protogoogle.cloud.securitycenter.v1+google/cloud/securitycenter/v1/folder.proto3google/cloud/securitycenter/v1/security_marks.protogoogle/protobuf/struct.protogoogle/protobuf/timestamp.proto"© +Asset +name ( b +security_center_properties ( 2>.google.cloud.securitycenter.v1.Asset.SecurityCenterPropertiesZ +resource_properties ( 2=.google.cloud.securitycenter.v1.Asset.ResourcePropertiesEntryE +security_marks ( 2-.google.cloud.securitycenter.v1.SecurityMarks/ + create_time ( 2.google.protobuf.Timestamp/ + update_time + ( 2.google.protobuf.TimestampC + +iam_policy ( 2/.google.cloud.securitycenter.v1.Asset.IamPolicy +canonical_name ( ¹ +SecurityCenterProperties + resource_name (  + resource_type (  +resource_parent (  +resource_project (  +resource_owners (  +resource_display_name ( $ +resource_parent_display_name ( % +resource_project_display_name ( 7 +folders + ( 2&.google.cloud.securitycenter.v1.Folder + IamPolicy + policy_blob ( Q +ResourcePropertiesEntry +key ( % +value ( 2.google.protobuf.Value:8:šêA– +#securitycenter.googleapis.com/Asset+organizations/{organization}/assets/{asset}folders/{folder}/assets/{asset}!projects/{project}/assets/{asset}BØ +"com.google.cloud.securitycenter.v1PZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/BackupDisasterRecovery.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/BackupDisasterRecovery.php new file mode 100644 index 000000000000..8b92fdb20c0d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/BackupDisasterRecovery.php @@ -0,0 +1,40 @@ +internalAddGeneratedFile( + ' +è +=google/cloud/securitycenter/v1/backup_disaster_recovery.protogoogle.cloud.securitycenter.v1"† +BackupDisasterRecovery +backup_template (  +policies (  +host (  + applications (  + storage_pool (  +policy_options (  +profile (  + appliance (  + backup_type ( 6 +backup_create_time + ( 2.google.protobuf.TimestampBõ +"com.google.cloud.securitycenter.v1BBackupDisasterRecoveryProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/BigqueryExport.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/BigqueryExport.php new file mode 100644 index 000000000000..d05399eac4ce --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/BigqueryExport.php @@ -0,0 +1,40 @@ +internalAddGeneratedFile( + ' +Ê +4google/cloud/securitycenter/v1/bigquery_export.protogoogle.cloud.securitycenter.v1google/api/resource.protogoogle/protobuf/timestamp.proto"½ +BigQueryExport +name (  + description (  +filter (  +dataset ( 4 + create_time ( 2.google.protobuf.TimestampBàA4 + update_time ( 2.google.protobuf.TimestampBàA +most_recent_editor ( BàA + principal ( BàA:ÁêA½ +,securitycenter.googleapis.com/BigQueryExport5organizations/{organization}/bigQueryExports/{export})folders/{folder}/bigQueryExports/{export}+projects/{project}/bigQueryExports/{export}Bí +"com.google.cloud.securitycenter.v1BBigQueryExportProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudArmor.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudArmor.php new file mode 100644 index 000000000000..1831a22fd0be --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudArmor.php @@ -0,0 +1,54 @@ +internalAddGeneratedFile( + ' +Æ +0google/cloud/securitycenter/v1/cloud_armor.protogoogle.cloud.securitycenter.v1"Þ + +CloudArmorG +security_policy ( 2..google.cloud.securitycenter.v1.SecurityPolicy: +requests ( 2(.google.cloud.securitycenter.v1.RequestsO +adaptive_protection ( 22.google.cloud.securitycenter.v1.AdaptiveProtection6 +attack ( 2&.google.cloud.securitycenter.v1.Attack + threat_vector ( + +duration ( 2.google.protobuf.Duration"= +SecurityPolicy +name (  +type (  +preview ("j +Requests +ratio ( +short_term_allowed ( +long_term_allowed ( +long_term_denied ("( +AdaptiveProtection + +confidence ("H +Attack + +volume_pps ( + +volume_bps ( +classification ( Bé +"com.google.cloud.securitycenter.v1BCloudArmorProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudDlpDataProfile.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudDlpDataProfile.php new file mode 100644 index 0000000000000000000000000000000000000000..36164f95b221e61def775212a3f99a19329bd29a GIT binary patch literal 1395 zcmbtUU2oGc6s1Lg@FrA+2PPp+-UnKdAf@n@vZ1uiN+;1qU6{laDRN!6Gsjk;ar+cqGIqWEC2UbWlkcO=GUkDT@?~ zD`(YwKNy5E7!XAQz#jshsp}vVkyDmPLK$wk^$$#uEXZ$ZNWYOm`iBdU{!z7t5DiI^ zVEw-t$|mHvIWD?D7#^ASLr!s`h=SKPPXZos#YxD&z)^Sckc0^Xoa?c}G@^=&2xkf1 zh_do?oMUFO+fsluyLieFswx3W`R(ku5efY!OK8lc60r-RmNjB(rg64Yem*Ii!SNw3 z=Nv8T8p&O(;*`x-$2evxjiZ|8odJwzD}RZ8w&Z?~P5NYA9_TV(pXcQspRl(FgBjU< z=u&wGpB39dzwV*hf3(|J&y!6(E9T;?m}k|^-v#t|NmGqIv^qaLYXw{=KdhJk*w4@w zOqQ9$63G)2=C$IHe#qvA!Z<`LlEg5QfjXCLtqAFlUhhrPZen9DVPd)(#siei_Xu5n z8Bfs@*X}tTFYrFOPVljF=sJz|e%oo5?ieMs+U>RMPW#yQ+TBj6V631AZm)abG`v!= z{`D@}1m3sssjn>|qzBL~93SM8PW1&5M&ha&K_BqrqUy3=ySnkcxZcwK%LOo}{%dGU zn@80j(*S?s(3wT^5Fb4Hv$&CiSe9mOS&J~11u^!w!oT(J72Fn|8C6N;VzL@nRMuoT zes-I{zW$uvE@Q)4k`W3D*MW#2db+#?rhgw`lz6i<^TCVUlye@w(Z4z}x7rwu5&8>; Cs@xj@ literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudDlpInspection.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudDlpInspection.php new file mode 100644 index 000000000000..d5020e24d7c5 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudDlpInspection.php @@ -0,0 +1,35 @@ +internalAddGeneratedFile( + ' +á +9google/cloud/securitycenter/v1/cloud_dlp_inspection.protogoogle.cloud.securitycenter.v1"ˆ +CloudDlpInspection3 + inspect_job ( BúA +dlp.googleapis.com/DlpJob + info_type (  +info_type_count ( + full_scan (Bð +"com.google.cloud.securitycenter.v1BCloudDlpInspectionProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1êA| +dlp.googleapis.com/DlpJob$projects/{project}/dlpJobs/{dlp_job}9projects/{project}/locations/{location}/dlpJobs/{dlp_job}bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Compliance.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Compliance.php new file mode 100644 index 000000000000..eb7e2081031a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Compliance.php @@ -0,0 +1,32 @@ +internalAddGeneratedFile( + ' +ƒ +/google/cloud/securitycenter/v1/compliance.protogoogle.cloud.securitycenter.v1"< + +Compliance +standard (  +version (  +ids ( Bé +"com.google.cloud.securitycenter.v1BComplianceProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Connection.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Connection.php new file mode 100644 index 0000000000000000000000000000000000000000..ecd7c31729ab4384d95f3c1c55c7abcc70256cbe GIT binary patch literal 1150 zcmb7D(Qeu>6djay)RVe2niW>|g&ICg&gyUo~ z!5ktsi%5vM1!1cPFMC7SZgq!;vNdK2N7#l_#-<^zqL3v)HO466MBE`v1?JV;S`{%$ zF%pDPOLGH2{TYrUA7R*Wn-^I4fiHZoqiH-x(RhOm8t=MR2LOeB9789g1784?zbF}p z1i@JNLjE0*ctj`>#1F}5`Kkt-_+gA?`$Oy`p;{MI4Lyo*dKvXYuZ3g8NhBC|CDgX3SY+c=mCDKDT17`Du##%D?FS+oQ1Aq=-wq+iBH^^I zbt{5-cGAjTzaVJA<9;6MHHr3iR)w->fzvcm0Ibps4 zdjXCGq0$3JM3tksT@Ku~(>?FDTgD@^2nt>2!ZmW{ zW3V-JTw_Nau3E0KuMVAl+o-BTd*B+U&7V0?mg)G1oaWP&9xcJmefp4&b@>i9lm6UK zjvo;jp3TWe^R%5SLxEO?f4(}TO-p|o`X36zX7qZa^wI2 literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ContactDetails.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ContactDetails.php new file mode 100644 index 000000000000..894ca1d04c11 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ContactDetails.php @@ -0,0 +1,31 @@ +internalAddGeneratedFile( + ' +µ +4google/cloud/securitycenter/v1/contact_details.protogoogle.cloud.securitycenter.v1"K +ContactDetails9 +contacts ( 2\'.google.cloud.securitycenter.v1.Contact" +Contact +email ( Bí +"com.google.cloud.securitycenter.v1BContactDetailsProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Container.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Container.php new file mode 100644 index 000000000000..f3cfed09c352 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Container.php @@ -0,0 +1,35 @@ +internalAddGeneratedFile( + ' +‡ +.google/cloud/securitycenter/v1/container.protogoogle.cloud.securitycenter.v1google/protobuf/timestamp.proto"  + Container +name (  +uri (  +image_id ( 5 +labels ( 2%.google.cloud.securitycenter.v1.Label/ + create_time ( 2.google.protobuf.TimestampBè +"com.google.cloud.securitycenter.v1BContainerProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Database.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Database.php new file mode 100644 index 000000000000..717d7fb26198 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Database.php @@ -0,0 +1,34 @@ +internalAddGeneratedFile( + ' +¶ +-google/cloud/securitycenter/v1/database.protogoogle.cloud.securitycenter.v1"s +Database +name (  + display_name (  + user_name (  +query (  +grantees (  +version ( Bç +"com.google.cloud.securitycenter.v1B DatabaseProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/EffectiveSecurityHealthAnalyticsCustomModule.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/EffectiveSecurityHealthAnalyticsCustomModule.php new file mode 100644 index 0000000000000000000000000000000000000000..81ddd71378bee6c71219d587a8597b5d7889ef2c GIT binary patch literal 2124 zcmcIl%TC)s6fFsTFwi#53Q&axibRm8qtKlxt@1D-2tw4PSyYy+iG7ny<#;T690^cX zU3Aeu>8JE7y5x`bI!fzzTUofhc0@B>)?P#I9RxMg!vG#>oLwu zX5(Ja?}LX;Hgc&Ao`P}h5H}AySgSQU%i^lf0?z~$4;UNRP&928SVbSqz@z-g1c!rH z9G8k9U`$TOU?l&HArPAn4dM{{h*Q%y%)sYtWQ>><*q}r%Amoq{_%1O4*IShX;KU-F z==F$AuZC=T`vRNZEo~uW+Qj#6gq+(ralI8PEY#H-p+v$V zy#~JNQI|8XB}`Ry06fi0_@%HO(}r-gj|N^x{s{%tZrp!~-v#8EMZo2vb;HYd0jnyq% zRx0L>sN_N#ekjHo`Za^P_fx|8C5fviDX|ua~Abon;aQYh|_6^D^2wL z(v>_$FSTa5vacOz&5qITlslU7vDt2E)y7UktK}Z#XVGJ6QOix`=g^Z{qaE7UavAk& z_O$#Zi}sRa#hI6aiKP3An6AaUgp?mKZ$KP+EM^pQ{Nl;^*GW2kFZE0tIH%6QKbytp z$DcrfWLjRF#FISfGur}Bn8?FDP?%!ee-;};aKxwoPg41oK`TP*TdJ#4x=SviIo_K3 zv?tp;X#OB%#bM|H}9flinbDUc=H!hjTQm%ptnjrKCO2YD} literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Exfiltration.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Exfiltration.php new file mode 100644 index 000000000000..d61d6bcfd96e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Exfiltration.php @@ -0,0 +1,35 @@ +internalAddGeneratedFile( + ' +® +1google/cloud/securitycenter/v1/exfiltration.protogoogle.cloud.securitycenter.v1"¯ + Exfiltration> +sources ( 2-.google.cloud.securitycenter.v1.ExfilResource> +targets ( 2-.google.cloud.securitycenter.v1.ExfilResource +total_exfiltrated_bytes ("1 + ExfilResource +name (  + +components ( Bë +"com.google.cloud.securitycenter.v1BExfiltrationProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ExternalSystem.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ExternalSystem.php new file mode 100644 index 000000000000..831b281808d5 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ExternalSystem.php @@ -0,0 +1,52 @@ +internalAddGeneratedFile( + ' +ô +4google/cloud/securitycenter/v1/external_system.protogoogle.cloud.securitycenter.v1google/protobuf/timestamp.proto"‚ +ExternalSystem +name (  + assignees (  + external_uid (  +status ( ? +external_system_update_time ( 2.google.protobuf.Timestamp +case_uri (  + case_priority ( , +case_sla ( 2.google.protobuf.Timestamp4 +case_create_time + ( 2.google.protobuf.Timestamp3 +case_close_time ( 2.google.protobuf.TimestampN + ticket_info ( 29.google.cloud.securitycenter.v1.ExternalSystem.TicketInfo + +TicketInfo + +id (  +assignee (  + description (  +uri (  +status ( / + update_time ( 2.google.protobuf.Timestamp:ÅêAÁ +,securitycenter.googleapis.com/ExternalSystemaorganizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}Ufolders/{folder}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}Wprojects/{project}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}Bí +"com.google.cloud.securitycenter.v1BExternalSystemProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/File.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/File.php new file mode 100644 index 000000000000..4aa4fc116a6b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/File.php @@ -0,0 +1,38 @@ +internalAddGeneratedFile( + ' +¬ +)google/cloud/securitycenter/v1/file.protogoogle.cloud.securitycenter.v1"ð +File +path (  +size ( +sha256 (  + hashed_size ( +partially_hashed ( +contents ( @ + disk_path ( 2-.google.cloud.securitycenter.v1.File.DiskPath9 +DiskPath +partition_uuid (  + relative_path ( Bã +"com.google.cloud.securitycenter.v1B FileProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Finding.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Finding.php new file mode 100644 index 0000000000000000000000000000000000000000..f850bf33828727a10ee0c7df3fdc88d8dfbe8d37 GIT binary patch literal 8589 zcmb_i+j85;5sj{vhLV=T$}U*tcwxm}%WIpo=Z);iUq4^;C5FY+wU(OSKuBN}Ly*Y$0O1{qB&RkcdBp_NN|;}$?euNPP}r*%B9 z2@8`&ejDuWFyU1l-ZonN6}C& zavd5aj$}{P?}=#{oqeRO^EKvjpDc1qi-H~a+{=gLz_mK`z&~s!wtev_{1~j*PlslbU(UqG34t>=*L*K5Q%OspnpvtYBKlJ-=j! zW(a#%qn39XaNNeUKp@rK(5D#eW8j2b;MgXd zmvL~p?)cW_My3^&Ae-3E7$UIf0iO+t@$zP}J#Crc7#vpq2!Rnnt{%&|D1YRstbPjT zqI-Eex5pB+JAv2p_h`38gYbjxUw&D-*)8yzF$ONEW001{apK=W8KF+i^P*!ry8O!C z^}t~+jp!I+f7dhH1=C@Nd<@~g>vhU*G>(M3XGa0eM{v%MFYmC57txmIje)5eboM^V%vwrmHa=jh>) z2)jCnFzX8rVghW~pk^bpdqJu~CHe4sTj<7oyPe2HmN3^7VaH_NUGn$);b-`x(b~X?~j|=hD`;v)FRC8kRBiZ1-WD|%j38IC%%xDW?W&}c+ zjW{71Y?w@c3B*gugdEX!e1ly$44>;P0e&$u*iPh>fM#XTL^F*Hh=q{=Jdw_T>c?nv z`6E!7QBX|di1804o6N*gAYX#tT1mMdzp7%ns03p$366;}Xc852%AE30C(Y%Ag% zYIIrg6d+k(B_N-dNCA5$*^r3UK?52raUm2q*+!lWRy%>YA?5;Wu~(4|v80J_zd8SH z6xS_2VC`Qw$Q99CQ5MKFYtpC_+Qj<2vP5QmGk_RSC-L)DvKUtq1BXrF<5y&c^*E?H z4Ih^_ABw=bs4`{5WSKexDQPkX=Y@8>;8dMKz7?{NJz3`63YNcp8bme? z)hpW6dTMiP(x1!F(o&oE}B&+whB}K%TFm8Lg)#2%wS$t z=aDDQ8QkB{Ov)tELCKPo6;QCB1Bet*Aafzi!1`?J0*qeTd^EE40;gOfOP1++E+i_4 zZ{!j%%_})F-R;3XeucabM&;cDjPi~wif*5Q{W^6SNuG>KB7&mGdVR_(GN0s8RRN;Z z<~7mRiMoOe(zqN_lFAE`X3j8rK9oPPJy((F|Li9Zg1?Y-62QEmh3Yko z)K@Yq;whpibC}k zVxP*Ov6r#g1GoYAqK$E@D^%A;wK0Y$8u^+hO(t-C$2{dH>^3u$@8H)Y)fP=;=;x?+ z&;)O(@Y)aS^Ul`+N@U-UziEs~05GIP@lbdxj^^v0jg;Q>>G$9gfp3k-8)`mMh6Ha*FB_uvKc!Crbwxk9FPt3Rcu*NS8s_2UXj z?;U)ylzB44o|b?oMXnrF_=iblk<1@dO66_60^d!q{bPbG3<=2Jlk4zZNw4e}#oc_p zer|=ZlE&LwIo|-@WwLm9uv;nD@&$btjDdx+wdnO?wX&`69Mtj+y;^}Ke??N&LcLr& zP8wkx^+PW+nx z_XN2UXCnU6T!ahs?7|FO4zt22z73T{=}bu;0J@>QPJd%cm9V2 z;0^dK!LXzJ*30t`{x*4Y2Y*VC!PJ(Cb9E7}W6z&4jn*t?hsSr57VZQ7CV$|?Kf4gy)@NS&<4FE${*0Uv@*ADecxV6s literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Folder.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Folder.php new file mode 100644 index 000000000000..d497fe11d042 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Folder.php @@ -0,0 +1,30 @@ +internalAddGeneratedFile( + ' +† ++google/cloud/securitycenter/v1/folder.protogoogle.cloud.securitycenter.v1"G +Folder +resource_folder ( $ +resource_folder_display_name ( Bå +"com.google.cloud.securitycenter.v1B FolderProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/GroupMembership.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/GroupMembership.php new file mode 100644 index 0000000000000000000000000000000000000000..fac67776518bddd0cfbd4cc6d6cc68df5e24ff37 GIT binary patch literal 1104 zcmbW0-HOvd6vs^wapyuy5m`i*vvpy+pea?nFty6|V?%^C!Oa$xK*`6n9Y{07WU^4D z@8EOz4!(eo;)T!PWYUJViwfo@$;|)!=FBLyajGJLhv#6QkFylllL!1cAo7b)8 zjMI!w7I+b0p3Vu=)d>hC{sO1W4>6cdcZh`_`NH>11@n42%)8uydE-_ap)mH-6wDkt zEScyF0{O5kh)D>k@P&MxkaR*4B8VT8&+>vDnEG*wCF7=cnkAtiG=V(8PD0!`gMyiB zPZ*U2>A)sCC$EvLk7wnVO#ImE<22-i3CbNQHH;Y+Wo7e~#@YJV97m?mC~`E68%cIR z@C}Lr zm-Xvb{kw+l?=_`1M5t)KSTcO5f!4V9{FVN9kiG{g{#^;ERngr7N20@ugdNl^bfDyF z`w@C*zPGQOiTlwROs+}`$eAIDTFi-}yJ6+*uO Du*PwX literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/IamBinding.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/IamBinding.php new file mode 100644 index 0000000000000000000000000000000000000000..e5dab7d5c25505dba260038dab0dd77a63420e5a GIT binary patch literal 1059 zcmb7D(TdYR6g90>9AqtdkUlMU>%w+HQ=|BjTBU8eCBnAFt$mO{nIzNhK#~cQ$-*lA z8=w3X|3txma58Dr?Jg?jCCPBkx#!+{=FPk0GC@yaL}J3RAOU#SAT9|coC)T$5WH-; zBpiGeB{U@50I(-8p3GoqJF_E6OB&zgtxEEHpS7x zqj5mvm7&BDig85J1p5R=)BZUTIKTqCBcKAh83j+Bh znHN$YQh|kh9n*9{V=5>P>1Wwi7nV3oiKO4fF06T$dYLM>}WL^;p=q;HwUG zjK>}2I~Q1&U&`6@w{+v97X)S5Gr6l)3Cw9H=vNiJ_}?YzhXun>Yc=-QYFwGkuNp$T zRp>ob!)lfd4Ybz5OVju}-`H`Do+9dx(0$HA(x^y*hx!4kMI`bFZ&dUD=4({j;GQ78 zH<&q-@#5q7Vmcf+XU@>B-_swUYR|UonvPKI!|;4EAJ!}V9~x@P2>-)P|MAX_TJu!< z^uFkP+Xjo;D|S2HIH5A(`@>1R&h3M5mBWz=x1qvqY{NZJm&BNx-?spF6aO;*1;mvX s;AiEi5V0(!Vp;n#mNhrMnz~`HPRay4D}r?+hkwkVLKbmbqcuXm0U8KdTmS$7 literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Indicator.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Indicator.php new file mode 100644 index 0000000000000000000000000000000000000000..4e0680b916cb812e13a30a8f327c6ef07bcfa538 GIT binary patch literal 1746 zcmbtUVNcUQ7^VY;dx1HM=(0p|Ad!)1m*KY}8ra5|!EIrKh*?r^?QOf*wN39zG7Z1Q z@BR=!_ybJ*2gYCFwcVPHL5$Kb>#pxT&-1>|-ShIb({tbnDie#im=goF2Z;9wa$K9+ zx^1Gi*Xa-!>2}|tCUF&niZxWNHBqTpX>N$E%=TQJsHkh(U6bT=)Ao!UBf95OKG2E9 ziJQC3=cr{+9dp}N0%!mW_X%^bPEfgi_?B>NV2)em0Hsy%QCf`&l-7BE4?s6DW2iDh zgU^7(<9Kb8>WFd7#m^RH8nq~=*rcCCPy48YO-97->DrEG>73dY@;B5hon&`Vi0RjE zIkuR=J{sw&`(qI!X;u8bENr%lgy}AIL}PVPs;XVWqhb0h*_|P+4@WyF8){V5DUth# zyB-;5N601IbFIBVw-0a?y#>mizoJ7O2Zj;R9toqeQK7$W8@?n!`8S8;^{`$E991SA zRW9?JKjV;ye2^c&5_L3e7%pLqu(X6`vkCb=EEsklQ;Vfz!9o>)(XNF>TcT)ItS#=U zLuI!yDG`ez=C2F<#t1@Qf;n-}SbEM!&wQJQ)KrNLYkktU-GSD_tfxiv={S-Ed-ea> zmA3)zv4D*f9nZ)gVRe9Atht^^#^@FTx|2K5T?o`u0Xk0h0g_Qi8Xq_$eNXTtcaQJD z6X7=nUgn1ct2Z<%ufcMgT3F1rgZtDR2+Jj5xd~tpPJ&An`m(tD?hayZpjL__f{Y4@ z=#QL)c&JDmHebqPSaXO7CyQ$i?h>Z;G1q&<5a&+HN|~pyGBr_o1rm{Y>3JV!(}3lP ziOB1aX;jM9gXY<3No!uzOWIkrQ7;uLN0m}BH6v%>;kEDe(^{d_Xrv_h5v*SOc2qej zrDBJRkcf;t{3XGrh}^%7?JybLj3Aim()%~zZ5>@*yPxaY*V7m~R0Q(mg?8F|*B8FV z*26Sbf;3h}X6SvE;lpHG|49Ag|yG;18r}MUwyk literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/KernelRootkit.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/KernelRootkit.php new file mode 100644 index 000000000000..0d7f479ab77e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/KernelRootkit.php @@ -0,0 +1,37 @@ +internalAddGeneratedFile( + ' +¦ +3google/cloud/securitycenter/v1/kernel_rootkit.protogoogle.cloud.securitycenter.v1"× + KernelRootkit +name ( $ +unexpected_code_modification (. +&unexpected_read_only_data_modification (! +unexpected_ftrace_handler (! +unexpected_kprobe_handler ($ +unexpected_kernel_code_pages (& +unexpected_system_call_handler ($ +unexpected_interrupt_handler (( + unexpected_processes_in_runqueue (Bì +"com.google.cloud.securitycenter.v1BKernelRootkitProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Kubernetes.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Kubernetes.php new file mode 100644 index 0000000000000000000000000000000000000000..53d182f98fafc58b327cec8c6f3d535f00137197 GIT binary patch literal 2621 zcmbtW-EQMV6efRd_H5}!W|2ZJRDMa|EK(2_*?sQ_7u9A}c6b#2RI z7Zp@4cn5B|Mmz)$z?;AWaLt*S*lF6`&06Fp&g6XGocYdoJm={b-kAsQlQwmzZv=Ek zrk5l*qr~&wz%^Z)OvCw{`owh4Jw@DmXHc;VExOu_;qz^_LZn^=w&ScYx=h^MNNxnVPk@Y}KT&@ltc zbqELa9Fvy!iR9$5k31JusF5hKJ{JZ>(L4NPj$!Lf%1qz#0@v?jsHQDw5X;F|%KOW0 zIh{2pWtpR<-Ab}X0zahJcPGTBLFhY&B5zJ`6+h{3E}PzPoxrfL#+tS|<%%>3)rm2s zc*>X22(3PTW-XODn$2P%o}+onaq9dakKx~4s3dfa@<0MqVKa5zX6i+?^x+0Vn`bW_ zxcAErz{*F;Q^A|jHnv}7LPcJO` z11oL`uFn#19SMSgz$yUkc1rt*29(=MX<7<}ZaP=6mOEINCxAy+J$@^^&Y%?G#-698GYMt-IjMe zYzN`Nn$l-mCwef;}8=Hq@$qZ{>Y40rXSfeI@Up=$dfP@iMzP_!yprv(Nf9 z&fHzD*i~$9M?vaSB@tlQVtDQa0T!mX*MqI literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Label.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Label.php new file mode 100644 index 000000000000..6d6184d29230 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Label.php @@ -0,0 +1,31 @@ +internalAddGeneratedFile( + ' +á +*google/cloud/securitycenter/v1/label.protogoogle.cloud.securitycenter.v1"$ +Label +name (  +value ( Bä +"com.google.cloud.securitycenter.v1B +LabelProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/LoadBalancer.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/LoadBalancer.php new file mode 100644 index 000000000000..d9a5d7eb068c --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/LoadBalancer.php @@ -0,0 +1,29 @@ +internalAddGeneratedFile( + ' +è +2google/cloud/securitycenter/v1/load_balancer.protogoogle.cloud.securitycenter.v1" + LoadBalancer +name ( Bë +"com.google.cloud.securitycenter.v1BLoadBalancerProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/LogEntry.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/LogEntry.php new file mode 100644 index 0000000000000000000000000000000000000000..225e8367a89d14020930b0c644343ce1d33a1b4d GIT binary patch literal 1183 zcmb7DU2hUW6cub5nMRYYFQgC66q}SLcFESaK{Qe-)~Jw3crcrgVRqO~vdnB|XPcnm z!N231f5Sgw;;(Q%*lj8DATO}Xx#!+{?l~`Cr`IWX2K$s#i4~3DbOF^hg{c%u5Rt%X zKATYqiI}G>q0)!2H-Mi8BY4@n8Xf7n3O= zBA)06x$rGD036S0mSRF-f7ty<6^^jNVc)WZ7ltMLyv7oagEjyp!C3}Bi1^Zwfo}ln zPnu5?Mqs9}(qG3cn=sB4!wLJUSL(nSPBN;CH?gyv6U79FreMGcZJt8MX|Tts&=PcD zG1kziq7@0R%vu~LVUK1+vQ!B<)KG+Cs!A=*o95}Nt)XKx*mN@@v@v7{Dw)%}-651z z<&wAU+=gIT{tEvgS~=Z_X=xRnrwHAyb<1M6I(x-dJG_aaa^$!A#?7*cX?X&E?g0P) zj_Vydyl>6mubaWY2^tJMDlX^^!BY#HXotj%uUt~Ez)ExPJXm$!#^hV0Xf9J}9r5l# zcMsGwmvdX=dj;%ofV_QBV?3i$O;}`G)x0NQ*Hr1}s%~BL4uB`AGxvlDt}xRPsXw&; zoq?JvG_LR1Ne_xit-ZBJ{PGIj-xbi%0V)t%ROvp}d)OW9A%~SO?;WxbQ_NejxF0Q? zGM%ngLl-Tlm|sNeLT6H^dK~;J0O2ZpW%?W>)baaMJ#r)nSxFIEr$J~O cOn0pSFHTAqJ$J^wlY^}put;arC0GLR7m%xo!~g&Q literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/MitreAttack.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/MitreAttack.php new file mode 100644 index 0000000000000000000000000000000000000000..7645341c03ea0e088a8ec7a8f6fd099c920c6aa0 GIT binary patch literal 3195 zcmbtW+j84R5?x8L9gS^yJif^{8IqM)&V^bzo4wHMO$~t|ITnCHFaRyOST#jakj+|( z`}i1M6^he4I?I-soi9A0(5CWjV_7Rb&ZAMw{?-I+{&-N!5Ba z8oe4MyS>3^cC2#9!Q%`*#-8{nlQ zvAAJ(&~cJ!Z_*#9qe%c)tJPOYx?mJfb{-dD5w3r1?c_ODs~;r!%t|M-q#WI{CP_M* z44-CsBfz`GZ&_wv{;gl+!H

Ve6pQ&f+3Idqn?FHIjd~t&ED4k zu9Ax-G1zmmHlFlPx|6pC#0DwWm#n3owI@$1KMhnVfmEXGCHt1J1y<5~J?#HumQ2@| ztrfug`WNBNUo)Su?$HtWVg$++8BW(%GRR+(Vnl9~@#b-+>mU7=EU%CYZ<5Irl3YIr z?5%Enzf8^-q}(Jd;&vo$6Z<+4wyaCx(BCme)~&ZRyKMa@TO%7FyGD>@ryu2f~gcseHP^u8@m?2({FaK(zCS7KE}TUC|Im zXq&q{yZSM^My@!bE_@B=Ew1tX1$Kj6wL{@Ryi$}^jN(XbtCk4cl(6fB0*nYD5f9F? z^e(bBLTu%_0_p^;OY9c8W-HI*zGLt&lo^G}r5`a$E{TJ>bfYlOnPI()1H{m0Z>l52H9RG7_GqpR)VpwlAU=D%>|( zge{3GEvT`Oz#vp8PU-m1m|2;NJOU&Qp@GLB6!0&o1r)}ecK<*IKHM8EJUk%^n!=z zv%pnt)X_vrxti{x*;?F{pq*{2*ate+P^da6vax+urH?QDXp4Z|vWvk>I z+G*wU>UPSvA2nLKKgSfEoO=gjM+<`ANAO=A4V5ipA zbO-&Xb<^-TYN}Aa6pq;!ZB1{nPsvvKDfp60A6T;882TnO;8LM!6}<-%K{M)%6$5_t zbsdCSL7{vwOG_9YNU${YT`i2kZgmBHOTWMhbrYy{phKJ(@y;RRdEWxuzVOdhw22kv z=gx4AMkUGVUG#vXJSfTp3NE!V2N*d; z18ihE@`!`%Itt^wU+<%r=8o2p3g{o$U2;qMO<99*x((EL2B%dv1hyH>w8fli%IDnP z$0q!^+#oPVaEz$>yjAE`#LUH-$2#qv-?J^U0b$TeB@351qo1)mA+@V=+^pm|Vt# zK?Ek$9^FE3z$k~oixQW8cbRRH`vo{!4@YUyi}N7&(CawwWC#*uBUsZ1$P947Yi>Ee zydD39pyioqPz94$nGGR&{evr!D%t|n40%J)8>pGnhKUHqLG9f9YvU4DGau*}@YLy# zS?3XXSd>#Vneqa3y7cQI&;0`=&^uUEL9h0Cpqnb9e?&#|XJ@aMhU3@RsH%oNXlx$v znslM7p-;UeFLZR|j#xICw^d5`b_ literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/MuteConfig.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/MuteConfig.php new file mode 100644 index 000000000000..d96ced9daf41 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/MuteConfig.php @@ -0,0 +1,40 @@ +internalAddGeneratedFile( + ' +³ +0google/cloud/securitycenter/v1/mute_config.protogoogle.cloud.securitycenter.v1google/api/resource.protogoogle/protobuf/timestamp.proto"® + +MuteConfig +name (  + display_name ( B + description (  +filter ( BàA4 + create_time ( 2.google.protobuf.TimestampBàA4 + update_time ( 2.google.protobuf.TimestampBàA +most_recent_editor ( BàA:ÀêA¼ +(securitycenter.googleapis.com/MuteConfig6organizations/{organization}/muteConfigs/{mute_config}*folders/{folder}/muteConfigs/{mute_config},projects/{project}/muteConfigs/{mute_config}Bé +"com.google.cloud.securitycenter.v1BMuteConfigProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Notebook.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Notebook.php new file mode 100644 index 000000000000..4a3e44210f39 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Notebook.php @@ -0,0 +1,33 @@ +internalAddGeneratedFile( + ' +» +-google/cloud/securitycenter/v1/notebook.protogoogle.cloud.securitycenter.v1"x +Notebook +name (  +service (  + last_author ( 8 +notebook_update_time ( 2.google.protobuf.TimestampBç +"com.google.cloud.securitycenter.v1B NotebookProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/NotificationConfig.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/NotificationConfig.php new file mode 100644 index 0000000000000000000000000000000000000000..4d5fdca064de9e62da6c40b2c8f56641ec50929b GIT binary patch literal 1674 zcmbVMT~8B16tx904k%`Qu%ePFnottmT1|`@Ky5)PCPE{G2eYx6&d!!G%gknWwh55_ z6Muov{t93H13vTYgYn7PnQiF@Xs|EcoxS(md(WJER$fN?5x5WQlv9Zn^ZcvZf)(ySilHYOz$d2@wt1!S}Of}4SY>;r0wh7aO zZBA%u30llF_CX{xEvvBCU?XKpv*c~2qjDU2>og{kMM}tq4n?RJ;R>)b}*I z-ZQfd6^~x9Z1Ae@_vhTuVkz}IOZ!{|->-n@|Em&b-e$T+U+%EJ+)icgc7}{2R+d@U zR$vRCCxJ6A6K4iYrphbiV6Jr4xe2EI?B4X%7xL!t8JN*Bij!7TiHMQHM0#3-zpMAa z9s9wxWp&lq)jLw&P2-%qU^b?*!w79+LPWw5MZa<<)t@==c!bB1VaBUD8$z}* zXGdm_-#z@`0%C}yCmsw-q8*PZE&G95(v>*r>6oiIh5YjQ#SAW-V@eG#D7HHbdf44QI bLzH;B*x&Pq)~^Qa?Oba!k=B5^pbNksZoxyS literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/NotificationMessage.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/NotificationMessage.php new file mode 100644 index 0000000000000000000000000000000000000000..da90f1e8f69d040f37bd17468861254da9bb91f7 GIT binary patch literal 1310 zcmbVM%We}f6eZzNFuSmcSX8&AQc{Ud6uQD8AkxrKq&5*$S)h?3$K#n=n%E42EVsZ~BrDdzOP)*f+Ve^!j*X$3 zCHHib2KsgfJ^ybf)wZ)%$C}VtHK8+aKR(z1t@2eeWA1*fphs)$RRdICu``vz=fNbk zalHbS=7SnWTYjc*y=o2~K64w+pSd~teZ0M8n(r4x>bGrob5nD12fZzHm(5M+dOs^@ z*MxRMW3RquKkMgF<>R|d#)7w;wE}rP*(Bm7+^b4Q)6VsSFV*dVjk9Cp>=bc6vhRa4 zZhtQd+&u7Q;internalAddGeneratedFile( + ' + +/google/cloud/securitycenter/v1/org_policy.protogoogle.cloud.securitycenter.v1"Ö + OrgPolicy +name ( :ºêA¶ +orgpolicy.googleapis.com/Policy7organizations/{organization}/policies/{constraint_name}+folders/{folder}/policies/{constraint_name}-projects/{project}/policies/{constraint_name}Bè +"com.google.cloud.securitycenter.v1BOrgPolicyProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/OrganizationSettings.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/OrganizationSettings.php new file mode 100644 index 0000000000000000000000000000000000000000..3dd3636474395a4b644d26642084c472911c9ea1 GIT binary patch literal 1504 zcmb_c-A>yu6kZErn_;NR5JFs3h9S{OTdK0VFgBH@RGFZuR$xDh6s3+6j6xjQ4icbB zdy+lC9%WCk%U$ynbDXxcrQ4)wxk_@*`ObI#zSnP)vjjYYEgWO!3GBn(6%=O}CX5P- zXasv{5MTxoy+}xenGT_8!?t}4o2GTVAwxM$8Nvn(DGeiBMG;N?D#s{gL|h>p3(TsQ zwJK$y7n5sG5E{E23qj(L>naTZv3G%a;vo!Mo&6&$Jl_+Z(^7~|BSUn$6Nt`fZ5IF( zd7MLg47oc11~&l8CrNt|L68fX7QrpTT@n*Pyog-OQukosMI1|@`@TUMql_xd0_+&! z%5#`wX1-eqm95!>LyDcOTe4G*m6aQNkz-y`yGa6V=i1Qu~=49LzbQiDcdHIG6*w=l3MD{>V zy)uH&l5K;Z3&8mIacku~R#&T{Pp*o7S=;ICE~0Tj!nHYRU)-_uKl9LManS2oE_0Zwp#ayv6v4_Y zgZ30G$`wDyNVvr3lK7k?PQfyXQIzuR6fUTb72)Nb5C4sjZVmB|B)p~p5YWiSOp%z& zNNl#jlS!vCShw1Z!;`LMx7{P#Y`Q1yZl~F>4y>kGdZ3lSlCn#K-9G$ODrk$~Ve_Mm zFq@^KaeiA5!Oqk$^9Fkf;kp!%>a2!pH9B^`ym~YK*`JV&;c@T(D1c3g_m_5c3ZLKQ zD>j_7q!7|+ZIbMyJWUc$db`s<#Yb05@iz7Ab swz!dl7=}VIj7b>7IIZ;-lqkO19v$6_Tmi-einternalAddGeneratedFile( + ' +é +,google/cloud/securitycenter/v1/process.protogoogle.cloud.securitycenter.v1"õ +Process +name ( 4 +binary ( 2$.google.cloud.securitycenter.v1.File7 + libraries ( 2$.google.cloud.securitycenter.v1.File4 +script ( 2$.google.cloud.securitycenter.v1.File +args (  +arguments_truncated (J + env_variables ( 23.google.cloud.securitycenter.v1.EnvironmentVariable +env_variables_truncated ( +pid + ( + +parent_pid ("0 +EnvironmentVariable +name (  +val ( Bæ +"com.google.cloud.securitycenter.v1B ProcessProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Resource.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Resource.php new file mode 100644 index 000000000000..cefe60f0d35d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Resource.php @@ -0,0 +1,38 @@ +internalAddGeneratedFile( + ' +Ç +-google/cloud/securitycenter/v1/resource.protogoogle.cloud.securitycenter.v1+google/cloud/securitycenter/v1/folder.proto"Ö +Resource +name (  + display_name (  +type (  +project (  +project_display_name (  +parent (  +parent_display_name ( < +folders ( 2&.google.cloud.securitycenter.v1.FolderBàABç +"com.google.cloud.securitycenter.v1B ResourceProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/RunAssetDiscoveryResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/RunAssetDiscoveryResponse.php new file mode 100644 index 0000000000000000000000000000000000000000..d9bf96aaf436dffaaeb3c0a91ba70638d8c5791f GIT binary patch literal 1217 zcmbu8(QeZ)6oyG*2#lCUC8X_U^2(%j0#bF{xs<7EvZ{!-QIquoMXFNA?JT8nI-qjbMOSb0TNGvoiy3HQEtdhV(0if=lnkZ`}62J0;+nvSGr=$m z;3Sz&35S@?BN`B{Lud?Of8apV=sHL8Xv`9h34$}mW&x?;fF*t{COF|#EHMcM;k8A* z#*=XD#W4|MpT?Li2w#pli6a)qL{GB;5PEaD<6#0j)N!8r0YCZG<*B~+GG!l$kG8Ca15ry7rr+T_h zt8jD*t67Z*-7B&Q1y9KB>=1Gy5*{|vx)oqme7S#7v8c{Sj*X_%b#@@q=pBku0$L0C92x4iU zKW4x3R@uBZV|UHxMO6B4Q_g78xV!PKbl6Fqrl(HRbEmaa3+to$k37I#d$BNM7UD`b r{w^J55QI_+LYo+bM)k?#RKIs8#Sp#8#`=~EwmKk<%;t0jRsj3~XMdK| literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityHealthAnalyticsCustomConfig.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityHealthAnalyticsCustomConfig.php new file mode 100644 index 0000000000000000000000000000000000000000..8a74b618fbc99a59094d92d3e0e001a65d0aad54 GIT binary patch literal 1709 zcmb_c-EI>{6vj>n&VeGcMaarUG=xYPXg6{YHyZ*<9LF(Au)!u2w34+RA3GzhcSf_b z5eDU^FHrFs-1jB=C_Du-v+KoaidrgsWgnmUzVG~fkDrPY0e46fBb0%{AsI}GIzb{N zSDf;Y43g0ZC82yGScuXkWUo!0w|k_q*XrHYPh*})iXItrJ`Qn%hCCT=#7Gm#)RbbR zP;Q*o@<{&#gHWCHgD426iqW`FlUVUdpYmwL#;zp>h=K{mBA`f`o!ui;!7xyP-?SWl z-EjEba~%G0Z3}>gK^&9WKL?g-XU0^wM0LvpAAsnONCqLJBvyfzLe^Q_XAx5@2-$nx zi)}Ir!WcE~#oSR6QN?&f%!77Bv3ifBm?n2!aNWCYGE>|!?bNOGTc#gckiUm9l}sou zJ37_##;Eckm`L?rMr+{Mh*VRJo_9gyHc>Lcd3Hi1szgRxR<{8-%fI>m(9hmfpx<~W zr00FD=Idiy%&$*aCVgi(%$4rzov7y6hUqT+QG&xCxeU%~isstYa?h`pdsLoWg&6MsNU#GffTA&H*dHZh|;yXrdFp1KV_@O6D1N=Dca2KS>`wB+inW1zu5T^;H7*ElhRb^2FUf+E5T~fQ*W9MhMI?T3D zFL33u##(l6!F7rH$|o4*7=fMPvhx7Sr$LxtANBY!j*ZB4W*4Wsav#bUI%sRmW@GjsmA<_8 z0!n#vDsZ#gIBvXb_1^SfJ@0lJ_11o?u~)vN#gytg+^X*!mJ3b^77tp@gL2UUSUS>X z`0A*<;9P-)!}ja);_mN7SkvA7m!9la|ASRo@8}fXK1&yJb_{&7G3L3gW=0zbHs`fz zPz<)t-;5Z1Dy}xImAckS-IY&@n3_W3MkAx%t-JBPS;IK)n;JG={5Q=TP0weW=VNl2T1$g`lC zQa?+WIQD5IXwp2|D*t#>N{L(yRR_Zw#0A;CotUCTRRB(AxTqQoIF=hc7fDZKnDs3y+atDI2(n`$EhF?3ck-$ zk3~!{60*0z#V#I`Fs0!4W7}~S`GWBX%L|8*Pa6-h_9<=e#~irZ#YMz@NheV0b|oJW zklUfDpRic)qz|T+HKC#`g8b8Xn8QkUY>XQ^M$7sr$XzUwj4q;MoKTS^(T<8+I+&Ml z?iqaAF?07A4TBb)k|V|w%leSj2PfxUeMxf-EPd;o0+uB`vv6%5joD=R&`QpS474Q3 zEI#|Ls?~STSY8=B2+Bh2f#e${b&|*j=#Mq@;&W=1Q zurvbsCXTNM|r7JgIP6zXB&;ZV$}=XT@A14$~=p52S1330lo!7$nq_ znbofX((3j`fmEbzmU@w)*Ni$^g{dMu8ZhYA`bv>h%^0Cu1UetaSCWsf`Zaahg?spGqFFN{@mO2DB Ri~roEuPpUyo})QJ{{i`GdT0Ou literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityMarks.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityMarks.php new file mode 100644 index 000000000000..a095177909fe --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityMarks.php @@ -0,0 +1,37 @@ +internalAddGeneratedFile( + ' + +3google/cloud/securitycenter/v1/security_marks.protogoogle.cloud.securitycenter.v1"Õ + SecurityMarks +name ( G +marks ( 28.google.cloud.securitycenter.v1.SecurityMarks.MarksEntry +canonical_name ( , + +MarksEntry +key (  +value ( :8:¦êA¢ ++securitycenter.googleapis.com/SecurityMarks9organizations/{organization}/assets/{asset}/securityMarksNorganizations/{organization}/sources/{source}/findings/{finding}/securityMarks-folders/{folder}/assets/{asset}/securityMarks/projects/{project}/assets/{asset}/securityMarksBfolders/{folder}/sources/{source}/findings/{finding}/securityMarksDprojects/{project}/sources/{source}/findings/{finding}/securityMarksBØ +"com.google.cloud.securitycenter.v1PZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityPosture.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityPosture.php new file mode 100644 index 000000000000..2e64f8687ba6 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityPosture.php @@ -0,0 +1,41 @@ +internalAddGeneratedFile( + ' +» +5google/cloud/securitycenter/v1/security_posture.protogoogle.cloud.securitycenter.v1"è +SecurityPosture +name (  + revision_id ( # +posture_deployment_resource (  +posture_deployment (  +changed_policy (  + +policy_set (  +policy ( ` +policy_drift_details ( 2B.google.cloud.securitycenter.v1.SecurityPosture.PolicyDriftDetailsS +PolicyDriftDetails +field (  +expected_value (  +detected_value ( Bî +"com.google.cloud.securitycenter.v1BSecurityPostureProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecuritycenterService.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecuritycenterService.php new file mode 100644 index 000000000000..eebef284d6ba --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecuritycenterService.php @@ -0,0 +1,383 @@ +internalAddGeneratedFile( + ' +ŒÖ +;google/cloud/securitycenter/v1/securitycenter_service.protogoogle.cloud.securitycenter.v1google/api/client.protogoogle/api/field_behavior.protogoogle/api/resource.proto*google/cloud/securitycenter/v1/asset.proto4google/cloud/securitycenter/v1/bigquery_export.protoVgoogle/cloud/securitycenter/v1/effective_security_health_analytics_custom_module.proto4google/cloud/securitycenter/v1/external_system.proto,google/cloud/securitycenter/v1/finding.proto+google/cloud/securitycenter/v1/folder.proto0google/cloud/securitycenter/v1/mute_config.proto8google/cloud/securitycenter/v1/notification_config.proto:google/cloud/securitycenter/v1/organization_settings.protoAgoogle/cloud/securitycenter/v1/run_asset_discovery_response.protoLgoogle/cloud/securitycenter/v1/security_health_analytics_custom_config.protoLgoogle/cloud/securitycenter/v1/security_health_analytics_custom_module.proto3google/cloud/securitycenter/v1/security_marks.proto+google/cloud/securitycenter/v1/source.protogoogle/iam/v1/iam_policy.protogoogle/iam/v1/policy.proto#google/longrunning/operations.protogoogle/protobuf/duration.protogoogle/protobuf/empty.proto google/protobuf/field_mask.protogoogle/protobuf/struct.protogoogle/protobuf/timestamp.protogoogle/rpc/status.proto"a +BulkMuteFindingsRequest +parent ( B àAúA +* +filter (  +mute_annotation ( B" +BulkMuteFindingsResponse"¬ +CreateFindingRequest< +parent ( B,àAúA& +$securitycenter.googleapis.com/Source + +finding_id ( BàA= +finding ( 2\'.google.cloud.securitycenter.v1.FindingBàA"¾ +CreateMuteConfigRequest@ +parent ( B0àAúA*(securitycenter.googleapis.com/MuteConfigD + mute_config ( 2*.google.cloud.securitycenter.v1.MuteConfigBàA +mute_config_id ( BàA"Ù +CreateNotificationConfigRequestH +parent ( B8àAúA20securitycenter.googleapis.com/NotificationConfig + config_id ( BàAT +notification_config ( 22.google.cloud.securitycenter.v1.NotificationConfigBàA"ˆ +0CreateSecurityHealthAnalyticsCustomModuleRequestY +parent ( BIàAúACAsecuritycenter.googleapis.com/SecurityHealthAnalyticsCustomModuley +\'security_health_analytics_custom_module ( 2C.google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModuleBàA"œ +CreateSourceRequestH +parent ( B8àAúA2 +0cloudresourcemanager.googleapis.com/Organization; +source ( 2&.google.cloud.securitycenter.v1.SourceBàA"Y +DeleteMuteConfigRequest> +name ( B0àAúA* +(securitycenter.googleapis.com/MuteConfig"i +DeleteNotificationConfigRequestF +name ( B8àAúA2 +0securitycenter.googleapis.com/NotificationConfig"‹ +0DeleteSecurityHealthAnalyticsCustomModuleRequestW +name ( BIàAúAC +Asecuritycenter.googleapis.com/SecurityHealthAnalyticsCustomModule"^ +GetBigQueryExportRequestB +name ( B4àAúA. +,securitycenter.googleapis.com/BigQueryExport"V +GetMuteConfigRequest> +name ( B0àAúA* +(securitycenter.googleapis.com/MuteConfig"f +GetNotificationConfigRequestF +name ( B8àAúA2 +0securitycenter.googleapis.com/NotificationConfig"j +GetOrganizationSettingsRequestH +name ( B:àAúA4 +2securitycenter.googleapis.com/OrganizationSettings"š +6GetEffectiveSecurityHealthAnalyticsCustomModuleRequest` +name ( BRàAúAL +Jsecuritycenter.googleapis.com/EffectiveSecurityHealthAnalyticsCustomModule"ˆ +-GetSecurityHealthAnalyticsCustomModuleRequestW +name ( BIàAúAC +Asecuritycenter.googleapis.com/SecurityHealthAnalyticsCustomModule"N +GetSourceRequest: +name ( B,àAúA& +$securitycenter.googleapis.com/Source"ƒ +GroupAssetsRequest; +parent ( B+àAúA%#securitycenter.googleapis.com/Asset +filter (  +group_by ( BàA3 +compare_duration ( 2.google.protobuf.Duration- + read_time ( 2.google.protobuf.Timestamp + +page_token (  + page_size ("¸ +GroupAssetsResponseE +group_by_results ( 2+.google.cloud.securitycenter.v1.GroupResult- + read_time ( 2.google.protobuf.Timestamp +next_page_token (  + +total_size ("† +GroupFindingsRequest< +parent ( B,àAúA& +$securitycenter.googleapis.com/Source +filter (  +group_by ( BàA- + read_time ( 2.google.protobuf.Timestamp3 +compare_duration ( 2.google.protobuf.Duration + +page_token (  + page_size ("º +GroupFindingsResponseE +group_by_results ( 2+.google.cloud.securitycenter.v1.GroupResult- + read_time ( 2.google.protobuf.Timestamp +next_page_token (  + +total_size ("¸ + GroupResultO + +properties ( 2;.google.cloud.securitycenter.v1.GroupResult.PropertiesEntry +count (I +PropertiesEntry +key ( % +value ( 2.google.protobuf.Value:8"½ +9ListDescendantSecurityHealthAnalyticsCustomModulesRequestY +parent ( BIàAúACAsecuritycenter.googleapis.com/SecurityHealthAnalyticsCustomModule + page_size ( + +page_token ( "Ì +:ListDescendantSecurityHealthAnalyticsCustomModulesResponseu +(security_health_analytics_custom_modules ( 2C.google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule +next_page_token ( " +ListMuteConfigsRequest@ +parent ( B0àAúA*(securitycenter.googleapis.com/MuteConfig + page_size ( + +page_token ( "t +ListMuteConfigsResponse@ + mute_configs ( 2*.google.cloud.securitycenter.v1.MuteConfig +next_page_token ( "‘ +ListNotificationConfigsRequestH +parent ( B8àAúA20securitycenter.googleapis.com/NotificationConfig + +page_token (  + page_size ("Œ +ListNotificationConfigsResponseP +notification_configs ( 22.google.cloud.securitycenter.v1.NotificationConfig +next_page_token ( "¼ +8ListEffectiveSecurityHealthAnalyticsCustomModulesRequestY +parent ( BIàAúACAsecuritycenter.googleapis.com/SecurityHealthAnalyticsCustomModule + page_size ( + +page_token ( "ß +9ListEffectiveSecurityHealthAnalyticsCustomModulesResponseˆ +2effective_security_health_analytics_custom_modules ( 2L.google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule +next_page_token ( "³ +/ListSecurityHealthAnalyticsCustomModulesRequestY +parent ( BIàAúACAsecuritycenter.googleapis.com/SecurityHealthAnalyticsCustomModule + page_size ( + +page_token ( " +0ListSecurityHealthAnalyticsCustomModulesResponseu +(security_health_analytics_custom_modules ( 2C.google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule +next_page_token ( "y +ListSourcesRequest< +parent ( B,àAúA&$securitycenter.googleapis.com/Source + +page_token (  + page_size ("g +ListSourcesResponse7 +sources ( 2&.google.cloud.securitycenter.v1.Source +next_page_token ( "­ +ListAssetsRequest; +parent ( B+àAúA%#securitycenter.googleapis.com/Asset +filter (  +order_by ( - + read_time ( 2.google.protobuf.Timestamp3 +compare_duration ( 2.google.protobuf.Duration. + +field_mask ( 2.google.protobuf.FieldMask + +page_token (  + page_size ("à +ListAssetsResponse` +list_assets_results ( 2C.google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult- + read_time ( 2.google.protobuf.Timestamp +next_page_token (  + +total_size (î +ListAssetsResult4 +asset ( 2%.google.cloud.securitycenter.v1.Assete + state_change (2O.google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult.StateChange"= + StateChange + +UNUSED +ADDED +REMOVED + +ACTIVE"° +ListFindingsRequest< +parent ( B,àAúA& +$securitycenter.googleapis.com/Source +filter (  +order_by ( - + read_time ( 2.google.protobuf.Timestamp3 +compare_duration ( 2.google.protobuf.Duration. + +field_mask ( 2.google.protobuf.FieldMask + +page_token (  + page_size ("¬ +ListFindingsResponsef +list_findings_results ( 2G.google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult- + read_time ( 2.google.protobuf.Timestamp +next_page_token (  + +total_size (Ï +ListFindingsResult8 +finding ( 2\'.google.cloud.securitycenter.v1.Findingi + state_change (2S.google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.StateChangeg +resource ( 2P.google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.ResourceBàAÛ +Resource +name (  + display_name (  +type (  + project_name (  +project_display_name (  + parent_name (  +parent_display_name ( 7 +folders ( 2&.google.cloud.securitycenter.v1.Folder"M + StateChange + +UNUSED +CHANGED + UNCHANGED +ADDED +REMOVED"Í +SetFindingStateRequest; +name ( B-àAúA\' +%securitycenter.googleapis.com/FindingA +state (2-.google.cloud.securitycenter.v1.Finding.StateBàA3 + +start_time ( 2.google.protobuf.TimestampBàA"Ž +SetMuteRequest; +name ( B-àAúA\' +%securitycenter.googleapis.com/Finding? +mute (2,.google.cloud.securitycenter.v1.Finding.MuteBàA"d +RunAssetDiscoveryRequestH +parent ( B8àAúA2 +0cloudresourcemanager.googleapis.com/Organization"¬ +2SimulateSecurityHealthAnalyticsCustomModuleRequest +parent ( BàAH + custom_config ( 2,.google.cloud.securitycenter.v1.CustomConfigBàA{ +resource ( 2d.google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleRequest.SimulatedResourceBàA™ +SimulatedResource + resource_type ( BàA3 + resource_data ( 2.google.protobuf.StructBàA3 +iam_policy_data ( 2.google.iam.v1.PolicyBàA"Ù +3SimulateSecurityHealthAnalyticsCustomModuleResponses +result ( 2c.google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleResponse.SimulatedResult¬ +SimulatedResult: +finding ( 2\'.google.cloud.securitycenter.v1.FindingH. + no_violation ( 2.google.protobuf.EmptyH# +error ( 2.google.rpc.StatusHB +result"œ +UpdateExternalSystemRequestL +external_system ( 2..google.cloud.securitycenter.v1.ExternalSystemBàA/ + update_mask ( 2.google.protobuf.FieldMask"† +UpdateFindingRequest= +finding ( 2\'.google.cloud.securitycenter.v1.FindingBàA/ + update_mask ( 2.google.protobuf.FieldMask" +UpdateMuteConfigRequestD + mute_config ( 2*.google.cloud.securitycenter.v1.MuteConfigBàA/ + update_mask ( 2.google.protobuf.FieldMask"¨ +UpdateNotificationConfigRequestT +notification_config ( 22.google.cloud.securitycenter.v1.NotificationConfigBàA/ + update_mask ( 2.google.protobuf.FieldMask"® +!UpdateOrganizationSettingsRequestX +organization_settings ( 24.google.cloud.securitycenter.v1.OrganizationSettingsBàA/ + update_mask ( 2.google.protobuf.FieldMask"Þ +0UpdateSecurityHealthAnalyticsCustomModuleRequesty +\'security_health_analytics_custom_module ( 2C.google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModuleBàA/ + update_mask ( 2.google.protobuf.FieldMask"ƒ +UpdateSourceRequest; +source ( 2&.google.cloud.securitycenter.v1.SourceBàA/ + update_mask ( 2.google.protobuf.FieldMask"É +UpdateSecurityMarksRequestJ +security_marks ( 2-.google.cloud.securitycenter.v1.SecurityMarksBàA/ + update_mask ( 2.google.protobuf.FieldMask. + +start_time ( 2.google.protobuf.Timestamp"Ô +CreateBigQueryExportRequestD +parent ( B4àAúA.,securitycenter.googleapis.com/BigQueryExportM +big_query_export ( 2..google.cloud.securitycenter.v1.BigQueryExportBàA +big_query_export_id ( BàA" +UpdateBigQueryExportRequestM +big_query_export ( 2..google.cloud.securitycenter.v1.BigQueryExportBàA/ + update_mask ( 2.google.protobuf.FieldMask"‰ +ListBigQueryExportsRequestD +parent ( B4àAúA.,securitycenter.googleapis.com/BigQueryExport + page_size ( + +page_token ( " +ListBigQueryExportsResponseI +big_query_exports ( 2..google.cloud.securitycenter.v1.BigQueryExport +next_page_token ( "a +DeleteBigQueryExportRequestB +name ( B4àAúA. +,securitycenter.googleapis.com/BigQueryExport2x +SecurityCenterâ +BulkMuteFindings7.google.cloud.securitycenter.v1.BulkMuteFindingsRequest.google.longrunning.Operation"õÊAP +7google.cloud.securitycenter.v1.BulkMuteFindingsResponsegoogle.protobuf.EmptyÚAparent‚Óä“’"./v1/{parent=organizations/*}/findings:bulkMute:*Z-"(/v1/{parent=folders/*}/findings:bulkMute:*Z.")/v1/{parent=projects/*}/findings:bulkMute:*Õ +)CreateSecurityHealthAnalyticsCustomModuleP.google.cloud.securitycenter.v1.CreateSecurityHealthAnalyticsCustomModuleRequestC.google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule"ÚA.parent,security_health_analytics_custom_module‚Óä“Ø"J/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/customModules:\'security_health_analytics_custom_moduleZo"D/v1/{parent=folders/*/securityHealthAnalyticsSettings}/customModules:\'security_health_analytics_custom_moduleZp"E/v1/{parent=projects/*/securityHealthAnalyticsSettings}/customModules:\'security_health_analytics_custom_module± + CreateSource3.google.cloud.securitycenter.v1.CreateSourceRequest&.google.cloud.securitycenter.v1.Source"DÚA parent,source‚Óä“."$/v1/{parent=organizations/*}/sources:sourceÌ + CreateFinding4.google.cloud.securitycenter.v1.CreateFindingRequest\'.google.cloud.securitycenter.v1.Finding"\\ÚAparent,finding_id,finding‚Óä“:"//v1/{parent=organizations/*/sources/*}/findings:findingØ +CreateMuteConfig7.google.cloud.securitycenter.v1.CreateMuteConfigRequest*.google.cloud.securitycenter.v1.MuteConfig"ÞÚAparent,mute_configÚA!parent,mute_config,mute_config_id‚Óä“ž"(/v1/{parent=organizations/*}/muteConfigs: mute_configZ1""/v1/{parent=folders/*}/muteConfigs: mute_configZ2"#/v1/{parent=projects/*}/muteConfigs: mute_config« +CreateNotificationConfig?.google.cloud.securitycenter.v1.CreateNotificationConfigRequest2.google.cloud.securitycenter.v1.NotificationConfig"™ÚA$parent,config_id,notification_configÚAparent,notification_config‚Óä“Î"0/v1/{parent=organizations/*}/notificationConfigs:notification_configZA"*/v1/{parent=folders/*}/notificationConfigs:notification_configZB"+/v1/{parent=projects/*}/notificationConfigs:notification_configê +DeleteMuteConfig7.google.cloud.securitycenter.v1.DeleteMuteConfigRequest.google.protobuf.Empty"„ÚAname‚Óä“w*(/v1/{name=organizations/*/muteConfigs/*}Z$*"/v1/{name=folders/*/muteConfigs/*}Z%*#/v1/{name=projects/*/muteConfigs/*}“ +DeleteNotificationConfig?.google.cloud.securitycenter.v1.DeleteNotificationConfigRequest.google.protobuf.Empty"ÚAname‚Óä“*0/v1/{name=organizations/*/notificationConfigs/*}Z,**/v1/{name=folders/*/notificationConfigs/*}Z-*+/v1/{name=projects/*/notificationConfigs/*}ƒ +)DeleteSecurityHealthAnalyticsCustomModuleP.google.cloud.securitycenter.v1.DeleteSecurityHealthAnalyticsCustomModuleRequest.google.protobuf.Empty"ëÚAname‚Óä“Ý*J/v1/{name=organizations/*/securityHealthAnalyticsSettings/customModules/*}ZF*D/v1/{name=folders/*/securityHealthAnalyticsSettings/customModules/*}ZG*E/v1/{name=projects/*/securityHealthAnalyticsSettings/customModules/*}‘ +GetBigQueryExport8.google.cloud.securitycenter.v1.GetBigQueryExportRequest..google.cloud.securitycenter.v1.BigQueryExport"‘ÚAname‚Ó䓃,/v1/{name=organizations/*/bigQueryExports/*}Z(&/v1/{name=folders/*/bigQueryExports/*}Z)\'/v1/{name=projects/*/bigQueryExports/*}– + GetIamPolicy".google.iam.v1.GetIamPolicyRequest.google.iam.v1.Policy"KÚAresource‚Óä“:"5/v1/{resource=organizations/*/sources/*}:getIamPolicy:*ø + GetMuteConfig4.google.cloud.securitycenter.v1.GetMuteConfigRequest*.google.cloud.securitycenter.v1.MuteConfig"„ÚAname‚Óä“w(/v1/{name=organizations/*/muteConfigs/*}Z$"/v1/{name=folders/*/muteConfigs/*}Z%#/v1/{name=projects/*/muteConfigs/*}© +GetNotificationConfig<.google.cloud.securitycenter.v1.GetNotificationConfigRequest2.google.cloud.securitycenter.v1.NotificationConfig"ÚAname‚Óä“0/v1/{name=organizations/*/notificationConfigs/*}Z,*/v1/{name=folders/*/notificationConfigs/*}Z-+/v1/{name=projects/*/notificationConfigs/*}Ï +GetOrganizationSettings>.google.cloud.securitycenter.v1.GetOrganizationSettingsRequest4.google.cloud.securitycenter.v1.OrganizationSettings">ÚAname‚Óä“1//v1/{name=organizations/*/organizationSettings}à +/GetEffectiveSecurityHealthAnalyticsCustomModuleV.google.cloud.securitycenter.v1.GetEffectiveSecurityHealthAnalyticsCustomModuleRequestL.google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule"†ÚAname‚Óä“øS/v1/{name=organizations/*/securityHealthAnalyticsSettings/effectiveCustomModules/*}ZOM/v1/{name=folders/*/securityHealthAnalyticsSettings/effectiveCustomModules/*}ZPN/v1/{name=projects/*/securityHealthAnalyticsSettings/effectiveCustomModules/*}ª +&GetSecurityHealthAnalyticsCustomModuleM.google.cloud.securitycenter.v1.GetSecurityHealthAnalyticsCustomModuleRequestC.google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule"ëÚAname‚Óä“ÝJ/v1/{name=organizations/*/securityHealthAnalyticsSettings/customModules/*}ZFD/v1/{name=folders/*/securityHealthAnalyticsSettings/customModules/*}ZGE/v1/{name=projects/*/securityHealthAnalyticsSettings/customModules/*}š + GetSource0.google.cloud.securitycenter.v1.GetSourceRequest&.google.cloud.securitycenter.v1.Source"3ÚAname‚Óä“&$/v1/{name=organizations/*/sources/*}† + GroupAssets2.google.cloud.securitycenter.v1.GroupAssetsRequest3.google.cloud.securitycenter.v1.GroupAssetsResponse"ˆ‚Ó䓃")/v1/{parent=organizations/*}/assets:group:*Z("#/v1/{parent=folders/*}/assets:group:*Z)"$/v1/{parent=projects/*}/assets:group:*¿ + GroupFindings4.google.cloud.securitycenter.v1.GroupFindingsRequest5.google.cloud.securitycenter.v1.GroupFindingsResponse"ÀÚAparent,group_by‚Ó䓧"5/v1/{parent=organizations/*/sources/*}/findings:group:*Z4"//v1/{parent=folders/*/sources/*}/findings:group:*Z5"0/v1/{parent=projects/*/sources/*}/findings:group:*æ + +ListAssets1.google.cloud.securitycenter.v1.ListAssetsRequest2.google.cloud.securitycenter.v1.ListAssetsResponse"qˆ‚Óä“h#/v1/{parent=organizations/*}/assetsZ/v1/{parent=folders/*}/assetsZ /v1/{parent=projects/*}/assetsˆ +2ListDescendantSecurityHealthAnalyticsCustomModulesY.google.cloud.securitycenter.v1.ListDescendantSecurityHealthAnalyticsCustomModulesRequestZ.google.cloud.securitycenter.v1.ListDescendantSecurityHealthAnalyticsCustomModulesResponse"šÚAparent‚Óä“ŠY/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/customModules:listDescendantZUS/v1/{parent=folders/*/securityHealthAnalyticsSettings}/customModules:listDescendantZVT/v1/{parent=projects/*/securityHealthAnalyticsSettings}/customModules:listDescendant + ListFindings3.google.cloud.securitycenter.v1.ListFindingsRequest4.google.cloud.securitycenter.v1.ListFindingsResponse"“‚Óä“Œ//v1/{parent=organizations/*/sources/*}/findingsZ+)/v1/{parent=folders/*/sources/*}/findingsZ,*/v1/{parent=projects/*/sources/*}/findings‹ +ListMuteConfigs6.google.cloud.securitycenter.v1.ListMuteConfigsRequest7.google.cloud.securitycenter.v1.ListMuteConfigsResponse"†ÚAparent‚Óä“w(/v1/{parent=organizations/*}/muteConfigsZ$"/v1/{parent=folders/*}/muteConfigsZ%#/v1/{parent=projects/*}/muteConfigs¼ +ListNotificationConfigs>.google.cloud.securitycenter.v1.ListNotificationConfigsRequest?.google.cloud.securitycenter.v1.ListNotificationConfigsResponse"ŸÚAparent‚Óä“0/v1/{parent=organizations/*}/notificationConfigsZ,*/v1/{parent=folders/*}/notificationConfigsZ-+/v1/{parent=projects/*}/notificationConfigsó +1ListEffectiveSecurityHealthAnalyticsCustomModulesX.google.cloud.securitycenter.v1.ListEffectiveSecurityHealthAnalyticsCustomModulesRequestY.google.cloud.securitycenter.v1.ListEffectiveSecurityHealthAnalyticsCustomModulesResponse"ˆÚAparent‚Óä“øS/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/effectiveCustomModulesZOM/v1/{parent=folders/*/securityHealthAnalyticsSettings}/effectiveCustomModulesZPN/v1/{parent=projects/*/securityHealthAnalyticsSettings}/effectiveCustomModules½ +(ListSecurityHealthAnalyticsCustomModulesO.google.cloud.securitycenter.v1.ListSecurityHealthAnalyticsCustomModulesRequestP.google.cloud.securitycenter.v1.ListSecurityHealthAnalyticsCustomModulesResponse"íÚAparent‚Óä“ÝJ/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/customModulesZFD/v1/{parent=folders/*/securityHealthAnalyticsSettings}/customModulesZGE/v1/{parent=projects/*/securityHealthAnalyticsSettings}/customModulesò + ListSources2.google.cloud.securitycenter.v1.ListSourcesRequest3.google.cloud.securitycenter.v1.ListSourcesResponse"zÚAparent‚Óä“k$/v1/{parent=organizations/*}/sourcesZ /v1/{parent=folders/*}/sourcesZ!/v1/{parent=projects/*}/sourcesŠ +RunAssetDiscovery8.google.cloud.securitycenter.v1.RunAssetDiscoveryRequest.google.longrunning.Operation"›ˆÊAQ +8google.cloud.securitycenter.v1.RunAssetDiscoveryResponsegoogle.protobuf.EmptyÚAparent‚Óä“5"0/v1/{parent=organizations/*}/assets:runDiscovery:*Ä +SetFindingState6.google.cloud.securitycenter.v1.SetFindingStateRequest\'.google.cloud.securitycenter.v1.Finding"ÏÚAname,state,start_time‚Óä“°"8/v1/{name=organizations/*/sources/*/findings/*}:setState:*Z7"2/v1/{name=folders/*/sources/*/findings/*}:setState:*Z8"3/v1/{name=projects/*/sources/*/findings/*}:setState:*¥ +SetMute..google.cloud.securitycenter.v1.SetMuteRequest\'.google.cloud.securitycenter.v1.Finding"ÀÚA name,mute‚Óä“­"7/v1/{name=organizations/*/sources/*/findings/*}:setMute:*Z6"1/v1/{name=folders/*/sources/*/findings/*}:setMute:*Z7"2/v1/{name=projects/*/sources/*/findings/*}:setMute:* + SetIamPolicy".google.iam.v1.SetIamPolicyRequest.google.iam.v1.Policy"RÚAresource,policy‚Óä“:"5/v1/{resource=organizations/*/sources/*}:setIamPolicy:*È +TestIamPermissions(.google.iam.v1.TestIamPermissionsRequest).google.iam.v1.TestIamPermissionsResponse"]ÚAresource,permissions‚Óä“@";/v1/{resource=organizations/*/sources/*}:testIamPermissions:* ++SimulateSecurityHealthAnalyticsCustomModuleR.google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleRequestS.google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleResponse"¨ÚAparent,custom_config,resource‚Óä“"S/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/customModules:simulate:*ZR"M/v1/{parent=folders/*/securityHealthAnalyticsSettings}/customModules:simulate:*ZS"N/v1/{parent=projects/*/securityHealthAnalyticsSettings}/customModules:simulate:*Ð +UpdateExternalSystem;.google.cloud.securitycenter.v1.UpdateExternalSystemRequest..google.cloud.securitycenter.v1.ExternalSystem"ÊÚAexternal_system,update_mask‚Óä“¥2Q/v1/{external_system.name=organizations/*/sources/*/findings/*/externalSystems/*}:external_systemZ^2K/v1/{external_system.name=folders/*/sources/*/findings/*/externalSystems/*}:external_systemZ_2L/v1/{external_system.name=projects/*/sources/*/findings/*/externalSystems/*}:external_systemÁ + UpdateFinding4.google.cloud.securitycenter.v1.UpdateFindingRequest\'.google.cloud.securitycenter.v1.Finding"ÐÚAfinding‚Óä“¿27/v1/{finding.name=organizations/*/sources/*/findings/*}:findingZ<21/v1/{finding.name=folders/*/sources/*/findings/*}:findingZ=22/v1/{finding.name=projects/*/sources/*/findings/*}:findingÝ +UpdateMuteConfig7.google.cloud.securitycenter.v1.UpdateMuteConfigRequest*.google.cloud.securitycenter.v1.MuteConfig"ãÚAmute_config,update_mask‚Óä“Â24/v1/{mute_config.name=organizations/*/muteConfigs/*}: mute_configZ=2./v1/{mute_config.name=folders/*/muteConfigs/*}: mute_configZ>2//v1/{mute_config.name=projects/*/muteConfigs/*}: mute_configÛ +UpdateNotificationConfig?.google.cloud.securitycenter.v1.UpdateNotificationConfigRequest2.google.cloud.securitycenter.v1.NotificationConfig"ÉÚAnotification_configÚAnotification_config,update_mask‚Óä“Š2D/v1/{notification_config.name=organizations/*/notificationConfigs/*}:notification_configZU2>/v1/{notification_config.name=folders/*/notificationConfigs/*}:notification_configZV2?/v1/{notification_config.name=projects/*/notificationConfigs/*}:notification_config“ +UpdateOrganizationSettingsA.google.cloud.securitycenter.v1.UpdateOrganizationSettingsRequest4.google.cloud.securitycenter.v1.OrganizationSettings"|ÚAorganization_settings‚Óä“^2E/v1/{organization_settings.name=organizations/*/organizationSettings}:organization_settingsÔ +)UpdateSecurityHealthAnalyticsCustomModuleP.google.cloud.securitycenter.v1.UpdateSecurityHealthAnalyticsCustomModuleRequestC.google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule"ÚA3security_health_analytics_custom_module,update_mask‚Óä“Ò2r/v1/{security_health_analytics_custom_module.name=organizations/*/securityHealthAnalyticsSettings/customModules/*}:\'security_health_analytics_custom_moduleZ—2l/v1/{security_health_analytics_custom_module.name=folders/*/securityHealthAnalyticsSettings/customModules/*}:\'security_health_analytics_custom_moduleZ˜2m/v1/{security_health_analytics_custom_module.name=projects/*/securityHealthAnalyticsSettings/customModules/*}:\'security_health_analytics_custom_module± + UpdateSource3.google.cloud.securitycenter.v1.UpdateSourceRequest&.google.cloud.securitycenter.v1.Source"DÚAsource‚Óä“52+/v1/{source.name=organizations/*/sources/*}:sourceŸ +UpdateSecurityMarks:.google.cloud.securitycenter.v1.UpdateSecurityMarksRequest-.google.cloud.securitycenter.v1.SecurityMarks"œÚAsecurity_marks‚Óä“„2@/v1/{security_marks.name=organizations/*/assets/*/securityMarks}:security_marksZL2:/v1/{security_marks.name=folders/*/assets/*/securityMarks}:security_marksZM2;/v1/{security_marks.name=projects/*/assets/*/securityMarks}:security_marksZ^2L/v1/{security_marks.name=organizations/*/sources/*/findings/*/securityMarks}:security_marksZX2F/v1/{security_marks.name=folders/*/sources/*/findings/*/securityMarks}:security_marksZY2G/v1/{security_marks.name=projects/*/sources/*/findings/*/securityMarks}:security_marksô +CreateBigQueryExport;.google.cloud.securitycenter.v1.CreateBigQueryExportRequest..google.cloud.securitycenter.v1.BigQueryExport"îÚA+parent,big_query_export,big_query_export_id‚Ó䓹",/v1/{parent=organizations/*}/bigQueryExports:big_query_exportZ:"&/v1/{parent=folders/*}/bigQueryExports:big_query_exportZ;"\'/v1/{parent=projects/*}/bigQueryExports:big_query_exportÿ +DeleteBigQueryExport;.google.cloud.securitycenter.v1.DeleteBigQueryExportRequest.google.protobuf.Empty"‘ÚAname‚Ó䓃*,/v1/{name=organizations/*/bigQueryExports/*}Z(*&/v1/{name=folders/*/bigQueryExports/*}Z)*\'/v1/{name=projects/*/bigQueryExports/*}˜ +UpdateBigQueryExport;.google.cloud.securitycenter.v1.UpdateBigQueryExportRequest..google.cloud.securitycenter.v1.BigQueryExport"’ÚAbig_query_export,update_mask‚Óä“ì2=/v1/{big_query_export.name=organizations/*/bigQueryExports/*}:big_query_exportZK27/v1/{big_query_export.name=folders/*/bigQueryExports/*}:big_query_exportZL28/v1/{big_query_export.name=projects/*/bigQueryExports/*}:big_query_export¤ +ListBigQueryExports:.google.cloud.securitycenter.v1.ListBigQueryExportsRequest;.google.cloud.securitycenter.v1.ListBigQueryExportsResponse"“ÚAparent‚Ó䓃,/v1/{parent=organizations/*}/bigQueryExportsZ(&/v1/{parent=folders/*}/bigQueryExportsZ)\'/v1/{parent=projects/*}/bigQueryExportsQÊAsecuritycenter.googleapis.comÒA.https://www.googleapis.com/auth/cloud-platformBØ +"com.google.cloud.securitycenter.v1PZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Source.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Source.php new file mode 100644 index 000000000000..86db591f38be --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Source.php @@ -0,0 +1,34 @@ +internalAddGeneratedFile( + ' +° ++google/cloud/securitycenter/v1/source.protogoogle.cloud.securitycenter.v1"ý +Source +name (  + display_name (  + description (  +canonical_name ( :¡êA +$securitycenter.googleapis.com/Source-organizations/{organization}/sources/{source}!folders/{folder}/sources/{source}#projects/{project}/sources/{source}BØ +"com.google.cloud.securitycenter.v1PZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ToxicCombination.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ToxicCombination.php new file mode 100644 index 000000000000..c95a4ce1508d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ToxicCombination.php @@ -0,0 +1,30 @@ +internalAddGeneratedFile( + ' +Ÿ +6google/cloud/securitycenter/v1/toxic_combination.protogoogle.cloud.securitycenter.v1"K +ToxicCombination +attack_exposure_score ( +related_findings ( Bï +"com.google.cloud.securitycenter.v1BToxicCombinationProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Vulnerability.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Vulnerability.php new file mode 100644 index 0000000000000000000000000000000000000000..96d54a80edd1311126fe443b7847161f0778b4d4 GIT binary patch literal 3436 zcmbVP-BR0D5Uy>0mp>x{andvuPTG)}!~~d0TT{{zvM>T8yRtAz$1@sPJ~*1llByp! zq?74QpCEUAh2Hfwde!IX^sX<^)sbXuLkfv+Y@f6H?a$f$&Yo|-b6z@dk1Z36xSCJe zZ0n5mUlP`FZQs^ylWhg3r^ID-yXzPxaSJS4sYtfH!C2d++vY{#}cCRx`_ zJ7}+aL=RlUKhufj6L-D0vEB>J&_v5Hak)U@0W7UcJV(`>uX)7 zSUeBw9EC>p_?Z#Mz_r_bm-q0n*ZM|6lMmqEW!U`iQ)cc)It5x8h2hF5^fvPE(l9r4 zmdq2#=sl84v8lD0&3lFa*Dvrr!tBDLjdg0Z4XdMKLA}yCB$uZ8%?DQj)FOH28O)s; zuSvTPkoiD>Ls(40Q(J*)65p_LV-)1cRZb*zz8mZ1{~Ci#7#cv@XwzIwGdln-!FD8A zpB~1S!TdbD3RzAxn5QtI_dKt+m5U<#@+wuHN;7w1C2&07C0bX-45?aAGfb^z5*pkT zCT_y$V%GiKI0ievS-2XP6lBADC1aaf9p(g<$!o{7jj(NPOGPB3hcuC!pm1Mb2Tm9O z;9`B|4&1O?9&vkksD`B?v8g{9W;-{DxKm6Prrr?OR@>THZYo^KHvk6Q`V?-;V*OB+ zIYpGp>akR>3B0%`3Z?8P%p_zg)st)r&u8KYx$yWXn`Wk9Y+o$zXEV$!O!2a)h&)%x zj^%$%!Hr8D`~p^m=e0^zRM19MQaN4`8=~@J#2Dh9h$R87&A~KZmG(p#ZK6T^%QZN$ z!tGWBw7LK@oPNjK{tt{Q zK70(YrFlg4blZ)3GQ}LgoaX!3HfoRPNO|$OZ(V&*Vf7U_s@tHdj0}r0R(Qvl?!)37MorJk=#X28K(bW1rvr=9;LrK7t$rFg3^qSWZ|=$ogTG+7_*x z`OT--1U*J|dS^u1%r=Z;VjYs3rltPqnlSZHhdF{3-L_7RHr}$~9p|5^aUTLjdwfka zkv1<=hHMyEC%m{5pqY;WI)J5^BIs?OV9kC6R{pmX%nsGdXK;&C6plYs8v?IX<&jpo z11RNH@1kK5XWY~8-+N zF%Vxps#S#N7rXh~#Q~9sOwL^#*rJq@&c90mb4g9!gU@R+l14=+3w2c%zCRXap)`_} zJCM6fNUBO9sUXo^wi~*XMh?AHHR8E^7ZyfKnuR;ZbwO4|NfG3b(2&=Lxf2s`K_Yeq zPxr!B5>qyv--Gd}^p|0=&R1)~2=WpvB+L9hCzX)|Q_LdFMT^N&IxoXST=Xlzh(|Sa za|8*gG+w8XrkHtvcp=Kmxd3%NlUHFfnIvw&Y&?Xh;fNbE>;g>c4pI9o%M6J5XUGBJ ztvrpTxR5CKi0g$M6V4FR`ClMAIwdemFq2FgYJW`Ff(0*Vbqz06R(%`-<5}o-LI`yJ z#`(3-pAeZMMo=rCGK{csS8 zC&QfGUGLbV?*z>;@Tri@P|@STX>E@#{GPsBrf-A-eIpc-tnl=;QD|)ZnFuuFS496A z5s5VM9r1U1H3BIXDN3<83{xyNHd+%jQCkoClklTxI3Jkh-#f=s$!OSq3vU7b1G=&( A)&Kwi literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Access.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Access.php new file mode 100644 index 000000000000..7e170a2e838e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Access.php @@ -0,0 +1,521 @@ +google.cloud.securitycenter.v1.Access + */ +class Access extends \Google\Protobuf\Internal\Message +{ + /** + * Associated email, such as "foo@google.com". + * The email address of the authenticated user or a service account acting on + * behalf of a third party principal making the request. For third party + * identity callers, the `principal_subject` field is populated instead of + * this field. For privacy reasons, the principal email address is sometimes + * redacted. For more information, see [Caller identities in audit + * logs](https://cloud.google.com/logging/docs/audit#user-id). + * + * Generated from protobuf field string principal_email = 1; + */ + protected $principal_email = ''; + /** + * Caller's IP address, such as "1.1.1.1". + * + * Generated from protobuf field string caller_ip = 2; + */ + protected $caller_ip = ''; + /** + * The caller IP's geolocation, which identifies where the call came from. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Geolocation caller_ip_geo = 3; + */ + protected $caller_ip_geo = null; + /** + * Type of user agent associated with the finding. For example, an operating + * system shell or an embedded or standalone application. + * + * Generated from protobuf field string user_agent_family = 4; + */ + protected $user_agent_family = ''; + /** + * The caller's user agent string associated with the finding. + * + * Generated from protobuf field string user_agent = 12; + */ + protected $user_agent = ''; + /** + * This is the API service that the service account made a call to, e.g. + * "iam.googleapis.com" + * + * Generated from protobuf field string service_name = 5; + */ + protected $service_name = ''; + /** + * The method that the service account called, e.g. "SetIamPolicy". + * + * Generated from protobuf field string method_name = 6; + */ + protected $method_name = ''; + /** + * A string that represents the principal_subject that is associated with the + * identity. Unlike `principal_email`, `principal_subject` supports principals + * that aren't associated with email addresses, such as third party + * principals. For most identities, the format is + * `principal://iam.googleapis.com/{identity pool name}/subject/{subject}`. + * Some GKE identities, such as GKE_WORKLOAD, FREEFORM, and GKE_HUB_WORKLOAD, + * still use the legacy format `serviceAccount:{identity pool + * name}[{subject}]`. + * + * Generated from protobuf field string principal_subject = 7; + */ + protected $principal_subject = ''; + /** + * The name of the service account key that was used to create or exchange + * credentials when authenticating the service account that made the request. + * This is a scheme-less URI full resource name. For example: + * "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}". + * + * Generated from protobuf field string service_account_key_name = 8; + */ + protected $service_account_key_name = ''; + /** + * The identity delegation history of an authenticated service account that + * made the request. The `serviceAccountDelegationInfo[]` object contains + * information about the real authorities that try to access Google Cloud + * resources by delegating on a service account. When multiple authorities are + * present, they are guaranteed to be sorted based on the original ordering of + * the identity delegation events. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ServiceAccountDelegationInfo service_account_delegation_info = 9; + */ + private $service_account_delegation_info; + /** + * A string that represents a username. The username provided depends on the + * type of the finding and is likely not an IAM principal. For example, this + * can be a system username if the finding is related to a virtual machine, or + * it can be an application login username. + * + * Generated from protobuf field string user_name = 11; + */ + protected $user_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $principal_email + * Associated email, such as "foo@google.com". + * The email address of the authenticated user or a service account acting on + * behalf of a third party principal making the request. For third party + * identity callers, the `principal_subject` field is populated instead of + * this field. For privacy reasons, the principal email address is sometimes + * redacted. For more information, see [Caller identities in audit + * logs](https://cloud.google.com/logging/docs/audit#user-id). + * @type string $caller_ip + * Caller's IP address, such as "1.1.1.1". + * @type \Google\Cloud\SecurityCenter\V1\Geolocation $caller_ip_geo + * The caller IP's geolocation, which identifies where the call came from. + * @type string $user_agent_family + * Type of user agent associated with the finding. For example, an operating + * system shell or an embedded or standalone application. + * @type string $user_agent + * The caller's user agent string associated with the finding. + * @type string $service_name + * This is the API service that the service account made a call to, e.g. + * "iam.googleapis.com" + * @type string $method_name + * The method that the service account called, e.g. "SetIamPolicy". + * @type string $principal_subject + * A string that represents the principal_subject that is associated with the + * identity. Unlike `principal_email`, `principal_subject` supports principals + * that aren't associated with email addresses, such as third party + * principals. For most identities, the format is + * `principal://iam.googleapis.com/{identity pool name}/subject/{subject}`. + * Some GKE identities, such as GKE_WORKLOAD, FREEFORM, and GKE_HUB_WORKLOAD, + * still use the legacy format `serviceAccount:{identity pool + * name}[{subject}]`. + * @type string $service_account_key_name + * The name of the service account key that was used to create or exchange + * credentials when authenticating the service account that made the request. + * This is a scheme-less URI full resource name. For example: + * "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}". + * @type array<\Google\Cloud\SecurityCenter\V1\ServiceAccountDelegationInfo>|\Google\Protobuf\Internal\RepeatedField $service_account_delegation_info + * The identity delegation history of an authenticated service account that + * made the request. The `serviceAccountDelegationInfo[]` object contains + * information about the real authorities that try to access Google Cloud + * resources by delegating on a service account. When multiple authorities are + * present, they are guaranteed to be sorted based on the original ordering of + * the identity delegation events. + * @type string $user_name + * A string that represents a username. The username provided depends on the + * type of the finding and is likely not an IAM principal. For example, this + * can be a system username if the finding is related to a virtual machine, or + * it can be an application login username. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Access::initOnce(); + parent::__construct($data); + } + + /** + * Associated email, such as "foo@google.com". + * The email address of the authenticated user or a service account acting on + * behalf of a third party principal making the request. For third party + * identity callers, the `principal_subject` field is populated instead of + * this field. For privacy reasons, the principal email address is sometimes + * redacted. For more information, see [Caller identities in audit + * logs](https://cloud.google.com/logging/docs/audit#user-id). + * + * Generated from protobuf field string principal_email = 1; + * @return string + */ + public function getPrincipalEmail() + { + return $this->principal_email; + } + + /** + * Associated email, such as "foo@google.com". + * The email address of the authenticated user or a service account acting on + * behalf of a third party principal making the request. For third party + * identity callers, the `principal_subject` field is populated instead of + * this field. For privacy reasons, the principal email address is sometimes + * redacted. For more information, see [Caller identities in audit + * logs](https://cloud.google.com/logging/docs/audit#user-id). + * + * Generated from protobuf field string principal_email = 1; + * @param string $var + * @return $this + */ + public function setPrincipalEmail($var) + { + GPBUtil::checkString($var, True); + $this->principal_email = $var; + + return $this; + } + + /** + * Caller's IP address, such as "1.1.1.1". + * + * Generated from protobuf field string caller_ip = 2; + * @return string + */ + public function getCallerIp() + { + return $this->caller_ip; + } + + /** + * Caller's IP address, such as "1.1.1.1". + * + * Generated from protobuf field string caller_ip = 2; + * @param string $var + * @return $this + */ + public function setCallerIp($var) + { + GPBUtil::checkString($var, True); + $this->caller_ip = $var; + + return $this; + } + + /** + * The caller IP's geolocation, which identifies where the call came from. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Geolocation caller_ip_geo = 3; + * @return \Google\Cloud\SecurityCenter\V1\Geolocation|null + */ + public function getCallerIpGeo() + { + return $this->caller_ip_geo; + } + + public function hasCallerIpGeo() + { + return isset($this->caller_ip_geo); + } + + public function clearCallerIpGeo() + { + unset($this->caller_ip_geo); + } + + /** + * The caller IP's geolocation, which identifies where the call came from. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Geolocation caller_ip_geo = 3; + * @param \Google\Cloud\SecurityCenter\V1\Geolocation $var + * @return $this + */ + public function setCallerIpGeo($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Geolocation::class); + $this->caller_ip_geo = $var; + + return $this; + } + + /** + * Type of user agent associated with the finding. For example, an operating + * system shell or an embedded or standalone application. + * + * Generated from protobuf field string user_agent_family = 4; + * @return string + */ + public function getUserAgentFamily() + { + return $this->user_agent_family; + } + + /** + * Type of user agent associated with the finding. For example, an operating + * system shell or an embedded or standalone application. + * + * Generated from protobuf field string user_agent_family = 4; + * @param string $var + * @return $this + */ + public function setUserAgentFamily($var) + { + GPBUtil::checkString($var, True); + $this->user_agent_family = $var; + + return $this; + } + + /** + * The caller's user agent string associated with the finding. + * + * Generated from protobuf field string user_agent = 12; + * @return string + */ + public function getUserAgent() + { + return $this->user_agent; + } + + /** + * The caller's user agent string associated with the finding. + * + * Generated from protobuf field string user_agent = 12; + * @param string $var + * @return $this + */ + public function setUserAgent($var) + { + GPBUtil::checkString($var, True); + $this->user_agent = $var; + + return $this; + } + + /** + * This is the API service that the service account made a call to, e.g. + * "iam.googleapis.com" + * + * Generated from protobuf field string service_name = 5; + * @return string + */ + public function getServiceName() + { + return $this->service_name; + } + + /** + * This is the API service that the service account made a call to, e.g. + * "iam.googleapis.com" + * + * Generated from protobuf field string service_name = 5; + * @param string $var + * @return $this + */ + public function setServiceName($var) + { + GPBUtil::checkString($var, True); + $this->service_name = $var; + + return $this; + } + + /** + * The method that the service account called, e.g. "SetIamPolicy". + * + * Generated from protobuf field string method_name = 6; + * @return string + */ + public function getMethodName() + { + return $this->method_name; + } + + /** + * The method that the service account called, e.g. "SetIamPolicy". + * + * Generated from protobuf field string method_name = 6; + * @param string $var + * @return $this + */ + public function setMethodName($var) + { + GPBUtil::checkString($var, True); + $this->method_name = $var; + + return $this; + } + + /** + * A string that represents the principal_subject that is associated with the + * identity. Unlike `principal_email`, `principal_subject` supports principals + * that aren't associated with email addresses, such as third party + * principals. For most identities, the format is + * `principal://iam.googleapis.com/{identity pool name}/subject/{subject}`. + * Some GKE identities, such as GKE_WORKLOAD, FREEFORM, and GKE_HUB_WORKLOAD, + * still use the legacy format `serviceAccount:{identity pool + * name}[{subject}]`. + * + * Generated from protobuf field string principal_subject = 7; + * @return string + */ + public function getPrincipalSubject() + { + return $this->principal_subject; + } + + /** + * A string that represents the principal_subject that is associated with the + * identity. Unlike `principal_email`, `principal_subject` supports principals + * that aren't associated with email addresses, such as third party + * principals. For most identities, the format is + * `principal://iam.googleapis.com/{identity pool name}/subject/{subject}`. + * Some GKE identities, such as GKE_WORKLOAD, FREEFORM, and GKE_HUB_WORKLOAD, + * still use the legacy format `serviceAccount:{identity pool + * name}[{subject}]`. + * + * Generated from protobuf field string principal_subject = 7; + * @param string $var + * @return $this + */ + public function setPrincipalSubject($var) + { + GPBUtil::checkString($var, True); + $this->principal_subject = $var; + + return $this; + } + + /** + * The name of the service account key that was used to create or exchange + * credentials when authenticating the service account that made the request. + * This is a scheme-less URI full resource name. For example: + * "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}". + * + * Generated from protobuf field string service_account_key_name = 8; + * @return string + */ + public function getServiceAccountKeyName() + { + return $this->service_account_key_name; + } + + /** + * The name of the service account key that was used to create or exchange + * credentials when authenticating the service account that made the request. + * This is a scheme-less URI full resource name. For example: + * "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}". + * + * Generated from protobuf field string service_account_key_name = 8; + * @param string $var + * @return $this + */ + public function setServiceAccountKeyName($var) + { + GPBUtil::checkString($var, True); + $this->service_account_key_name = $var; + + return $this; + } + + /** + * The identity delegation history of an authenticated service account that + * made the request. The `serviceAccountDelegationInfo[]` object contains + * information about the real authorities that try to access Google Cloud + * resources by delegating on a service account. When multiple authorities are + * present, they are guaranteed to be sorted based on the original ordering of + * the identity delegation events. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ServiceAccountDelegationInfo service_account_delegation_info = 9; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getServiceAccountDelegationInfo() + { + return $this->service_account_delegation_info; + } + + /** + * The identity delegation history of an authenticated service account that + * made the request. The `serviceAccountDelegationInfo[]` object contains + * information about the real authorities that try to access Google Cloud + * resources by delegating on a service account. When multiple authorities are + * present, they are guaranteed to be sorted based on the original ordering of + * the identity delegation events. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ServiceAccountDelegationInfo service_account_delegation_info = 9; + * @param array<\Google\Cloud\SecurityCenter\V1\ServiceAccountDelegationInfo>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setServiceAccountDelegationInfo($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\ServiceAccountDelegationInfo::class); + $this->service_account_delegation_info = $arr; + + return $this; + } + + /** + * A string that represents a username. The username provided depends on the + * type of the finding and is likely not an IAM principal. For example, this + * can be a system username if the finding is related to a virtual machine, or + * it can be an application login username. + * + * Generated from protobuf field string user_name = 11; + * @return string + */ + public function getUserName() + { + return $this->user_name; + } + + /** + * A string that represents a username. The username provided depends on the + * type of the finding and is likely not an IAM principal. For example, this + * can be a system username if the finding is related to a virtual machine, or + * it can be an application login username. + * + * Generated from protobuf field string user_name = 11; + * @param string $var + * @return $this + */ + public function setUserName($var) + { + GPBUtil::checkString($var, True); + $this->user_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/AdaptiveProtection.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/AdaptiveProtection.php new file mode 100644 index 000000000000..ff0bc1a51916 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/AdaptiveProtection.php @@ -0,0 +1,84 @@ +google.cloud.securitycenter.v1.AdaptiveProtection + */ +class AdaptiveProtection extends \Google\Protobuf\Internal\Message +{ + /** + * A score of 0 means that there is low confidence that the detected event is + * an actual attack. A score of 1 means that there is high confidence that the + * detected event is an attack. See the [Adaptive Protection + * documentation](https://cloud.google.com/armor/docs/adaptive-protection-overview#configure-alert-tuning) + * for further explanation. + * + * Generated from protobuf field double confidence = 1; + */ + protected $confidence = 0.0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type float $confidence + * A score of 0 means that there is low confidence that the detected event is + * an actual attack. A score of 1 means that there is high confidence that the + * detected event is an attack. See the [Adaptive Protection + * documentation](https://cloud.google.com/armor/docs/adaptive-protection-overview#configure-alert-tuning) + * for further explanation. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\CloudArmor::initOnce(); + parent::__construct($data); + } + + /** + * A score of 0 means that there is low confidence that the detected event is + * an actual attack. A score of 1 means that there is high confidence that the + * detected event is an attack. See the [Adaptive Protection + * documentation](https://cloud.google.com/armor/docs/adaptive-protection-overview#configure-alert-tuning) + * for further explanation. + * + * Generated from protobuf field double confidence = 1; + * @return float + */ + public function getConfidence() + { + return $this->confidence; + } + + /** + * A score of 0 means that there is low confidence that the detected event is + * an actual attack. A score of 1 means that there is high confidence that the + * detected event is an attack. See the [Adaptive Protection + * documentation](https://cloud.google.com/armor/docs/adaptive-protection-overview#configure-alert-tuning) + * for further explanation. + * + * Generated from protobuf field double confidence = 1; + * @param float $var + * @return $this + */ + public function setConfidence($var) + { + GPBUtil::checkDouble($var); + $this->confidence = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Application.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Application.php new file mode 100644 index 000000000000..9d6b9c134d80 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Application.php @@ -0,0 +1,109 @@ +google.cloud.securitycenter.v1.Application + */ +class Application extends \Google\Protobuf\Internal\Message +{ + /** + * The base URI that identifies the network location of the application in + * which the vulnerability was detected. For example, `http://example.com`. + * + * Generated from protobuf field string base_uri = 1; + */ + protected $base_uri = ''; + /** + * The full URI with payload that can be used to reproduce the + * vulnerability. For example, `http://example.com?p=aMmYgI6H`. + * + * Generated from protobuf field string full_uri = 2; + */ + protected $full_uri = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $base_uri + * The base URI that identifies the network location of the application in + * which the vulnerability was detected. For example, `http://example.com`. + * @type string $full_uri + * The full URI with payload that can be used to reproduce the + * vulnerability. For example, `http://example.com?p=aMmYgI6H`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Application::initOnce(); + parent::__construct($data); + } + + /** + * The base URI that identifies the network location of the application in + * which the vulnerability was detected. For example, `http://example.com`. + * + * Generated from protobuf field string base_uri = 1; + * @return string + */ + public function getBaseUri() + { + return $this->base_uri; + } + + /** + * The base URI that identifies the network location of the application in + * which the vulnerability was detected. For example, `http://example.com`. + * + * Generated from protobuf field string base_uri = 1; + * @param string $var + * @return $this + */ + public function setBaseUri($var) + { + GPBUtil::checkString($var, True); + $this->base_uri = $var; + + return $this; + } + + /** + * The full URI with payload that can be used to reproduce the + * vulnerability. For example, `http://example.com?p=aMmYgI6H`. + * + * Generated from protobuf field string full_uri = 2; + * @return string + */ + public function getFullUri() + { + return $this->full_uri; + } + + /** + * The full URI with payload that can be used to reproduce the + * vulnerability. For example, `http://example.com?p=aMmYgI6H`. + * + * Generated from protobuf field string full_uri = 2; + * @param string $var + * @return $this + */ + public function setFullUri($var) + { + GPBUtil::checkString($var, True); + $this->full_uri = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset.php new file mode 100644 index 000000000000..9a5c7fa0c831 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset.php @@ -0,0 +1,412 @@ +google.cloud.securitycenter.v1.Asset + */ +class Asset extends \Google\Protobuf\Internal\Message +{ + /** + * The relative resource name of this asset. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/assets/{asset_id}". + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Security Command Center managed properties. These properties are managed by + * Security Command Center and cannot be modified by the user. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Asset.SecurityCenterProperties security_center_properties = 2; + */ + protected $security_center_properties = null; + /** + * Resource managed properties. These properties are managed and defined by + * the Google Cloud resource and cannot be modified by the user. + * + * Generated from protobuf field map resource_properties = 7; + */ + private $resource_properties; + /** + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityMarks security_marks = 8; + */ + protected $security_marks = null; + /** + * The time at which the asset was created in Security Command Center. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 9; + */ + protected $create_time = null; + /** + * The time at which the asset was last updated or added in Cloud SCC. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 10; + */ + protected $update_time = null; + /** + * Cloud IAM Policy information associated with the Google Cloud resource + * described by the Security Command Center asset. This information is managed + * and defined by the Google Cloud resource and cannot be modified by the + * user. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Asset.IamPolicy iam_policy = 11; + */ + protected $iam_policy = null; + /** + * The canonical name of the resource. It's either + * "organizations/{organization_id}/assets/{asset_id}", + * "folders/{folder_id}/assets/{asset_id}" or + * "projects/{project_number}/assets/{asset_id}", depending on the closest CRM + * ancestor of the resource. + * + * Generated from protobuf field string canonical_name = 13; + */ + protected $canonical_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The relative resource name of this asset. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/assets/{asset_id}". + * @type \Google\Cloud\SecurityCenter\V1\Asset\SecurityCenterProperties $security_center_properties + * Security Command Center managed properties. These properties are managed by + * Security Command Center and cannot be modified by the user. + * @type array|\Google\Protobuf\Internal\MapField $resource_properties + * Resource managed properties. These properties are managed and defined by + * the Google Cloud resource and cannot be modified by the user. + * @type \Google\Cloud\SecurityCenter\V1\SecurityMarks $security_marks + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + * @type \Google\Protobuf\Timestamp $create_time + * The time at which the asset was created in Security Command Center. + * @type \Google\Protobuf\Timestamp $update_time + * The time at which the asset was last updated or added in Cloud SCC. + * @type \Google\Cloud\SecurityCenter\V1\Asset\IamPolicy $iam_policy + * Cloud IAM Policy information associated with the Google Cloud resource + * described by the Security Command Center asset. This information is managed + * and defined by the Google Cloud resource and cannot be modified by the + * user. + * @type string $canonical_name + * The canonical name of the resource. It's either + * "organizations/{organization_id}/assets/{asset_id}", + * "folders/{folder_id}/assets/{asset_id}" or + * "projects/{project_number}/assets/{asset_id}", depending on the closest CRM + * ancestor of the resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Asset::initOnce(); + parent::__construct($data); + } + + /** + * The relative resource name of this asset. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/assets/{asset_id}". + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The relative resource name of this asset. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/assets/{asset_id}". + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Security Command Center managed properties. These properties are managed by + * Security Command Center and cannot be modified by the user. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Asset.SecurityCenterProperties security_center_properties = 2; + * @return \Google\Cloud\SecurityCenter\V1\Asset\SecurityCenterProperties|null + */ + public function getSecurityCenterProperties() + { + return $this->security_center_properties; + } + + public function hasSecurityCenterProperties() + { + return isset($this->security_center_properties); + } + + public function clearSecurityCenterProperties() + { + unset($this->security_center_properties); + } + + /** + * Security Command Center managed properties. These properties are managed by + * Security Command Center and cannot be modified by the user. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Asset.SecurityCenterProperties security_center_properties = 2; + * @param \Google\Cloud\SecurityCenter\V1\Asset\SecurityCenterProperties $var + * @return $this + */ + public function setSecurityCenterProperties($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Asset\SecurityCenterProperties::class); + $this->security_center_properties = $var; + + return $this; + } + + /** + * Resource managed properties. These properties are managed and defined by + * the Google Cloud resource and cannot be modified by the user. + * + * Generated from protobuf field map resource_properties = 7; + * @return \Google\Protobuf\Internal\MapField + */ + public function getResourceProperties() + { + return $this->resource_properties; + } + + /** + * Resource managed properties. These properties are managed and defined by + * the Google Cloud resource and cannot be modified by the user. + * + * Generated from protobuf field map resource_properties = 7; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setResourceProperties($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Value::class); + $this->resource_properties = $arr; + + return $this; + } + + /** + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityMarks security_marks = 8; + * @return \Google\Cloud\SecurityCenter\V1\SecurityMarks|null + */ + public function getSecurityMarks() + { + return $this->security_marks; + } + + public function hasSecurityMarks() + { + return isset($this->security_marks); + } + + public function clearSecurityMarks() + { + unset($this->security_marks); + } + + /** + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityMarks security_marks = 8; + * @param \Google\Cloud\SecurityCenter\V1\SecurityMarks $var + * @return $this + */ + public function setSecurityMarks($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SecurityMarks::class); + $this->security_marks = $var; + + return $this; + } + + /** + * The time at which the asset was created in Security Command Center. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 9; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCreateTime() + { + return $this->create_time; + } + + public function hasCreateTime() + { + return isset($this->create_time); + } + + public function clearCreateTime() + { + unset($this->create_time); + } + + /** + * The time at which the asset was created in Security Command Center. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 9; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->create_time = $var; + + return $this; + } + + /** + * The time at which the asset was last updated or added in Cloud SCC. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 10; + * @return \Google\Protobuf\Timestamp|null + */ + public function getUpdateTime() + { + return $this->update_time; + } + + public function hasUpdateTime() + { + return isset($this->update_time); + } + + public function clearUpdateTime() + { + unset($this->update_time); + } + + /** + * The time at which the asset was last updated or added in Cloud SCC. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 10; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->update_time = $var; + + return $this; + } + + /** + * Cloud IAM Policy information associated with the Google Cloud resource + * described by the Security Command Center asset. This information is managed + * and defined by the Google Cloud resource and cannot be modified by the + * user. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Asset.IamPolicy iam_policy = 11; + * @return \Google\Cloud\SecurityCenter\V1\Asset\IamPolicy|null + */ + public function getIamPolicy() + { + return $this->iam_policy; + } + + public function hasIamPolicy() + { + return isset($this->iam_policy); + } + + public function clearIamPolicy() + { + unset($this->iam_policy); + } + + /** + * Cloud IAM Policy information associated with the Google Cloud resource + * described by the Security Command Center asset. This information is managed + * and defined by the Google Cloud resource and cannot be modified by the + * user. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Asset.IamPolicy iam_policy = 11; + * @param \Google\Cloud\SecurityCenter\V1\Asset\IamPolicy $var + * @return $this + */ + public function setIamPolicy($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Asset\IamPolicy::class); + $this->iam_policy = $var; + + return $this; + } + + /** + * The canonical name of the resource. It's either + * "organizations/{organization_id}/assets/{asset_id}", + * "folders/{folder_id}/assets/{asset_id}" or + * "projects/{project_number}/assets/{asset_id}", depending on the closest CRM + * ancestor of the resource. + * + * Generated from protobuf field string canonical_name = 13; + * @return string + */ + public function getCanonicalName() + { + return $this->canonical_name; + } + + /** + * The canonical name of the resource. It's either + * "organizations/{organization_id}/assets/{asset_id}", + * "folders/{folder_id}/assets/{asset_id}" or + * "projects/{project_number}/assets/{asset_id}", depending on the closest CRM + * ancestor of the resource. + * + * Generated from protobuf field string canonical_name = 13; + * @param string $var + * @return $this + */ + public function setCanonicalName($var) + { + GPBUtil::checkString($var, True); + $this->canonical_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset/IamPolicy.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset/IamPolicy.php new file mode 100644 index 000000000000..6df487a6cfce --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset/IamPolicy.php @@ -0,0 +1,81 @@ +google.cloud.securitycenter.v1.Asset.IamPolicy + */ +class IamPolicy extends \Google\Protobuf\Internal\Message +{ + /** + * The JSON representation of the Policy associated with the asset. + * See https://cloud.google.com/iam/reference/rest/v1/Policy for format + * details. + * + * Generated from protobuf field string policy_blob = 1; + */ + protected $policy_blob = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $policy_blob + * The JSON representation of the Policy associated with the asset. + * See https://cloud.google.com/iam/reference/rest/v1/Policy for format + * details. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Asset::initOnce(); + parent::__construct($data); + } + + /** + * The JSON representation of the Policy associated with the asset. + * See https://cloud.google.com/iam/reference/rest/v1/Policy for format + * details. + * + * Generated from protobuf field string policy_blob = 1; + * @return string + */ + public function getPolicyBlob() + { + return $this->policy_blob; + } + + /** + * The JSON representation of the Policy associated with the asset. + * See https://cloud.google.com/iam/reference/rest/v1/Policy for format + * details. + * + * Generated from protobuf field string policy_blob = 1; + * @param string $var + * @return $this + */ + public function setPolicyBlob($var) + { + GPBUtil::checkString($var, True); + $this->policy_blob = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(IamPolicy::class, \Google\Cloud\SecurityCenter\V1\Asset_IamPolicy::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset/SecurityCenterProperties.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset/SecurityCenterProperties.php new file mode 100644 index 000000000000..e52bfc4be7db --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset/SecurityCenterProperties.php @@ -0,0 +1,379 @@ +google.cloud.securitycenter.v1.Asset.SecurityCenterProperties + */ +class SecurityCenterProperties extends \Google\Protobuf\Internal\Message +{ + /** + * The full resource name of the Google Cloud resource this asset + * represents. This field is immutable after create time. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_name = 1; + */ + protected $resource_name = ''; + /** + * The type of the Google Cloud resource. Examples include: APPLICATION, + * PROJECT, and ORGANIZATION. This is a case insensitive field defined by + * Security Command Center and/or the producer of the resource and is + * immutable after create time. + * + * Generated from protobuf field string resource_type = 2; + */ + protected $resource_type = ''; + /** + * The full resource name of the immediate parent of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_parent = 3; + */ + protected $resource_parent = ''; + /** + * The full resource name of the project the resource belongs to. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_project = 4; + */ + protected $resource_project = ''; + /** + * Owners of the Google Cloud resource. + * + * Generated from protobuf field repeated string resource_owners = 5; + */ + private $resource_owners; + /** + * The user defined display name for this resource. + * + * Generated from protobuf field string resource_display_name = 6; + */ + protected $resource_display_name = ''; + /** + * The user defined display name for the parent of this resource. + * + * Generated from protobuf field string resource_parent_display_name = 7; + */ + protected $resource_parent_display_name = ''; + /** + * The user defined display name for the project of this resource. + * + * Generated from protobuf field string resource_project_display_name = 8; + */ + protected $resource_project_display_name = ''; + /** + * Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is the + * folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Folder folders = 10; + */ + private $folders; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $resource_name + * The full resource name of the Google Cloud resource this asset + * represents. This field is immutable after create time. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * @type string $resource_type + * The type of the Google Cloud resource. Examples include: APPLICATION, + * PROJECT, and ORGANIZATION. This is a case insensitive field defined by + * Security Command Center and/or the producer of the resource and is + * immutable after create time. + * @type string $resource_parent + * The full resource name of the immediate parent of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * @type string $resource_project + * The full resource name of the project the resource belongs to. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * @type array|\Google\Protobuf\Internal\RepeatedField $resource_owners + * Owners of the Google Cloud resource. + * @type string $resource_display_name + * The user defined display name for this resource. + * @type string $resource_parent_display_name + * The user defined display name for the parent of this resource. + * @type string $resource_project_display_name + * The user defined display name for the project of this resource. + * @type array<\Google\Cloud\SecurityCenter\V1\Folder>|\Google\Protobuf\Internal\RepeatedField $folders + * Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is the + * folder directly under the Organization. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Asset::initOnce(); + parent::__construct($data); + } + + /** + * The full resource name of the Google Cloud resource this asset + * represents. This field is immutable after create time. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_name = 1; + * @return string + */ + public function getResourceName() + { + return $this->resource_name; + } + + /** + * The full resource name of the Google Cloud resource this asset + * represents. This field is immutable after create time. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_name = 1; + * @param string $var + * @return $this + */ + public function setResourceName($var) + { + GPBUtil::checkString($var, True); + $this->resource_name = $var; + + return $this; + } + + /** + * The type of the Google Cloud resource. Examples include: APPLICATION, + * PROJECT, and ORGANIZATION. This is a case insensitive field defined by + * Security Command Center and/or the producer of the resource and is + * immutable after create time. + * + * Generated from protobuf field string resource_type = 2; + * @return string + */ + public function getResourceType() + { + return $this->resource_type; + } + + /** + * The type of the Google Cloud resource. Examples include: APPLICATION, + * PROJECT, and ORGANIZATION. This is a case insensitive field defined by + * Security Command Center and/or the producer of the resource and is + * immutable after create time. + * + * Generated from protobuf field string resource_type = 2; + * @param string $var + * @return $this + */ + public function setResourceType($var) + { + GPBUtil::checkString($var, True); + $this->resource_type = $var; + + return $this; + } + + /** + * The full resource name of the immediate parent of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_parent = 3; + * @return string + */ + public function getResourceParent() + { + return $this->resource_parent; + } + + /** + * The full resource name of the immediate parent of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_parent = 3; + * @param string $var + * @return $this + */ + public function setResourceParent($var) + { + GPBUtil::checkString($var, True); + $this->resource_parent = $var; + + return $this; + } + + /** + * The full resource name of the project the resource belongs to. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_project = 4; + * @return string + */ + public function getResourceProject() + { + return $this->resource_project; + } + + /** + * The full resource name of the project the resource belongs to. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_project = 4; + * @param string $var + * @return $this + */ + public function setResourceProject($var) + { + GPBUtil::checkString($var, True); + $this->resource_project = $var; + + return $this; + } + + /** + * Owners of the Google Cloud resource. + * + * Generated from protobuf field repeated string resource_owners = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getResourceOwners() + { + return $this->resource_owners; + } + + /** + * Owners of the Google Cloud resource. + * + * Generated from protobuf field repeated string resource_owners = 5; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setResourceOwners($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->resource_owners = $arr; + + return $this; + } + + /** + * The user defined display name for this resource. + * + * Generated from protobuf field string resource_display_name = 6; + * @return string + */ + public function getResourceDisplayName() + { + return $this->resource_display_name; + } + + /** + * The user defined display name for this resource. + * + * Generated from protobuf field string resource_display_name = 6; + * @param string $var + * @return $this + */ + public function setResourceDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->resource_display_name = $var; + + return $this; + } + + /** + * The user defined display name for the parent of this resource. + * + * Generated from protobuf field string resource_parent_display_name = 7; + * @return string + */ + public function getResourceParentDisplayName() + { + return $this->resource_parent_display_name; + } + + /** + * The user defined display name for the parent of this resource. + * + * Generated from protobuf field string resource_parent_display_name = 7; + * @param string $var + * @return $this + */ + public function setResourceParentDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->resource_parent_display_name = $var; + + return $this; + } + + /** + * The user defined display name for the project of this resource. + * + * Generated from protobuf field string resource_project_display_name = 8; + * @return string + */ + public function getResourceProjectDisplayName() + { + return $this->resource_project_display_name; + } + + /** + * The user defined display name for the project of this resource. + * + * Generated from protobuf field string resource_project_display_name = 8; + * @param string $var + * @return $this + */ + public function setResourceProjectDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->resource_project_display_name = $var; + + return $this; + } + + /** + * Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is the + * folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Folder folders = 10; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFolders() + { + return $this->folders; + } + + /** + * Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is the + * folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Folder folders = 10; + * @param array<\Google\Cloud\SecurityCenter\V1\Folder>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFolders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Folder::class); + $this->folders = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SecurityCenterProperties::class, \Google\Cloud\SecurityCenter\V1\Asset_SecurityCenterProperties::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Attack.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Attack.php new file mode 100644 index 000000000000..9e82c4b8ffd9 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Attack.php @@ -0,0 +1,135 @@ +google.cloud.securitycenter.v1.Attack + */ +class Attack extends \Google\Protobuf\Internal\Message +{ + /** + * Total PPS (packets per second) volume of attack. + * + * Generated from protobuf field int32 volume_pps = 1; + */ + protected $volume_pps = 0; + /** + * Total BPS (bytes per second) volume of attack. + * + * Generated from protobuf field int32 volume_bps = 2; + */ + protected $volume_bps = 0; + /** + * Type of attack, for example, ‘SYN-flood’, ‘NTP-udp’, or ‘CHARGEN-udp’. + * + * Generated from protobuf field string classification = 3; + */ + protected $classification = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $volume_pps + * Total PPS (packets per second) volume of attack. + * @type int $volume_bps + * Total BPS (bytes per second) volume of attack. + * @type string $classification + * Type of attack, for example, ‘SYN-flood’, ‘NTP-udp’, or ‘CHARGEN-udp’. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\CloudArmor::initOnce(); + parent::__construct($data); + } + + /** + * Total PPS (packets per second) volume of attack. + * + * Generated from protobuf field int32 volume_pps = 1; + * @return int + */ + public function getVolumePps() + { + return $this->volume_pps; + } + + /** + * Total PPS (packets per second) volume of attack. + * + * Generated from protobuf field int32 volume_pps = 1; + * @param int $var + * @return $this + */ + public function setVolumePps($var) + { + GPBUtil::checkInt32($var); + $this->volume_pps = $var; + + return $this; + } + + /** + * Total BPS (bytes per second) volume of attack. + * + * Generated from protobuf field int32 volume_bps = 2; + * @return int + */ + public function getVolumeBps() + { + return $this->volume_bps; + } + + /** + * Total BPS (bytes per second) volume of attack. + * + * Generated from protobuf field int32 volume_bps = 2; + * @param int $var + * @return $this + */ + public function setVolumeBps($var) + { + GPBUtil::checkInt32($var); + $this->volume_bps = $var; + + return $this; + } + + /** + * Type of attack, for example, ‘SYN-flood’, ‘NTP-udp’, or ‘CHARGEN-udp’. + * + * Generated from protobuf field string classification = 3; + * @return string + */ + public function getClassification() + { + return $this->classification; + } + + /** + * Type of attack, for example, ‘SYN-flood’, ‘NTP-udp’, or ‘CHARGEN-udp’. + * + * Generated from protobuf field string classification = 3; + * @param string $var + * @return $this + */ + public function setClassification($var) + { + GPBUtil::checkString($var, True); + $this->classification = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BackupDisasterRecovery.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BackupDisasterRecovery.php new file mode 100644 index 000000000000..82e7db8a2ad7 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BackupDisasterRecovery.php @@ -0,0 +1,495 @@ +google.cloud.securitycenter.v1.BackupDisasterRecovery + */ +class BackupDisasterRecovery extends \Google\Protobuf\Internal\Message +{ + /** + * The name of a Backup and DR template which comprises one or more backup + * policies. See the [Backup and DR + * documentation](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#temp) + * for more information. For example, `snap-ov`. + * + * Generated from protobuf field string backup_template = 1; + */ + protected $backup_template = ''; + /** + * The names of Backup and DR policies that are associated with a template + * and that define when to run a backup, how frequently to run a backup, and + * how long to retain the backup image. For example, `onvaults`. + * + * Generated from protobuf field repeated string policies = 2; + */ + private $policies; + /** + * The name of a Backup and DR host, which is managed by the backup and + * recovery appliance and known to the management console. The host can be of + * type Generic (for example, Compute Engine, SQL Server, Oracle DB, SMB file + * system, etc.), vCenter, or an ESX server. See the [Backup and DR + * documentation on + * hosts](https://cloud.google.com/backup-disaster-recovery/docs/configuration/manage-hosts-and-their-applications) + * for more information. For example, `centos7-01`. + * + * Generated from protobuf field string host = 3; + */ + protected $host = ''; + /** + * The names of Backup and DR applications. An application is a VM, database, + * or file system on a managed host monitored by a backup and recovery + * appliance. For example, `centos7-01-vol00`, `centos7-01-vol01`, + * `centos7-01-vol02`. + * + * Generated from protobuf field repeated string applications = 4; + */ + private $applications; + /** + * The name of the Backup and DR storage pool that the backup and recovery + * appliance is storing data in. The storage pool could be of type Cloud, + * Primary, Snapshot, or OnVault. See the [Backup and DR documentation on + * storage + * pools](https://cloud.google.com/backup-disaster-recovery/docs/concepts/storage-pools). + * For example, `DiskPoolOne`. + * + * Generated from protobuf field string storage_pool = 5; + */ + protected $storage_pool = ''; + /** + * The names of Backup and DR advanced policy options of a policy applying to + * an application. See the [Backup and DR documentation on policy + * options](https://cloud.google.com/backup-disaster-recovery/docs/create-plan/policy-settings). + * For example, `skipofflineappsincongrp, nounmap`. + * + * Generated from protobuf field repeated string policy_options = 6; + */ + private $policy_options; + /** + * The name of the Backup and DR resource profile that specifies the storage + * media for backups of application and VM data. See the [Backup and DR + * documentation on + * profiles](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#profile). + * For example, `GCP`. + * + * Generated from protobuf field string profile = 7; + */ + protected $profile = ''; + /** + * The name of the Backup and DR appliance that captures, moves, and manages + * the lifecycle of backup data. For example, `backup-server-57137`. + * + * Generated from protobuf field string appliance = 8; + */ + protected $appliance = ''; + /** + * The backup type of the Backup and DR image. + * For example, `Snapshot`, `Remote Snapshot`, `OnVault`. + * + * Generated from protobuf field string backup_type = 9; + */ + protected $backup_type = ''; + /** + * The timestamp at which the Backup and DR backup was created. + * + * Generated from protobuf field .google.protobuf.Timestamp backup_create_time = 10; + */ + protected $backup_create_time = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $backup_template + * The name of a Backup and DR template which comprises one or more backup + * policies. See the [Backup and DR + * documentation](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#temp) + * for more information. For example, `snap-ov`. + * @type array|\Google\Protobuf\Internal\RepeatedField $policies + * The names of Backup and DR policies that are associated with a template + * and that define when to run a backup, how frequently to run a backup, and + * how long to retain the backup image. For example, `onvaults`. + * @type string $host + * The name of a Backup and DR host, which is managed by the backup and + * recovery appliance and known to the management console. The host can be of + * type Generic (for example, Compute Engine, SQL Server, Oracle DB, SMB file + * system, etc.), vCenter, or an ESX server. See the [Backup and DR + * documentation on + * hosts](https://cloud.google.com/backup-disaster-recovery/docs/configuration/manage-hosts-and-their-applications) + * for more information. For example, `centos7-01`. + * @type array|\Google\Protobuf\Internal\RepeatedField $applications + * The names of Backup and DR applications. An application is a VM, database, + * or file system on a managed host monitored by a backup and recovery + * appliance. For example, `centos7-01-vol00`, `centos7-01-vol01`, + * `centos7-01-vol02`. + * @type string $storage_pool + * The name of the Backup and DR storage pool that the backup and recovery + * appliance is storing data in. The storage pool could be of type Cloud, + * Primary, Snapshot, or OnVault. See the [Backup and DR documentation on + * storage + * pools](https://cloud.google.com/backup-disaster-recovery/docs/concepts/storage-pools). + * For example, `DiskPoolOne`. + * @type array|\Google\Protobuf\Internal\RepeatedField $policy_options + * The names of Backup and DR advanced policy options of a policy applying to + * an application. See the [Backup and DR documentation on policy + * options](https://cloud.google.com/backup-disaster-recovery/docs/create-plan/policy-settings). + * For example, `skipofflineappsincongrp, nounmap`. + * @type string $profile + * The name of the Backup and DR resource profile that specifies the storage + * media for backups of application and VM data. See the [Backup and DR + * documentation on + * profiles](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#profile). + * For example, `GCP`. + * @type string $appliance + * The name of the Backup and DR appliance that captures, moves, and manages + * the lifecycle of backup data. For example, `backup-server-57137`. + * @type string $backup_type + * The backup type of the Backup and DR image. + * For example, `Snapshot`, `Remote Snapshot`, `OnVault`. + * @type \Google\Protobuf\Timestamp $backup_create_time + * The timestamp at which the Backup and DR backup was created. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\BackupDisasterRecovery::initOnce(); + parent::__construct($data); + } + + /** + * The name of a Backup and DR template which comprises one or more backup + * policies. See the [Backup and DR + * documentation](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#temp) + * for more information. For example, `snap-ov`. + * + * Generated from protobuf field string backup_template = 1; + * @return string + */ + public function getBackupTemplate() + { + return $this->backup_template; + } + + /** + * The name of a Backup and DR template which comprises one or more backup + * policies. See the [Backup and DR + * documentation](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#temp) + * for more information. For example, `snap-ov`. + * + * Generated from protobuf field string backup_template = 1; + * @param string $var + * @return $this + */ + public function setBackupTemplate($var) + { + GPBUtil::checkString($var, True); + $this->backup_template = $var; + + return $this; + } + + /** + * The names of Backup and DR policies that are associated with a template + * and that define when to run a backup, how frequently to run a backup, and + * how long to retain the backup image. For example, `onvaults`. + * + * Generated from protobuf field repeated string policies = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPolicies() + { + return $this->policies; + } + + /** + * The names of Backup and DR policies that are associated with a template + * and that define when to run a backup, how frequently to run a backup, and + * how long to retain the backup image. For example, `onvaults`. + * + * Generated from protobuf field repeated string policies = 2; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPolicies($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->policies = $arr; + + return $this; + } + + /** + * The name of a Backup and DR host, which is managed by the backup and + * recovery appliance and known to the management console. The host can be of + * type Generic (for example, Compute Engine, SQL Server, Oracle DB, SMB file + * system, etc.), vCenter, or an ESX server. See the [Backup and DR + * documentation on + * hosts](https://cloud.google.com/backup-disaster-recovery/docs/configuration/manage-hosts-and-their-applications) + * for more information. For example, `centos7-01`. + * + * Generated from protobuf field string host = 3; + * @return string + */ + public function getHost() + { + return $this->host; + } + + /** + * The name of a Backup and DR host, which is managed by the backup and + * recovery appliance and known to the management console. The host can be of + * type Generic (for example, Compute Engine, SQL Server, Oracle DB, SMB file + * system, etc.), vCenter, or an ESX server. See the [Backup and DR + * documentation on + * hosts](https://cloud.google.com/backup-disaster-recovery/docs/configuration/manage-hosts-and-their-applications) + * for more information. For example, `centos7-01`. + * + * Generated from protobuf field string host = 3; + * @param string $var + * @return $this + */ + public function setHost($var) + { + GPBUtil::checkString($var, True); + $this->host = $var; + + return $this; + } + + /** + * The names of Backup and DR applications. An application is a VM, database, + * or file system on a managed host monitored by a backup and recovery + * appliance. For example, `centos7-01-vol00`, `centos7-01-vol01`, + * `centos7-01-vol02`. + * + * Generated from protobuf field repeated string applications = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getApplications() + { + return $this->applications; + } + + /** + * The names of Backup and DR applications. An application is a VM, database, + * or file system on a managed host monitored by a backup and recovery + * appliance. For example, `centos7-01-vol00`, `centos7-01-vol01`, + * `centos7-01-vol02`. + * + * Generated from protobuf field repeated string applications = 4; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setApplications($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->applications = $arr; + + return $this; + } + + /** + * The name of the Backup and DR storage pool that the backup and recovery + * appliance is storing data in. The storage pool could be of type Cloud, + * Primary, Snapshot, or OnVault. See the [Backup and DR documentation on + * storage + * pools](https://cloud.google.com/backup-disaster-recovery/docs/concepts/storage-pools). + * For example, `DiskPoolOne`. + * + * Generated from protobuf field string storage_pool = 5; + * @return string + */ + public function getStoragePool() + { + return $this->storage_pool; + } + + /** + * The name of the Backup and DR storage pool that the backup and recovery + * appliance is storing data in. The storage pool could be of type Cloud, + * Primary, Snapshot, or OnVault. See the [Backup and DR documentation on + * storage + * pools](https://cloud.google.com/backup-disaster-recovery/docs/concepts/storage-pools). + * For example, `DiskPoolOne`. + * + * Generated from protobuf field string storage_pool = 5; + * @param string $var + * @return $this + */ + public function setStoragePool($var) + { + GPBUtil::checkString($var, True); + $this->storage_pool = $var; + + return $this; + } + + /** + * The names of Backup and DR advanced policy options of a policy applying to + * an application. See the [Backup and DR documentation on policy + * options](https://cloud.google.com/backup-disaster-recovery/docs/create-plan/policy-settings). + * For example, `skipofflineappsincongrp, nounmap`. + * + * Generated from protobuf field repeated string policy_options = 6; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPolicyOptions() + { + return $this->policy_options; + } + + /** + * The names of Backup and DR advanced policy options of a policy applying to + * an application. See the [Backup and DR documentation on policy + * options](https://cloud.google.com/backup-disaster-recovery/docs/create-plan/policy-settings). + * For example, `skipofflineappsincongrp, nounmap`. + * + * Generated from protobuf field repeated string policy_options = 6; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPolicyOptions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->policy_options = $arr; + + return $this; + } + + /** + * The name of the Backup and DR resource profile that specifies the storage + * media for backups of application and VM data. See the [Backup and DR + * documentation on + * profiles](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#profile). + * For example, `GCP`. + * + * Generated from protobuf field string profile = 7; + * @return string + */ + public function getProfile() + { + return $this->profile; + } + + /** + * The name of the Backup and DR resource profile that specifies the storage + * media for backups of application and VM data. See the [Backup and DR + * documentation on + * profiles](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#profile). + * For example, `GCP`. + * + * Generated from protobuf field string profile = 7; + * @param string $var + * @return $this + */ + public function setProfile($var) + { + GPBUtil::checkString($var, True); + $this->profile = $var; + + return $this; + } + + /** + * The name of the Backup and DR appliance that captures, moves, and manages + * the lifecycle of backup data. For example, `backup-server-57137`. + * + * Generated from protobuf field string appliance = 8; + * @return string + */ + public function getAppliance() + { + return $this->appliance; + } + + /** + * The name of the Backup and DR appliance that captures, moves, and manages + * the lifecycle of backup data. For example, `backup-server-57137`. + * + * Generated from protobuf field string appliance = 8; + * @param string $var + * @return $this + */ + public function setAppliance($var) + { + GPBUtil::checkString($var, True); + $this->appliance = $var; + + return $this; + } + + /** + * The backup type of the Backup and DR image. + * For example, `Snapshot`, `Remote Snapshot`, `OnVault`. + * + * Generated from protobuf field string backup_type = 9; + * @return string + */ + public function getBackupType() + { + return $this->backup_type; + } + + /** + * The backup type of the Backup and DR image. + * For example, `Snapshot`, `Remote Snapshot`, `OnVault`. + * + * Generated from protobuf field string backup_type = 9; + * @param string $var + * @return $this + */ + public function setBackupType($var) + { + GPBUtil::checkString($var, True); + $this->backup_type = $var; + + return $this; + } + + /** + * The timestamp at which the Backup and DR backup was created. + * + * Generated from protobuf field .google.protobuf.Timestamp backup_create_time = 10; + * @return \Google\Protobuf\Timestamp|null + */ + public function getBackupCreateTime() + { + return $this->backup_create_time; + } + + public function hasBackupCreateTime() + { + return isset($this->backup_create_time); + } + + public function clearBackupCreateTime() + { + unset($this->backup_create_time); + } + + /** + * The timestamp at which the Backup and DR backup was created. + * + * Generated from protobuf field .google.protobuf.Timestamp backup_create_time = 10; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setBackupCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->backup_create_time = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BigQueryExport.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BigQueryExport.php new file mode 100644 index 000000000000..9d9444af8a9b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BigQueryExport.php @@ -0,0 +1,449 @@ +google.cloud.securitycenter.v1.BigQueryExport + */ +class BigQueryExport extends \Google\Protobuf\Internal\Message +{ + /** + * The relative resource name of this export. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name. + * Example format: + * "organizations/{organization_id}/bigQueryExports/{export_id}" Example + * format: "folders/{folder_id}/bigQueryExports/{export_id}" Example format: + * "projects/{project_id}/bigQueryExports/{export_id}" + * This field is provided in responses, and is ignored when provided in create + * requests. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The description of the export (max of 1024 characters). + * + * Generated from protobuf field string description = 2; + */ + protected $description = ''; + /** + * Expression that defines the filter to apply across create/update events + * of findings. The expression is a list of zero or more restrictions combined + * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` + * has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 3; + */ + protected $filter = ''; + /** + * The dataset to write findings' updates to. Its format is + * "projects/[project_id]/datasets/[bigquery_dataset_id]". + * BigQuery Dataset unique ID must contain only letters (a-z, A-Z), numbers + * (0-9), or underscores (_). + * + * Generated from protobuf field string dataset = 4; + */ + protected $dataset = ''; + /** + * Output only. The time at which the BigQuery export was created. + * This field is set by the server and will be ignored if provided on export + * on creation. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. The most recent time at which the BigQuery export was updated. + * This field is set by the server and will be ignored if provided on export + * creation or update. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Output only. Email address of the user who last edited the BigQuery export. + * This field is set by the server and will be ignored if provided on export + * creation or update. + * + * Generated from protobuf field string most_recent_editor = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $most_recent_editor = ''; + /** + * Output only. The service account that needs permission to create table and + * upload data to the BigQuery dataset. + * + * Generated from protobuf field string principal = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $principal = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The relative resource name of this export. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name. + * Example format: + * "organizations/{organization_id}/bigQueryExports/{export_id}" Example + * format: "folders/{folder_id}/bigQueryExports/{export_id}" Example format: + * "projects/{project_id}/bigQueryExports/{export_id}" + * This field is provided in responses, and is ignored when provided in create + * requests. + * @type string $description + * The description of the export (max of 1024 characters). + * @type string $filter + * Expression that defines the filter to apply across create/update events + * of findings. The expression is a list of zero or more restrictions combined + * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` + * has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * @type string $dataset + * The dataset to write findings' updates to. Its format is + * "projects/[project_id]/datasets/[bigquery_dataset_id]". + * BigQuery Dataset unique ID must contain only letters (a-z, A-Z), numbers + * (0-9), or underscores (_). + * @type \Google\Protobuf\Timestamp $create_time + * Output only. The time at which the BigQuery export was created. + * This field is set by the server and will be ignored if provided on export + * on creation. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. The most recent time at which the BigQuery export was updated. + * This field is set by the server and will be ignored if provided on export + * creation or update. + * @type string $most_recent_editor + * Output only. Email address of the user who last edited the BigQuery export. + * This field is set by the server and will be ignored if provided on export + * creation or update. + * @type string $principal + * Output only. The service account that needs permission to create table and + * upload data to the BigQuery dataset. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\BigqueryExport::initOnce(); + parent::__construct($data); + } + + /** + * The relative resource name of this export. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name. + * Example format: + * "organizations/{organization_id}/bigQueryExports/{export_id}" Example + * format: "folders/{folder_id}/bigQueryExports/{export_id}" Example format: + * "projects/{project_id}/bigQueryExports/{export_id}" + * This field is provided in responses, and is ignored when provided in create + * requests. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The relative resource name of this export. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name. + * Example format: + * "organizations/{organization_id}/bigQueryExports/{export_id}" Example + * format: "folders/{folder_id}/bigQueryExports/{export_id}" Example format: + * "projects/{project_id}/bigQueryExports/{export_id}" + * This field is provided in responses, and is ignored when provided in create + * requests. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The description of the export (max of 1024 characters). + * + * Generated from protobuf field string description = 2; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * The description of the export (max of 1024 characters). + * + * Generated from protobuf field string description = 2; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * Expression that defines the filter to apply across create/update events + * of findings. The expression is a list of zero or more restrictions combined + * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` + * has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 3; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Expression that defines the filter to apply across create/update events + * of findings. The expression is a list of zero or more restrictions combined + * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` + * has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 3; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * The dataset to write findings' updates to. Its format is + * "projects/[project_id]/datasets/[bigquery_dataset_id]". + * BigQuery Dataset unique ID must contain only letters (a-z, A-Z), numbers + * (0-9), or underscores (_). + * + * Generated from protobuf field string dataset = 4; + * @return string + */ + public function getDataset() + { + return $this->dataset; + } + + /** + * The dataset to write findings' updates to. Its format is + * "projects/[project_id]/datasets/[bigquery_dataset_id]". + * BigQuery Dataset unique ID must contain only letters (a-z, A-Z), numbers + * (0-9), or underscores (_). + * + * Generated from protobuf field string dataset = 4; + * @param string $var + * @return $this + */ + public function setDataset($var) + { + GPBUtil::checkString($var, True); + $this->dataset = $var; + + return $this; + } + + /** + * Output only. The time at which the BigQuery export was created. + * This field is set by the server and will be ignored if provided on export + * on creation. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCreateTime() + { + return $this->create_time; + } + + public function hasCreateTime() + { + return isset($this->create_time); + } + + public function clearCreateTime() + { + unset($this->create_time); + } + + /** + * Output only. The time at which the BigQuery export was created. + * This field is set by the server and will be ignored if provided on export + * on creation. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->create_time = $var; + + return $this; + } + + /** + * Output only. The most recent time at which the BigQuery export was updated. + * This field is set by the server and will be ignored if provided on export + * creation or update. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getUpdateTime() + { + return $this->update_time; + } + + public function hasUpdateTime() + { + return isset($this->update_time); + } + + public function clearUpdateTime() + { + unset($this->update_time); + } + + /** + * Output only. The most recent time at which the BigQuery export was updated. + * This field is set by the server and will be ignored if provided on export + * creation or update. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->update_time = $var; + + return $this; + } + + /** + * Output only. Email address of the user who last edited the BigQuery export. + * This field is set by the server and will be ignored if provided on export + * creation or update. + * + * Generated from protobuf field string most_recent_editor = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getMostRecentEditor() + { + return $this->most_recent_editor; + } + + /** + * Output only. Email address of the user who last edited the BigQuery export. + * This field is set by the server and will be ignored if provided on export + * creation or update. + * + * Generated from protobuf field string most_recent_editor = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setMostRecentEditor($var) + { + GPBUtil::checkString($var, True); + $this->most_recent_editor = $var; + + return $this; + } + + /** + * Output only. The service account that needs permission to create table and + * upload data to the BigQuery dataset. + * + * Generated from protobuf field string principal = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getPrincipal() + { + return $this->principal; + } + + /** + * Output only. The service account that needs permission to create table and + * upload data to the BigQuery dataset. + * + * Generated from protobuf field string principal = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setPrincipal($var) + { + GPBUtil::checkString($var, True); + $this->principal = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BulkMuteFindingsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BulkMuteFindingsRequest.php new file mode 100644 index 000000000000..5c6e40c5f606 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BulkMuteFindingsRequest.php @@ -0,0 +1,227 @@ +google.cloud.securitycenter.v1.BulkMuteFindingsRequest + */ +class BulkMuteFindingsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The parent, at which bulk action needs to be applied. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Expression that identifies findings that should be updated. + * The expression is a list of zero or more restrictions combined + * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` + * has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 2; + */ + protected $filter = ''; + /** + * This can be a mute configuration name or any identifier for mute/unmute + * of findings based on the filter. + * + * Generated from protobuf field string mute_annotation = 3 [deprecated = true]; + * @deprecated + */ + protected $mute_annotation = ''; + + /** + * @param string $parent Required. The parent, at which bulk action needs to be applied. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]". + * + * @return \Google\Cloud\SecurityCenter\V1\BulkMuteFindingsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The parent, at which bulk action needs to be applied. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]". + * @type string $filter + * Expression that identifies findings that should be updated. + * The expression is a list of zero or more restrictions combined + * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` + * has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * @type string $mute_annotation + * This can be a mute configuration name or any identifier for mute/unmute + * of findings based on the filter. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The parent, at which bulk action needs to be applied. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The parent, at which bulk action needs to be applied. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Expression that identifies findings that should be updated. + * The expression is a list of zero or more restrictions combined + * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` + * has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 2; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Expression that identifies findings that should be updated. + * The expression is a list of zero or more restrictions combined + * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` + * has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 2; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * This can be a mute configuration name or any identifier for mute/unmute + * of findings based on the filter. + * + * Generated from protobuf field string mute_annotation = 3 [deprecated = true]; + * @return string + * @deprecated + */ + public function getMuteAnnotation() + { + @trigger_error('mute_annotation is deprecated.', E_USER_DEPRECATED); + return $this->mute_annotation; + } + + /** + * This can be a mute configuration name or any identifier for mute/unmute + * of findings based on the filter. + * + * Generated from protobuf field string mute_annotation = 3 [deprecated = true]; + * @param string $var + * @return $this + * @deprecated + */ + public function setMuteAnnotation($var) + { + @trigger_error('mute_annotation is deprecated.', E_USER_DEPRECATED); + GPBUtil::checkString($var, True); + $this->mute_annotation = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BulkMuteFindingsResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BulkMuteFindingsResponse.php new file mode 100644 index 000000000000..68edc47a055a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BulkMuteFindingsResponse.php @@ -0,0 +1,33 @@ +google.cloud.securitycenter.v1.BulkMuteFindingsResponse + */ +class BulkMuteFindingsResponse extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudArmor.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudArmor.php new file mode 100644 index 000000000000..0ad826f6e3fd --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudArmor.php @@ -0,0 +1,323 @@ +google.cloud.securitycenter.v1.CloudArmor + */ +class CloudArmor extends \Google\Protobuf\Internal\Message +{ + /** + * Information about the [Google Cloud Armor security + * policy](https://cloud.google.com/armor/docs/security-policy-overview) + * relevant to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityPolicy security_policy = 1; + */ + protected $security_policy = null; + /** + * Information about incoming requests evaluated by [Google Cloud Armor + * security + * policies](https://cloud.google.com/armor/docs/security-policy-overview). + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Requests requests = 2; + */ + protected $requests = null; + /** + * Information about potential Layer 7 DDoS attacks identified by [Google + * Cloud Armor Adaptive + * Protection](https://cloud.google.com/armor/docs/adaptive-protection-overview). + * + * Generated from protobuf field .google.cloud.securitycenter.v1.AdaptiveProtection adaptive_protection = 3; + */ + protected $adaptive_protection = null; + /** + * Information about DDoS attack volume and classification. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Attack attack = 4; + */ + protected $attack = null; + /** + * Distinguish between volumetric & protocol DDoS attack and + * application layer attacks. For example, “L3_4†for Layer 3 and Layer 4 DDoS + * attacks, or “L_7†for Layer 7 DDoS attacks. + * + * Generated from protobuf field string threat_vector = 5; + */ + protected $threat_vector = ''; + /** + * Duration of attack from the start until the current moment (updated every 5 + * minutes). + * + * Generated from protobuf field .google.protobuf.Duration duration = 6; + */ + protected $duration = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1\SecurityPolicy $security_policy + * Information about the [Google Cloud Armor security + * policy](https://cloud.google.com/armor/docs/security-policy-overview) + * relevant to the finding. + * @type \Google\Cloud\SecurityCenter\V1\Requests $requests + * Information about incoming requests evaluated by [Google Cloud Armor + * security + * policies](https://cloud.google.com/armor/docs/security-policy-overview). + * @type \Google\Cloud\SecurityCenter\V1\AdaptiveProtection $adaptive_protection + * Information about potential Layer 7 DDoS attacks identified by [Google + * Cloud Armor Adaptive + * Protection](https://cloud.google.com/armor/docs/adaptive-protection-overview). + * @type \Google\Cloud\SecurityCenter\V1\Attack $attack + * Information about DDoS attack volume and classification. + * @type string $threat_vector + * Distinguish between volumetric & protocol DDoS attack and + * application layer attacks. For example, “L3_4†for Layer 3 and Layer 4 DDoS + * attacks, or “L_7†for Layer 7 DDoS attacks. + * @type \Google\Protobuf\Duration $duration + * Duration of attack from the start until the current moment (updated every 5 + * minutes). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\CloudArmor::initOnce(); + parent::__construct($data); + } + + /** + * Information about the [Google Cloud Armor security + * policy](https://cloud.google.com/armor/docs/security-policy-overview) + * relevant to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityPolicy security_policy = 1; + * @return \Google\Cloud\SecurityCenter\V1\SecurityPolicy|null + */ + public function getSecurityPolicy() + { + return $this->security_policy; + } + + public function hasSecurityPolicy() + { + return isset($this->security_policy); + } + + public function clearSecurityPolicy() + { + unset($this->security_policy); + } + + /** + * Information about the [Google Cloud Armor security + * policy](https://cloud.google.com/armor/docs/security-policy-overview) + * relevant to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityPolicy security_policy = 1; + * @param \Google\Cloud\SecurityCenter\V1\SecurityPolicy $var + * @return $this + */ + public function setSecurityPolicy($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SecurityPolicy::class); + $this->security_policy = $var; + + return $this; + } + + /** + * Information about incoming requests evaluated by [Google Cloud Armor + * security + * policies](https://cloud.google.com/armor/docs/security-policy-overview). + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Requests requests = 2; + * @return \Google\Cloud\SecurityCenter\V1\Requests|null + */ + public function getRequests() + { + return $this->requests; + } + + public function hasRequests() + { + return isset($this->requests); + } + + public function clearRequests() + { + unset($this->requests); + } + + /** + * Information about incoming requests evaluated by [Google Cloud Armor + * security + * policies](https://cloud.google.com/armor/docs/security-policy-overview). + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Requests requests = 2; + * @param \Google\Cloud\SecurityCenter\V1\Requests $var + * @return $this + */ + public function setRequests($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Requests::class); + $this->requests = $var; + + return $this; + } + + /** + * Information about potential Layer 7 DDoS attacks identified by [Google + * Cloud Armor Adaptive + * Protection](https://cloud.google.com/armor/docs/adaptive-protection-overview). + * + * Generated from protobuf field .google.cloud.securitycenter.v1.AdaptiveProtection adaptive_protection = 3; + * @return \Google\Cloud\SecurityCenter\V1\AdaptiveProtection|null + */ + public function getAdaptiveProtection() + { + return $this->adaptive_protection; + } + + public function hasAdaptiveProtection() + { + return isset($this->adaptive_protection); + } + + public function clearAdaptiveProtection() + { + unset($this->adaptive_protection); + } + + /** + * Information about potential Layer 7 DDoS attacks identified by [Google + * Cloud Armor Adaptive + * Protection](https://cloud.google.com/armor/docs/adaptive-protection-overview). + * + * Generated from protobuf field .google.cloud.securitycenter.v1.AdaptiveProtection adaptive_protection = 3; + * @param \Google\Cloud\SecurityCenter\V1\AdaptiveProtection $var + * @return $this + */ + public function setAdaptiveProtection($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\AdaptiveProtection::class); + $this->adaptive_protection = $var; + + return $this; + } + + /** + * Information about DDoS attack volume and classification. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Attack attack = 4; + * @return \Google\Cloud\SecurityCenter\V1\Attack|null + */ + public function getAttack() + { + return $this->attack; + } + + public function hasAttack() + { + return isset($this->attack); + } + + public function clearAttack() + { + unset($this->attack); + } + + /** + * Information about DDoS attack volume and classification. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Attack attack = 4; + * @param \Google\Cloud\SecurityCenter\V1\Attack $var + * @return $this + */ + public function setAttack($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Attack::class); + $this->attack = $var; + + return $this; + } + + /** + * Distinguish between volumetric & protocol DDoS attack and + * application layer attacks. For example, “L3_4†for Layer 3 and Layer 4 DDoS + * attacks, or “L_7†for Layer 7 DDoS attacks. + * + * Generated from protobuf field string threat_vector = 5; + * @return string + */ + public function getThreatVector() + { + return $this->threat_vector; + } + + /** + * Distinguish between volumetric & protocol DDoS attack and + * application layer attacks. For example, “L3_4†for Layer 3 and Layer 4 DDoS + * attacks, or “L_7†for Layer 7 DDoS attacks. + * + * Generated from protobuf field string threat_vector = 5; + * @param string $var + * @return $this + */ + public function setThreatVector($var) + { + GPBUtil::checkString($var, True); + $this->threat_vector = $var; + + return $this; + } + + /** + * Duration of attack from the start until the current moment (updated every 5 + * minutes). + * + * Generated from protobuf field .google.protobuf.Duration duration = 6; + * @return \Google\Protobuf\Duration|null + */ + public function getDuration() + { + return $this->duration; + } + + public function hasDuration() + { + return isset($this->duration); + } + + public function clearDuration() + { + unset($this->duration); + } + + /** + * Duration of attack from the start until the current moment (updated every 5 + * minutes). + * + * Generated from protobuf field .google.protobuf.Duration duration = 6; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setDuration($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->duration = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpDataProfile.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpDataProfile.php new file mode 100644 index 000000000000..452c80d52546 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpDataProfile.php @@ -0,0 +1,106 @@ +google.cloud.securitycenter.v1.CloudDlpDataProfile + */ +class CloudDlpDataProfile extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the data profile, for example, + * `projects/123/locations/europe/tableProfiles/8383929`. + * + * Generated from protobuf field string data_profile = 1 [(.google.api.resource_reference) = { + */ + protected $data_profile = ''; + /** + * The resource hierarchy level at which the data profile was generated. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CloudDlpDataProfile.ParentType parent_type = 2; + */ + protected $parent_type = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $data_profile + * Name of the data profile, for example, + * `projects/123/locations/europe/tableProfiles/8383929`. + * @type int $parent_type + * The resource hierarchy level at which the data profile was generated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\CloudDlpDataProfile::initOnce(); + parent::__construct($data); + } + + /** + * Name of the data profile, for example, + * `projects/123/locations/europe/tableProfiles/8383929`. + * + * Generated from protobuf field string data_profile = 1 [(.google.api.resource_reference) = { + * @return string + */ + public function getDataProfile() + { + return $this->data_profile; + } + + /** + * Name of the data profile, for example, + * `projects/123/locations/europe/tableProfiles/8383929`. + * + * Generated from protobuf field string data_profile = 1 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setDataProfile($var) + { + GPBUtil::checkString($var, True); + $this->data_profile = $var; + + return $this; + } + + /** + * The resource hierarchy level at which the data profile was generated. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CloudDlpDataProfile.ParentType parent_type = 2; + * @return int + */ + public function getParentType() + { + return $this->parent_type; + } + + /** + * The resource hierarchy level at which the data profile was generated. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CloudDlpDataProfile.ParentType parent_type = 2; + * @param int $var + * @return $this + */ + public function setParentType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\CloudDlpDataProfile\ParentType::class); + $this->parent_type = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpDataProfile/ParentType.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpDataProfile/ParentType.php new file mode 100644 index 000000000000..05f30f7a6786 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpDataProfile/ParentType.php @@ -0,0 +1,64 @@ +google.cloud.securitycenter.v1.CloudDlpDataProfile.ParentType + */ +class ParentType +{ + /** + * Unspecified parent type. + * + * Generated from protobuf enum PARENT_TYPE_UNSPECIFIED = 0; + */ + const PARENT_TYPE_UNSPECIFIED = 0; + /** + * Organization-level configurations. + * + * Generated from protobuf enum ORGANIZATION = 1; + */ + const ORGANIZATION = 1; + /** + * Project-level configurations. + * + * Generated from protobuf enum PROJECT = 2; + */ + const PROJECT = 2; + + private static $valueToName = [ + self::PARENT_TYPE_UNSPECIFIED => 'PARENT_TYPE_UNSPECIFIED', + self::ORGANIZATION => 'ORGANIZATION', + self::PROJECT => 'PROJECT', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ParentType::class, \Google\Cloud\SecurityCenter\V1\CloudDlpDataProfile_ParentType::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpInspection.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpInspection.php new file mode 100644 index 000000000000..0c7dd6a2013d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpInspection.php @@ -0,0 +1,187 @@ +google.cloud.securitycenter.v1.CloudDlpInspection + */ +class CloudDlpInspection extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the inspection job, for example, + * `projects/123/locations/europe/dlpJobs/i-8383929`. + * + * Generated from protobuf field string inspect_job = 1 [(.google.api.resource_reference) = { + */ + protected $inspect_job = ''; + /** + * The type of information (or + * *[infoType](https://cloud.google.com/dlp/docs/infotypes-reference)*) found, + * for example, `EMAIL_ADDRESS` or `STREET_ADDRESS`. + * + * Generated from protobuf field string info_type = 2; + */ + protected $info_type = ''; + /** + * The number of times Cloud DLP found this infoType within this job + * and resource. + * + * Generated from protobuf field int64 info_type_count = 3; + */ + protected $info_type_count = 0; + /** + * Whether Cloud DLP scanned the complete resource or a sampled subset. + * + * Generated from protobuf field bool full_scan = 4; + */ + protected $full_scan = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $inspect_job + * Name of the inspection job, for example, + * `projects/123/locations/europe/dlpJobs/i-8383929`. + * @type string $info_type + * The type of information (or + * *[infoType](https://cloud.google.com/dlp/docs/infotypes-reference)*) found, + * for example, `EMAIL_ADDRESS` or `STREET_ADDRESS`. + * @type int|string $info_type_count + * The number of times Cloud DLP found this infoType within this job + * and resource. + * @type bool $full_scan + * Whether Cloud DLP scanned the complete resource or a sampled subset. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\CloudDlpInspection::initOnce(); + parent::__construct($data); + } + + /** + * Name of the inspection job, for example, + * `projects/123/locations/europe/dlpJobs/i-8383929`. + * + * Generated from protobuf field string inspect_job = 1 [(.google.api.resource_reference) = { + * @return string + */ + public function getInspectJob() + { + return $this->inspect_job; + } + + /** + * Name of the inspection job, for example, + * `projects/123/locations/europe/dlpJobs/i-8383929`. + * + * Generated from protobuf field string inspect_job = 1 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setInspectJob($var) + { + GPBUtil::checkString($var, True); + $this->inspect_job = $var; + + return $this; + } + + /** + * The type of information (or + * *[infoType](https://cloud.google.com/dlp/docs/infotypes-reference)*) found, + * for example, `EMAIL_ADDRESS` or `STREET_ADDRESS`. + * + * Generated from protobuf field string info_type = 2; + * @return string + */ + public function getInfoType() + { + return $this->info_type; + } + + /** + * The type of information (or + * *[infoType](https://cloud.google.com/dlp/docs/infotypes-reference)*) found, + * for example, `EMAIL_ADDRESS` or `STREET_ADDRESS`. + * + * Generated from protobuf field string info_type = 2; + * @param string $var + * @return $this + */ + public function setInfoType($var) + { + GPBUtil::checkString($var, True); + $this->info_type = $var; + + return $this; + } + + /** + * The number of times Cloud DLP found this infoType within this job + * and resource. + * + * Generated from protobuf field int64 info_type_count = 3; + * @return int|string + */ + public function getInfoTypeCount() + { + return $this->info_type_count; + } + + /** + * The number of times Cloud DLP found this infoType within this job + * and resource. + * + * Generated from protobuf field int64 info_type_count = 3; + * @param int|string $var + * @return $this + */ + public function setInfoTypeCount($var) + { + GPBUtil::checkInt64($var); + $this->info_type_count = $var; + + return $this; + } + + /** + * Whether Cloud DLP scanned the complete resource or a sampled subset. + * + * Generated from protobuf field bool full_scan = 4; + * @return bool + */ + public function getFullScan() + { + return $this->full_scan; + } + + /** + * Whether Cloud DLP scanned the complete resource or a sampled subset. + * + * Generated from protobuf field bool full_scan = 4; + * @param bool $var + * @return $this + */ + public function setFullScan($var) + { + GPBUtil::checkBool($var); + $this->full_scan = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudLoggingEntry.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudLoggingEntry.php new file mode 100644 index 000000000000..e734077cde56 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudLoggingEntry.php @@ -0,0 +1,196 @@ +google.cloud.securitycenter.v1.CloudLoggingEntry + */ +class CloudLoggingEntry extends \Google\Protobuf\Internal\Message +{ + /** + * A unique identifier for the log entry. + * + * Generated from protobuf field string insert_id = 1; + */ + protected $insert_id = ''; + /** + * The type of the log (part of `log_name`. `log_name` is the resource name of + * the log to which this log entry belongs). For example: + * `cloudresourcemanager.googleapis.com/activity`. Note that this field is not + * URL-encoded, unlike the `LOG_ID` field in `LogEntry`. + * + * Generated from protobuf field string log_id = 2; + */ + protected $log_id = ''; + /** + * The organization, folder, or project of the monitored resource that + * produced this log entry. + * + * Generated from protobuf field string resource_container = 3; + */ + protected $resource_container = ''; + /** + * The time the event described by the log entry occurred. + * + * Generated from protobuf field .google.protobuf.Timestamp timestamp = 4; + */ + protected $timestamp = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $insert_id + * A unique identifier for the log entry. + * @type string $log_id + * The type of the log (part of `log_name`. `log_name` is the resource name of + * the log to which this log entry belongs). For example: + * `cloudresourcemanager.googleapis.com/activity`. Note that this field is not + * URL-encoded, unlike the `LOG_ID` field in `LogEntry`. + * @type string $resource_container + * The organization, folder, or project of the monitored resource that + * produced this log entry. + * @type \Google\Protobuf\Timestamp $timestamp + * The time the event described by the log entry occurred. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\LogEntry::initOnce(); + parent::__construct($data); + } + + /** + * A unique identifier for the log entry. + * + * Generated from protobuf field string insert_id = 1; + * @return string + */ + public function getInsertId() + { + return $this->insert_id; + } + + /** + * A unique identifier for the log entry. + * + * Generated from protobuf field string insert_id = 1; + * @param string $var + * @return $this + */ + public function setInsertId($var) + { + GPBUtil::checkString($var, True); + $this->insert_id = $var; + + return $this; + } + + /** + * The type of the log (part of `log_name`. `log_name` is the resource name of + * the log to which this log entry belongs). For example: + * `cloudresourcemanager.googleapis.com/activity`. Note that this field is not + * URL-encoded, unlike the `LOG_ID` field in `LogEntry`. + * + * Generated from protobuf field string log_id = 2; + * @return string + */ + public function getLogId() + { + return $this->log_id; + } + + /** + * The type of the log (part of `log_name`. `log_name` is the resource name of + * the log to which this log entry belongs). For example: + * `cloudresourcemanager.googleapis.com/activity`. Note that this field is not + * URL-encoded, unlike the `LOG_ID` field in `LogEntry`. + * + * Generated from protobuf field string log_id = 2; + * @param string $var + * @return $this + */ + public function setLogId($var) + { + GPBUtil::checkString($var, True); + $this->log_id = $var; + + return $this; + } + + /** + * The organization, folder, or project of the monitored resource that + * produced this log entry. + * + * Generated from protobuf field string resource_container = 3; + * @return string + */ + public function getResourceContainer() + { + return $this->resource_container; + } + + /** + * The organization, folder, or project of the monitored resource that + * produced this log entry. + * + * Generated from protobuf field string resource_container = 3; + * @param string $var + * @return $this + */ + public function setResourceContainer($var) + { + GPBUtil::checkString($var, True); + $this->resource_container = $var; + + return $this; + } + + /** + * The time the event described by the log entry occurred. + * + * Generated from protobuf field .google.protobuf.Timestamp timestamp = 4; + * @return \Google\Protobuf\Timestamp|null + */ + public function getTimestamp() + { + return $this->timestamp; + } + + public function hasTimestamp() + { + return isset($this->timestamp); + } + + public function clearTimestamp() + { + unset($this->timestamp); + } + + /** + * The time the event described by the log entry occurred. + * + * Generated from protobuf field .google.protobuf.Timestamp timestamp = 4; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setTimestamp($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->timestamp = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Compliance.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Compliance.php new file mode 100644 index 000000000000..e8ba84f97551 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Compliance.php @@ -0,0 +1,140 @@ +google.cloud.securitycenter.v1.Compliance + */ +class Compliance extends \Google\Protobuf\Internal\Message +{ + /** + * Industry-wide compliance standards or benchmarks, such as CIS, PCI, and + * OWASP. + * + * Generated from protobuf field string standard = 1; + */ + protected $standard = ''; + /** + * Version of the standard or benchmark, for example, 1.1 + * + * Generated from protobuf field string version = 2; + */ + protected $version = ''; + /** + * Policies within the standard or benchmark, for example, A.12.4.1 + * + * Generated from protobuf field repeated string ids = 3; + */ + private $ids; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $standard + * Industry-wide compliance standards or benchmarks, such as CIS, PCI, and + * OWASP. + * @type string $version + * Version of the standard or benchmark, for example, 1.1 + * @type array|\Google\Protobuf\Internal\RepeatedField $ids + * Policies within the standard or benchmark, for example, A.12.4.1 + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Compliance::initOnce(); + parent::__construct($data); + } + + /** + * Industry-wide compliance standards or benchmarks, such as CIS, PCI, and + * OWASP. + * + * Generated from protobuf field string standard = 1; + * @return string + */ + public function getStandard() + { + return $this->standard; + } + + /** + * Industry-wide compliance standards or benchmarks, such as CIS, PCI, and + * OWASP. + * + * Generated from protobuf field string standard = 1; + * @param string $var + * @return $this + */ + public function setStandard($var) + { + GPBUtil::checkString($var, True); + $this->standard = $var; + + return $this; + } + + /** + * Version of the standard or benchmark, for example, 1.1 + * + * Generated from protobuf field string version = 2; + * @return string + */ + public function getVersion() + { + return $this->version; + } + + /** + * Version of the standard or benchmark, for example, 1.1 + * + * Generated from protobuf field string version = 2; + * @param string $var + * @return $this + */ + public function setVersion($var) + { + GPBUtil::checkString($var, True); + $this->version = $var; + + return $this; + } + + /** + * Policies within the standard or benchmark, for example, A.12.4.1 + * + * Generated from protobuf field repeated string ids = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getIds() + { + return $this->ids; + } + + /** + * Policies within the standard or benchmark, for example, A.12.4.1 + * + * Generated from protobuf field repeated string ids = 3; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setIds($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->ids = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Connection.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Connection.php new file mode 100644 index 000000000000..ddaeaf3950ae --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Connection.php @@ -0,0 +1,211 @@ +google.cloud.securitycenter.v1.Connection + */ +class Connection extends \Google\Protobuf\Internal\Message +{ + /** + * Destination IP address. Not present for sockets that are listening and not + * connected. + * + * Generated from protobuf field string destination_ip = 1; + */ + protected $destination_ip = ''; + /** + * Destination port. Not present for sockets that are listening and not + * connected. + * + * Generated from protobuf field int32 destination_port = 2; + */ + protected $destination_port = 0; + /** + * Source IP address. + * + * Generated from protobuf field string source_ip = 3; + */ + protected $source_ip = ''; + /** + * Source port. + * + * Generated from protobuf field int32 source_port = 4; + */ + protected $source_port = 0; + /** + * IANA Internet Protocol Number such as TCP(6) and UDP(17). + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Connection.Protocol protocol = 5; + */ + protected $protocol = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $destination_ip + * Destination IP address. Not present for sockets that are listening and not + * connected. + * @type int $destination_port + * Destination port. Not present for sockets that are listening and not + * connected. + * @type string $source_ip + * Source IP address. + * @type int $source_port + * Source port. + * @type int $protocol + * IANA Internet Protocol Number such as TCP(6) and UDP(17). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Connection::initOnce(); + parent::__construct($data); + } + + /** + * Destination IP address. Not present for sockets that are listening and not + * connected. + * + * Generated from protobuf field string destination_ip = 1; + * @return string + */ + public function getDestinationIp() + { + return $this->destination_ip; + } + + /** + * Destination IP address. Not present for sockets that are listening and not + * connected. + * + * Generated from protobuf field string destination_ip = 1; + * @param string $var + * @return $this + */ + public function setDestinationIp($var) + { + GPBUtil::checkString($var, True); + $this->destination_ip = $var; + + return $this; + } + + /** + * Destination port. Not present for sockets that are listening and not + * connected. + * + * Generated from protobuf field int32 destination_port = 2; + * @return int + */ + public function getDestinationPort() + { + return $this->destination_port; + } + + /** + * Destination port. Not present for sockets that are listening and not + * connected. + * + * Generated from protobuf field int32 destination_port = 2; + * @param int $var + * @return $this + */ + public function setDestinationPort($var) + { + GPBUtil::checkInt32($var); + $this->destination_port = $var; + + return $this; + } + + /** + * Source IP address. + * + * Generated from protobuf field string source_ip = 3; + * @return string + */ + public function getSourceIp() + { + return $this->source_ip; + } + + /** + * Source IP address. + * + * Generated from protobuf field string source_ip = 3; + * @param string $var + * @return $this + */ + public function setSourceIp($var) + { + GPBUtil::checkString($var, True); + $this->source_ip = $var; + + return $this; + } + + /** + * Source port. + * + * Generated from protobuf field int32 source_port = 4; + * @return int + */ + public function getSourcePort() + { + return $this->source_port; + } + + /** + * Source port. + * + * Generated from protobuf field int32 source_port = 4; + * @param int $var + * @return $this + */ + public function setSourcePort($var) + { + GPBUtil::checkInt32($var); + $this->source_port = $var; + + return $this; + } + + /** + * IANA Internet Protocol Number such as TCP(6) and UDP(17). + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Connection.Protocol protocol = 5; + * @return int + */ + public function getProtocol() + { + return $this->protocol; + } + + /** + * IANA Internet Protocol Number such as TCP(6) and UDP(17). + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Connection.Protocol protocol = 5; + * @param int $var + * @return $this + */ + public function setProtocol($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Connection\Protocol::class); + $this->protocol = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Connection/Protocol.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Connection/Protocol.php new file mode 100644 index 000000000000..8c4837dac97d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Connection/Protocol.php @@ -0,0 +1,85 @@ +google.cloud.securitycenter.v1.Connection.Protocol + */ +class Protocol +{ + /** + * Unspecified protocol (not HOPOPT). + * + * Generated from protobuf enum PROTOCOL_UNSPECIFIED = 0; + */ + const PROTOCOL_UNSPECIFIED = 0; + /** + * Internet Control Message Protocol. + * + * Generated from protobuf enum ICMP = 1; + */ + const ICMP = 1; + /** + * Transmission Control Protocol. + * + * Generated from protobuf enum TCP = 6; + */ + const TCP = 6; + /** + * User Datagram Protocol. + * + * Generated from protobuf enum UDP = 17; + */ + const UDP = 17; + /** + * Generic Routing Encapsulation. + * + * Generated from protobuf enum GRE = 47; + */ + const GRE = 47; + /** + * Encap Security Payload. + * + * Generated from protobuf enum ESP = 50; + */ + const ESP = 50; + + private static $valueToName = [ + self::PROTOCOL_UNSPECIFIED => 'PROTOCOL_UNSPECIFIED', + self::ICMP => 'ICMP', + self::TCP => 'TCP', + self::UDP => 'UDP', + self::GRE => 'GRE', + self::ESP => 'ESP', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Protocol::class, \Google\Cloud\SecurityCenter\V1\Connection_Protocol::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Contact.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Contact.php new file mode 100644 index 000000000000..c930a46f7f51 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Contact.php @@ -0,0 +1,67 @@ +google.cloud.securitycenter.v1.Contact + */ +class Contact extends \Google\Protobuf\Internal\Message +{ + /** + * An email address. For example, "`person123@company.com`". + * + * Generated from protobuf field string email = 1; + */ + protected $email = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $email + * An email address. For example, "`person123@company.com`". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\ContactDetails::initOnce(); + parent::__construct($data); + } + + /** + * An email address. For example, "`person123@company.com`". + * + * Generated from protobuf field string email = 1; + * @return string + */ + public function getEmail() + { + return $this->email; + } + + /** + * An email address. For example, "`person123@company.com`". + * + * Generated from protobuf field string email = 1; + * @param string $var + * @return $this + */ + public function setEmail($var) + { + GPBUtil::checkString($var, True); + $this->email = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ContactDetails.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ContactDetails.php new file mode 100644 index 000000000000..fb1bd8fe5e82 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ContactDetails.php @@ -0,0 +1,67 @@ +google.cloud.securitycenter.v1.ContactDetails + */ +class ContactDetails extends \Google\Protobuf\Internal\Message +{ + /** + * A list of contacts + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Contact contacts = 1; + */ + private $contacts; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1\Contact>|\Google\Protobuf\Internal\RepeatedField $contacts + * A list of contacts + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\ContactDetails::initOnce(); + parent::__construct($data); + } + + /** + * A list of contacts + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Contact contacts = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getContacts() + { + return $this->contacts; + } + + /** + * A list of contacts + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Contact contacts = 1; + * @param array<\Google\Cloud\SecurityCenter\V1\Contact>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setContacts($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Contact::class); + $this->contacts = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Container.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Container.php new file mode 100644 index 000000000000..cacdf9423402 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Container.php @@ -0,0 +1,221 @@ +google.cloud.securitycenter.v1.Container + */ +class Container extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the container. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Container image URI provided when configuring a pod or container. This + * string can identify a container image version using mutable tags. + * + * Generated from protobuf field string uri = 2; + */ + protected $uri = ''; + /** + * Optional container image ID, if provided by the container runtime. Uniquely + * identifies the container image launched using a container image digest. + * + * Generated from protobuf field string image_id = 3; + */ + protected $image_id = ''; + /** + * Container labels, as provided by the container runtime. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Label labels = 4; + */ + private $labels; + /** + * The time that the container was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 5; + */ + protected $create_time = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Name of the container. + * @type string $uri + * Container image URI provided when configuring a pod or container. This + * string can identify a container image version using mutable tags. + * @type string $image_id + * Optional container image ID, if provided by the container runtime. Uniquely + * identifies the container image launched using a container image digest. + * @type array<\Google\Cloud\SecurityCenter\V1\Label>|\Google\Protobuf\Internal\RepeatedField $labels + * Container labels, as provided by the container runtime. + * @type \Google\Protobuf\Timestamp $create_time + * The time that the container was created. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Container::initOnce(); + parent::__construct($data); + } + + /** + * Name of the container. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Name of the container. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Container image URI provided when configuring a pod or container. This + * string can identify a container image version using mutable tags. + * + * Generated from protobuf field string uri = 2; + * @return string + */ + public function getUri() + { + return $this->uri; + } + + /** + * Container image URI provided when configuring a pod or container. This + * string can identify a container image version using mutable tags. + * + * Generated from protobuf field string uri = 2; + * @param string $var + * @return $this + */ + public function setUri($var) + { + GPBUtil::checkString($var, True); + $this->uri = $var; + + return $this; + } + + /** + * Optional container image ID, if provided by the container runtime. Uniquely + * identifies the container image launched using a container image digest. + * + * Generated from protobuf field string image_id = 3; + * @return string + */ + public function getImageId() + { + return $this->image_id; + } + + /** + * Optional container image ID, if provided by the container runtime. Uniquely + * identifies the container image launched using a container image digest. + * + * Generated from protobuf field string image_id = 3; + * @param string $var + * @return $this + */ + public function setImageId($var) + { + GPBUtil::checkString($var, True); + $this->image_id = $var; + + return $this; + } + + /** + * Container labels, as provided by the container runtime. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Label labels = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getLabels() + { + return $this->labels; + } + + /** + * Container labels, as provided by the container runtime. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Label labels = 4; + * @param array<\Google\Cloud\SecurityCenter\V1\Label>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setLabels($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Label::class); + $this->labels = $arr; + + return $this; + } + + /** + * The time that the container was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 5; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCreateTime() + { + return $this->create_time; + } + + public function hasCreateTime() + { + return isset($this->create_time); + } + + public function clearCreateTime() + { + unset($this->create_time); + } + + /** + * The time that the container was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 5; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->create_time = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateBigQueryExportRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateBigQueryExportRequest.php new file mode 100644 index 000000000000..a893628cb305 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateBigQueryExportRequest.php @@ -0,0 +1,188 @@ +google.cloud.securitycenter.v1.CreateBigQueryExportRequest + */ +class CreateBigQueryExportRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the parent resource of the new BigQuery export. Its + * format is "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The BigQuery export being created. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.BigQueryExport big_query_export = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $big_query_export = null; + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * + * Generated from protobuf field string big_query_export_id = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $big_query_export_id = ''; + + /** + * @param string $parent Required. The name of the parent resource of the new BigQuery export. Its + * format is "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". Please see + * {@see SecurityCenterClient::projectName()} for help formatting this field. + * @param \Google\Cloud\SecurityCenter\V1\BigQueryExport $bigQueryExport Required. The BigQuery export being created. + * @param string $bigQueryExportId Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * + * @return \Google\Cloud\SecurityCenter\V1\CreateBigQueryExportRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\SecurityCenter\V1\BigQueryExport $bigQueryExport, string $bigQueryExportId): self + { + return (new self()) + ->setParent($parent) + ->setBigQueryExport($bigQueryExport) + ->setBigQueryExportId($bigQueryExportId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The name of the parent resource of the new BigQuery export. Its + * format is "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * @type \Google\Cloud\SecurityCenter\V1\BigQueryExport $big_query_export + * Required. The BigQuery export being created. + * @type string $big_query_export_id + * Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the parent resource of the new BigQuery export. Its + * format is "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The name of the parent resource of the new BigQuery export. Its + * format is "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. The BigQuery export being created. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.BigQueryExport big_query_export = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1\BigQueryExport|null + */ + public function getBigQueryExport() + { + return $this->big_query_export; + } + + public function hasBigQueryExport() + { + return isset($this->big_query_export); + } + + public function clearBigQueryExport() + { + unset($this->big_query_export); + } + + /** + * Required. The BigQuery export being created. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.BigQueryExport big_query_export = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1\BigQueryExport $var + * @return $this + */ + public function setBigQueryExport($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\BigQueryExport::class); + $this->big_query_export = $var; + + return $this; + } + + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * + * Generated from protobuf field string big_query_export_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getBigQueryExportId() + { + return $this->big_query_export_id; + } + + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * + * Generated from protobuf field string big_query_export_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setBigQueryExportId($var) + { + GPBUtil::checkString($var, True); + $this->big_query_export_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateFindingRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateFindingRequest.php new file mode 100644 index 000000000000..8e04470b0fa5 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateFindingRequest.php @@ -0,0 +1,183 @@ +google.cloud.securitycenter.v1.CreateFindingRequest + */ +class CreateFindingRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + * + * Generated from protobuf field string finding_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $finding_id = ''; + /** + * Required. The Finding being created. The name and security_marks will be + * ignored as they are both output only fields on this resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $finding = null; + + /** + * @param string $parent Required. Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". Please see + * {@see SecurityCenterClient::sourceName()} for help formatting this field. + * @param string $findingId Required. Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + * @param \Google\Cloud\SecurityCenter\V1\Finding $finding Required. The Finding being created. The name and security_marks will be + * ignored as they are both output only fields on this resource. + * + * @return \Google\Cloud\SecurityCenter\V1\CreateFindingRequest + * + * @experimental + */ + public static function build(string $parent, string $findingId, \Google\Cloud\SecurityCenter\V1\Finding $finding): self + { + return (new self()) + ->setParent($parent) + ->setFindingId($findingId) + ->setFinding($finding); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". + * @type string $finding_id + * Required. Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + * @type \Google\Cloud\SecurityCenter\V1\Finding $finding + * Required. The Finding being created. The name and security_marks will be + * ignored as they are both output only fields on this resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + * + * Generated from protobuf field string finding_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getFindingId() + { + return $this->finding_id; + } + + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + * + * Generated from protobuf field string finding_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setFindingId($var) + { + GPBUtil::checkString($var, True); + $this->finding_id = $var; + + return $this; + } + + /** + * Required. The Finding being created. The name and security_marks will be + * ignored as they are both output only fields on this resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1\Finding|null + */ + public function getFinding() + { + return $this->finding; + } + + public function hasFinding() + { + return isset($this->finding); + } + + public function clearFinding() + { + unset($this->finding); + } + + /** + * Required. The Finding being created. The name and security_marks will be + * ignored as they are both output only fields on this resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1\Finding $var + * @return $this + */ + public function setFinding($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Finding::class); + $this->finding = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateMuteConfigRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateMuteConfigRequest.php new file mode 100644 index 000000000000..c4fe4a60a0fa --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateMuteConfigRequest.php @@ -0,0 +1,206 @@ +google.cloud.securitycenter.v1.CreateMuteConfigRequest + */ +class CreateMuteConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the new mute configs's parent. Its format is + * "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The mute config being created. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.MuteConfig mute_config = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $mute_config = null; + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * + * Generated from protobuf field string mute_config_id = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $mute_config_id = ''; + + /** + * @param string $parent Required. Resource name of the new mute configs's parent. Its format is + * "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". Please see + * {@see SecurityCenterClient::projectName()} for help formatting this field. + * @param \Google\Cloud\SecurityCenter\V1\MuteConfig $muteConfig Required. The mute config being created. + * + * @return \Google\Cloud\SecurityCenter\V1\CreateMuteConfigRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\SecurityCenter\V1\MuteConfig $muteConfig): self + { + return (new self()) + ->setParent($parent) + ->setMuteConfig($muteConfig); + } + + /** + * @param string $parent Required. Resource name of the new mute configs's parent. Its format is + * "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". Please see + * {@see SecurityCenterClient::projectName()} for help formatting this field. + * @param \Google\Cloud\SecurityCenter\V1\MuteConfig $muteConfig Required. The mute config being created. + * @param string $muteConfigId Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * + * @return \Google\Cloud\SecurityCenter\V1\CreateMuteConfigRequest + * + * @experimental + */ + public static function buildFromParentMuteConfigMuteConfigId(string $parent, \Google\Cloud\SecurityCenter\V1\MuteConfig $muteConfig, string $muteConfigId): self + { + return (new self()) + ->setParent($parent) + ->setMuteConfig($muteConfig) + ->setMuteConfigId($muteConfigId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Resource name of the new mute configs's parent. Its format is + * "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * @type \Google\Cloud\SecurityCenter\V1\MuteConfig $mute_config + * Required. The mute config being created. + * @type string $mute_config_id + * Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the new mute configs's parent. Its format is + * "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Resource name of the new mute configs's parent. Its format is + * "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. The mute config being created. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.MuteConfig mute_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1\MuteConfig|null + */ + public function getMuteConfig() + { + return $this->mute_config; + } + + public function hasMuteConfig() + { + return isset($this->mute_config); + } + + public function clearMuteConfig() + { + unset($this->mute_config); + } + + /** + * Required. The mute config being created. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.MuteConfig mute_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1\MuteConfig $var + * @return $this + */ + public function setMuteConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\MuteConfig::class); + $this->mute_config = $var; + + return $this; + } + + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * + * Generated from protobuf field string mute_config_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getMuteConfigId() + { + return $this->mute_config_id; + } + + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * + * Generated from protobuf field string mute_config_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setMuteConfigId($var) + { + GPBUtil::checkString($var, True); + $this->mute_config_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateNotificationConfigRequest.php new file mode 100644 index 000000000000..325c4600eb91 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateNotificationConfigRequest.php @@ -0,0 +1,218 @@ +google.cloud.securitycenter.v1.CreateNotificationConfigRequest + */ +class CreateNotificationConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the new notification config's parent. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. + * Unique identifier provided by the client within the parent scope. + * It must be between 1 and 128 characters and contain alphanumeric + * characters, underscores, or hyphens only. + * + * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $config_id = ''; + /** + * Required. The notification config being created. The name and the service + * account will be ignored as they are both output only fields on this + * resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.NotificationConfig notification_config = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $notification_config = null; + + /** + * @param string $parent Required. Resource name of the new notification config's parent. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". Please see + * {@see SecurityCenterClient::projectName()} for help formatting this field. + * @param string $configId Required. + * Unique identifier provided by the client within the parent scope. + * It must be between 1 and 128 characters and contain alphanumeric + * characters, underscores, or hyphens only. + * @param \Google\Cloud\SecurityCenter\V1\NotificationConfig $notificationConfig Required. The notification config being created. The name and the service + * account will be ignored as they are both output only fields on this + * resource. + * + * @return \Google\Cloud\SecurityCenter\V1\CreateNotificationConfigRequest + * + * @experimental + */ + public static function build(string $parent, string $configId, \Google\Cloud\SecurityCenter\V1\NotificationConfig $notificationConfig): self + { + return (new self()) + ->setParent($parent) + ->setConfigId($configId) + ->setNotificationConfig($notificationConfig); + } + + /** + * @param string $parent Required. Resource name of the new notification config's parent. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". Please see + * {@see SecurityCenterClient::projectName()} for help formatting this field. + * @param \Google\Cloud\SecurityCenter\V1\NotificationConfig $notificationConfig Required. The notification config being created. The name and the service + * account will be ignored as they are both output only fields on this + * resource. + * + * @return \Google\Cloud\SecurityCenter\V1\CreateNotificationConfigRequest + * + * @experimental + */ + public static function buildFromParentNotificationConfig(string $parent, \Google\Cloud\SecurityCenter\V1\NotificationConfig $notificationConfig): self + { + return (new self()) + ->setParent($parent) + ->setNotificationConfig($notificationConfig); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Resource name of the new notification config's parent. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * @type string $config_id + * Required. + * Unique identifier provided by the client within the parent scope. + * It must be between 1 and 128 characters and contain alphanumeric + * characters, underscores, or hyphens only. + * @type \Google\Cloud\SecurityCenter\V1\NotificationConfig $notification_config + * Required. The notification config being created. The name and the service + * account will be ignored as they are both output only fields on this + * resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the new notification config's parent. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Resource name of the new notification config's parent. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. + * Unique identifier provided by the client within the parent scope. + * It must be between 1 and 128 characters and contain alphanumeric + * characters, underscores, or hyphens only. + * + * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getConfigId() + { + return $this->config_id; + } + + /** + * Required. + * Unique identifier provided by the client within the parent scope. + * It must be between 1 and 128 characters and contain alphanumeric + * characters, underscores, or hyphens only. + * + * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setConfigId($var) + { + GPBUtil::checkString($var, True); + $this->config_id = $var; + + return $this; + } + + /** + * Required. The notification config being created. The name and the service + * account will be ignored as they are both output only fields on this + * resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.NotificationConfig notification_config = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1\NotificationConfig|null + */ + public function getNotificationConfig() + { + return $this->notification_config; + } + + public function hasNotificationConfig() + { + return isset($this->notification_config); + } + + public function clearNotificationConfig() + { + unset($this->notification_config); + } + + /** + * Required. The notification config being created. The name and the service + * account will be ignored as they are both output only fields on this + * resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.NotificationConfig notification_config = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1\NotificationConfig $var + * @return $this + */ + public function setNotificationConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\NotificationConfig::class); + $this->notification_config = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateSecurityHealthAnalyticsCustomModuleRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateSecurityHealthAnalyticsCustomModuleRequest.php new file mode 100644 index 000000000000..20d1e474ef68 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateSecurityHealthAnalyticsCustomModuleRequest.php @@ -0,0 +1,152 @@ +google.cloud.securitycenter.v1.CreateSecurityHealthAnalyticsCustomModuleRequest + */ +class CreateSecurityHealthAnalyticsCustomModuleRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the new custom module's parent. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. SecurityHealthAnalytics custom module to create. The provided + * name is ignored and reset with provided parent information and + * server-generated ID. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_module = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $security_health_analytics_custom_module = null; + + /** + * @param string $parent Required. Resource name of the new custom module's parent. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * Please see {@see SecurityCenterClient::securityHealthAnalyticsSettingsName()} for help formatting this field. + * @param \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule $securityHealthAnalyticsCustomModule Required. SecurityHealthAnalytics custom module to create. The provided + * name is ignored and reset with provided parent information and + * server-generated ID. + * + * @return \Google\Cloud\SecurityCenter\V1\CreateSecurityHealthAnalyticsCustomModuleRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule $securityHealthAnalyticsCustomModule): self + { + return (new self()) + ->setParent($parent) + ->setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Resource name of the new custom module's parent. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * @type \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule $security_health_analytics_custom_module + * Required. SecurityHealthAnalytics custom module to create. The provided + * name is ignored and reset with provided parent information and + * server-generated ID. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the new custom module's parent. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Resource name of the new custom module's parent. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. SecurityHealthAnalytics custom module to create. The provided + * name is ignored and reset with provided parent information and + * server-generated ID. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_module = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule|null + */ + public function getSecurityHealthAnalyticsCustomModule() + { + return $this->security_health_analytics_custom_module; + } + + public function hasSecurityHealthAnalyticsCustomModule() + { + return isset($this->security_health_analytics_custom_module); + } + + public function clearSecurityHealthAnalyticsCustomModule() + { + unset($this->security_health_analytics_custom_module); + } + + /** + * Required. SecurityHealthAnalytics custom module to create. The provided + * name is ignored and reset with provided parent information and + * server-generated ID. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_module = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule $var + * @return $this + */ + public function setSecurityHealthAnalyticsCustomModule($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule::class); + $this->security_health_analytics_custom_module = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateSourceRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateSourceRequest.php new file mode 100644 index 000000000000..bfec5e12c859 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateSourceRequest.php @@ -0,0 +1,137 @@ +google.cloud.securitycenter.v1.CreateSourceRequest + */ +class CreateSourceRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The Source being created, only the display_name and description + * will be used. All other fields will be ignored. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Source source = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $source = null; + + /** + * @param string $parent Required. Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". Please see + * {@see SecurityCenterClient::organizationName()} for help formatting this field. + * @param \Google\Cloud\SecurityCenter\V1\Source $source Required. The Source being created, only the display_name and description + * will be used. All other fields will be ignored. + * + * @return \Google\Cloud\SecurityCenter\V1\CreateSourceRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\SecurityCenter\V1\Source $source): self + { + return (new self()) + ->setParent($parent) + ->setSource($source); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + * @type \Google\Cloud\SecurityCenter\V1\Source $source + * Required. The Source being created, only the display_name and description + * will be used. All other fields will be ignored. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. The Source being created, only the display_name and description + * will be used. All other fields will be ignored. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Source source = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1\Source|null + */ + public function getSource() + { + return $this->source; + } + + public function hasSource() + { + return isset($this->source); + } + + public function clearSource() + { + unset($this->source); + } + + /** + * Required. The Source being created, only the display_name and description + * will be used. All other fields will be ignored. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Source source = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1\Source $var + * @return $this + */ + public function setSource($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Source::class); + $this->source = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig.php new file mode 100644 index 000000000000..3e04151b84f1 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig.php @@ -0,0 +1,297 @@ +google.cloud.securitycenter.v1.CustomConfig + */ +class CustomConfig extends \Google\Protobuf\Internal\Message +{ + /** + * The CEL expression to evaluate to produce findings. When the expression + * evaluates to true against a resource, a finding is generated. + * + * Generated from protobuf field .google.type.Expr predicate = 1; + */ + protected $predicate = null; + /** + * Custom output properties. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig.CustomOutputSpec custom_output = 2; + */ + protected $custom_output = null; + /** + * The resource types that the custom module operates on. Each custom module + * can specify up to 5 resource types. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig.ResourceSelector resource_selector = 3; + */ + protected $resource_selector = null; + /** + * The severity to assign to findings generated by the module. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig.Severity severity = 4; + */ + protected $severity = 0; + /** + * Text that describes the vulnerability or misconfiguration that the custom + * module detects. This explanation is returned with each finding instance to + * help investigators understand the detected issue. The text must be enclosed + * in quotation marks. + * + * Generated from protobuf field string description = 5; + */ + protected $description = ''; + /** + * An explanation of the recommended steps that security teams can take to + * resolve the detected issue. This explanation is returned with each finding + * generated by this module in the `nextSteps` property of the finding JSON. + * + * Generated from protobuf field string recommendation = 6; + */ + protected $recommendation = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Type\Expr $predicate + * The CEL expression to evaluate to produce findings. When the expression + * evaluates to true against a resource, a finding is generated. + * @type \Google\Cloud\SecurityCenter\V1\CustomConfig\CustomOutputSpec $custom_output + * Custom output properties. + * @type \Google\Cloud\SecurityCenter\V1\CustomConfig\ResourceSelector $resource_selector + * The resource types that the custom module operates on. Each custom module + * can specify up to 5 resource types. + * @type int $severity + * The severity to assign to findings generated by the module. + * @type string $description + * Text that describes the vulnerability or misconfiguration that the custom + * module detects. This explanation is returned with each finding instance to + * help investigators understand the detected issue. The text must be enclosed + * in quotation marks. + * @type string $recommendation + * An explanation of the recommended steps that security teams can take to + * resolve the detected issue. This explanation is returned with each finding + * generated by this module in the `nextSteps` property of the finding JSON. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecurityHealthAnalyticsCustomConfig::initOnce(); + parent::__construct($data); + } + + /** + * The CEL expression to evaluate to produce findings. When the expression + * evaluates to true against a resource, a finding is generated. + * + * Generated from protobuf field .google.type.Expr predicate = 1; + * @return \Google\Type\Expr|null + */ + public function getPredicate() + { + return $this->predicate; + } + + public function hasPredicate() + { + return isset($this->predicate); + } + + public function clearPredicate() + { + unset($this->predicate); + } + + /** + * The CEL expression to evaluate to produce findings. When the expression + * evaluates to true against a resource, a finding is generated. + * + * Generated from protobuf field .google.type.Expr predicate = 1; + * @param \Google\Type\Expr $var + * @return $this + */ + public function setPredicate($var) + { + GPBUtil::checkMessage($var, \Google\Type\Expr::class); + $this->predicate = $var; + + return $this; + } + + /** + * Custom output properties. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig.CustomOutputSpec custom_output = 2; + * @return \Google\Cloud\SecurityCenter\V1\CustomConfig\CustomOutputSpec|null + */ + public function getCustomOutput() + { + return $this->custom_output; + } + + public function hasCustomOutput() + { + return isset($this->custom_output); + } + + public function clearCustomOutput() + { + unset($this->custom_output); + } + + /** + * Custom output properties. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig.CustomOutputSpec custom_output = 2; + * @param \Google\Cloud\SecurityCenter\V1\CustomConfig\CustomOutputSpec $var + * @return $this + */ + public function setCustomOutput($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\CustomConfig\CustomOutputSpec::class); + $this->custom_output = $var; + + return $this; + } + + /** + * The resource types that the custom module operates on. Each custom module + * can specify up to 5 resource types. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig.ResourceSelector resource_selector = 3; + * @return \Google\Cloud\SecurityCenter\V1\CustomConfig\ResourceSelector|null + */ + public function getResourceSelector() + { + return $this->resource_selector; + } + + public function hasResourceSelector() + { + return isset($this->resource_selector); + } + + public function clearResourceSelector() + { + unset($this->resource_selector); + } + + /** + * The resource types that the custom module operates on. Each custom module + * can specify up to 5 resource types. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig.ResourceSelector resource_selector = 3; + * @param \Google\Cloud\SecurityCenter\V1\CustomConfig\ResourceSelector $var + * @return $this + */ + public function setResourceSelector($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\CustomConfig\ResourceSelector::class); + $this->resource_selector = $var; + + return $this; + } + + /** + * The severity to assign to findings generated by the module. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig.Severity severity = 4; + * @return int + */ + public function getSeverity() + { + return $this->severity; + } + + /** + * The severity to assign to findings generated by the module. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig.Severity severity = 4; + * @param int $var + * @return $this + */ + public function setSeverity($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\CustomConfig\Severity::class); + $this->severity = $var; + + return $this; + } + + /** + * Text that describes the vulnerability or misconfiguration that the custom + * module detects. This explanation is returned with each finding instance to + * help investigators understand the detected issue. The text must be enclosed + * in quotation marks. + * + * Generated from protobuf field string description = 5; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Text that describes the vulnerability or misconfiguration that the custom + * module detects. This explanation is returned with each finding instance to + * help investigators understand the detected issue. The text must be enclosed + * in quotation marks. + * + * Generated from protobuf field string description = 5; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * An explanation of the recommended steps that security teams can take to + * resolve the detected issue. This explanation is returned with each finding + * generated by this module in the `nextSteps` property of the finding JSON. + * + * Generated from protobuf field string recommendation = 6; + * @return string + */ + public function getRecommendation() + { + return $this->recommendation; + } + + /** + * An explanation of the recommended steps that security teams can take to + * resolve the detected issue. This explanation is returned with each finding + * generated by this module in the `nextSteps` property of the finding JSON. + * + * Generated from protobuf field string recommendation = 6; + * @param string $var + * @return $this + */ + public function setRecommendation($var) + { + GPBUtil::checkString($var, True); + $this->recommendation = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/CustomOutputSpec.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/CustomOutputSpec.php new file mode 100644 index 000000000000..f5fd23d84efd --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/CustomOutputSpec.php @@ -0,0 +1,73 @@ +google.cloud.securitycenter.v1.CustomConfig.CustomOutputSpec + */ +class CustomOutputSpec extends \Google\Protobuf\Internal\Message +{ + /** + * A list of custom output properties to add to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.CustomConfig.CustomOutputSpec.Property properties = 1; + */ + private $properties; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1\CustomConfig\CustomOutputSpec\Property>|\Google\Protobuf\Internal\RepeatedField $properties + * A list of custom output properties to add to the finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecurityHealthAnalyticsCustomConfig::initOnce(); + parent::__construct($data); + } + + /** + * A list of custom output properties to add to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.CustomConfig.CustomOutputSpec.Property properties = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getProperties() + { + return $this->properties; + } + + /** + * A list of custom output properties to add to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.CustomConfig.CustomOutputSpec.Property properties = 1; + * @param array<\Google\Cloud\SecurityCenter\V1\CustomConfig\CustomOutputSpec\Property>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setProperties($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\CustomConfig\CustomOutputSpec\Property::class); + $this->properties = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(CustomOutputSpec::class, \Google\Cloud\SecurityCenter\V1\CustomConfig_CustomOutputSpec::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/CustomOutputSpec/Property.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/CustomOutputSpec/Property.php new file mode 100644 index 000000000000..4ab8ce23ac6a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/CustomOutputSpec/Property.php @@ -0,0 +1,122 @@ +google.cloud.securitycenter.v1.CustomConfig.CustomOutputSpec.Property + */ +class Property extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the property for the custom output. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The CEL expression for the custom output. A resource property can be + * specified to return the value of the property or a text string enclosed + * in quotation marks. + * + * Generated from protobuf field .google.type.Expr value_expression = 2; + */ + protected $value_expression = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Name of the property for the custom output. + * @type \Google\Type\Expr $value_expression + * The CEL expression for the custom output. A resource property can be + * specified to return the value of the property or a text string enclosed + * in quotation marks. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecurityHealthAnalyticsCustomConfig::initOnce(); + parent::__construct($data); + } + + /** + * Name of the property for the custom output. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Name of the property for the custom output. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The CEL expression for the custom output. A resource property can be + * specified to return the value of the property or a text string enclosed + * in quotation marks. + * + * Generated from protobuf field .google.type.Expr value_expression = 2; + * @return \Google\Type\Expr|null + */ + public function getValueExpression() + { + return $this->value_expression; + } + + public function hasValueExpression() + { + return isset($this->value_expression); + } + + public function clearValueExpression() + { + unset($this->value_expression); + } + + /** + * The CEL expression for the custom output. A resource property can be + * specified to return the value of the property or a text string enclosed + * in quotation marks. + * + * Generated from protobuf field .google.type.Expr value_expression = 2; + * @param \Google\Type\Expr $var + * @return $this + */ + public function setValueExpression($var) + { + GPBUtil::checkMessage($var, \Google\Type\Expr::class); + $this->value_expression = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Property::class, \Google\Cloud\SecurityCenter\V1\CustomConfig_CustomOutputSpec_Property::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/ResourceSelector.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/ResourceSelector.php new file mode 100644 index 000000000000..f16fa3fe0910 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/ResourceSelector.php @@ -0,0 +1,70 @@ +google.cloud.securitycenter.v1.CustomConfig.ResourceSelector + */ +class ResourceSelector extends \Google\Protobuf\Internal\Message +{ + /** + * The resource types to run the detector on. + * + * Generated from protobuf field repeated string resource_types = 1; + */ + private $resource_types; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\RepeatedField $resource_types + * The resource types to run the detector on. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecurityHealthAnalyticsCustomConfig::initOnce(); + parent::__construct($data); + } + + /** + * The resource types to run the detector on. + * + * Generated from protobuf field repeated string resource_types = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getResourceTypes() + { + return $this->resource_types; + } + + /** + * The resource types to run the detector on. + * + * Generated from protobuf field repeated string resource_types = 1; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setResourceTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->resource_types = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ResourceSelector::class, \Google\Cloud\SecurityCenter\V1\CustomConfig_ResourceSelector::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/Severity.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/Severity.php new file mode 100644 index 000000000000..1ad1df7543cd --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/Severity.php @@ -0,0 +1,78 @@ +google.cloud.securitycenter.v1.CustomConfig.Severity + */ +class Severity +{ + /** + * Unspecified severity. + * + * Generated from protobuf enum SEVERITY_UNSPECIFIED = 0; + */ + const SEVERITY_UNSPECIFIED = 0; + /** + * Critical severity. + * + * Generated from protobuf enum CRITICAL = 1; + */ + const CRITICAL = 1; + /** + * High severity. + * + * Generated from protobuf enum HIGH = 2; + */ + const HIGH = 2; + /** + * Medium severity. + * + * Generated from protobuf enum MEDIUM = 3; + */ + const MEDIUM = 3; + /** + * Low severity. + * + * Generated from protobuf enum LOW = 4; + */ + const LOW = 4; + + private static $valueToName = [ + self::SEVERITY_UNSPECIFIED => 'SEVERITY_UNSPECIFIED', + self::CRITICAL => 'CRITICAL', + self::HIGH => 'HIGH', + self::MEDIUM => 'MEDIUM', + self::LOW => 'LOW', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Severity::class, \Google\Cloud\SecurityCenter\V1\CustomConfig_Severity::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve.php new file mode 100644 index 000000000000..fe9664a68a58 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve.php @@ -0,0 +1,330 @@ +google.cloud.securitycenter.v1.Cve + */ +class Cve extends \Google\Protobuf\Internal\Message +{ + /** + * The unique identifier for the vulnerability. e.g. CVE-2021-34527 + * + * Generated from protobuf field string id = 1; + */ + protected $id = ''; + /** + * Additional information about the CVE. + * e.g. https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527 + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Reference references = 2; + */ + private $references; + /** + * Describe Common Vulnerability Scoring System specified at + * https://www.first.org/cvss/v3.1/specification-document + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3 cvssv3 = 3; + */ + protected $cvssv3 = null; + /** + * Whether upstream fix is available for the CVE. + * + * Generated from protobuf field bool upstream_fix_available = 4; + */ + protected $upstream_fix_available = false; + /** + * The potential impact of the vulnerability if it was to be exploited. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cve.RiskRating impact = 5; + */ + protected $impact = 0; + /** + * The exploitation activity of the vulnerability in the wild. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cve.ExploitationActivity exploitation_activity = 6; + */ + protected $exploitation_activity = 0; + /** + * Whether or not the vulnerability has been observed in the wild. + * + * Generated from protobuf field bool observed_in_the_wild = 7; + */ + protected $observed_in_the_wild = false; + /** + * Whether or not the vulnerability was zero day when the finding was + * published. + * + * Generated from protobuf field bool zero_day = 8; + */ + protected $zero_day = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $id + * The unique identifier for the vulnerability. e.g. CVE-2021-34527 + * @type array<\Google\Cloud\SecurityCenter\V1\Reference>|\Google\Protobuf\Internal\RepeatedField $references + * Additional information about the CVE. + * e.g. https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527 + * @type \Google\Cloud\SecurityCenter\V1\Cvssv3 $cvssv3 + * Describe Common Vulnerability Scoring System specified at + * https://www.first.org/cvss/v3.1/specification-document + * @type bool $upstream_fix_available + * Whether upstream fix is available for the CVE. + * @type int $impact + * The potential impact of the vulnerability if it was to be exploited. + * @type int $exploitation_activity + * The exploitation activity of the vulnerability in the wild. + * @type bool $observed_in_the_wild + * Whether or not the vulnerability has been observed in the wild. + * @type bool $zero_day + * Whether or not the vulnerability was zero day when the finding was + * published. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Vulnerability::initOnce(); + parent::__construct($data); + } + + /** + * The unique identifier for the vulnerability. e.g. CVE-2021-34527 + * + * Generated from protobuf field string id = 1; + * @return string + */ + public function getId() + { + return $this->id; + } + + /** + * The unique identifier for the vulnerability. e.g. CVE-2021-34527 + * + * Generated from protobuf field string id = 1; + * @param string $var + * @return $this + */ + public function setId($var) + { + GPBUtil::checkString($var, True); + $this->id = $var; + + return $this; + } + + /** + * Additional information about the CVE. + * e.g. https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527 + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Reference references = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getReferences() + { + return $this->references; + } + + /** + * Additional information about the CVE. + * e.g. https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527 + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Reference references = 2; + * @param array<\Google\Cloud\SecurityCenter\V1\Reference>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setReferences($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Reference::class); + $this->references = $arr; + + return $this; + } + + /** + * Describe Common Vulnerability Scoring System specified at + * https://www.first.org/cvss/v3.1/specification-document + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3 cvssv3 = 3; + * @return \Google\Cloud\SecurityCenter\V1\Cvssv3|null + */ + public function getCvssv3() + { + return $this->cvssv3; + } + + public function hasCvssv3() + { + return isset($this->cvssv3); + } + + public function clearCvssv3() + { + unset($this->cvssv3); + } + + /** + * Describe Common Vulnerability Scoring System specified at + * https://www.first.org/cvss/v3.1/specification-document + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3 cvssv3 = 3; + * @param \Google\Cloud\SecurityCenter\V1\Cvssv3 $var + * @return $this + */ + public function setCvssv3($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Cvssv3::class); + $this->cvssv3 = $var; + + return $this; + } + + /** + * Whether upstream fix is available for the CVE. + * + * Generated from protobuf field bool upstream_fix_available = 4; + * @return bool + */ + public function getUpstreamFixAvailable() + { + return $this->upstream_fix_available; + } + + /** + * Whether upstream fix is available for the CVE. + * + * Generated from protobuf field bool upstream_fix_available = 4; + * @param bool $var + * @return $this + */ + public function setUpstreamFixAvailable($var) + { + GPBUtil::checkBool($var); + $this->upstream_fix_available = $var; + + return $this; + } + + /** + * The potential impact of the vulnerability if it was to be exploited. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cve.RiskRating impact = 5; + * @return int + */ + public function getImpact() + { + return $this->impact; + } + + /** + * The potential impact of the vulnerability if it was to be exploited. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cve.RiskRating impact = 5; + * @param int $var + * @return $this + */ + public function setImpact($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cve\RiskRating::class); + $this->impact = $var; + + return $this; + } + + /** + * The exploitation activity of the vulnerability in the wild. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cve.ExploitationActivity exploitation_activity = 6; + * @return int + */ + public function getExploitationActivity() + { + return $this->exploitation_activity; + } + + /** + * The exploitation activity of the vulnerability in the wild. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cve.ExploitationActivity exploitation_activity = 6; + * @param int $var + * @return $this + */ + public function setExploitationActivity($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cve\ExploitationActivity::class); + $this->exploitation_activity = $var; + + return $this; + } + + /** + * Whether or not the vulnerability has been observed in the wild. + * + * Generated from protobuf field bool observed_in_the_wild = 7; + * @return bool + */ + public function getObservedInTheWild() + { + return $this->observed_in_the_wild; + } + + /** + * Whether or not the vulnerability has been observed in the wild. + * + * Generated from protobuf field bool observed_in_the_wild = 7; + * @param bool $var + * @return $this + */ + public function setObservedInTheWild($var) + { + GPBUtil::checkBool($var); + $this->observed_in_the_wild = $var; + + return $this; + } + + /** + * Whether or not the vulnerability was zero day when the finding was + * published. + * + * Generated from protobuf field bool zero_day = 8; + * @return bool + */ + public function getZeroDay() + { + return $this->zero_day; + } + + /** + * Whether or not the vulnerability was zero day when the finding was + * published. + * + * Generated from protobuf field bool zero_day = 8; + * @param bool $var + * @return $this + */ + public function setZeroDay($var) + { + GPBUtil::checkBool($var); + $this->zero_day = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve/ExploitationActivity.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve/ExploitationActivity.php new file mode 100644 index 000000000000..fcc54b82f136 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve/ExploitationActivity.php @@ -0,0 +1,87 @@ +google.cloud.securitycenter.v1.Cve.ExploitationActivity + */ +class ExploitationActivity +{ + /** + * Invalid or empty value. + * + * Generated from protobuf enum EXPLOITATION_ACTIVITY_UNSPECIFIED = 0; + */ + const EXPLOITATION_ACTIVITY_UNSPECIFIED = 0; + /** + * Exploitation has been reported or confirmed to widely occur. + * + * Generated from protobuf enum WIDE = 1; + */ + const WIDE = 1; + /** + * Limited reported or confirmed exploitation activities. + * + * Generated from protobuf enum CONFIRMED = 2; + */ + const CONFIRMED = 2; + /** + * Exploit is publicly available. + * + * Generated from protobuf enum AVAILABLE = 3; + */ + const AVAILABLE = 3; + /** + * No known exploitation activity, but has a high potential for + * exploitation. + * + * Generated from protobuf enum ANTICIPATED = 4; + */ + const ANTICIPATED = 4; + /** + * No known exploitation activity. + * + * Generated from protobuf enum NO_KNOWN = 5; + */ + const NO_KNOWN = 5; + + private static $valueToName = [ + self::EXPLOITATION_ACTIVITY_UNSPECIFIED => 'EXPLOITATION_ACTIVITY_UNSPECIFIED', + self::WIDE => 'WIDE', + self::CONFIRMED => 'CONFIRMED', + self::AVAILABLE => 'AVAILABLE', + self::ANTICIPATED => 'ANTICIPATED', + self::NO_KNOWN => 'NO_KNOWN', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ExploitationActivity::class, \Google\Cloud\SecurityCenter\V1\Cve_ExploitationActivity::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve/RiskRating.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve/RiskRating.php new file mode 100644 index 000000000000..b18aa86caf9c --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve/RiskRating.php @@ -0,0 +1,83 @@ +google.cloud.securitycenter.v1.Cve.RiskRating + */ +class RiskRating +{ + /** + * Invalid or empty value. + * + * Generated from protobuf enum RISK_RATING_UNSPECIFIED = 0; + */ + const RISK_RATING_UNSPECIFIED = 0; + /** + * Exploitation would have little to no security impact. + * + * Generated from protobuf enum LOW = 1; + */ + const LOW = 1; + /** + * Exploitation would enable attackers to perform activities, or could allow + * attackers to have a direct impact, but would require additional steps. + * + * Generated from protobuf enum MEDIUM = 2; + */ + const MEDIUM = 2; + /** + * Exploitation would enable attackers to have a notable direct impact + * without needing to overcome any major mitigating factors. + * + * Generated from protobuf enum HIGH = 3; + */ + const HIGH = 3; + /** + * Exploitation would fundamentally undermine the security of affected + * systems, enable actors to perform significant attacks with minimal + * effort, with little to no mitigating factors to overcome. + * + * Generated from protobuf enum CRITICAL = 4; + */ + const CRITICAL = 4; + + private static $valueToName = [ + self::RISK_RATING_UNSPECIFIED => 'RISK_RATING_UNSPECIFIED', + self::LOW => 'LOW', + self::MEDIUM => 'MEDIUM', + self::HIGH => 'HIGH', + self::CRITICAL => 'CRITICAL', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(RiskRating::class, \Google\Cloud\SecurityCenter\V1\Cve_RiskRating::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3.php new file mode 100644 index 000000000000..d7eb6ed7aaa5 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3.php @@ -0,0 +1,391 @@ +google.cloud.securitycenter.v1.Cvssv3 + */ +class Cvssv3 extends \Google\Protobuf\Internal\Message +{ + /** + * The base score is a function of the base metric scores. + * + * Generated from protobuf field double base_score = 1; + */ + protected $base_score = 0.0; + /** + * Base Metrics + * Represents the intrinsic characteristics of a vulnerability that are + * constant over time and across user environments. + * This metric reflects the context by which vulnerability exploitation is + * possible. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.AttackVector attack_vector = 5; + */ + protected $attack_vector = 0; + /** + * This metric describes the conditions beyond the attacker's control that + * must exist in order to exploit the vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.AttackComplexity attack_complexity = 6; + */ + protected $attack_complexity = 0; + /** + * This metric describes the level of privileges an attacker must possess + * before successfully exploiting the vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.PrivilegesRequired privileges_required = 7; + */ + protected $privileges_required = 0; + /** + * This metric captures the requirement for a human user, other than the + * attacker, to participate in the successful compromise of the vulnerable + * component. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.UserInteraction user_interaction = 8; + */ + protected $user_interaction = 0; + /** + * The Scope metric captures whether a vulnerability in one vulnerable + * component impacts resources in components beyond its security scope. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Scope scope = 9; + */ + protected $scope = 0; + /** + * This metric measures the impact to the confidentiality of the information + * resources managed by a software component due to a successfully exploited + * vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Impact confidentiality_impact = 10; + */ + protected $confidentiality_impact = 0; + /** + * This metric measures the impact to integrity of a successfully exploited + * vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Impact integrity_impact = 11; + */ + protected $integrity_impact = 0; + /** + * This metric measures the impact to the availability of the impacted + * component resulting from a successfully exploited vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Impact availability_impact = 12; + */ + protected $availability_impact = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type float $base_score + * The base score is a function of the base metric scores. + * @type int $attack_vector + * Base Metrics + * Represents the intrinsic characteristics of a vulnerability that are + * constant over time and across user environments. + * This metric reflects the context by which vulnerability exploitation is + * possible. + * @type int $attack_complexity + * This metric describes the conditions beyond the attacker's control that + * must exist in order to exploit the vulnerability. + * @type int $privileges_required + * This metric describes the level of privileges an attacker must possess + * before successfully exploiting the vulnerability. + * @type int $user_interaction + * This metric captures the requirement for a human user, other than the + * attacker, to participate in the successful compromise of the vulnerable + * component. + * @type int $scope + * The Scope metric captures whether a vulnerability in one vulnerable + * component impacts resources in components beyond its security scope. + * @type int $confidentiality_impact + * This metric measures the impact to the confidentiality of the information + * resources managed by a software component due to a successfully exploited + * vulnerability. + * @type int $integrity_impact + * This metric measures the impact to integrity of a successfully exploited + * vulnerability. + * @type int $availability_impact + * This metric measures the impact to the availability of the impacted + * component resulting from a successfully exploited vulnerability. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Vulnerability::initOnce(); + parent::__construct($data); + } + + /** + * The base score is a function of the base metric scores. + * + * Generated from protobuf field double base_score = 1; + * @return float + */ + public function getBaseScore() + { + return $this->base_score; + } + + /** + * The base score is a function of the base metric scores. + * + * Generated from protobuf field double base_score = 1; + * @param float $var + * @return $this + */ + public function setBaseScore($var) + { + GPBUtil::checkDouble($var); + $this->base_score = $var; + + return $this; + } + + /** + * Base Metrics + * Represents the intrinsic characteristics of a vulnerability that are + * constant over time and across user environments. + * This metric reflects the context by which vulnerability exploitation is + * possible. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.AttackVector attack_vector = 5; + * @return int + */ + public function getAttackVector() + { + return $this->attack_vector; + } + + /** + * Base Metrics + * Represents the intrinsic characteristics of a vulnerability that are + * constant over time and across user environments. + * This metric reflects the context by which vulnerability exploitation is + * possible. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.AttackVector attack_vector = 5; + * @param int $var + * @return $this + */ + public function setAttackVector($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cvssv3\AttackVector::class); + $this->attack_vector = $var; + + return $this; + } + + /** + * This metric describes the conditions beyond the attacker's control that + * must exist in order to exploit the vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.AttackComplexity attack_complexity = 6; + * @return int + */ + public function getAttackComplexity() + { + return $this->attack_complexity; + } + + /** + * This metric describes the conditions beyond the attacker's control that + * must exist in order to exploit the vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.AttackComplexity attack_complexity = 6; + * @param int $var + * @return $this + */ + public function setAttackComplexity($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cvssv3\AttackComplexity::class); + $this->attack_complexity = $var; + + return $this; + } + + /** + * This metric describes the level of privileges an attacker must possess + * before successfully exploiting the vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.PrivilegesRequired privileges_required = 7; + * @return int + */ + public function getPrivilegesRequired() + { + return $this->privileges_required; + } + + /** + * This metric describes the level of privileges an attacker must possess + * before successfully exploiting the vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.PrivilegesRequired privileges_required = 7; + * @param int $var + * @return $this + */ + public function setPrivilegesRequired($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cvssv3\PrivilegesRequired::class); + $this->privileges_required = $var; + + return $this; + } + + /** + * This metric captures the requirement for a human user, other than the + * attacker, to participate in the successful compromise of the vulnerable + * component. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.UserInteraction user_interaction = 8; + * @return int + */ + public function getUserInteraction() + { + return $this->user_interaction; + } + + /** + * This metric captures the requirement for a human user, other than the + * attacker, to participate in the successful compromise of the vulnerable + * component. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.UserInteraction user_interaction = 8; + * @param int $var + * @return $this + */ + public function setUserInteraction($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cvssv3\UserInteraction::class); + $this->user_interaction = $var; + + return $this; + } + + /** + * The Scope metric captures whether a vulnerability in one vulnerable + * component impacts resources in components beyond its security scope. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Scope scope = 9; + * @return int + */ + public function getScope() + { + return $this->scope; + } + + /** + * The Scope metric captures whether a vulnerability in one vulnerable + * component impacts resources in components beyond its security scope. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Scope scope = 9; + * @param int $var + * @return $this + */ + public function setScope($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cvssv3\Scope::class); + $this->scope = $var; + + return $this; + } + + /** + * This metric measures the impact to the confidentiality of the information + * resources managed by a software component due to a successfully exploited + * vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Impact confidentiality_impact = 10; + * @return int + */ + public function getConfidentialityImpact() + { + return $this->confidentiality_impact; + } + + /** + * This metric measures the impact to the confidentiality of the information + * resources managed by a software component due to a successfully exploited + * vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Impact confidentiality_impact = 10; + * @param int $var + * @return $this + */ + public function setConfidentialityImpact($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cvssv3\Impact::class); + $this->confidentiality_impact = $var; + + return $this; + } + + /** + * This metric measures the impact to integrity of a successfully exploited + * vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Impact integrity_impact = 11; + * @return int + */ + public function getIntegrityImpact() + { + return $this->integrity_impact; + } + + /** + * This metric measures the impact to integrity of a successfully exploited + * vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Impact integrity_impact = 11; + * @param int $var + * @return $this + */ + public function setIntegrityImpact($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cvssv3\Impact::class); + $this->integrity_impact = $var; + + return $this; + } + + /** + * This metric measures the impact to the availability of the impacted + * component resulting from a successfully exploited vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Impact availability_impact = 12; + * @return int + */ + public function getAvailabilityImpact() + { + return $this->availability_impact; + } + + /** + * This metric measures the impact to the availability of the impacted + * component resulting from a successfully exploited vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Impact availability_impact = 12; + * @param int $var + * @return $this + */ + public function setAvailabilityImpact($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cvssv3\Impact::class); + $this->availability_impact = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/AttackComplexity.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/AttackComplexity.php new file mode 100644 index 000000000000..179eeffa8a5e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/AttackComplexity.php @@ -0,0 +1,71 @@ +google.cloud.securitycenter.v1.Cvssv3.AttackComplexity + */ +class AttackComplexity +{ + /** + * Invalid value. + * + * Generated from protobuf enum ATTACK_COMPLEXITY_UNSPECIFIED = 0; + */ + const ATTACK_COMPLEXITY_UNSPECIFIED = 0; + /** + * Specialized access conditions or extenuating circumstances do not exist. + * An attacker can expect repeatable success when attacking the vulnerable + * component. + * + * Generated from protobuf enum ATTACK_COMPLEXITY_LOW = 1; + */ + const ATTACK_COMPLEXITY_LOW = 1; + /** + * A successful attack depends on conditions beyond the attacker's control. + * That is, a successful attack cannot be accomplished at will, but requires + * the attacker to invest in some measurable amount of effort in preparation + * or execution against the vulnerable component before a successful attack + * can be expected. + * + * Generated from protobuf enum ATTACK_COMPLEXITY_HIGH = 2; + */ + const ATTACK_COMPLEXITY_HIGH = 2; + + private static $valueToName = [ + self::ATTACK_COMPLEXITY_UNSPECIFIED => 'ATTACK_COMPLEXITY_UNSPECIFIED', + self::ATTACK_COMPLEXITY_LOW => 'ATTACK_COMPLEXITY_LOW', + self::ATTACK_COMPLEXITY_HIGH => 'ATTACK_COMPLEXITY_HIGH', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AttackComplexity::class, \Google\Cloud\SecurityCenter\V1\Cvssv3_AttackComplexity::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/AttackVector.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/AttackVector.php new file mode 100644 index 000000000000..fa6acfc9dc84 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/AttackVector.php @@ -0,0 +1,84 @@ +google.cloud.securitycenter.v1.Cvssv3.AttackVector + */ +class AttackVector +{ + /** + * Invalid value. + * + * Generated from protobuf enum ATTACK_VECTOR_UNSPECIFIED = 0; + */ + const ATTACK_VECTOR_UNSPECIFIED = 0; + /** + * The vulnerable component is bound to the network stack and the set of + * possible attackers extends beyond the other options listed below, up to + * and including the entire Internet. + * + * Generated from protobuf enum ATTACK_VECTOR_NETWORK = 1; + */ + const ATTACK_VECTOR_NETWORK = 1; + /** + * The vulnerable component is bound to the network stack, but the attack is + * limited at the protocol level to a logically adjacent topology. + * + * Generated from protobuf enum ATTACK_VECTOR_ADJACENT = 2; + */ + const ATTACK_VECTOR_ADJACENT = 2; + /** + * The vulnerable component is not bound to the network stack and the + * attacker's path is via read/write/execute capabilities. + * + * Generated from protobuf enum ATTACK_VECTOR_LOCAL = 3; + */ + const ATTACK_VECTOR_LOCAL = 3; + /** + * The attack requires the attacker to physically touch or manipulate the + * vulnerable component. + * + * Generated from protobuf enum ATTACK_VECTOR_PHYSICAL = 4; + */ + const ATTACK_VECTOR_PHYSICAL = 4; + + private static $valueToName = [ + self::ATTACK_VECTOR_UNSPECIFIED => 'ATTACK_VECTOR_UNSPECIFIED', + self::ATTACK_VECTOR_NETWORK => 'ATTACK_VECTOR_NETWORK', + self::ATTACK_VECTOR_ADJACENT => 'ATTACK_VECTOR_ADJACENT', + self::ATTACK_VECTOR_LOCAL => 'ATTACK_VECTOR_LOCAL', + self::ATTACK_VECTOR_PHYSICAL => 'ATTACK_VECTOR_PHYSICAL', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AttackVector::class, \Google\Cloud\SecurityCenter\V1\Cvssv3_AttackVector::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/Impact.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/Impact.php new file mode 100644 index 000000000000..027aced5e553 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/Impact.php @@ -0,0 +1,73 @@ +google.cloud.securitycenter.v1.Cvssv3.Impact + */ +class Impact +{ + /** + * Invalid value. + * + * Generated from protobuf enum IMPACT_UNSPECIFIED = 0; + */ + const IMPACT_UNSPECIFIED = 0; + /** + * High impact. + * + * Generated from protobuf enum IMPACT_HIGH = 1; + */ + const IMPACT_HIGH = 1; + /** + * Low impact. + * + * Generated from protobuf enum IMPACT_LOW = 2; + */ + const IMPACT_LOW = 2; + /** + * No impact. + * + * Generated from protobuf enum IMPACT_NONE = 3; + */ + const IMPACT_NONE = 3; + + private static $valueToName = [ + self::IMPACT_UNSPECIFIED => 'IMPACT_UNSPECIFIED', + self::IMPACT_HIGH => 'IMPACT_HIGH', + self::IMPACT_LOW => 'IMPACT_LOW', + self::IMPACT_NONE => 'IMPACT_NONE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Impact::class, \Google\Cloud\SecurityCenter\V1\Cvssv3_Impact::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/PrivilegesRequired.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/PrivilegesRequired.php new file mode 100644 index 000000000000..29fef4718691 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/PrivilegesRequired.php @@ -0,0 +1,79 @@ +google.cloud.securitycenter.v1.Cvssv3.PrivilegesRequired + */ +class PrivilegesRequired +{ + /** + * Invalid value. + * + * Generated from protobuf enum PRIVILEGES_REQUIRED_UNSPECIFIED = 0; + */ + const PRIVILEGES_REQUIRED_UNSPECIFIED = 0; + /** + * The attacker is unauthorized prior to attack, and therefore does not + * require any access to settings or files of the vulnerable system to + * carry out an attack. + * + * Generated from protobuf enum PRIVILEGES_REQUIRED_NONE = 1; + */ + const PRIVILEGES_REQUIRED_NONE = 1; + /** + * The attacker requires privileges that provide basic user capabilities + * that could normally affect only settings and files owned by a user. + * Alternatively, an attacker with Low privileges has the ability to access + * only non-sensitive resources. + * + * Generated from protobuf enum PRIVILEGES_REQUIRED_LOW = 2; + */ + const PRIVILEGES_REQUIRED_LOW = 2; + /** + * The attacker requires privileges that provide significant (e.g., + * administrative) control over the vulnerable component allowing access to + * component-wide settings and files. + * + * Generated from protobuf enum PRIVILEGES_REQUIRED_HIGH = 3; + */ + const PRIVILEGES_REQUIRED_HIGH = 3; + + private static $valueToName = [ + self::PRIVILEGES_REQUIRED_UNSPECIFIED => 'PRIVILEGES_REQUIRED_UNSPECIFIED', + self::PRIVILEGES_REQUIRED_NONE => 'PRIVILEGES_REQUIRED_NONE', + self::PRIVILEGES_REQUIRED_LOW => 'PRIVILEGES_REQUIRED_LOW', + self::PRIVILEGES_REQUIRED_HIGH => 'PRIVILEGES_REQUIRED_HIGH', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(PrivilegesRequired::class, \Google\Cloud\SecurityCenter\V1\Cvssv3_PrivilegesRequired::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/Scope.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/Scope.php new file mode 100644 index 000000000000..cb0e08038f76 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/Scope.php @@ -0,0 +1,67 @@ +google.cloud.securitycenter.v1.Cvssv3.Scope + */ +class Scope +{ + /** + * Invalid value. + * + * Generated from protobuf enum SCOPE_UNSPECIFIED = 0; + */ + const SCOPE_UNSPECIFIED = 0; + /** + * An exploited vulnerability can only affect resources managed by the same + * security authority. + * + * Generated from protobuf enum SCOPE_UNCHANGED = 1; + */ + const SCOPE_UNCHANGED = 1; + /** + * An exploited vulnerability can affect resources beyond the security scope + * managed by the security authority of the vulnerable component. + * + * Generated from protobuf enum SCOPE_CHANGED = 2; + */ + const SCOPE_CHANGED = 2; + + private static $valueToName = [ + self::SCOPE_UNSPECIFIED => 'SCOPE_UNSPECIFIED', + self::SCOPE_UNCHANGED => 'SCOPE_UNCHANGED', + self::SCOPE_CHANGED => 'SCOPE_CHANGED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Scope::class, \Google\Cloud\SecurityCenter\V1\Cvssv3_Scope::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/UserInteraction.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/UserInteraction.php new file mode 100644 index 000000000000..305d85c574e2 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/UserInteraction.php @@ -0,0 +1,67 @@ +google.cloud.securitycenter.v1.Cvssv3.UserInteraction + */ +class UserInteraction +{ + /** + * Invalid value. + * + * Generated from protobuf enum USER_INTERACTION_UNSPECIFIED = 0; + */ + const USER_INTERACTION_UNSPECIFIED = 0; + /** + * The vulnerable system can be exploited without interaction from any user. + * + * Generated from protobuf enum USER_INTERACTION_NONE = 1; + */ + const USER_INTERACTION_NONE = 1; + /** + * Successful exploitation of this vulnerability requires a user to take + * some action before the vulnerability can be exploited. + * + * Generated from protobuf enum USER_INTERACTION_REQUIRED = 2; + */ + const USER_INTERACTION_REQUIRED = 2; + + private static $valueToName = [ + self::USER_INTERACTION_UNSPECIFIED => 'USER_INTERACTION_UNSPECIFIED', + self::USER_INTERACTION_NONE => 'USER_INTERACTION_NONE', + self::USER_INTERACTION_REQUIRED => 'USER_INTERACTION_REQUIRED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(UserInteraction::class, \Google\Cloud\SecurityCenter\V1\Cvssv3_UserInteraction::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Database.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Database.php new file mode 100644 index 000000000000..832630602155 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Database.php @@ -0,0 +1,287 @@ +google.cloud.securitycenter.v1.Database + */ +class Database extends \Google\Protobuf\Internal\Message +{ + /** + * Some database resources may not have the [full resource + * name](https://google.aip.dev/122#full-resource-names) populated because + * these resource types are not yet supported by Cloud Asset Inventory (e.g. + * Cloud SQL databases). In these cases only the display name will be + * provided. + * The [full resource name](https://google.aip.dev/122#full-resource-names) of + * the database that the user connected to, if it is supported by Cloud Asset + * Inventory. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The human-readable name of the database that the user connected to. + * + * Generated from protobuf field string display_name = 2; + */ + protected $display_name = ''; + /** + * The username used to connect to the database. The username might not be an + * IAM principal and does not have a set format. + * + * Generated from protobuf field string user_name = 3; + */ + protected $user_name = ''; + /** + * The SQL statement that is associated with the database access. + * + * Generated from protobuf field string query = 4; + */ + protected $query = ''; + /** + * The target usernames, roles, or groups of an SQL privilege grant, which is + * not an IAM policy change. + * + * Generated from protobuf field repeated string grantees = 5; + */ + private $grantees; + /** + * The version of the database, for example, POSTGRES_14. + * See [the complete + * list](https://cloud.google.com/sql/docs/mysql/admin-api/rest/v1/SqlDatabaseVersion). + * + * Generated from protobuf field string version = 6; + */ + protected $version = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Some database resources may not have the [full resource + * name](https://google.aip.dev/122#full-resource-names) populated because + * these resource types are not yet supported by Cloud Asset Inventory (e.g. + * Cloud SQL databases). In these cases only the display name will be + * provided. + * The [full resource name](https://google.aip.dev/122#full-resource-names) of + * the database that the user connected to, if it is supported by Cloud Asset + * Inventory. + * @type string $display_name + * The human-readable name of the database that the user connected to. + * @type string $user_name + * The username used to connect to the database. The username might not be an + * IAM principal and does not have a set format. + * @type string $query + * The SQL statement that is associated with the database access. + * @type array|\Google\Protobuf\Internal\RepeatedField $grantees + * The target usernames, roles, or groups of an SQL privilege grant, which is + * not an IAM policy change. + * @type string $version + * The version of the database, for example, POSTGRES_14. + * See [the complete + * list](https://cloud.google.com/sql/docs/mysql/admin-api/rest/v1/SqlDatabaseVersion). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Database::initOnce(); + parent::__construct($data); + } + + /** + * Some database resources may not have the [full resource + * name](https://google.aip.dev/122#full-resource-names) populated because + * these resource types are not yet supported by Cloud Asset Inventory (e.g. + * Cloud SQL databases). In these cases only the display name will be + * provided. + * The [full resource name](https://google.aip.dev/122#full-resource-names) of + * the database that the user connected to, if it is supported by Cloud Asset + * Inventory. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Some database resources may not have the [full resource + * name](https://google.aip.dev/122#full-resource-names) populated because + * these resource types are not yet supported by Cloud Asset Inventory (e.g. + * Cloud SQL databases). In these cases only the display name will be + * provided. + * The [full resource name](https://google.aip.dev/122#full-resource-names) of + * the database that the user connected to, if it is supported by Cloud Asset + * Inventory. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The human-readable name of the database that the user connected to. + * + * Generated from protobuf field string display_name = 2; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * The human-readable name of the database that the user connected to. + * + * Generated from protobuf field string display_name = 2; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * The username used to connect to the database. The username might not be an + * IAM principal and does not have a set format. + * + * Generated from protobuf field string user_name = 3; + * @return string + */ + public function getUserName() + { + return $this->user_name; + } + + /** + * The username used to connect to the database. The username might not be an + * IAM principal and does not have a set format. + * + * Generated from protobuf field string user_name = 3; + * @param string $var + * @return $this + */ + public function setUserName($var) + { + GPBUtil::checkString($var, True); + $this->user_name = $var; + + return $this; + } + + /** + * The SQL statement that is associated with the database access. + * + * Generated from protobuf field string query = 4; + * @return string + */ + public function getQuery() + { + return $this->query; + } + + /** + * The SQL statement that is associated with the database access. + * + * Generated from protobuf field string query = 4; + * @param string $var + * @return $this + */ + public function setQuery($var) + { + GPBUtil::checkString($var, True); + $this->query = $var; + + return $this; + } + + /** + * The target usernames, roles, or groups of an SQL privilege grant, which is + * not an IAM policy change. + * + * Generated from protobuf field repeated string grantees = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getGrantees() + { + return $this->grantees; + } + + /** + * The target usernames, roles, or groups of an SQL privilege grant, which is + * not an IAM policy change. + * + * Generated from protobuf field repeated string grantees = 5; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setGrantees($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->grantees = $arr; + + return $this; + } + + /** + * The version of the database, for example, POSTGRES_14. + * See [the complete + * list](https://cloud.google.com/sql/docs/mysql/admin-api/rest/v1/SqlDatabaseVersion). + * + * Generated from protobuf field string version = 6; + * @return string + */ + public function getVersion() + { + return $this->version; + } + + /** + * The version of the database, for example, POSTGRES_14. + * See [the complete + * list](https://cloud.google.com/sql/docs/mysql/admin-api/rest/v1/SqlDatabaseVersion). + * + * Generated from protobuf field string version = 6; + * @param string $var + * @return $this + */ + public function setVersion($var) + { + GPBUtil::checkString($var, True); + $this->version = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteBigQueryExportRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteBigQueryExportRequest.php new file mode 100644 index 000000000000..503020359328 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteBigQueryExportRequest.php @@ -0,0 +1,96 @@ +google.cloud.securitycenter.v1.DeleteBigQueryExportRequest + */ +class DeleteBigQueryExportRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the BigQuery export to delete. Its format is + * organizations/{organization}/bigQueryExports/{export_id}, + * folders/{folder}/bigQueryExports/{export_id}, or + * projects/{project}/bigQueryExports/{export_id} + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. The name of the BigQuery export to delete. Its format is + * organizations/{organization}/bigQueryExports/{export_id}, + * folders/{folder}/bigQueryExports/{export_id}, or + * projects/{project}/bigQueryExports/{export_id} + * Please see {@see SecurityCenterClient::bigQueryExportName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V1\DeleteBigQueryExportRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The name of the BigQuery export to delete. Its format is + * organizations/{organization}/bigQueryExports/{export_id}, + * folders/{folder}/bigQueryExports/{export_id}, or + * projects/{project}/bigQueryExports/{export_id} + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the BigQuery export to delete. Its format is + * organizations/{organization}/bigQueryExports/{export_id}, + * folders/{folder}/bigQueryExports/{export_id}, or + * projects/{project}/bigQueryExports/{export_id} + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The name of the BigQuery export to delete. Its format is + * organizations/{organization}/bigQueryExports/{export_id}, + * folders/{folder}/bigQueryExports/{export_id}, or + * projects/{project}/bigQueryExports/{export_id} + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteMuteConfigRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteMuteConfigRequest.php new file mode 100644 index 000000000000..a598b80efffb --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteMuteConfigRequest.php @@ -0,0 +1,96 @@ +google.cloud.securitycenter.v1.DeleteMuteConfigRequest + */ +class DeleteMuteConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the mute config to delete. Its format is + * organizations/{organization}/muteConfigs/{config_id}, + * folders/{folder}/muteConfigs/{config_id}, or + * projects/{project}/muteConfigs/{config_id} + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Name of the mute config to delete. Its format is + * organizations/{organization}/muteConfigs/{config_id}, + * folders/{folder}/muteConfigs/{config_id}, or + * projects/{project}/muteConfigs/{config_id} + * Please see {@see SecurityCenterClient::muteConfigName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V1\DeleteMuteConfigRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the mute config to delete. Its format is + * organizations/{organization}/muteConfigs/{config_id}, + * folders/{folder}/muteConfigs/{config_id}, or + * projects/{project}/muteConfigs/{config_id} + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the mute config to delete. Its format is + * organizations/{organization}/muteConfigs/{config_id}, + * folders/{folder}/muteConfigs/{config_id}, or + * projects/{project}/muteConfigs/{config_id} + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the mute config to delete. Its format is + * organizations/{organization}/muteConfigs/{config_id}, + * folders/{folder}/muteConfigs/{config_id}, or + * projects/{project}/muteConfigs/{config_id} + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteNotificationConfigRequest.php new file mode 100644 index 000000000000..d08650df3d0f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteNotificationConfigRequest.php @@ -0,0 +1,96 @@ +google.cloud.securitycenter.v1.DeleteNotificationConfigRequest + */ +class DeleteNotificationConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the notification config to delete. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]", + * "folders/[folder_id]/notificationConfigs/[config_id]", + * or "projects/[project_id]/notificationConfigs/[config_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Name of the notification config to delete. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]", + * "folders/[folder_id]/notificationConfigs/[config_id]", + * or "projects/[project_id]/notificationConfigs/[config_id]". Please see + * {@see SecurityCenterClient::notificationConfigName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V1\DeleteNotificationConfigRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the notification config to delete. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]", + * "folders/[folder_id]/notificationConfigs/[config_id]", + * or "projects/[project_id]/notificationConfigs/[config_id]". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the notification config to delete. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]", + * "folders/[folder_id]/notificationConfigs/[config_id]", + * or "projects/[project_id]/notificationConfigs/[config_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the notification config to delete. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]", + * "folders/[folder_id]/notificationConfigs/[config_id]", + * or "projects/[project_id]/notificationConfigs/[config_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteSecurityHealthAnalyticsCustomModuleRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteSecurityHealthAnalyticsCustomModuleRequest.php new file mode 100644 index 000000000000..60ddfdedb227 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteSecurityHealthAnalyticsCustomModuleRequest.php @@ -0,0 +1,101 @@ +google.cloud.securitycenter.v1.DeleteSecurityHealthAnalyticsCustomModuleRequest + */ +class DeleteSecurityHealthAnalyticsCustomModuleRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the custom module to delete. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", + * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Name of the custom module to delete. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", + * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" + * Please see {@see SecurityCenterClient::securityHealthAnalyticsCustomModuleName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V1\DeleteSecurityHealthAnalyticsCustomModuleRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the custom module to delete. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", + * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the custom module to delete. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", + * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the custom module to delete. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", + * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EffectiveSecurityHealthAnalyticsCustomModule.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EffectiveSecurityHealthAnalyticsCustomModule.php new file mode 100644 index 000000000000..e16fe3e3ff88 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EffectiveSecurityHealthAnalyticsCustomModule.php @@ -0,0 +1,223 @@ +google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule + */ +class EffectiveSecurityHealthAnalyticsCustomModule extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The resource name of the custom module. + * Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * or + * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Output only. The user-specified configuration for the module. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig custom_config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $custom_config = null; + /** + * Output only. The effective state of enablement for the module at the given + * level of the hierarchy. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule.EnablementState enablement_state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $enablement_state = 0; + /** + * Output only. The display name for the custom module. The name must be + * between 1 and 128 characters, start with a lowercase letter, and contain + * alphanumeric characters or underscores only. + * + * Generated from protobuf field string display_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $display_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The resource name of the custom module. + * Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * or + * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" + * @type \Google\Cloud\SecurityCenter\V1\CustomConfig $custom_config + * Output only. The user-specified configuration for the module. + * @type int $enablement_state + * Output only. The effective state of enablement for the module at the given + * level of the hierarchy. + * @type string $display_name + * Output only. The display name for the custom module. The name must be + * between 1 and 128 characters, start with a lowercase letter, and contain + * alphanumeric characters or underscores only. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\EffectiveSecurityHealthAnalyticsCustomModule::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The resource name of the custom module. + * Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * or + * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Output only. The resource name of the custom module. + * Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * or + * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Output only. The user-specified configuration for the module. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig custom_config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Cloud\SecurityCenter\V1\CustomConfig|null + */ + public function getCustomConfig() + { + return $this->custom_config; + } + + public function hasCustomConfig() + { + return isset($this->custom_config); + } + + public function clearCustomConfig() + { + unset($this->custom_config); + } + + /** + * Output only. The user-specified configuration for the module. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig custom_config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\SecurityCenter\V1\CustomConfig $var + * @return $this + */ + public function setCustomConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\CustomConfig::class); + $this->custom_config = $var; + + return $this; + } + + /** + * Output only. The effective state of enablement for the module at the given + * level of the hierarchy. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule.EnablementState enablement_state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getEnablementState() + { + return $this->enablement_state; + } + + /** + * Output only. The effective state of enablement for the module at the given + * level of the hierarchy. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule.EnablementState enablement_state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setEnablementState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\EffectiveSecurityHealthAnalyticsCustomModule\EnablementState::class); + $this->enablement_state = $var; + + return $this; + } + + /** + * Output only. The display name for the custom module. The name must be + * between 1 and 128 characters, start with a lowercase letter, and contain + * alphanumeric characters or underscores only. + * + * Generated from protobuf field string display_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * Output only. The display name for the custom module. The name must be + * between 1 and 128 characters, start with a lowercase letter, and contain + * alphanumeric characters or underscores only. + * + * Generated from protobuf field string display_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EffectiveSecurityHealthAnalyticsCustomModule/EnablementState.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EffectiveSecurityHealthAnalyticsCustomModule/EnablementState.php new file mode 100644 index 000000000000..8a5a60c564f6 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EffectiveSecurityHealthAnalyticsCustomModule/EnablementState.php @@ -0,0 +1,64 @@ +google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule.EnablementState + */ +class EnablementState +{ + /** + * Unspecified enablement state. + * + * Generated from protobuf enum ENABLEMENT_STATE_UNSPECIFIED = 0; + */ + const ENABLEMENT_STATE_UNSPECIFIED = 0; + /** + * The module is enabled at the given level. + * + * Generated from protobuf enum ENABLED = 1; + */ + const ENABLED = 1; + /** + * The module is disabled at the given level. + * + * Generated from protobuf enum DISABLED = 2; + */ + const DISABLED = 2; + + private static $valueToName = [ + self::ENABLEMENT_STATE_UNSPECIFIED => 'ENABLEMENT_STATE_UNSPECIFIED', + self::ENABLED => 'ENABLED', + self::DISABLED => 'DISABLED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(EnablementState::class, \Google\Cloud\SecurityCenter\V1\EffectiveSecurityHealthAnalyticsCustomModule_EnablementState::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EnvironmentVariable.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EnvironmentVariable.php new file mode 100644 index 000000000000..fc98632adc3f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EnvironmentVariable.php @@ -0,0 +1,102 @@ +google.cloud.securitycenter.v1.EnvironmentVariable + */ +class EnvironmentVariable extends \Google\Protobuf\Internal\Message +{ + /** + * Environment variable name as a JSON encoded string. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Environment variable value as a JSON encoded string. + * + * Generated from protobuf field string val = 2; + */ + protected $val = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Environment variable name as a JSON encoded string. + * @type string $val + * Environment variable value as a JSON encoded string. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Process::initOnce(); + parent::__construct($data); + } + + /** + * Environment variable name as a JSON encoded string. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Environment variable name as a JSON encoded string. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Environment variable value as a JSON encoded string. + * + * Generated from protobuf field string val = 2; + * @return string + */ + public function getVal() + { + return $this->val; + } + + /** + * Environment variable value as a JSON encoded string. + * + * Generated from protobuf field string val = 2; + * @param string $var + * @return $this + */ + public function setVal($var) + { + GPBUtil::checkString($var, True); + $this->val = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExfilResource.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExfilResource.php new file mode 100644 index 000000000000..830ad855f956 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExfilResource.php @@ -0,0 +1,121 @@ +google.cloud.securitycenter.v1.ExfilResource + */ +class ExfilResource extends \Google\Protobuf\Internal\Message +{ + /** + * The resource's [full resource + * name](https://cloud.google.com/apis/design/resource_names#full_resource_name). + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Subcomponents of the asset that was exfiltrated, like URIs used during + * exfiltration, table names, databases, and filenames. For example, multiple + * tables might have been exfiltrated from the same Cloud SQL instance, or + * multiple files might have been exfiltrated from the same Cloud Storage + * bucket. + * + * Generated from protobuf field repeated string components = 2; + */ + private $components; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The resource's [full resource + * name](https://cloud.google.com/apis/design/resource_names#full_resource_name). + * @type array|\Google\Protobuf\Internal\RepeatedField $components + * Subcomponents of the asset that was exfiltrated, like URIs used during + * exfiltration, table names, databases, and filenames. For example, multiple + * tables might have been exfiltrated from the same Cloud SQL instance, or + * multiple files might have been exfiltrated from the same Cloud Storage + * bucket. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Exfiltration::initOnce(); + parent::__construct($data); + } + + /** + * The resource's [full resource + * name](https://cloud.google.com/apis/design/resource_names#full_resource_name). + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The resource's [full resource + * name](https://cloud.google.com/apis/design/resource_names#full_resource_name). + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Subcomponents of the asset that was exfiltrated, like URIs used during + * exfiltration, table names, databases, and filenames. For example, multiple + * tables might have been exfiltrated from the same Cloud SQL instance, or + * multiple files might have been exfiltrated from the same Cloud Storage + * bucket. + * + * Generated from protobuf field repeated string components = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getComponents() + { + return $this->components; + } + + /** + * Subcomponents of the asset that was exfiltrated, like URIs used during + * exfiltration, table names, databases, and filenames. For example, multiple + * tables might have been exfiltrated from the same Cloud SQL instance, or + * multiple files might have been exfiltrated from the same Cloud Storage + * bucket. + * + * Generated from protobuf field repeated string components = 2; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setComponents($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->components = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Exfiltration.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Exfiltration.php new file mode 100644 index 000000000000..a8e7f4621a2c --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Exfiltration.php @@ -0,0 +1,150 @@ +google.cloud.securitycenter.v1.Exfiltration + */ +class Exfiltration extends \Google\Protobuf\Internal\Message +{ + /** + * If there are multiple sources, then the data is considered "joined" between + * them. For instance, BigQuery can join multiple tables, and each + * table would be considered a source. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ExfilResource sources = 1; + */ + private $sources; + /** + * If there are multiple targets, each target would get a complete copy of the + * "joined" source data. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ExfilResource targets = 2; + */ + private $targets; + /** + * Total exfiltrated bytes processed for the entire job. + * + * Generated from protobuf field int64 total_exfiltrated_bytes = 3; + */ + protected $total_exfiltrated_bytes = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1\ExfilResource>|\Google\Protobuf\Internal\RepeatedField $sources + * If there are multiple sources, then the data is considered "joined" between + * them. For instance, BigQuery can join multiple tables, and each + * table would be considered a source. + * @type array<\Google\Cloud\SecurityCenter\V1\ExfilResource>|\Google\Protobuf\Internal\RepeatedField $targets + * If there are multiple targets, each target would get a complete copy of the + * "joined" source data. + * @type int|string $total_exfiltrated_bytes + * Total exfiltrated bytes processed for the entire job. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Exfiltration::initOnce(); + parent::__construct($data); + } + + /** + * If there are multiple sources, then the data is considered "joined" between + * them. For instance, BigQuery can join multiple tables, and each + * table would be considered a source. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ExfilResource sources = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSources() + { + return $this->sources; + } + + /** + * If there are multiple sources, then the data is considered "joined" between + * them. For instance, BigQuery can join multiple tables, and each + * table would be considered a source. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ExfilResource sources = 1; + * @param array<\Google\Cloud\SecurityCenter\V1\ExfilResource>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSources($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\ExfilResource::class); + $this->sources = $arr; + + return $this; + } + + /** + * If there are multiple targets, each target would get a complete copy of the + * "joined" source data. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ExfilResource targets = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTargets() + { + return $this->targets; + } + + /** + * If there are multiple targets, each target would get a complete copy of the + * "joined" source data. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ExfilResource targets = 2; + * @param array<\Google\Cloud\SecurityCenter\V1\ExfilResource>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTargets($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\ExfilResource::class); + $this->targets = $arr; + + return $this; + } + + /** + * Total exfiltrated bytes processed for the entire job. + * + * Generated from protobuf field int64 total_exfiltrated_bytes = 3; + * @return int|string + */ + public function getTotalExfiltratedBytes() + { + return $this->total_exfiltrated_bytes; + } + + /** + * Total exfiltrated bytes processed for the entire job. + * + * Generated from protobuf field int64 total_exfiltrated_bytes = 3; + * @param int|string $var + * @return $this + */ + public function setTotalExfiltratedBytes($var) + { + GPBUtil::checkInt64($var); + $this->total_exfiltrated_bytes = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExternalSystem.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExternalSystem.php new file mode 100644 index 000000000000..345ab6fbe6d4 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExternalSystem.php @@ -0,0 +1,485 @@ +google.cloud.securitycenter.v1.ExternalSystem + */ +class ExternalSystem extends \Google\Protobuf\Internal\Message +{ + /** + * Full resource name of the external system, for example: + * "organizations/1234/sources/5678/findings/123456/externalSystems/jira", + * "folders/1234/sources/5678/findings/123456/externalSystems/jira", + * "projects/1234/sources/5678/findings/123456/externalSystems/jira" + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * References primary/secondary etc assignees in the external system. + * + * Generated from protobuf field repeated string assignees = 2; + */ + private $assignees; + /** + * The identifier that's used to track the finding's corresponding case in the + * external system. + * + * Generated from protobuf field string external_uid = 3; + */ + protected $external_uid = ''; + /** + * The most recent status of the finding's corresponding case, as reported by + * the external system. + * + * Generated from protobuf field string status = 4; + */ + protected $status = ''; + /** + * The time when the case was last updated, as reported by the external + * system. + * + * Generated from protobuf field .google.protobuf.Timestamp external_system_update_time = 5; + */ + protected $external_system_update_time = null; + /** + * The link to the finding's corresponding case in the external system. + * + * Generated from protobuf field string case_uri = 6; + */ + protected $case_uri = ''; + /** + * The priority of the finding's corresponding case in the external system. + * + * Generated from protobuf field string case_priority = 7; + */ + protected $case_priority = ''; + /** + * The SLA of the finding's corresponding case in the external system. + * + * Generated from protobuf field .google.protobuf.Timestamp case_sla = 9; + */ + protected $case_sla = null; + /** + * The time when the case was created, as reported by the external system. + * + * Generated from protobuf field .google.protobuf.Timestamp case_create_time = 10; + */ + protected $case_create_time = null; + /** + * The time when the case was closed, as reported by the external system. + * + * Generated from protobuf field .google.protobuf.Timestamp case_close_time = 11; + */ + protected $case_close_time = null; + /** + * Information about the ticket, if any, that is being used to track the + * resolution of the issue that is identified by this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.ExternalSystem.TicketInfo ticket_info = 8; + */ + protected $ticket_info = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Full resource name of the external system, for example: + * "organizations/1234/sources/5678/findings/123456/externalSystems/jira", + * "folders/1234/sources/5678/findings/123456/externalSystems/jira", + * "projects/1234/sources/5678/findings/123456/externalSystems/jira" + * @type array|\Google\Protobuf\Internal\RepeatedField $assignees + * References primary/secondary etc assignees in the external system. + * @type string $external_uid + * The identifier that's used to track the finding's corresponding case in the + * external system. + * @type string $status + * The most recent status of the finding's corresponding case, as reported by + * the external system. + * @type \Google\Protobuf\Timestamp $external_system_update_time + * The time when the case was last updated, as reported by the external + * system. + * @type string $case_uri + * The link to the finding's corresponding case in the external system. + * @type string $case_priority + * The priority of the finding's corresponding case in the external system. + * @type \Google\Protobuf\Timestamp $case_sla + * The SLA of the finding's corresponding case in the external system. + * @type \Google\Protobuf\Timestamp $case_create_time + * The time when the case was created, as reported by the external system. + * @type \Google\Protobuf\Timestamp $case_close_time + * The time when the case was closed, as reported by the external system. + * @type \Google\Cloud\SecurityCenter\V1\ExternalSystem\TicketInfo $ticket_info + * Information about the ticket, if any, that is being used to track the + * resolution of the issue that is identified by this finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\ExternalSystem::initOnce(); + parent::__construct($data); + } + + /** + * Full resource name of the external system, for example: + * "organizations/1234/sources/5678/findings/123456/externalSystems/jira", + * "folders/1234/sources/5678/findings/123456/externalSystems/jira", + * "projects/1234/sources/5678/findings/123456/externalSystems/jira" + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Full resource name of the external system, for example: + * "organizations/1234/sources/5678/findings/123456/externalSystems/jira", + * "folders/1234/sources/5678/findings/123456/externalSystems/jira", + * "projects/1234/sources/5678/findings/123456/externalSystems/jira" + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * References primary/secondary etc assignees in the external system. + * + * Generated from protobuf field repeated string assignees = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAssignees() + { + return $this->assignees; + } + + /** + * References primary/secondary etc assignees in the external system. + * + * Generated from protobuf field repeated string assignees = 2; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAssignees($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->assignees = $arr; + + return $this; + } + + /** + * The identifier that's used to track the finding's corresponding case in the + * external system. + * + * Generated from protobuf field string external_uid = 3; + * @return string + */ + public function getExternalUid() + { + return $this->external_uid; + } + + /** + * The identifier that's used to track the finding's corresponding case in the + * external system. + * + * Generated from protobuf field string external_uid = 3; + * @param string $var + * @return $this + */ + public function setExternalUid($var) + { + GPBUtil::checkString($var, True); + $this->external_uid = $var; + + return $this; + } + + /** + * The most recent status of the finding's corresponding case, as reported by + * the external system. + * + * Generated from protobuf field string status = 4; + * @return string + */ + public function getStatus() + { + return $this->status; + } + + /** + * The most recent status of the finding's corresponding case, as reported by + * the external system. + * + * Generated from protobuf field string status = 4; + * @param string $var + * @return $this + */ + public function setStatus($var) + { + GPBUtil::checkString($var, True); + $this->status = $var; + + return $this; + } + + /** + * The time when the case was last updated, as reported by the external + * system. + * + * Generated from protobuf field .google.protobuf.Timestamp external_system_update_time = 5; + * @return \Google\Protobuf\Timestamp|null + */ + public function getExternalSystemUpdateTime() + { + return $this->external_system_update_time; + } + + public function hasExternalSystemUpdateTime() + { + return isset($this->external_system_update_time); + } + + public function clearExternalSystemUpdateTime() + { + unset($this->external_system_update_time); + } + + /** + * The time when the case was last updated, as reported by the external + * system. + * + * Generated from protobuf field .google.protobuf.Timestamp external_system_update_time = 5; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setExternalSystemUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->external_system_update_time = $var; + + return $this; + } + + /** + * The link to the finding's corresponding case in the external system. + * + * Generated from protobuf field string case_uri = 6; + * @return string + */ + public function getCaseUri() + { + return $this->case_uri; + } + + /** + * The link to the finding's corresponding case in the external system. + * + * Generated from protobuf field string case_uri = 6; + * @param string $var + * @return $this + */ + public function setCaseUri($var) + { + GPBUtil::checkString($var, True); + $this->case_uri = $var; + + return $this; + } + + /** + * The priority of the finding's corresponding case in the external system. + * + * Generated from protobuf field string case_priority = 7; + * @return string + */ + public function getCasePriority() + { + return $this->case_priority; + } + + /** + * The priority of the finding's corresponding case in the external system. + * + * Generated from protobuf field string case_priority = 7; + * @param string $var + * @return $this + */ + public function setCasePriority($var) + { + GPBUtil::checkString($var, True); + $this->case_priority = $var; + + return $this; + } + + /** + * The SLA of the finding's corresponding case in the external system. + * + * Generated from protobuf field .google.protobuf.Timestamp case_sla = 9; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCaseSla() + { + return $this->case_sla; + } + + public function hasCaseSla() + { + return isset($this->case_sla); + } + + public function clearCaseSla() + { + unset($this->case_sla); + } + + /** + * The SLA of the finding's corresponding case in the external system. + * + * Generated from protobuf field .google.protobuf.Timestamp case_sla = 9; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCaseSla($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->case_sla = $var; + + return $this; + } + + /** + * The time when the case was created, as reported by the external system. + * + * Generated from protobuf field .google.protobuf.Timestamp case_create_time = 10; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCaseCreateTime() + { + return $this->case_create_time; + } + + public function hasCaseCreateTime() + { + return isset($this->case_create_time); + } + + public function clearCaseCreateTime() + { + unset($this->case_create_time); + } + + /** + * The time when the case was created, as reported by the external system. + * + * Generated from protobuf field .google.protobuf.Timestamp case_create_time = 10; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCaseCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->case_create_time = $var; + + return $this; + } + + /** + * The time when the case was closed, as reported by the external system. + * + * Generated from protobuf field .google.protobuf.Timestamp case_close_time = 11; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCaseCloseTime() + { + return $this->case_close_time; + } + + public function hasCaseCloseTime() + { + return isset($this->case_close_time); + } + + public function clearCaseCloseTime() + { + unset($this->case_close_time); + } + + /** + * The time when the case was closed, as reported by the external system. + * + * Generated from protobuf field .google.protobuf.Timestamp case_close_time = 11; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCaseCloseTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->case_close_time = $var; + + return $this; + } + + /** + * Information about the ticket, if any, that is being used to track the + * resolution of the issue that is identified by this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.ExternalSystem.TicketInfo ticket_info = 8; + * @return \Google\Cloud\SecurityCenter\V1\ExternalSystem\TicketInfo|null + */ + public function getTicketInfo() + { + return $this->ticket_info; + } + + public function hasTicketInfo() + { + return isset($this->ticket_info); + } + + public function clearTicketInfo() + { + unset($this->ticket_info); + } + + /** + * Information about the ticket, if any, that is being used to track the + * resolution of the issue that is identified by this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.ExternalSystem.TicketInfo ticket_info = 8; + * @param \Google\Cloud\SecurityCenter\V1\ExternalSystem\TicketInfo $var + * @return $this + */ + public function setTicketInfo($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\ExternalSystem\TicketInfo::class); + $this->ticket_info = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExternalSystem/TicketInfo.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExternalSystem/TicketInfo.php new file mode 100644 index 000000000000..5f07523664f1 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExternalSystem/TicketInfo.php @@ -0,0 +1,255 @@ +google.cloud.securitycenter.v1.ExternalSystem.TicketInfo + */ +class TicketInfo extends \Google\Protobuf\Internal\Message +{ + /** + * The identifier of the ticket in the ticket system. + * + * Generated from protobuf field string id = 1; + */ + protected $id = ''; + /** + * The assignee of the ticket in the ticket system. + * + * Generated from protobuf field string assignee = 2; + */ + protected $assignee = ''; + /** + * The description of the ticket in the ticket system. + * + * Generated from protobuf field string description = 3; + */ + protected $description = ''; + /** + * The link to the ticket in the ticket system. + * + * Generated from protobuf field string uri = 4; + */ + protected $uri = ''; + /** + * The latest status of the ticket, as reported by the ticket system. + * + * Generated from protobuf field string status = 5; + */ + protected $status = ''; + /** + * The time when the ticket was last updated, as reported by the ticket + * system. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 6; + */ + protected $update_time = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $id + * The identifier of the ticket in the ticket system. + * @type string $assignee + * The assignee of the ticket in the ticket system. + * @type string $description + * The description of the ticket in the ticket system. + * @type string $uri + * The link to the ticket in the ticket system. + * @type string $status + * The latest status of the ticket, as reported by the ticket system. + * @type \Google\Protobuf\Timestamp $update_time + * The time when the ticket was last updated, as reported by the ticket + * system. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\ExternalSystem::initOnce(); + parent::__construct($data); + } + + /** + * The identifier of the ticket in the ticket system. + * + * Generated from protobuf field string id = 1; + * @return string + */ + public function getId() + { + return $this->id; + } + + /** + * The identifier of the ticket in the ticket system. + * + * Generated from protobuf field string id = 1; + * @param string $var + * @return $this + */ + public function setId($var) + { + GPBUtil::checkString($var, True); + $this->id = $var; + + return $this; + } + + /** + * The assignee of the ticket in the ticket system. + * + * Generated from protobuf field string assignee = 2; + * @return string + */ + public function getAssignee() + { + return $this->assignee; + } + + /** + * The assignee of the ticket in the ticket system. + * + * Generated from protobuf field string assignee = 2; + * @param string $var + * @return $this + */ + public function setAssignee($var) + { + GPBUtil::checkString($var, True); + $this->assignee = $var; + + return $this; + } + + /** + * The description of the ticket in the ticket system. + * + * Generated from protobuf field string description = 3; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * The description of the ticket in the ticket system. + * + * Generated from protobuf field string description = 3; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * The link to the ticket in the ticket system. + * + * Generated from protobuf field string uri = 4; + * @return string + */ + public function getUri() + { + return $this->uri; + } + + /** + * The link to the ticket in the ticket system. + * + * Generated from protobuf field string uri = 4; + * @param string $var + * @return $this + */ + public function setUri($var) + { + GPBUtil::checkString($var, True); + $this->uri = $var; + + return $this; + } + + /** + * The latest status of the ticket, as reported by the ticket system. + * + * Generated from protobuf field string status = 5; + * @return string + */ + public function getStatus() + { + return $this->status; + } + + /** + * The latest status of the ticket, as reported by the ticket system. + * + * Generated from protobuf field string status = 5; + * @param string $var + * @return $this + */ + public function setStatus($var) + { + GPBUtil::checkString($var, True); + $this->status = $var; + + return $this; + } + + /** + * The time when the ticket was last updated, as reported by the ticket + * system. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 6; + * @return \Google\Protobuf\Timestamp|null + */ + public function getUpdateTime() + { + return $this->update_time; + } + + public function hasUpdateTime() + { + return isset($this->update_time); + } + + public function clearUpdateTime() + { + unset($this->update_time); + } + + /** + * The time when the ticket was last updated, as reported by the ticket + * system. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 6; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->update_time = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(TicketInfo::class, \Google\Cloud\SecurityCenter\V1\ExternalSystem_TicketInfo::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/File.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/File.php new file mode 100644 index 000000000000..060cfc9caf73 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/File.php @@ -0,0 +1,298 @@ +google.cloud.securitycenter.v1.File + */ +class File extends \Google\Protobuf\Internal\Message +{ + /** + * Absolute path of the file as a JSON encoded string. + * + * Generated from protobuf field string path = 1; + */ + protected $path = ''; + /** + * Size of the file in bytes. + * + * Generated from protobuf field int64 size = 2; + */ + protected $size = 0; + /** + * SHA256 hash of the first hashed_size bytes of the file encoded as a + * hex string. If hashed_size == size, sha256 represents the SHA256 hash + * of the entire file. + * + * Generated from protobuf field string sha256 = 3; + */ + protected $sha256 = ''; + /** + * The length in bytes of the file prefix that was hashed. If + * hashed_size == size, any hashes reported represent the entire + * file. + * + * Generated from protobuf field int64 hashed_size = 4; + */ + protected $hashed_size = 0; + /** + * True when the hash covers only a prefix of the file. + * + * Generated from protobuf field bool partially_hashed = 5; + */ + protected $partially_hashed = false; + /** + * Prefix of the file contents as a JSON-encoded string. + * + * Generated from protobuf field string contents = 6; + */ + protected $contents = ''; + /** + * Path of the file in terms of underlying disk/partition identifiers. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.File.DiskPath disk_path = 7; + */ + protected $disk_path = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $path + * Absolute path of the file as a JSON encoded string. + * @type int|string $size + * Size of the file in bytes. + * @type string $sha256 + * SHA256 hash of the first hashed_size bytes of the file encoded as a + * hex string. If hashed_size == size, sha256 represents the SHA256 hash + * of the entire file. + * @type int|string $hashed_size + * The length in bytes of the file prefix that was hashed. If + * hashed_size == size, any hashes reported represent the entire + * file. + * @type bool $partially_hashed + * True when the hash covers only a prefix of the file. + * @type string $contents + * Prefix of the file contents as a JSON-encoded string. + * @type \Google\Cloud\SecurityCenter\V1\File\DiskPath $disk_path + * Path of the file in terms of underlying disk/partition identifiers. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\File::initOnce(); + parent::__construct($data); + } + + /** + * Absolute path of the file as a JSON encoded string. + * + * Generated from protobuf field string path = 1; + * @return string + */ + public function getPath() + { + return $this->path; + } + + /** + * Absolute path of the file as a JSON encoded string. + * + * Generated from protobuf field string path = 1; + * @param string $var + * @return $this + */ + public function setPath($var) + { + GPBUtil::checkString($var, True); + $this->path = $var; + + return $this; + } + + /** + * Size of the file in bytes. + * + * Generated from protobuf field int64 size = 2; + * @return int|string + */ + public function getSize() + { + return $this->size; + } + + /** + * Size of the file in bytes. + * + * Generated from protobuf field int64 size = 2; + * @param int|string $var + * @return $this + */ + public function setSize($var) + { + GPBUtil::checkInt64($var); + $this->size = $var; + + return $this; + } + + /** + * SHA256 hash of the first hashed_size bytes of the file encoded as a + * hex string. If hashed_size == size, sha256 represents the SHA256 hash + * of the entire file. + * + * Generated from protobuf field string sha256 = 3; + * @return string + */ + public function getSha256() + { + return $this->sha256; + } + + /** + * SHA256 hash of the first hashed_size bytes of the file encoded as a + * hex string. If hashed_size == size, sha256 represents the SHA256 hash + * of the entire file. + * + * Generated from protobuf field string sha256 = 3; + * @param string $var + * @return $this + */ + public function setSha256($var) + { + GPBUtil::checkString($var, True); + $this->sha256 = $var; + + return $this; + } + + /** + * The length in bytes of the file prefix that was hashed. If + * hashed_size == size, any hashes reported represent the entire + * file. + * + * Generated from protobuf field int64 hashed_size = 4; + * @return int|string + */ + public function getHashedSize() + { + return $this->hashed_size; + } + + /** + * The length in bytes of the file prefix that was hashed. If + * hashed_size == size, any hashes reported represent the entire + * file. + * + * Generated from protobuf field int64 hashed_size = 4; + * @param int|string $var + * @return $this + */ + public function setHashedSize($var) + { + GPBUtil::checkInt64($var); + $this->hashed_size = $var; + + return $this; + } + + /** + * True when the hash covers only a prefix of the file. + * + * Generated from protobuf field bool partially_hashed = 5; + * @return bool + */ + public function getPartiallyHashed() + { + return $this->partially_hashed; + } + + /** + * True when the hash covers only a prefix of the file. + * + * Generated from protobuf field bool partially_hashed = 5; + * @param bool $var + * @return $this + */ + public function setPartiallyHashed($var) + { + GPBUtil::checkBool($var); + $this->partially_hashed = $var; + + return $this; + } + + /** + * Prefix of the file contents as a JSON-encoded string. + * + * Generated from protobuf field string contents = 6; + * @return string + */ + public function getContents() + { + return $this->contents; + } + + /** + * Prefix of the file contents as a JSON-encoded string. + * + * Generated from protobuf field string contents = 6; + * @param string $var + * @return $this + */ + public function setContents($var) + { + GPBUtil::checkString($var, True); + $this->contents = $var; + + return $this; + } + + /** + * Path of the file in terms of underlying disk/partition identifiers. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.File.DiskPath disk_path = 7; + * @return \Google\Cloud\SecurityCenter\V1\File\DiskPath|null + */ + public function getDiskPath() + { + return $this->disk_path; + } + + public function hasDiskPath() + { + return isset($this->disk_path); + } + + public function clearDiskPath() + { + unset($this->disk_path); + } + + /** + * Path of the file in terms of underlying disk/partition identifiers. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.File.DiskPath disk_path = 7; + * @param \Google\Cloud\SecurityCenter\V1\File\DiskPath $var + * @return $this + */ + public function setDiskPath($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\File\DiskPath::class); + $this->disk_path = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/File/DiskPath.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/File/DiskPath.php new file mode 100644 index 000000000000..ff77dd9eb7bf --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/File/DiskPath.php @@ -0,0 +1,112 @@ +google.cloud.securitycenter.v1.File.DiskPath + */ +class DiskPath extends \Google\Protobuf\Internal\Message +{ + /** + * UUID of the partition (format + * https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid) + * + * Generated from protobuf field string partition_uuid = 1; + */ + protected $partition_uuid = ''; + /** + * Relative path of the file in the partition as a JSON encoded string. + * Example: /home/user1/executable_file.sh + * + * Generated from protobuf field string relative_path = 2; + */ + protected $relative_path = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $partition_uuid + * UUID of the partition (format + * https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid) + * @type string $relative_path + * Relative path of the file in the partition as a JSON encoded string. + * Example: /home/user1/executable_file.sh + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\File::initOnce(); + parent::__construct($data); + } + + /** + * UUID of the partition (format + * https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid) + * + * Generated from protobuf field string partition_uuid = 1; + * @return string + */ + public function getPartitionUuid() + { + return $this->partition_uuid; + } + + /** + * UUID of the partition (format + * https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid) + * + * Generated from protobuf field string partition_uuid = 1; + * @param string $var + * @return $this + */ + public function setPartitionUuid($var) + { + GPBUtil::checkString($var, True); + $this->partition_uuid = $var; + + return $this; + } + + /** + * Relative path of the file in the partition as a JSON encoded string. + * Example: /home/user1/executable_file.sh + * + * Generated from protobuf field string relative_path = 2; + * @return string + */ + public function getRelativePath() + { + return $this->relative_path; + } + + /** + * Relative path of the file in the partition as a JSON encoded string. + * Example: /home/user1/executable_file.sh + * + * Generated from protobuf field string relative_path = 2; + * @param string $var + * @return $this + */ + public function setRelativePath($var) + { + GPBUtil::checkString($var, True); + $this->relative_path = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(DiskPath::class, \Google\Cloud\SecurityCenter\V1\File_DiskPath::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding.php new file mode 100644 index 000000000000..aaab60855177 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding.php @@ -0,0 +1,2170 @@ +google.cloud.securitycenter.v1.Finding + */ +class Finding extends \Google\Protobuf\Internal\Message +{ + /** + * The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", + * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The relative resource name of the source the finding belongs to. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * This field is immutable after creation time. + * For example: + * "organizations/{organization_id}/sources/{source_id}" + * + * Generated from protobuf field string parent = 2; + */ + protected $parent = ''; + /** + * For findings on Google Cloud resources, the full resource + * name of the Google Cloud resource this finding is for. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * When the finding is for a non-Google Cloud resource, the resourceName can + * be a customer or partner defined string. This field is immutable after + * creation time. + * + * Generated from protobuf field string resource_name = 3; + */ + protected $resource_name = ''; + /** + * The state of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.State state = 4; + */ + protected $state = 0; + /** + * The additional taxonomy group within findings from a given source. + * This field is immutable after creation time. + * Example: "XSS_FLASH_INJECTION" + * + * Generated from protobuf field string category = 5; + */ + protected $category = ''; + /** + * The URI that, if available, points to a web page outside of Security + * Command Center where additional information about the finding can be found. + * This field is guaranteed to be either empty or a well formed URL. + * + * Generated from protobuf field string external_uri = 6; + */ + protected $external_uri = ''; + /** + * Source specific properties. These properties are managed by the source + * that writes the finding. The key names in the source_properties map must be + * between 1 and 255 characters, and must start with a letter and contain + * alphanumeric characters or underscores only. + * + * Generated from protobuf field map source_properties = 7; + */ + private $source_properties; + /** + * Output only. User specified security marks. These marks are entirely + * managed by the user and come from the SecurityMarks resource that belongs + * to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityMarks security_marks = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $security_marks = null; + /** + * The time the finding was first detected. If an existing finding is updated, + * then this is the time the update occurred. + * For example, if the finding represents an open firewall, this property + * captures the time the detector believes the firewall became open. The + * accuracy is determined by the detector. If the finding is later resolved, + * then this time reflects when the finding was resolved. This must not + * be set to a value greater than the current timestamp. + * + * Generated from protobuf field .google.protobuf.Timestamp event_time = 9; + */ + protected $event_time = null; + /** + * The time at which the finding was created in Security Command Center. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 10; + */ + protected $create_time = null; + /** + * The severity of the finding. This field is managed by the source that + * writes the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.Severity severity = 12; + */ + protected $severity = 0; + /** + * The canonical name of the finding. It's either + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}" or + * "projects/{project_number}/sources/{source_id}/findings/{finding_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * + * Generated from protobuf field string canonical_name = 14; + */ + protected $canonical_name = ''; + /** + * Indicates the mute state of a finding (either muted, unmuted + * or undefined). Unlike other attributes of a finding, a finding provider + * shouldn't set the value of mute. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.Mute mute = 15; + */ + protected $mute = 0; + /** + * The class of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.FindingClass finding_class = 17; + */ + protected $finding_class = 0; + /** + * Represents what's commonly known as an *indicator of compromise* (IoC) in + * computer forensics. This is an artifact observed on a network or in an + * operating system that, with high confidence, indicates a computer + * intrusion. For more information, see [Indicator of + * compromise](https://en.wikipedia.org/wiki/Indicator_of_compromise). + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator indicator = 18; + */ + protected $indicator = null; + /** + * Represents vulnerability-specific fields like CVE and CVSS scores. + * CVE stands for Common Vulnerabilities and Exposures + * (https://cve.mitre.org/about/) + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Vulnerability vulnerability = 20; + */ + protected $vulnerability = null; + /** + * Output only. The most recent time this finding was muted or unmuted. + * + * Generated from protobuf field .google.protobuf.Timestamp mute_update_time = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $mute_update_time = null; + /** + * Output only. Third party SIEM/SOAR fields within SCC, contains external + * system information and external system finding fields. + * + * Generated from protobuf field map external_systems = 22 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $external_systems; + /** + * MITRE ATT&CK tactics and techniques related to this finding. + * See: https://attack.mitre.org + * + * Generated from protobuf field .google.cloud.securitycenter.v1.MitreAttack mitre_attack = 25; + */ + protected $mitre_attack = null; + /** + * Access details associated with the finding, such as more information on the + * caller, which method was accessed, and from where. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Access access = 26; + */ + protected $access = null; + /** + * Contains information about the IP connection associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Connection connections = 31; + */ + private $connections; + /** + * Records additional information about the mute operation, for example, the + * [mute configuration](/security-command-center/docs/how-to-mute-findings) + * that muted the finding and the user who muted the finding. + * + * Generated from protobuf field string mute_initiator = 28; + */ + protected $mute_initiator = ''; + /** + * Represents operating system processes associated with the Finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Process processes = 30; + */ + private $processes; + /** + * Output only. Map containing the points of contact for the given finding. + * The key represents the type of contact, while the value contains a list of + * all the contacts that pertain. Please refer to: + * https://cloud.google.com/resource-manager/docs/managing-notification-contacts#notification-categories + * { + * "security": { + * "contacts": [ + * { + * "email": "person1@company.com" + * }, + * { + * "email": "person2@company.com" + * } + * ] + * } + * } + * + * Generated from protobuf field map contacts = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $contacts; + /** + * Contains compliance information for security standards associated to the + * finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Compliance compliances = 34; + */ + private $compliances; + /** + * Output only. The human readable display name of the finding source such as + * "Event Threat Detection" or "Security Health Analytics". + * + * Generated from protobuf field string parent_display_name = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $parent_display_name = ''; + /** + * Contains more details about the finding. + * + * Generated from protobuf field string description = 37; + */ + protected $description = ''; + /** + * Represents exfiltrations associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Exfiltration exfiltration = 38; + */ + protected $exfiltration = null; + /** + * Represents IAM bindings associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.IamBinding iam_bindings = 39; + */ + private $iam_bindings; + /** + * Steps to address the finding. + * + * Generated from protobuf field string next_steps = 40; + */ + protected $next_steps = ''; + /** + * Unique identifier of the module which generated the finding. + * Example: + * folders/598186756061/securityHealthAnalyticsSettings/customModules/56799441161885 + * + * Generated from protobuf field string module_name = 41; + */ + protected $module_name = ''; + /** + * Containers associated with the finding. This field provides information for + * both Kubernetes and non-Kubernetes containers. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Container containers = 42; + */ + private $containers; + /** + * Kubernetes resources associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes kubernetes = 43; + */ + protected $kubernetes = null; + /** + * Database associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Database database = 44; + */ + protected $database = null; + /** + * File associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.File files = 46; + */ + private $files; + /** + * Cloud Data Loss Prevention (Cloud DLP) inspection results that are + * associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CloudDlpInspection cloud_dlp_inspection = 48; + */ + protected $cloud_dlp_inspection = null; + /** + * Cloud DLP data profile that is associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CloudDlpDataProfile cloud_dlp_data_profile = 49; + */ + protected $cloud_dlp_data_profile = null; + /** + * Signature of the kernel rootkit. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.KernelRootkit kernel_rootkit = 50; + */ + protected $kernel_rootkit = null; + /** + * Contains information about the org policies associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.OrgPolicy org_policies = 51; + */ + private $org_policies; + /** + * Represents an application associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Application application = 53; + */ + protected $application = null; + /** + * Fields related to Backup and DR findings. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.BackupDisasterRecovery backup_disaster_recovery = 55; + */ + protected $backup_disaster_recovery = null; + /** + * The security posture associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityPosture security_posture = 56; + */ + protected $security_posture = null; + /** + * Log entries that are relevant to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.LogEntry log_entries = 57; + */ + private $log_entries; + /** + * The load balancers associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.LoadBalancer load_balancers = 58; + */ + private $load_balancers; + /** + * Fields related to Cloud Armor findings. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CloudArmor cloud_armor = 59; + */ + protected $cloud_armor = null; + /** + * Notebook associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Notebook notebook = 63; + */ + protected $notebook = null; + /** + * Contains details about a group of security issues that, when the issues + * occur together, represent a greater risk than when the issues occur + * independently. A group of such issues is referred to as a toxic + * combination. + * This field cannot be updated. Its value is ignored in all update requests. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.ToxicCombination toxic_combination = 64; + */ + protected $toxic_combination = null; + /** + * Contains details about groups of which this finding is a member. A group is + * a collection of findings that are related in some way. + * This field cannot be updated. Its value is ignored in all update requests. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.GroupMembership group_memberships = 65; + */ + private $group_memberships; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", + * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". + * @type string $parent + * The relative resource name of the source the finding belongs to. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * This field is immutable after creation time. + * For example: + * "organizations/{organization_id}/sources/{source_id}" + * @type string $resource_name + * For findings on Google Cloud resources, the full resource + * name of the Google Cloud resource this finding is for. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * When the finding is for a non-Google Cloud resource, the resourceName can + * be a customer or partner defined string. This field is immutable after + * creation time. + * @type int $state + * The state of the finding. + * @type string $category + * The additional taxonomy group within findings from a given source. + * This field is immutable after creation time. + * Example: "XSS_FLASH_INJECTION" + * @type string $external_uri + * The URI that, if available, points to a web page outside of Security + * Command Center where additional information about the finding can be found. + * This field is guaranteed to be either empty or a well formed URL. + * @type array|\Google\Protobuf\Internal\MapField $source_properties + * Source specific properties. These properties are managed by the source + * that writes the finding. The key names in the source_properties map must be + * between 1 and 255 characters, and must start with a letter and contain + * alphanumeric characters or underscores only. + * @type \Google\Cloud\SecurityCenter\V1\SecurityMarks $security_marks + * Output only. User specified security marks. These marks are entirely + * managed by the user and come from the SecurityMarks resource that belongs + * to the finding. + * @type \Google\Protobuf\Timestamp $event_time + * The time the finding was first detected. If an existing finding is updated, + * then this is the time the update occurred. + * For example, if the finding represents an open firewall, this property + * captures the time the detector believes the firewall became open. The + * accuracy is determined by the detector. If the finding is later resolved, + * then this time reflects when the finding was resolved. This must not + * be set to a value greater than the current timestamp. + * @type \Google\Protobuf\Timestamp $create_time + * The time at which the finding was created in Security Command Center. + * @type int $severity + * The severity of the finding. This field is managed by the source that + * writes the finding. + * @type string $canonical_name + * The canonical name of the finding. It's either + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}" or + * "projects/{project_number}/sources/{source_id}/findings/{finding_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * @type int $mute + * Indicates the mute state of a finding (either muted, unmuted + * or undefined). Unlike other attributes of a finding, a finding provider + * shouldn't set the value of mute. + * @type int $finding_class + * The class of the finding. + * @type \Google\Cloud\SecurityCenter\V1\Indicator $indicator + * Represents what's commonly known as an *indicator of compromise* (IoC) in + * computer forensics. This is an artifact observed on a network or in an + * operating system that, with high confidence, indicates a computer + * intrusion. For more information, see [Indicator of + * compromise](https://en.wikipedia.org/wiki/Indicator_of_compromise). + * @type \Google\Cloud\SecurityCenter\V1\Vulnerability $vulnerability + * Represents vulnerability-specific fields like CVE and CVSS scores. + * CVE stands for Common Vulnerabilities and Exposures + * (https://cve.mitre.org/about/) + * @type \Google\Protobuf\Timestamp $mute_update_time + * Output only. The most recent time this finding was muted or unmuted. + * @type array|\Google\Protobuf\Internal\MapField $external_systems + * Output only. Third party SIEM/SOAR fields within SCC, contains external + * system information and external system finding fields. + * @type \Google\Cloud\SecurityCenter\V1\MitreAttack $mitre_attack + * MITRE ATT&CK tactics and techniques related to this finding. + * See: https://attack.mitre.org + * @type \Google\Cloud\SecurityCenter\V1\Access $access + * Access details associated with the finding, such as more information on the + * caller, which method was accessed, and from where. + * @type array<\Google\Cloud\SecurityCenter\V1\Connection>|\Google\Protobuf\Internal\RepeatedField $connections + * Contains information about the IP connection associated with the finding. + * @type string $mute_initiator + * Records additional information about the mute operation, for example, the + * [mute configuration](/security-command-center/docs/how-to-mute-findings) + * that muted the finding and the user who muted the finding. + * @type array<\Google\Cloud\SecurityCenter\V1\Process>|\Google\Protobuf\Internal\RepeatedField $processes + * Represents operating system processes associated with the Finding. + * @type array|\Google\Protobuf\Internal\MapField $contacts + * Output only. Map containing the points of contact for the given finding. + * The key represents the type of contact, while the value contains a list of + * all the contacts that pertain. Please refer to: + * https://cloud.google.com/resource-manager/docs/managing-notification-contacts#notification-categories + * { + * "security": { + * "contacts": [ + * { + * "email": "person1@company.com" + * }, + * { + * "email": "person2@company.com" + * } + * ] + * } + * } + * @type array<\Google\Cloud\SecurityCenter\V1\Compliance>|\Google\Protobuf\Internal\RepeatedField $compliances + * Contains compliance information for security standards associated to the + * finding. + * @type string $parent_display_name + * Output only. The human readable display name of the finding source such as + * "Event Threat Detection" or "Security Health Analytics". + * @type string $description + * Contains more details about the finding. + * @type \Google\Cloud\SecurityCenter\V1\Exfiltration $exfiltration + * Represents exfiltrations associated with the finding. + * @type array<\Google\Cloud\SecurityCenter\V1\IamBinding>|\Google\Protobuf\Internal\RepeatedField $iam_bindings + * Represents IAM bindings associated with the finding. + * @type string $next_steps + * Steps to address the finding. + * @type string $module_name + * Unique identifier of the module which generated the finding. + * Example: + * folders/598186756061/securityHealthAnalyticsSettings/customModules/56799441161885 + * @type array<\Google\Cloud\SecurityCenter\V1\Container>|\Google\Protobuf\Internal\RepeatedField $containers + * Containers associated with the finding. This field provides information for + * both Kubernetes and non-Kubernetes containers. + * @type \Google\Cloud\SecurityCenter\V1\Kubernetes $kubernetes + * Kubernetes resources associated with the finding. + * @type \Google\Cloud\SecurityCenter\V1\Database $database + * Database associated with the finding. + * @type array<\Google\Cloud\SecurityCenter\V1\File>|\Google\Protobuf\Internal\RepeatedField $files + * File associated with the finding. + * @type \Google\Cloud\SecurityCenter\V1\CloudDlpInspection $cloud_dlp_inspection + * Cloud Data Loss Prevention (Cloud DLP) inspection results that are + * associated with the finding. + * @type \Google\Cloud\SecurityCenter\V1\CloudDlpDataProfile $cloud_dlp_data_profile + * Cloud DLP data profile that is associated with the finding. + * @type \Google\Cloud\SecurityCenter\V1\KernelRootkit $kernel_rootkit + * Signature of the kernel rootkit. + * @type array<\Google\Cloud\SecurityCenter\V1\OrgPolicy>|\Google\Protobuf\Internal\RepeatedField $org_policies + * Contains information about the org policies associated with the finding. + * @type \Google\Cloud\SecurityCenter\V1\Application $application + * Represents an application associated with the finding. + * @type \Google\Cloud\SecurityCenter\V1\BackupDisasterRecovery $backup_disaster_recovery + * Fields related to Backup and DR findings. + * @type \Google\Cloud\SecurityCenter\V1\SecurityPosture $security_posture + * The security posture associated with the finding. + * @type array<\Google\Cloud\SecurityCenter\V1\LogEntry>|\Google\Protobuf\Internal\RepeatedField $log_entries + * Log entries that are relevant to the finding. + * @type array<\Google\Cloud\SecurityCenter\V1\LoadBalancer>|\Google\Protobuf\Internal\RepeatedField $load_balancers + * The load balancers associated with the finding. + * @type \Google\Cloud\SecurityCenter\V1\CloudArmor $cloud_armor + * Fields related to Cloud Armor findings. + * @type \Google\Cloud\SecurityCenter\V1\Notebook $notebook + * Notebook associated with the finding. + * @type \Google\Cloud\SecurityCenter\V1\ToxicCombination $toxic_combination + * Contains details about a group of security issues that, when the issues + * occur together, represent a greater risk than when the issues occur + * independently. A group of such issues is referred to as a toxic + * combination. + * This field cannot be updated. Its value is ignored in all update requests. + * @type array<\Google\Cloud\SecurityCenter\V1\GroupMembership>|\Google\Protobuf\Internal\RepeatedField $group_memberships + * Contains details about groups of which this finding is a member. A group is + * a collection of findings that are related in some way. + * This field cannot be updated. Its value is ignored in all update requests. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Finding::initOnce(); + parent::__construct($data); + } + + /** + * The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", + * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", + * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The relative resource name of the source the finding belongs to. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * This field is immutable after creation time. + * For example: + * "organizations/{organization_id}/sources/{source_id}" + * + * Generated from protobuf field string parent = 2; + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * The relative resource name of the source the finding belongs to. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * This field is immutable after creation time. + * For example: + * "organizations/{organization_id}/sources/{source_id}" + * + * Generated from protobuf field string parent = 2; + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * For findings on Google Cloud resources, the full resource + * name of the Google Cloud resource this finding is for. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * When the finding is for a non-Google Cloud resource, the resourceName can + * be a customer or partner defined string. This field is immutable after + * creation time. + * + * Generated from protobuf field string resource_name = 3; + * @return string + */ + public function getResourceName() + { + return $this->resource_name; + } + + /** + * For findings on Google Cloud resources, the full resource + * name of the Google Cloud resource this finding is for. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * When the finding is for a non-Google Cloud resource, the resourceName can + * be a customer or partner defined string. This field is immutable after + * creation time. + * + * Generated from protobuf field string resource_name = 3; + * @param string $var + * @return $this + */ + public function setResourceName($var) + { + GPBUtil::checkString($var, True); + $this->resource_name = $var; + + return $this; + } + + /** + * The state of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.State state = 4; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * The state of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.State state = 4; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Finding\State::class); + $this->state = $var; + + return $this; + } + + /** + * The additional taxonomy group within findings from a given source. + * This field is immutable after creation time. + * Example: "XSS_FLASH_INJECTION" + * + * Generated from protobuf field string category = 5; + * @return string + */ + public function getCategory() + { + return $this->category; + } + + /** + * The additional taxonomy group within findings from a given source. + * This field is immutable after creation time. + * Example: "XSS_FLASH_INJECTION" + * + * Generated from protobuf field string category = 5; + * @param string $var + * @return $this + */ + public function setCategory($var) + { + GPBUtil::checkString($var, True); + $this->category = $var; + + return $this; + } + + /** + * The URI that, if available, points to a web page outside of Security + * Command Center where additional information about the finding can be found. + * This field is guaranteed to be either empty or a well formed URL. + * + * Generated from protobuf field string external_uri = 6; + * @return string + */ + public function getExternalUri() + { + return $this->external_uri; + } + + /** + * The URI that, if available, points to a web page outside of Security + * Command Center where additional information about the finding can be found. + * This field is guaranteed to be either empty or a well formed URL. + * + * Generated from protobuf field string external_uri = 6; + * @param string $var + * @return $this + */ + public function setExternalUri($var) + { + GPBUtil::checkString($var, True); + $this->external_uri = $var; + + return $this; + } + + /** + * Source specific properties. These properties are managed by the source + * that writes the finding. The key names in the source_properties map must be + * between 1 and 255 characters, and must start with a letter and contain + * alphanumeric characters or underscores only. + * + * Generated from protobuf field map source_properties = 7; + * @return \Google\Protobuf\Internal\MapField + */ + public function getSourceProperties() + { + return $this->source_properties; + } + + /** + * Source specific properties. These properties are managed by the source + * that writes the finding. The key names in the source_properties map must be + * between 1 and 255 characters, and must start with a letter and contain + * alphanumeric characters or underscores only. + * + * Generated from protobuf field map source_properties = 7; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setSourceProperties($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Value::class); + $this->source_properties = $arr; + + return $this; + } + + /** + * Output only. User specified security marks. These marks are entirely + * managed by the user and come from the SecurityMarks resource that belongs + * to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityMarks security_marks = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Cloud\SecurityCenter\V1\SecurityMarks|null + */ + public function getSecurityMarks() + { + return $this->security_marks; + } + + public function hasSecurityMarks() + { + return isset($this->security_marks); + } + + public function clearSecurityMarks() + { + unset($this->security_marks); + } + + /** + * Output only. User specified security marks. These marks are entirely + * managed by the user and come from the SecurityMarks resource that belongs + * to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityMarks security_marks = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\SecurityCenter\V1\SecurityMarks $var + * @return $this + */ + public function setSecurityMarks($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SecurityMarks::class); + $this->security_marks = $var; + + return $this; + } + + /** + * The time the finding was first detected. If an existing finding is updated, + * then this is the time the update occurred. + * For example, if the finding represents an open firewall, this property + * captures the time the detector believes the firewall became open. The + * accuracy is determined by the detector. If the finding is later resolved, + * then this time reflects when the finding was resolved. This must not + * be set to a value greater than the current timestamp. + * + * Generated from protobuf field .google.protobuf.Timestamp event_time = 9; + * @return \Google\Protobuf\Timestamp|null + */ + public function getEventTime() + { + return $this->event_time; + } + + public function hasEventTime() + { + return isset($this->event_time); + } + + public function clearEventTime() + { + unset($this->event_time); + } + + /** + * The time the finding was first detected. If an existing finding is updated, + * then this is the time the update occurred. + * For example, if the finding represents an open firewall, this property + * captures the time the detector believes the firewall became open. The + * accuracy is determined by the detector. If the finding is later resolved, + * then this time reflects when the finding was resolved. This must not + * be set to a value greater than the current timestamp. + * + * Generated from protobuf field .google.protobuf.Timestamp event_time = 9; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setEventTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->event_time = $var; + + return $this; + } + + /** + * The time at which the finding was created in Security Command Center. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 10; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCreateTime() + { + return $this->create_time; + } + + public function hasCreateTime() + { + return isset($this->create_time); + } + + public function clearCreateTime() + { + unset($this->create_time); + } + + /** + * The time at which the finding was created in Security Command Center. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 10; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->create_time = $var; + + return $this; + } + + /** + * The severity of the finding. This field is managed by the source that + * writes the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.Severity severity = 12; + * @return int + */ + public function getSeverity() + { + return $this->severity; + } + + /** + * The severity of the finding. This field is managed by the source that + * writes the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.Severity severity = 12; + * @param int $var + * @return $this + */ + public function setSeverity($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Finding\Severity::class); + $this->severity = $var; + + return $this; + } + + /** + * The canonical name of the finding. It's either + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}" or + * "projects/{project_number}/sources/{source_id}/findings/{finding_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * + * Generated from protobuf field string canonical_name = 14; + * @return string + */ + public function getCanonicalName() + { + return $this->canonical_name; + } + + /** + * The canonical name of the finding. It's either + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}" or + * "projects/{project_number}/sources/{source_id}/findings/{finding_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * + * Generated from protobuf field string canonical_name = 14; + * @param string $var + * @return $this + */ + public function setCanonicalName($var) + { + GPBUtil::checkString($var, True); + $this->canonical_name = $var; + + return $this; + } + + /** + * Indicates the mute state of a finding (either muted, unmuted + * or undefined). Unlike other attributes of a finding, a finding provider + * shouldn't set the value of mute. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.Mute mute = 15; + * @return int + */ + public function getMute() + { + return $this->mute; + } + + /** + * Indicates the mute state of a finding (either muted, unmuted + * or undefined). Unlike other attributes of a finding, a finding provider + * shouldn't set the value of mute. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.Mute mute = 15; + * @param int $var + * @return $this + */ + public function setMute($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Finding\Mute::class); + $this->mute = $var; + + return $this; + } + + /** + * The class of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.FindingClass finding_class = 17; + * @return int + */ + public function getFindingClass() + { + return $this->finding_class; + } + + /** + * The class of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.FindingClass finding_class = 17; + * @param int $var + * @return $this + */ + public function setFindingClass($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Finding\FindingClass::class); + $this->finding_class = $var; + + return $this; + } + + /** + * Represents what's commonly known as an *indicator of compromise* (IoC) in + * computer forensics. This is an artifact observed on a network or in an + * operating system that, with high confidence, indicates a computer + * intrusion. For more information, see [Indicator of + * compromise](https://en.wikipedia.org/wiki/Indicator_of_compromise). + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator indicator = 18; + * @return \Google\Cloud\SecurityCenter\V1\Indicator|null + */ + public function getIndicator() + { + return $this->indicator; + } + + public function hasIndicator() + { + return isset($this->indicator); + } + + public function clearIndicator() + { + unset($this->indicator); + } + + /** + * Represents what's commonly known as an *indicator of compromise* (IoC) in + * computer forensics. This is an artifact observed on a network or in an + * operating system that, with high confidence, indicates a computer + * intrusion. For more information, see [Indicator of + * compromise](https://en.wikipedia.org/wiki/Indicator_of_compromise). + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator indicator = 18; + * @param \Google\Cloud\SecurityCenter\V1\Indicator $var + * @return $this + */ + public function setIndicator($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Indicator::class); + $this->indicator = $var; + + return $this; + } + + /** + * Represents vulnerability-specific fields like CVE and CVSS scores. + * CVE stands for Common Vulnerabilities and Exposures + * (https://cve.mitre.org/about/) + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Vulnerability vulnerability = 20; + * @return \Google\Cloud\SecurityCenter\V1\Vulnerability|null + */ + public function getVulnerability() + { + return $this->vulnerability; + } + + public function hasVulnerability() + { + return isset($this->vulnerability); + } + + public function clearVulnerability() + { + unset($this->vulnerability); + } + + /** + * Represents vulnerability-specific fields like CVE and CVSS scores. + * CVE stands for Common Vulnerabilities and Exposures + * (https://cve.mitre.org/about/) + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Vulnerability vulnerability = 20; + * @param \Google\Cloud\SecurityCenter\V1\Vulnerability $var + * @return $this + */ + public function setVulnerability($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Vulnerability::class); + $this->vulnerability = $var; + + return $this; + } + + /** + * Output only. The most recent time this finding was muted or unmuted. + * + * Generated from protobuf field .google.protobuf.Timestamp mute_update_time = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getMuteUpdateTime() + { + return $this->mute_update_time; + } + + public function hasMuteUpdateTime() + { + return isset($this->mute_update_time); + } + + public function clearMuteUpdateTime() + { + unset($this->mute_update_time); + } + + /** + * Output only. The most recent time this finding was muted or unmuted. + * + * Generated from protobuf field .google.protobuf.Timestamp mute_update_time = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setMuteUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->mute_update_time = $var; + + return $this; + } + + /** + * Output only. Third party SIEM/SOAR fields within SCC, contains external + * system information and external system finding fields. + * + * Generated from protobuf field map external_systems = 22 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Internal\MapField + */ + public function getExternalSystems() + { + return $this->external_systems; + } + + /** + * Output only. Third party SIEM/SOAR fields within SCC, contains external + * system information and external system finding fields. + * + * Generated from protobuf field map external_systems = 22 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setExternalSystems($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\ExternalSystem::class); + $this->external_systems = $arr; + + return $this; + } + + /** + * MITRE ATT&CK tactics and techniques related to this finding. + * See: https://attack.mitre.org + * + * Generated from protobuf field .google.cloud.securitycenter.v1.MitreAttack mitre_attack = 25; + * @return \Google\Cloud\SecurityCenter\V1\MitreAttack|null + */ + public function getMitreAttack() + { + return $this->mitre_attack; + } + + public function hasMitreAttack() + { + return isset($this->mitre_attack); + } + + public function clearMitreAttack() + { + unset($this->mitre_attack); + } + + /** + * MITRE ATT&CK tactics and techniques related to this finding. + * See: https://attack.mitre.org + * + * Generated from protobuf field .google.cloud.securitycenter.v1.MitreAttack mitre_attack = 25; + * @param \Google\Cloud\SecurityCenter\V1\MitreAttack $var + * @return $this + */ + public function setMitreAttack($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\MitreAttack::class); + $this->mitre_attack = $var; + + return $this; + } + + /** + * Access details associated with the finding, such as more information on the + * caller, which method was accessed, and from where. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Access access = 26; + * @return \Google\Cloud\SecurityCenter\V1\Access|null + */ + public function getAccess() + { + return $this->access; + } + + public function hasAccess() + { + return isset($this->access); + } + + public function clearAccess() + { + unset($this->access); + } + + /** + * Access details associated with the finding, such as more information on the + * caller, which method was accessed, and from where. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Access access = 26; + * @param \Google\Cloud\SecurityCenter\V1\Access $var + * @return $this + */ + public function setAccess($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Access::class); + $this->access = $var; + + return $this; + } + + /** + * Contains information about the IP connection associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Connection connections = 31; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getConnections() + { + return $this->connections; + } + + /** + * Contains information about the IP connection associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Connection connections = 31; + * @param array<\Google\Cloud\SecurityCenter\V1\Connection>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setConnections($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Connection::class); + $this->connections = $arr; + + return $this; + } + + /** + * Records additional information about the mute operation, for example, the + * [mute configuration](/security-command-center/docs/how-to-mute-findings) + * that muted the finding and the user who muted the finding. + * + * Generated from protobuf field string mute_initiator = 28; + * @return string + */ + public function getMuteInitiator() + { + return $this->mute_initiator; + } + + /** + * Records additional information about the mute operation, for example, the + * [mute configuration](/security-command-center/docs/how-to-mute-findings) + * that muted the finding and the user who muted the finding. + * + * Generated from protobuf field string mute_initiator = 28; + * @param string $var + * @return $this + */ + public function setMuteInitiator($var) + { + GPBUtil::checkString($var, True); + $this->mute_initiator = $var; + + return $this; + } + + /** + * Represents operating system processes associated with the Finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Process processes = 30; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getProcesses() + { + return $this->processes; + } + + /** + * Represents operating system processes associated with the Finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Process processes = 30; + * @param array<\Google\Cloud\SecurityCenter\V1\Process>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setProcesses($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Process::class); + $this->processes = $arr; + + return $this; + } + + /** + * Output only. Map containing the points of contact for the given finding. + * The key represents the type of contact, while the value contains a list of + * all the contacts that pertain. Please refer to: + * https://cloud.google.com/resource-manager/docs/managing-notification-contacts#notification-categories + * { + * "security": { + * "contacts": [ + * { + * "email": "person1@company.com" + * }, + * { + * "email": "person2@company.com" + * } + * ] + * } + * } + * + * Generated from protobuf field map contacts = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Internal\MapField + */ + public function getContacts() + { + return $this->contacts; + } + + /** + * Output only. Map containing the points of contact for the given finding. + * The key represents the type of contact, while the value contains a list of + * all the contacts that pertain. Please refer to: + * https://cloud.google.com/resource-manager/docs/managing-notification-contacts#notification-categories + * { + * "security": { + * "contacts": [ + * { + * "email": "person1@company.com" + * }, + * { + * "email": "person2@company.com" + * } + * ] + * } + * } + * + * Generated from protobuf field map contacts = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setContacts($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\ContactDetails::class); + $this->contacts = $arr; + + return $this; + } + + /** + * Contains compliance information for security standards associated to the + * finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Compliance compliances = 34; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getCompliances() + { + return $this->compliances; + } + + /** + * Contains compliance information for security standards associated to the + * finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Compliance compliances = 34; + * @param array<\Google\Cloud\SecurityCenter\V1\Compliance>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setCompliances($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Compliance::class); + $this->compliances = $arr; + + return $this; + } + + /** + * Output only. The human readable display name of the finding source such as + * "Event Threat Detection" or "Security Health Analytics". + * + * Generated from protobuf field string parent_display_name = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getParentDisplayName() + { + return $this->parent_display_name; + } + + /** + * Output only. The human readable display name of the finding source such as + * "Event Threat Detection" or "Security Health Analytics". + * + * Generated from protobuf field string parent_display_name = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setParentDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->parent_display_name = $var; + + return $this; + } + + /** + * Contains more details about the finding. + * + * Generated from protobuf field string description = 37; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Contains more details about the finding. + * + * Generated from protobuf field string description = 37; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * Represents exfiltrations associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Exfiltration exfiltration = 38; + * @return \Google\Cloud\SecurityCenter\V1\Exfiltration|null + */ + public function getExfiltration() + { + return $this->exfiltration; + } + + public function hasExfiltration() + { + return isset($this->exfiltration); + } + + public function clearExfiltration() + { + unset($this->exfiltration); + } + + /** + * Represents exfiltrations associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Exfiltration exfiltration = 38; + * @param \Google\Cloud\SecurityCenter\V1\Exfiltration $var + * @return $this + */ + public function setExfiltration($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Exfiltration::class); + $this->exfiltration = $var; + + return $this; + } + + /** + * Represents IAM bindings associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.IamBinding iam_bindings = 39; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getIamBindings() + { + return $this->iam_bindings; + } + + /** + * Represents IAM bindings associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.IamBinding iam_bindings = 39; + * @param array<\Google\Cloud\SecurityCenter\V1\IamBinding>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setIamBindings($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\IamBinding::class); + $this->iam_bindings = $arr; + + return $this; + } + + /** + * Steps to address the finding. + * + * Generated from protobuf field string next_steps = 40; + * @return string + */ + public function getNextSteps() + { + return $this->next_steps; + } + + /** + * Steps to address the finding. + * + * Generated from protobuf field string next_steps = 40; + * @param string $var + * @return $this + */ + public function setNextSteps($var) + { + GPBUtil::checkString($var, True); + $this->next_steps = $var; + + return $this; + } + + /** + * Unique identifier of the module which generated the finding. + * Example: + * folders/598186756061/securityHealthAnalyticsSettings/customModules/56799441161885 + * + * Generated from protobuf field string module_name = 41; + * @return string + */ + public function getModuleName() + { + return $this->module_name; + } + + /** + * Unique identifier of the module which generated the finding. + * Example: + * folders/598186756061/securityHealthAnalyticsSettings/customModules/56799441161885 + * + * Generated from protobuf field string module_name = 41; + * @param string $var + * @return $this + */ + public function setModuleName($var) + { + GPBUtil::checkString($var, True); + $this->module_name = $var; + + return $this; + } + + /** + * Containers associated with the finding. This field provides information for + * both Kubernetes and non-Kubernetes containers. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Container containers = 42; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getContainers() + { + return $this->containers; + } + + /** + * Containers associated with the finding. This field provides information for + * both Kubernetes and non-Kubernetes containers. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Container containers = 42; + * @param array<\Google\Cloud\SecurityCenter\V1\Container>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setContainers($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Container::class); + $this->containers = $arr; + + return $this; + } + + /** + * Kubernetes resources associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes kubernetes = 43; + * @return \Google\Cloud\SecurityCenter\V1\Kubernetes|null + */ + public function getKubernetes() + { + return $this->kubernetes; + } + + public function hasKubernetes() + { + return isset($this->kubernetes); + } + + public function clearKubernetes() + { + unset($this->kubernetes); + } + + /** + * Kubernetes resources associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes kubernetes = 43; + * @param \Google\Cloud\SecurityCenter\V1\Kubernetes $var + * @return $this + */ + public function setKubernetes($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Kubernetes::class); + $this->kubernetes = $var; + + return $this; + } + + /** + * Database associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Database database = 44; + * @return \Google\Cloud\SecurityCenter\V1\Database|null + */ + public function getDatabase() + { + return $this->database; + } + + public function hasDatabase() + { + return isset($this->database); + } + + public function clearDatabase() + { + unset($this->database); + } + + /** + * Database associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Database database = 44; + * @param \Google\Cloud\SecurityCenter\V1\Database $var + * @return $this + */ + public function setDatabase($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Database::class); + $this->database = $var; + + return $this; + } + + /** + * File associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.File files = 46; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFiles() + { + return $this->files; + } + + /** + * File associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.File files = 46; + * @param array<\Google\Cloud\SecurityCenter\V1\File>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFiles($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\File::class); + $this->files = $arr; + + return $this; + } + + /** + * Cloud Data Loss Prevention (Cloud DLP) inspection results that are + * associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CloudDlpInspection cloud_dlp_inspection = 48; + * @return \Google\Cloud\SecurityCenter\V1\CloudDlpInspection|null + */ + public function getCloudDlpInspection() + { + return $this->cloud_dlp_inspection; + } + + public function hasCloudDlpInspection() + { + return isset($this->cloud_dlp_inspection); + } + + public function clearCloudDlpInspection() + { + unset($this->cloud_dlp_inspection); + } + + /** + * Cloud Data Loss Prevention (Cloud DLP) inspection results that are + * associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CloudDlpInspection cloud_dlp_inspection = 48; + * @param \Google\Cloud\SecurityCenter\V1\CloudDlpInspection $var + * @return $this + */ + public function setCloudDlpInspection($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\CloudDlpInspection::class); + $this->cloud_dlp_inspection = $var; + + return $this; + } + + /** + * Cloud DLP data profile that is associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CloudDlpDataProfile cloud_dlp_data_profile = 49; + * @return \Google\Cloud\SecurityCenter\V1\CloudDlpDataProfile|null + */ + public function getCloudDlpDataProfile() + { + return $this->cloud_dlp_data_profile; + } + + public function hasCloudDlpDataProfile() + { + return isset($this->cloud_dlp_data_profile); + } + + public function clearCloudDlpDataProfile() + { + unset($this->cloud_dlp_data_profile); + } + + /** + * Cloud DLP data profile that is associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CloudDlpDataProfile cloud_dlp_data_profile = 49; + * @param \Google\Cloud\SecurityCenter\V1\CloudDlpDataProfile $var + * @return $this + */ + public function setCloudDlpDataProfile($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\CloudDlpDataProfile::class); + $this->cloud_dlp_data_profile = $var; + + return $this; + } + + /** + * Signature of the kernel rootkit. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.KernelRootkit kernel_rootkit = 50; + * @return \Google\Cloud\SecurityCenter\V1\KernelRootkit|null + */ + public function getKernelRootkit() + { + return $this->kernel_rootkit; + } + + public function hasKernelRootkit() + { + return isset($this->kernel_rootkit); + } + + public function clearKernelRootkit() + { + unset($this->kernel_rootkit); + } + + /** + * Signature of the kernel rootkit. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.KernelRootkit kernel_rootkit = 50; + * @param \Google\Cloud\SecurityCenter\V1\KernelRootkit $var + * @return $this + */ + public function setKernelRootkit($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\KernelRootkit::class); + $this->kernel_rootkit = $var; + + return $this; + } + + /** + * Contains information about the org policies associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.OrgPolicy org_policies = 51; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getOrgPolicies() + { + return $this->org_policies; + } + + /** + * Contains information about the org policies associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.OrgPolicy org_policies = 51; + * @param array<\Google\Cloud\SecurityCenter\V1\OrgPolicy>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setOrgPolicies($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\OrgPolicy::class); + $this->org_policies = $arr; + + return $this; + } + + /** + * Represents an application associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Application application = 53; + * @return \Google\Cloud\SecurityCenter\V1\Application|null + */ + public function getApplication() + { + return $this->application; + } + + public function hasApplication() + { + return isset($this->application); + } + + public function clearApplication() + { + unset($this->application); + } + + /** + * Represents an application associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Application application = 53; + * @param \Google\Cloud\SecurityCenter\V1\Application $var + * @return $this + */ + public function setApplication($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Application::class); + $this->application = $var; + + return $this; + } + + /** + * Fields related to Backup and DR findings. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.BackupDisasterRecovery backup_disaster_recovery = 55; + * @return \Google\Cloud\SecurityCenter\V1\BackupDisasterRecovery|null + */ + public function getBackupDisasterRecovery() + { + return $this->backup_disaster_recovery; + } + + public function hasBackupDisasterRecovery() + { + return isset($this->backup_disaster_recovery); + } + + public function clearBackupDisasterRecovery() + { + unset($this->backup_disaster_recovery); + } + + /** + * Fields related to Backup and DR findings. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.BackupDisasterRecovery backup_disaster_recovery = 55; + * @param \Google\Cloud\SecurityCenter\V1\BackupDisasterRecovery $var + * @return $this + */ + public function setBackupDisasterRecovery($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\BackupDisasterRecovery::class); + $this->backup_disaster_recovery = $var; + + return $this; + } + + /** + * The security posture associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityPosture security_posture = 56; + * @return \Google\Cloud\SecurityCenter\V1\SecurityPosture|null + */ + public function getSecurityPosture() + { + return $this->security_posture; + } + + public function hasSecurityPosture() + { + return isset($this->security_posture); + } + + public function clearSecurityPosture() + { + unset($this->security_posture); + } + + /** + * The security posture associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityPosture security_posture = 56; + * @param \Google\Cloud\SecurityCenter\V1\SecurityPosture $var + * @return $this + */ + public function setSecurityPosture($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SecurityPosture::class); + $this->security_posture = $var; + + return $this; + } + + /** + * Log entries that are relevant to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.LogEntry log_entries = 57; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getLogEntries() + { + return $this->log_entries; + } + + /** + * Log entries that are relevant to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.LogEntry log_entries = 57; + * @param array<\Google\Cloud\SecurityCenter\V1\LogEntry>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setLogEntries($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\LogEntry::class); + $this->log_entries = $arr; + + return $this; + } + + /** + * The load balancers associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.LoadBalancer load_balancers = 58; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getLoadBalancers() + { + return $this->load_balancers; + } + + /** + * The load balancers associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.LoadBalancer load_balancers = 58; + * @param array<\Google\Cloud\SecurityCenter\V1\LoadBalancer>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setLoadBalancers($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\LoadBalancer::class); + $this->load_balancers = $arr; + + return $this; + } + + /** + * Fields related to Cloud Armor findings. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CloudArmor cloud_armor = 59; + * @return \Google\Cloud\SecurityCenter\V1\CloudArmor|null + */ + public function getCloudArmor() + { + return $this->cloud_armor; + } + + public function hasCloudArmor() + { + return isset($this->cloud_armor); + } + + public function clearCloudArmor() + { + unset($this->cloud_armor); + } + + /** + * Fields related to Cloud Armor findings. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CloudArmor cloud_armor = 59; + * @param \Google\Cloud\SecurityCenter\V1\CloudArmor $var + * @return $this + */ + public function setCloudArmor($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\CloudArmor::class); + $this->cloud_armor = $var; + + return $this; + } + + /** + * Notebook associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Notebook notebook = 63; + * @return \Google\Cloud\SecurityCenter\V1\Notebook|null + */ + public function getNotebook() + { + return $this->notebook; + } + + public function hasNotebook() + { + return isset($this->notebook); + } + + public function clearNotebook() + { + unset($this->notebook); + } + + /** + * Notebook associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Notebook notebook = 63; + * @param \Google\Cloud\SecurityCenter\V1\Notebook $var + * @return $this + */ + public function setNotebook($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Notebook::class); + $this->notebook = $var; + + return $this; + } + + /** + * Contains details about a group of security issues that, when the issues + * occur together, represent a greater risk than when the issues occur + * independently. A group of such issues is referred to as a toxic + * combination. + * This field cannot be updated. Its value is ignored in all update requests. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.ToxicCombination toxic_combination = 64; + * @return \Google\Cloud\SecurityCenter\V1\ToxicCombination|null + */ + public function getToxicCombination() + { + return $this->toxic_combination; + } + + public function hasToxicCombination() + { + return isset($this->toxic_combination); + } + + public function clearToxicCombination() + { + unset($this->toxic_combination); + } + + /** + * Contains details about a group of security issues that, when the issues + * occur together, represent a greater risk than when the issues occur + * independently. A group of such issues is referred to as a toxic + * combination. + * This field cannot be updated. Its value is ignored in all update requests. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.ToxicCombination toxic_combination = 64; + * @param \Google\Cloud\SecurityCenter\V1\ToxicCombination $var + * @return $this + */ + public function setToxicCombination($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\ToxicCombination::class); + $this->toxic_combination = $var; + + return $this; + } + + /** + * Contains details about groups of which this finding is a member. A group is + * a collection of findings that are related in some way. + * This field cannot be updated. Its value is ignored in all update requests. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.GroupMembership group_memberships = 65; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getGroupMemberships() + { + return $this->group_memberships; + } + + /** + * Contains details about groups of which this finding is a member. A group is + * a collection of findings that are related in some way. + * This field cannot be updated. Its value is ignored in all update requests. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.GroupMembership group_memberships = 65; + * @param array<\Google\Cloud\SecurityCenter\V1\GroupMembership>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setGroupMemberships($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\GroupMembership::class); + $this->group_memberships = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/FindingClass.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/FindingClass.php new file mode 100644 index 000000000000..d26244482636 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/FindingClass.php @@ -0,0 +1,105 @@ +google.cloud.securitycenter.v1.Finding.FindingClass + */ +class FindingClass +{ + /** + * Unspecified finding class. + * + * Generated from protobuf enum FINDING_CLASS_UNSPECIFIED = 0; + */ + const FINDING_CLASS_UNSPECIFIED = 0; + /** + * Describes unwanted or malicious activity. + * + * Generated from protobuf enum THREAT = 1; + */ + const THREAT = 1; + /** + * Describes a potential weakness in software that increases risk to + * Confidentiality & Integrity & Availability. + * + * Generated from protobuf enum VULNERABILITY = 2; + */ + const VULNERABILITY = 2; + /** + * Describes a potential weakness in cloud resource/asset configuration that + * increases risk. + * + * Generated from protobuf enum MISCONFIGURATION = 3; + */ + const MISCONFIGURATION = 3; + /** + * Describes a security observation that is for informational purposes. + * + * Generated from protobuf enum OBSERVATION = 4; + */ + const OBSERVATION = 4; + /** + * Describes an error that prevents some SCC functionality. + * + * Generated from protobuf enum SCC_ERROR = 5; + */ + const SCC_ERROR = 5; + /** + * Describes a potential security risk due to a change in the security + * posture. + * + * Generated from protobuf enum POSTURE_VIOLATION = 6; + */ + const POSTURE_VIOLATION = 6; + /** + * Describes a group of security issues that, when the issues + * occur together, represent a greater risk than when the issues occur + * independently. A group of such issues is referred to as a toxic + * combination. + * + * Generated from protobuf enum TOXIC_COMBINATION = 7; + */ + const TOXIC_COMBINATION = 7; + + private static $valueToName = [ + self::FINDING_CLASS_UNSPECIFIED => 'FINDING_CLASS_UNSPECIFIED', + self::THREAT => 'THREAT', + self::VULNERABILITY => 'VULNERABILITY', + self::MISCONFIGURATION => 'MISCONFIGURATION', + self::OBSERVATION => 'OBSERVATION', + self::SCC_ERROR => 'SCC_ERROR', + self::POSTURE_VIOLATION => 'POSTURE_VIOLATION', + self::TOXIC_COMBINATION => 'TOXIC_COMBINATION', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(FindingClass::class, \Google\Cloud\SecurityCenter\V1\Finding_FindingClass::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/Mute.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/Mute.php new file mode 100644 index 000000000000..8e7576dc4a0e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/Mute.php @@ -0,0 +1,71 @@ +google.cloud.securitycenter.v1.Finding.Mute + */ +class Mute +{ + /** + * Unspecified. + * + * Generated from protobuf enum MUTE_UNSPECIFIED = 0; + */ + const MUTE_UNSPECIFIED = 0; + /** + * Finding has been muted. + * + * Generated from protobuf enum MUTED = 1; + */ + const MUTED = 1; + /** + * Finding has been unmuted. + * + * Generated from protobuf enum UNMUTED = 2; + */ + const UNMUTED = 2; + /** + * Finding has never been muted/unmuted. + * + * Generated from protobuf enum UNDEFINED = 4; + */ + const UNDEFINED = 4; + + private static $valueToName = [ + self::MUTE_UNSPECIFIED => 'MUTE_UNSPECIFIED', + self::MUTED => 'MUTED', + self::UNMUTED => 'UNMUTED', + self::UNDEFINED => 'UNDEFINED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Mute::class, \Google\Cloud\SecurityCenter\V1\Finding_Mute::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/Severity.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/Severity.php new file mode 100644 index 000000000000..e25546a23b7e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/Severity.php @@ -0,0 +1,116 @@ +google.cloud.securitycenter.v1.Finding.Severity + */ +class Severity +{ + /** + * This value is used for findings when a source doesn't write a severity + * value. + * + * Generated from protobuf enum SEVERITY_UNSPECIFIED = 0; + */ + const SEVERITY_UNSPECIFIED = 0; + /** + * Vulnerability: + * A critical vulnerability is easily discoverable by an external actor, + * exploitable, and results in the direct ability to execute arbitrary code, + * exfiltrate data, and otherwise gain additional access and privileges to + * cloud resources and workloads. Examples include publicly accessible + * unprotected user data and public SSH access with weak or no + * passwords. + * Threat: + * Indicates a threat that is able to access, modify, or delete data or + * execute unauthorized code within existing resources. + * + * Generated from protobuf enum CRITICAL = 1; + */ + const CRITICAL = 1; + /** + * Vulnerability: + * A high risk vulnerability can be easily discovered and exploited in + * combination with other vulnerabilities in order to gain direct access and + * the ability to execute arbitrary code, exfiltrate data, and otherwise + * gain additional access and privileges to cloud resources and workloads. + * An example is a database with weak or no passwords that is only + * accessible internally. This database could easily be compromised by an + * actor that had access to the internal network. + * Threat: + * Indicates a threat that is able to create new computational resources in + * an environment but not able to access data or execute code in existing + * resources. + * + * Generated from protobuf enum HIGH = 2; + */ + const HIGH = 2; + /** + * Vulnerability: + * A medium risk vulnerability could be used by an actor to gain access to + * resources or privileges that enable them to eventually (through multiple + * steps or a complex exploit) gain access and the ability to execute + * arbitrary code or exfiltrate data. An example is a service account with + * access to more projects than it should have. If an actor gains access to + * the service account, they could potentially use that access to manipulate + * a project the service account was not intended to. + * Threat: + * Indicates a threat that is able to cause operational impact but may not + * access data or execute unauthorized code. + * + * Generated from protobuf enum MEDIUM = 3; + */ + const MEDIUM = 3; + /** + * Vulnerability: + * A low risk vulnerability hampers a security organization's ability to + * detect vulnerabilities or active threats in their deployment, or prevents + * the root cause investigation of security issues. An example is monitoring + * and logs being disabled for resource configurations and access. + * Threat: + * Indicates a threat that has obtained minimal access to an environment but + * is not able to access data, execute code, or create resources. + * + * Generated from protobuf enum LOW = 4; + */ + const LOW = 4; + + private static $valueToName = [ + self::SEVERITY_UNSPECIFIED => 'SEVERITY_UNSPECIFIED', + self::CRITICAL => 'CRITICAL', + self::HIGH => 'HIGH', + self::MEDIUM => 'MEDIUM', + self::LOW => 'LOW', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Severity::class, \Google\Cloud\SecurityCenter\V1\Finding_Severity::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/State.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/State.php new file mode 100644 index 000000000000..c1d5b5aa3bf5 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/State.php @@ -0,0 +1,65 @@ +google.cloud.securitycenter.v1.Finding.State + */ +class State +{ + /** + * Unspecified state. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The finding requires attention and has not been addressed yet. + * + * Generated from protobuf enum ACTIVE = 1; + */ + const ACTIVE = 1; + /** + * The finding has been fixed, triaged as a non-issue or otherwise addressed + * and is no longer active. + * + * Generated from protobuf enum INACTIVE = 2; + */ + const INACTIVE = 2; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::ACTIVE => 'ACTIVE', + self::INACTIVE => 'INACTIVE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(State::class, \Google\Cloud\SecurityCenter\V1\Finding_State::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Folder.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Folder.php new file mode 100644 index 000000000000..ae3dee022d24 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Folder.php @@ -0,0 +1,106 @@ +google.cloud.securitycenter.v1.Folder + */ +class Folder extends \Google\Protobuf\Internal\Message +{ + /** + * Full resource name of this folder. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_folder = 1; + */ + protected $resource_folder = ''; + /** + * The user defined display name for this folder. + * + * Generated from protobuf field string resource_folder_display_name = 2; + */ + protected $resource_folder_display_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $resource_folder + * Full resource name of this folder. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * @type string $resource_folder_display_name + * The user defined display name for this folder. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Folder::initOnce(); + parent::__construct($data); + } + + /** + * Full resource name of this folder. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_folder = 1; + * @return string + */ + public function getResourceFolder() + { + return $this->resource_folder; + } + + /** + * Full resource name of this folder. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_folder = 1; + * @param string $var + * @return $this + */ + public function setResourceFolder($var) + { + GPBUtil::checkString($var, True); + $this->resource_folder = $var; + + return $this; + } + + /** + * The user defined display name for this folder. + * + * Generated from protobuf field string resource_folder_display_name = 2; + * @return string + */ + public function getResourceFolderDisplayName() + { + return $this->resource_folder_display_name; + } + + /** + * The user defined display name for this folder. + * + * Generated from protobuf field string resource_folder_display_name = 2; + * @param string $var + * @return $this + */ + public function setResourceFolderDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->resource_folder_display_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Geolocation.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Geolocation.php new file mode 100644 index 000000000000..840ddadf3caf --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Geolocation.php @@ -0,0 +1,67 @@ +google.cloud.securitycenter.v1.Geolocation + */ +class Geolocation extends \Google\Protobuf\Internal\Message +{ + /** + * A CLDR. + * + * Generated from protobuf field string region_code = 1; + */ + protected $region_code = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $region_code + * A CLDR. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Access::initOnce(); + parent::__construct($data); + } + + /** + * A CLDR. + * + * Generated from protobuf field string region_code = 1; + * @return string + */ + public function getRegionCode() + { + return $this->region_code; + } + + /** + * A CLDR. + * + * Generated from protobuf field string region_code = 1; + * @param string $var + * @return $this + */ + public function setRegionCode($var) + { + GPBUtil::checkString($var, True); + $this->region_code = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetBigQueryExportRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetBigQueryExportRequest.php new file mode 100644 index 000000000000..70e467e86dea --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetBigQueryExportRequest.php @@ -0,0 +1,96 @@ +google.cloud.securitycenter.v1.GetBigQueryExportRequest + */ +class GetBigQueryExportRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the BigQuery export to retrieve. Its format is + * organizations/{organization}/bigQueryExports/{export_id}, + * folders/{folder}/bigQueryExports/{export_id}, or + * projects/{project}/bigQueryExports/{export_id} + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Name of the BigQuery export to retrieve. Its format is + * organizations/{organization}/bigQueryExports/{export_id}, + * folders/{folder}/bigQueryExports/{export_id}, or + * projects/{project}/bigQueryExports/{export_id} + * Please see {@see SecurityCenterClient::bigQueryExportName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V1\GetBigQueryExportRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the BigQuery export to retrieve. Its format is + * organizations/{organization}/bigQueryExports/{export_id}, + * folders/{folder}/bigQueryExports/{export_id}, or + * projects/{project}/bigQueryExports/{export_id} + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the BigQuery export to retrieve. Its format is + * organizations/{organization}/bigQueryExports/{export_id}, + * folders/{folder}/bigQueryExports/{export_id}, or + * projects/{project}/bigQueryExports/{export_id} + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the BigQuery export to retrieve. Its format is + * organizations/{organization}/bigQueryExports/{export_id}, + * folders/{folder}/bigQueryExports/{export_id}, or + * projects/{project}/bigQueryExports/{export_id} + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetEffectiveSecurityHealthAnalyticsCustomModuleRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetEffectiveSecurityHealthAnalyticsCustomModuleRequest.php new file mode 100644 index 000000000000..b2ca49a8c08d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetEffectiveSecurityHealthAnalyticsCustomModuleRequest.php @@ -0,0 +1,102 @@ +google.cloud.securitycenter.v1.GetEffectiveSecurityHealthAnalyticsCustomModuleRequest + */ +class GetEffectiveSecurityHealthAnalyticsCustomModuleRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the effective custom module to get. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Name of the effective custom module to get. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" + * Please see {@see SecurityCenterClient::effectiveSecurityHealthAnalyticsCustomModuleName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V1\GetEffectiveSecurityHealthAnalyticsCustomModuleRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the effective custom module to get. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the effective custom module to get. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the effective custom module to get. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetMuteConfigRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetMuteConfigRequest.php new file mode 100644 index 000000000000..06f01976795e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetMuteConfigRequest.php @@ -0,0 +1,96 @@ +google.cloud.securitycenter.v1.GetMuteConfigRequest + */ +class GetMuteConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the mute config to retrieve. Its format is + * organizations/{organization}/muteConfigs/{config_id}, + * folders/{folder}/muteConfigs/{config_id}, or + * projects/{project}/muteConfigs/{config_id} + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Name of the mute config to retrieve. Its format is + * organizations/{organization}/muteConfigs/{config_id}, + * folders/{folder}/muteConfigs/{config_id}, or + * projects/{project}/muteConfigs/{config_id} + * Please see {@see SecurityCenterClient::muteConfigName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V1\GetMuteConfigRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the mute config to retrieve. Its format is + * organizations/{organization}/muteConfigs/{config_id}, + * folders/{folder}/muteConfigs/{config_id}, or + * projects/{project}/muteConfigs/{config_id} + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the mute config to retrieve. Its format is + * organizations/{organization}/muteConfigs/{config_id}, + * folders/{folder}/muteConfigs/{config_id}, or + * projects/{project}/muteConfigs/{config_id} + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the mute config to retrieve. Its format is + * organizations/{organization}/muteConfigs/{config_id}, + * folders/{folder}/muteConfigs/{config_id}, or + * projects/{project}/muteConfigs/{config_id} + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetNotificationConfigRequest.php new file mode 100644 index 000000000000..5df4aa389dca --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetNotificationConfigRequest.php @@ -0,0 +1,96 @@ +google.cloud.securitycenter.v1.GetNotificationConfigRequest + */ +class GetNotificationConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the notification config to get. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]", + * "folders/[folder_id]/notificationConfigs/[config_id]", + * or "projects/[project_id]/notificationConfigs/[config_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Name of the notification config to get. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]", + * "folders/[folder_id]/notificationConfigs/[config_id]", + * or "projects/[project_id]/notificationConfigs/[config_id]". Please see + * {@see SecurityCenterClient::notificationConfigName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V1\GetNotificationConfigRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the notification config to get. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]", + * "folders/[folder_id]/notificationConfigs/[config_id]", + * or "projects/[project_id]/notificationConfigs/[config_id]". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the notification config to get. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]", + * "folders/[folder_id]/notificationConfigs/[config_id]", + * or "projects/[project_id]/notificationConfigs/[config_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the notification config to get. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]", + * "folders/[folder_id]/notificationConfigs/[config_id]", + * or "projects/[project_id]/notificationConfigs/[config_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetOrganizationSettingsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetOrganizationSettingsRequest.php new file mode 100644 index 000000000000..d1e930b5e466 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetOrganizationSettingsRequest.php @@ -0,0 +1,86 @@ +google.cloud.securitycenter.v1.GetOrganizationSettingsRequest + */ +class GetOrganizationSettingsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the organization to get organization settings for. Its + * format is "organizations/[organization_id]/organizationSettings". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Name of the organization to get organization settings for. Its + * format is "organizations/[organization_id]/organizationSettings". Please see + * {@see SecurityCenterClient::organizationSettingsName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V1\GetOrganizationSettingsRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the organization to get organization settings for. Its + * format is "organizations/[organization_id]/organizationSettings". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the organization to get organization settings for. Its + * format is "organizations/[organization_id]/organizationSettings". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the organization to get organization settings for. Its + * format is "organizations/[organization_id]/organizationSettings". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetSecurityHealthAnalyticsCustomModuleRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetSecurityHealthAnalyticsCustomModuleRequest.php new file mode 100644 index 000000000000..a5f7fb16a6fd --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetSecurityHealthAnalyticsCustomModuleRequest.php @@ -0,0 +1,101 @@ +google.cloud.securitycenter.v1.GetSecurityHealthAnalyticsCustomModuleRequest + */ +class GetSecurityHealthAnalyticsCustomModuleRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the custom module to get. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", + * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Name of the custom module to get. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", + * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" + * Please see {@see SecurityCenterClient::securityHealthAnalyticsCustomModuleName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V1\GetSecurityHealthAnalyticsCustomModuleRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the custom module to get. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", + * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the custom module to get. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", + * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the custom module to get. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", + * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetSourceRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetSourceRequest.php new file mode 100644 index 000000000000..20815c4a1e55 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetSourceRequest.php @@ -0,0 +1,86 @@ +google.cloud.securitycenter.v1.GetSourceRequest + */ +class GetSourceRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Relative resource name of the source. Its format is + * "organizations/[organization_id]/source/[source_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Relative resource name of the source. Its format is + * "organizations/[organization_id]/source/[source_id]". Please see + * {@see SecurityCenterClient::sourceName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V1\GetSourceRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Relative resource name of the source. Its format is + * "organizations/[organization_id]/source/[source_id]". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Relative resource name of the source. Its format is + * "organizations/[organization_id]/source/[source_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Relative resource name of the source. Its format is + * "organizations/[organization_id]/source/[source_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupAssetsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupAssetsRequest.php new file mode 100644 index 000000000000..5414cdfb275b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupAssetsRequest.php @@ -0,0 +1,643 @@ +google.cloud.securitycenter.v1.GroupAssetsRequest + */ +class GroupAssetsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the parent to group the assets by. Its format is + * "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * For example, `resource_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * + * Generated from protobuf field string filter = 2; + */ + protected $filter = ''; + /** + * Required. Expression that defines what assets fields to use for grouping. + * The string value should follow SQL syntax: comma separated list of fields. + * For example: + * "security_center_properties.resource_project,security_center_properties.project". + * The following fields are supported when compare_duration is not set: + * * security_center_properties.resource_project + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_type + * * security_center_properties.resource_parent + * * security_center_properties.resource_parent_display_name + * The following fields are supported when compare_duration is set: + * * security_center_properties.resource_type + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_parent_display_name + * + * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $group_by = ''; + /** + * When compare_duration is set, the GroupResult's "state_change" property is + * updated to indicate whether the asset was added, removed, or remained + * present during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * Possible "state_change" values when compare_duration is specified: + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at reference_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at reference_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and reference_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 4; + */ + protected $compare_duration = null; + /** + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 5; + */ + protected $read_time = null; + /** + * The value returned by the last `GroupAssetsResponse`; indicates + * that this is a continuation of a prior `GroupAssets` call, and that the + * system should return the next page of data. + * + * Generated from protobuf field string page_token = 7; + */ + protected $page_token = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 8; + */ + protected $page_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The name of the parent to group the assets by. Its format is + * "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * @type string $filter + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * For example, `resource_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * @type string $group_by + * Required. Expression that defines what assets fields to use for grouping. + * The string value should follow SQL syntax: comma separated list of fields. + * For example: + * "security_center_properties.resource_project,security_center_properties.project". + * The following fields are supported when compare_duration is not set: + * * security_center_properties.resource_project + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_type + * * security_center_properties.resource_parent + * * security_center_properties.resource_parent_display_name + * The following fields are supported when compare_duration is set: + * * security_center_properties.resource_type + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_parent_display_name + * @type \Google\Protobuf\Duration $compare_duration + * When compare_duration is set, the GroupResult's "state_change" property is + * updated to indicate whether the asset was added, removed, or remained + * present during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * Possible "state_change" values when compare_duration is specified: + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at reference_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at reference_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and reference_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * @type \Google\Protobuf\Timestamp $read_time + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * @type string $page_token + * The value returned by the last `GroupAssetsResponse`; indicates + * that this is a continuation of a prior `GroupAssets` call, and that the + * system should return the next page of data. + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the parent to group the assets by. Its format is + * "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The name of the parent to group the assets by. Its format is + * "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * For example, `resource_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * + * Generated from protobuf field string filter = 2; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * For example, `resource_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * + * Generated from protobuf field string filter = 2; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * Required. Expression that defines what assets fields to use for grouping. + * The string value should follow SQL syntax: comma separated list of fields. + * For example: + * "security_center_properties.resource_project,security_center_properties.project". + * The following fields are supported when compare_duration is not set: + * * security_center_properties.resource_project + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_type + * * security_center_properties.resource_parent + * * security_center_properties.resource_parent_display_name + * The following fields are supported when compare_duration is set: + * * security_center_properties.resource_type + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_parent_display_name + * + * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getGroupBy() + { + return $this->group_by; + } + + /** + * Required. Expression that defines what assets fields to use for grouping. + * The string value should follow SQL syntax: comma separated list of fields. + * For example: + * "security_center_properties.resource_project,security_center_properties.project". + * The following fields are supported when compare_duration is not set: + * * security_center_properties.resource_project + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_type + * * security_center_properties.resource_parent + * * security_center_properties.resource_parent_display_name + * The following fields are supported when compare_duration is set: + * * security_center_properties.resource_type + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_parent_display_name + * + * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setGroupBy($var) + { + GPBUtil::checkString($var, True); + $this->group_by = $var; + + return $this; + } + + /** + * When compare_duration is set, the GroupResult's "state_change" property is + * updated to indicate whether the asset was added, removed, or remained + * present during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * Possible "state_change" values when compare_duration is specified: + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at reference_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at reference_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and reference_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 4; + * @return \Google\Protobuf\Duration|null + */ + public function getCompareDuration() + { + return $this->compare_duration; + } + + public function hasCompareDuration() + { + return isset($this->compare_duration); + } + + public function clearCompareDuration() + { + unset($this->compare_duration); + } + + /** + * When compare_duration is set, the GroupResult's "state_change" property is + * updated to indicate whether the asset was added, removed, or remained + * present during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * Possible "state_change" values when compare_duration is specified: + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at reference_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at reference_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and reference_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 4; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setCompareDuration($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->compare_duration = $var; + + return $this; + } + + /** + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 5; + * @return \Google\Protobuf\Timestamp|null + */ + public function getReadTime() + { + return $this->read_time; + } + + public function hasReadTime() + { + return isset($this->read_time); + } + + public function clearReadTime() + { + unset($this->read_time); + } + + /** + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 5; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setReadTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->read_time = $var; + + return $this; + } + + /** + * The value returned by the last `GroupAssetsResponse`; indicates + * that this is a continuation of a prior `GroupAssets` call, and that the + * system should return the next page of data. + * + * Generated from protobuf field string page_token = 7; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last `GroupAssetsResponse`; indicates + * that this is a continuation of a prior `GroupAssets` call, and that the + * system should return the next page of data. + * + * Generated from protobuf field string page_token = 7; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 8; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 8; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupAssetsResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupAssetsResponse.php new file mode 100644 index 000000000000..22c92dbe38ec --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupAssetsResponse.php @@ -0,0 +1,191 @@ +google.cloud.securitycenter.v1.GroupAssetsResponse + */ +class GroupAssetsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.GroupResult group_by_results = 1; + */ + private $group_by_results; + /** + * Time used for executing the groupBy request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + */ + protected $read_time = null; + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + */ + protected $next_page_token = ''; + /** + * The total number of results matching the query. + * + * Generated from protobuf field int32 total_size = 4; + */ + protected $total_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1\GroupResult>|\Google\Protobuf\Internal\RepeatedField $group_by_results + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * @type \Google\Protobuf\Timestamp $read_time + * Time used for executing the groupBy request. + * @type string $next_page_token + * Token to retrieve the next page of results, or empty if there are no more + * results. + * @type int $total_size + * The total number of results matching the query. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.GroupResult group_by_results = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getGroupByResults() + { + return $this->group_by_results; + } + + /** + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.GroupResult group_by_results = 1; + * @param array<\Google\Cloud\SecurityCenter\V1\GroupResult>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setGroupByResults($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\GroupResult::class); + $this->group_by_results = $arr; + + return $this; + } + + /** + * Time used for executing the groupBy request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + * @return \Google\Protobuf\Timestamp|null + */ + public function getReadTime() + { + return $this->read_time; + } + + public function hasReadTime() + { + return isset($this->read_time); + } + + public function clearReadTime() + { + unset($this->read_time); + } + + /** + * Time used for executing the groupBy request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setReadTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->read_time = $var; + + return $this; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + + /** + * The total number of results matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @return int + */ + public function getTotalSize() + { + return $this->total_size; + } + + /** + * The total number of results matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @param int $var + * @return $this + */ + public function setTotalSize($var) + { + GPBUtil::checkInt32($var); + $this->total_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupFindingsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupFindingsRequest.php new file mode 100644 index 000000000000..65a1af3a2ad5 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupFindingsRequest.php @@ -0,0 +1,695 @@ +google.cloud.securitycenter.v1.GroupFindingsRequest + */ +class GroupFindingsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the source to groupBy. Its format is + * "organizations/[organization_id]/sources/[source_id]", + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]. To groupBy across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, + * or projects/{project_id}/sources/- + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * severity: `=`, `:` + * * workflow_state: `=`, `:` + * * security_marks.marks: `=`, `:` + * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * For example, `source_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * * resource: + * * resource.name: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.type: `=`, `:` + * + * Generated from protobuf field string filter = 2; + */ + protected $filter = ''; + /** + * Required. Expression that defines what assets fields to use for grouping + * (including `state_change`). The string value should follow SQL syntax: + * comma separated list of fields. For example: "parent,resource_name". + * The following fields are supported: + * * resource_name + * * category + * * state + * * parent + * * severity + * The following fields are supported when compare_duration is set: + * * state_change + * + * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $group_by = ''; + /** + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; + */ + protected $read_time = null; + /** + * When compare_duration is set, the GroupResult's "state_change" attribute is + * updated to indicate whether the finding had its state changed, the + * finding's state remained unchanged, or if the finding was added during the + * compare_duration period of time that precedes the read_time. This is the + * time between (read_time - compare_duration) and read_time. + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * Possible "state_change" values when compare_duration is specified: + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present + * at read_time. + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; + */ + protected $compare_duration = null; + /** + * The value returned by the last `GroupFindingsResponse`; indicates + * that this is a continuation of a prior `GroupFindings` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 7; + */ + protected $page_token = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 8; + */ + protected $page_size = 0; + + /** + * @param string $parent Required. Name of the source to groupBy. Its format is + * "organizations/[organization_id]/sources/[source_id]", + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]. To groupBy across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, + * or projects/{project_id}/sources/- + * Please see {@see SecurityCenterClient::sourceName()} for help formatting this field. + * @param string $groupBy Required. Expression that defines what assets fields to use for grouping + * (including `state_change`). The string value should follow SQL syntax: + * comma separated list of fields. For example: "parent,resource_name". + * + * The following fields are supported: + * + * * resource_name + * * category + * * state + * * parent + * * severity + * + * The following fields are supported when compare_duration is set: + * + * * state_change + * + * @return \Google\Cloud\SecurityCenter\V1\GroupFindingsRequest + * + * @experimental + */ + public static function build(string $parent, string $groupBy): self + { + return (new self()) + ->setParent($parent) + ->setGroupBy($groupBy); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Name of the source to groupBy. Its format is + * "organizations/[organization_id]/sources/[source_id]", + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]. To groupBy across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, + * or projects/{project_id}/sources/- + * @type string $filter + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * severity: `=`, `:` + * * workflow_state: `=`, `:` + * * security_marks.marks: `=`, `:` + * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * For example, `source_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * * resource: + * * resource.name: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.type: `=`, `:` + * @type string $group_by + * Required. Expression that defines what assets fields to use for grouping + * (including `state_change`). The string value should follow SQL syntax: + * comma separated list of fields. For example: "parent,resource_name". + * The following fields are supported: + * * resource_name + * * category + * * state + * * parent + * * severity + * The following fields are supported when compare_duration is set: + * * state_change + * @type \Google\Protobuf\Timestamp $read_time + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * @type \Google\Protobuf\Duration $compare_duration + * When compare_duration is set, the GroupResult's "state_change" attribute is + * updated to indicate whether the finding had its state changed, the + * finding's state remained unchanged, or if the finding was added during the + * compare_duration period of time that precedes the read_time. This is the + * time between (read_time - compare_duration) and read_time. + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * Possible "state_change" values when compare_duration is specified: + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present + * at read_time. + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * @type string $page_token + * The value returned by the last `GroupFindingsResponse`; indicates + * that this is a continuation of a prior `GroupFindings` call, and + * that the system should return the next page of data. + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the source to groupBy. Its format is + * "organizations/[organization_id]/sources/[source_id]", + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]. To groupBy across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, + * or projects/{project_id}/sources/- + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Name of the source to groupBy. Its format is + * "organizations/[organization_id]/sources/[source_id]", + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]. To groupBy across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, + * or projects/{project_id}/sources/- + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * severity: `=`, `:` + * * workflow_state: `=`, `:` + * * security_marks.marks: `=`, `:` + * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * For example, `source_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * * resource: + * * resource.name: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.type: `=`, `:` + * + * Generated from protobuf field string filter = 2; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * severity: `=`, `:` + * * workflow_state: `=`, `:` + * * security_marks.marks: `=`, `:` + * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * For example, `source_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * * resource: + * * resource.name: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.type: `=`, `:` + * + * Generated from protobuf field string filter = 2; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * Required. Expression that defines what assets fields to use for grouping + * (including `state_change`). The string value should follow SQL syntax: + * comma separated list of fields. For example: "parent,resource_name". + * The following fields are supported: + * * resource_name + * * category + * * state + * * parent + * * severity + * The following fields are supported when compare_duration is set: + * * state_change + * + * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getGroupBy() + { + return $this->group_by; + } + + /** + * Required. Expression that defines what assets fields to use for grouping + * (including `state_change`). The string value should follow SQL syntax: + * comma separated list of fields. For example: "parent,resource_name". + * The following fields are supported: + * * resource_name + * * category + * * state + * * parent + * * severity + * The following fields are supported when compare_duration is set: + * * state_change + * + * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setGroupBy($var) + { + GPBUtil::checkString($var, True); + $this->group_by = $var; + + return $this; + } + + /** + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; + * @return \Google\Protobuf\Timestamp|null + */ + public function getReadTime() + { + return $this->read_time; + } + + public function hasReadTime() + { + return isset($this->read_time); + } + + public function clearReadTime() + { + unset($this->read_time); + } + + /** + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setReadTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->read_time = $var; + + return $this; + } + + /** + * When compare_duration is set, the GroupResult's "state_change" attribute is + * updated to indicate whether the finding had its state changed, the + * finding's state remained unchanged, or if the finding was added during the + * compare_duration period of time that precedes the read_time. This is the + * time between (read_time - compare_duration) and read_time. + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * Possible "state_change" values when compare_duration is specified: + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present + * at read_time. + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; + * @return \Google\Protobuf\Duration|null + */ + public function getCompareDuration() + { + return $this->compare_duration; + } + + public function hasCompareDuration() + { + return isset($this->compare_duration); + } + + public function clearCompareDuration() + { + unset($this->compare_duration); + } + + /** + * When compare_duration is set, the GroupResult's "state_change" attribute is + * updated to indicate whether the finding had its state changed, the + * finding's state remained unchanged, or if the finding was added during the + * compare_duration period of time that precedes the read_time. This is the + * time between (read_time - compare_duration) and read_time. + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * Possible "state_change" values when compare_duration is specified: + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present + * at read_time. + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setCompareDuration($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->compare_duration = $var; + + return $this; + } + + /** + * The value returned by the last `GroupFindingsResponse`; indicates + * that this is a continuation of a prior `GroupFindings` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 7; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last `GroupFindingsResponse`; indicates + * that this is a continuation of a prior `GroupFindings` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 7; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 8; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 8; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupFindingsResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupFindingsResponse.php new file mode 100644 index 000000000000..fdda76699257 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupFindingsResponse.php @@ -0,0 +1,191 @@ +google.cloud.securitycenter.v1.GroupFindingsResponse + */ +class GroupFindingsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.GroupResult group_by_results = 1; + */ + private $group_by_results; + /** + * Time used for executing the groupBy request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + */ + protected $read_time = null; + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + */ + protected $next_page_token = ''; + /** + * The total number of results matching the query. + * + * Generated from protobuf field int32 total_size = 4; + */ + protected $total_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1\GroupResult>|\Google\Protobuf\Internal\RepeatedField $group_by_results + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * @type \Google\Protobuf\Timestamp $read_time + * Time used for executing the groupBy request. + * @type string $next_page_token + * Token to retrieve the next page of results, or empty if there are no more + * results. + * @type int $total_size + * The total number of results matching the query. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.GroupResult group_by_results = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getGroupByResults() + { + return $this->group_by_results; + } + + /** + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.GroupResult group_by_results = 1; + * @param array<\Google\Cloud\SecurityCenter\V1\GroupResult>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setGroupByResults($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\GroupResult::class); + $this->group_by_results = $arr; + + return $this; + } + + /** + * Time used for executing the groupBy request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + * @return \Google\Protobuf\Timestamp|null + */ + public function getReadTime() + { + return $this->read_time; + } + + public function hasReadTime() + { + return isset($this->read_time); + } + + public function clearReadTime() + { + unset($this->read_time); + } + + /** + * Time used for executing the groupBy request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setReadTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->read_time = $var; + + return $this; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + + /** + * The total number of results matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @return int + */ + public function getTotalSize() + { + return $this->total_size; + } + + /** + * The total number of results matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @param int $var + * @return $this + */ + public function setTotalSize($var) + { + GPBUtil::checkInt32($var); + $this->total_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupMembership.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupMembership.php new file mode 100644 index 000000000000..144725fbd37f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupMembership.php @@ -0,0 +1,102 @@ +google.cloud.securitycenter.v1.GroupMembership + */ +class GroupMembership extends \Google\Protobuf\Internal\Message +{ + /** + * Type of group. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.GroupMembership.GroupType group_type = 1; + */ + protected $group_type = 0; + /** + * ID of the group. + * + * Generated from protobuf field string group_id = 2; + */ + protected $group_id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $group_type + * Type of group. + * @type string $group_id + * ID of the group. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\GroupMembership::initOnce(); + parent::__construct($data); + } + + /** + * Type of group. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.GroupMembership.GroupType group_type = 1; + * @return int + */ + public function getGroupType() + { + return $this->group_type; + } + + /** + * Type of group. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.GroupMembership.GroupType group_type = 1; + * @param int $var + * @return $this + */ + public function setGroupType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\GroupMembership\GroupType::class); + $this->group_type = $var; + + return $this; + } + + /** + * ID of the group. + * + * Generated from protobuf field string group_id = 2; + * @return string + */ + public function getGroupId() + { + return $this->group_id; + } + + /** + * ID of the group. + * + * Generated from protobuf field string group_id = 2; + * @param string $var + * @return $this + */ + public function setGroupId($var) + { + GPBUtil::checkString($var, True); + $this->group_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupMembership/GroupType.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupMembership/GroupType.php new file mode 100644 index 000000000000..1aba0208c8ac --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupMembership/GroupType.php @@ -0,0 +1,57 @@ +google.cloud.securitycenter.v1.GroupMembership.GroupType + */ +class GroupType +{ + /** + * Default value. + * + * Generated from protobuf enum GROUP_TYPE_UNSPECIFIED = 0; + */ + const GROUP_TYPE_UNSPECIFIED = 0; + /** + * Group represents a toxic combination. + * + * Generated from protobuf enum GROUP_TYPE_TOXIC_COMBINATION = 1; + */ + const GROUP_TYPE_TOXIC_COMBINATION = 1; + + private static $valueToName = [ + self::GROUP_TYPE_UNSPECIFIED => 'GROUP_TYPE_UNSPECIFIED', + self::GROUP_TYPE_TOXIC_COMBINATION => 'GROUP_TYPE_TOXIC_COMBINATION', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(GroupType::class, \Google\Cloud\SecurityCenter\V1\GroupMembership_GroupType::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupResult.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupResult.php new file mode 100644 index 000000000000..a4e254e07323 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupResult.php @@ -0,0 +1,101 @@ +google.cloud.securitycenter.v1.GroupResult + */ +class GroupResult extends \Google\Protobuf\Internal\Message +{ + /** + * Properties matching the groupBy fields in the request. + * + * Generated from protobuf field map properties = 1; + */ + private $properties; + /** + * Total count of resources for the given properties. + * + * Generated from protobuf field int64 count = 2; + */ + protected $count = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\MapField $properties + * Properties matching the groupBy fields in the request. + * @type int|string $count + * Total count of resources for the given properties. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Properties matching the groupBy fields in the request. + * + * Generated from protobuf field map properties = 1; + * @return \Google\Protobuf\Internal\MapField + */ + public function getProperties() + { + return $this->properties; + } + + /** + * Properties matching the groupBy fields in the request. + * + * Generated from protobuf field map properties = 1; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setProperties($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Value::class); + $this->properties = $arr; + + return $this; + } + + /** + * Total count of resources for the given properties. + * + * Generated from protobuf field int64 count = 2; + * @return int|string + */ + public function getCount() + { + return $this->count; + } + + /** + * Total count of resources for the given properties. + * + * Generated from protobuf field int64 count = 2; + * @param int|string $var + * @return $this + */ + public function setCount($var) + { + GPBUtil::checkInt64($var); + $this->count = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/IamBinding.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/IamBinding.php new file mode 100644 index 000000000000..38408c425841 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/IamBinding.php @@ -0,0 +1,144 @@ +google.cloud.securitycenter.v1.IamBinding + */ +class IamBinding extends \Google\Protobuf\Internal\Message +{ + /** + * The action that was performed on a Binding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.IamBinding.Action action = 1; + */ + protected $action = 0; + /** + * Role that is assigned to "members". + * For example, "roles/viewer", "roles/editor", or "roles/owner". + * + * Generated from protobuf field string role = 2; + */ + protected $role = ''; + /** + * A single identity requesting access for a Cloud Platform resource, for + * example, "foo@google.com". + * + * Generated from protobuf field string member = 3; + */ + protected $member = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $action + * The action that was performed on a Binding. + * @type string $role + * Role that is assigned to "members". + * For example, "roles/viewer", "roles/editor", or "roles/owner". + * @type string $member + * A single identity requesting access for a Cloud Platform resource, for + * example, "foo@google.com". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\IamBinding::initOnce(); + parent::__construct($data); + } + + /** + * The action that was performed on a Binding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.IamBinding.Action action = 1; + * @return int + */ + public function getAction() + { + return $this->action; + } + + /** + * The action that was performed on a Binding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.IamBinding.Action action = 1; + * @param int $var + * @return $this + */ + public function setAction($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\IamBinding\Action::class); + $this->action = $var; + + return $this; + } + + /** + * Role that is assigned to "members". + * For example, "roles/viewer", "roles/editor", or "roles/owner". + * + * Generated from protobuf field string role = 2; + * @return string + */ + public function getRole() + { + return $this->role; + } + + /** + * Role that is assigned to "members". + * For example, "roles/viewer", "roles/editor", or "roles/owner". + * + * Generated from protobuf field string role = 2; + * @param string $var + * @return $this + */ + public function setRole($var) + { + GPBUtil::checkString($var, True); + $this->role = $var; + + return $this; + } + + /** + * A single identity requesting access for a Cloud Platform resource, for + * example, "foo@google.com". + * + * Generated from protobuf field string member = 3; + * @return string + */ + public function getMember() + { + return $this->member; + } + + /** + * A single identity requesting access for a Cloud Platform resource, for + * example, "foo@google.com". + * + * Generated from protobuf field string member = 3; + * @param string $var + * @return $this + */ + public function setMember($var) + { + GPBUtil::checkString($var, True); + $this->member = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/IamBinding/Action.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/IamBinding/Action.php new file mode 100644 index 000000000000..f846cd97254a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/IamBinding/Action.php @@ -0,0 +1,64 @@ +google.cloud.securitycenter.v1.IamBinding.Action + */ +class Action +{ + /** + * Unspecified. + * + * Generated from protobuf enum ACTION_UNSPECIFIED = 0; + */ + const ACTION_UNSPECIFIED = 0; + /** + * Addition of a Binding. + * + * Generated from protobuf enum ADD = 1; + */ + const ADD = 1; + /** + * Removal of a Binding. + * + * Generated from protobuf enum REMOVE = 2; + */ + const REMOVE = 2; + + private static $valueToName = [ + self::ACTION_UNSPECIFIED => 'ACTION_UNSPECIFIED', + self::ADD => 'ADD', + self::REMOVE => 'REMOVE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Action::class, \Google\Cloud\SecurityCenter\V1\IamBinding_Action::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator.php new file mode 100644 index 000000000000..04556501988b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator.php @@ -0,0 +1,177 @@ +google.cloud.securitycenter.v1.Indicator + */ +class Indicator extends \Google\Protobuf\Internal\Message +{ + /** + * The list of IP addresses that are associated with the finding. + * + * Generated from protobuf field repeated string ip_addresses = 1; + */ + private $ip_addresses; + /** + * List of domains associated to the Finding. + * + * Generated from protobuf field repeated string domains = 2; + */ + private $domains; + /** + * The list of matched signatures indicating that the given + * process is present in the environment. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Indicator.ProcessSignature signatures = 3; + */ + private $signatures; + /** + * The list of URIs associated to the Findings. + * + * Generated from protobuf field repeated string uris = 4; + */ + private $uris; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\RepeatedField $ip_addresses + * The list of IP addresses that are associated with the finding. + * @type array|\Google\Protobuf\Internal\RepeatedField $domains + * List of domains associated to the Finding. + * @type array<\Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature>|\Google\Protobuf\Internal\RepeatedField $signatures + * The list of matched signatures indicating that the given + * process is present in the environment. + * @type array|\Google\Protobuf\Internal\RepeatedField $uris + * The list of URIs associated to the Findings. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Indicator::initOnce(); + parent::__construct($data); + } + + /** + * The list of IP addresses that are associated with the finding. + * + * Generated from protobuf field repeated string ip_addresses = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getIpAddresses() + { + return $this->ip_addresses; + } + + /** + * The list of IP addresses that are associated with the finding. + * + * Generated from protobuf field repeated string ip_addresses = 1; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setIpAddresses($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->ip_addresses = $arr; + + return $this; + } + + /** + * List of domains associated to the Finding. + * + * Generated from protobuf field repeated string domains = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDomains() + { + return $this->domains; + } + + /** + * List of domains associated to the Finding. + * + * Generated from protobuf field repeated string domains = 2; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDomains($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->domains = $arr; + + return $this; + } + + /** + * The list of matched signatures indicating that the given + * process is present in the environment. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Indicator.ProcessSignature signatures = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSignatures() + { + return $this->signatures; + } + + /** + * The list of matched signatures indicating that the given + * process is present in the environment. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Indicator.ProcessSignature signatures = 3; + * @param array<\Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSignatures($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature::class); + $this->signatures = $arr; + + return $this; + } + + /** + * The list of URIs associated to the Findings. + * + * Generated from protobuf field repeated string uris = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getUris() + { + return $this->uris; + } + + /** + * The list of URIs associated to the Findings. + * + * Generated from protobuf field repeated string uris = 4; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setUris($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->uris = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature.php new file mode 100644 index 000000000000..017e6785809f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature.php @@ -0,0 +1,145 @@ +google.cloud.securitycenter.v1.Indicator.ProcessSignature + */ +class ProcessSignature extends \Google\Protobuf\Internal\Message +{ + /** + * Describes the type of resource associated with the signature. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator.ProcessSignature.SignatureType signature_type = 8; + */ + protected $signature_type = 0; + protected $signature; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\MemoryHashSignature $memory_hash_signature + * Signature indicating that a binary family was matched. + * @type \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\YaraRuleSignature $yara_rule_signature + * Signature indicating that a YARA rule was matched. + * @type int $signature_type + * Describes the type of resource associated with the signature. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Indicator::initOnce(); + parent::__construct($data); + } + + /** + * Signature indicating that a binary family was matched. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator.ProcessSignature.MemoryHashSignature memory_hash_signature = 6; + * @return \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\MemoryHashSignature|null + */ + public function getMemoryHashSignature() + { + return $this->readOneof(6); + } + + public function hasMemoryHashSignature() + { + return $this->hasOneof(6); + } + + /** + * Signature indicating that a binary family was matched. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator.ProcessSignature.MemoryHashSignature memory_hash_signature = 6; + * @param \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\MemoryHashSignature $var + * @return $this + */ + public function setMemoryHashSignature($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\MemoryHashSignature::class); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * Signature indicating that a YARA rule was matched. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator.ProcessSignature.YaraRuleSignature yara_rule_signature = 7; + * @return \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\YaraRuleSignature|null + */ + public function getYaraRuleSignature() + { + return $this->readOneof(7); + } + + public function hasYaraRuleSignature() + { + return $this->hasOneof(7); + } + + /** + * Signature indicating that a YARA rule was matched. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator.ProcessSignature.YaraRuleSignature yara_rule_signature = 7; + * @param \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\YaraRuleSignature $var + * @return $this + */ + public function setYaraRuleSignature($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\YaraRuleSignature::class); + $this->writeOneof(7, $var); + + return $this; + } + + /** + * Describes the type of resource associated with the signature. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator.ProcessSignature.SignatureType signature_type = 8; + * @return int + */ + public function getSignatureType() + { + return $this->signature_type; + } + + /** + * Describes the type of resource associated with the signature. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator.ProcessSignature.SignatureType signature_type = 8; + * @param int $var + * @return $this + */ + public function setSignatureType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\SignatureType::class); + $this->signature_type = $var; + + return $this; + } + + /** + * @return string + */ + public function getSignature() + { + return $this->whichOneof("signature"); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ProcessSignature::class, \Google\Cloud\SecurityCenter\V1\Indicator_ProcessSignature::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/MemoryHashSignature.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/MemoryHashSignature.php new file mode 100644 index 000000000000..11476d5b7ad9 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/MemoryHashSignature.php @@ -0,0 +1,108 @@ +google.cloud.securitycenter.v1.Indicator.ProcessSignature.MemoryHashSignature + */ +class MemoryHashSignature extends \Google\Protobuf\Internal\Message +{ + /** + * The binary family. + * + * Generated from protobuf field string binary_family = 1; + */ + protected $binary_family = ''; + /** + * The list of memory hash detections contributing to the binary family + * match. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Indicator.ProcessSignature.MemoryHashSignature.Detection detections = 4; + */ + private $detections; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $binary_family + * The binary family. + * @type array<\Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\MemoryHashSignature\Detection>|\Google\Protobuf\Internal\RepeatedField $detections + * The list of memory hash detections contributing to the binary family + * match. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Indicator::initOnce(); + parent::__construct($data); + } + + /** + * The binary family. + * + * Generated from protobuf field string binary_family = 1; + * @return string + */ + public function getBinaryFamily() + { + return $this->binary_family; + } + + /** + * The binary family. + * + * Generated from protobuf field string binary_family = 1; + * @param string $var + * @return $this + */ + public function setBinaryFamily($var) + { + GPBUtil::checkString($var, True); + $this->binary_family = $var; + + return $this; + } + + /** + * The list of memory hash detections contributing to the binary family + * match. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Indicator.ProcessSignature.MemoryHashSignature.Detection detections = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDetections() + { + return $this->detections; + } + + /** + * The list of memory hash detections contributing to the binary family + * match. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Indicator.ProcessSignature.MemoryHashSignature.Detection detections = 4; + * @param array<\Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\MemoryHashSignature\Detection>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDetections($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\MemoryHashSignature\Detection::class); + $this->detections = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(MemoryHashSignature::class, \Google\Cloud\SecurityCenter\V1\Indicator_ProcessSignature_MemoryHashSignature::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/MemoryHashSignature/Detection.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/MemoryHashSignature/Detection.php new file mode 100644 index 000000000000..5ffcc1036014 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/MemoryHashSignature/Detection.php @@ -0,0 +1,112 @@ +google.cloud.securitycenter.v1.Indicator.ProcessSignature.MemoryHashSignature.Detection + */ +class Detection extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the binary associated with the memory hash + * signature detection. + * + * Generated from protobuf field string binary = 2; + */ + protected $binary = ''; + /** + * The percentage of memory page hashes in the signature + * that were matched. + * + * Generated from protobuf field double percent_pages_matched = 3; + */ + protected $percent_pages_matched = 0.0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $binary + * The name of the binary associated with the memory hash + * signature detection. + * @type float $percent_pages_matched + * The percentage of memory page hashes in the signature + * that were matched. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Indicator::initOnce(); + parent::__construct($data); + } + + /** + * The name of the binary associated with the memory hash + * signature detection. + * + * Generated from protobuf field string binary = 2; + * @return string + */ + public function getBinary() + { + return $this->binary; + } + + /** + * The name of the binary associated with the memory hash + * signature detection. + * + * Generated from protobuf field string binary = 2; + * @param string $var + * @return $this + */ + public function setBinary($var) + { + GPBUtil::checkString($var, True); + $this->binary = $var; + + return $this; + } + + /** + * The percentage of memory page hashes in the signature + * that were matched. + * + * Generated from protobuf field double percent_pages_matched = 3; + * @return float + */ + public function getPercentPagesMatched() + { + return $this->percent_pages_matched; + } + + /** + * The percentage of memory page hashes in the signature + * that were matched. + * + * Generated from protobuf field double percent_pages_matched = 3; + * @param float $var + * @return $this + */ + public function setPercentPagesMatched($var) + { + GPBUtil::checkDouble($var); + $this->percent_pages_matched = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Detection::class, \Google\Cloud\SecurityCenter\V1\Indicator_ProcessSignature_MemoryHashSignature_Detection::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/SignatureType.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/SignatureType.php new file mode 100644 index 000000000000..02d1ec800c07 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/SignatureType.php @@ -0,0 +1,64 @@ +google.cloud.securitycenter.v1.Indicator.ProcessSignature.SignatureType + */ +class SignatureType +{ + /** + * The default signature type. + * + * Generated from protobuf enum SIGNATURE_TYPE_UNSPECIFIED = 0; + */ + const SIGNATURE_TYPE_UNSPECIFIED = 0; + /** + * Used for signatures concerning processes. + * + * Generated from protobuf enum SIGNATURE_TYPE_PROCESS = 1; + */ + const SIGNATURE_TYPE_PROCESS = 1; + /** + * Used for signatures concerning disks. + * + * Generated from protobuf enum SIGNATURE_TYPE_FILE = 2; + */ + const SIGNATURE_TYPE_FILE = 2; + + private static $valueToName = [ + self::SIGNATURE_TYPE_UNSPECIFIED => 'SIGNATURE_TYPE_UNSPECIFIED', + self::SIGNATURE_TYPE_PROCESS => 'SIGNATURE_TYPE_PROCESS', + self::SIGNATURE_TYPE_FILE => 'SIGNATURE_TYPE_FILE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SignatureType::class, \Google\Cloud\SecurityCenter\V1\Indicator_ProcessSignature_SignatureType::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/YaraRuleSignature.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/YaraRuleSignature.php new file mode 100644 index 000000000000..2b26a610f499 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/YaraRuleSignature.php @@ -0,0 +1,70 @@ +google.cloud.securitycenter.v1.Indicator.ProcessSignature.YaraRuleSignature + */ +class YaraRuleSignature extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the YARA rule. + * + * Generated from protobuf field string yara_rule = 5; + */ + protected $yara_rule = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $yara_rule + * The name of the YARA rule. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Indicator::initOnce(); + parent::__construct($data); + } + + /** + * The name of the YARA rule. + * + * Generated from protobuf field string yara_rule = 5; + * @return string + */ + public function getYaraRule() + { + return $this->yara_rule; + } + + /** + * The name of the YARA rule. + * + * Generated from protobuf field string yara_rule = 5; + * @param string $var + * @return $this + */ + public function setYaraRule($var) + { + GPBUtil::checkString($var, True); + $this->yara_rule = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(YaraRuleSignature::class, \Google\Cloud\SecurityCenter\V1\Indicator_ProcessSignature_YaraRuleSignature::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/KernelRootkit.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/KernelRootkit.php new file mode 100644 index 000000000000..6909bf3ddd8c --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/KernelRootkit.php @@ -0,0 +1,367 @@ +google.cloud.securitycenter.v1.KernelRootkit + */ +class KernelRootkit extends \Google\Protobuf\Internal\Message +{ + /** + * Rootkit name, when available. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * True if unexpected modifications of kernel code memory are present. + * + * Generated from protobuf field bool unexpected_code_modification = 2; + */ + protected $unexpected_code_modification = false; + /** + * True if unexpected modifications of kernel read-only data memory are + * present. + * + * Generated from protobuf field bool unexpected_read_only_data_modification = 3; + */ + protected $unexpected_read_only_data_modification = false; + /** + * True if `ftrace` points are present with callbacks pointing to regions + * that are not in the expected kernel or module code range. + * + * Generated from protobuf field bool unexpected_ftrace_handler = 4; + */ + protected $unexpected_ftrace_handler = false; + /** + * True if `kprobe` points are present with callbacks pointing to regions + * that are not in the expected kernel or module code range. + * + * Generated from protobuf field bool unexpected_kprobe_handler = 5; + */ + protected $unexpected_kprobe_handler = false; + /** + * True if kernel code pages that are not in the expected kernel or module + * code regions are present. + * + * Generated from protobuf field bool unexpected_kernel_code_pages = 6; + */ + protected $unexpected_kernel_code_pages = false; + /** + * True if system call handlers that are are not in the expected kernel or + * module code regions are present. + * + * Generated from protobuf field bool unexpected_system_call_handler = 7; + */ + protected $unexpected_system_call_handler = false; + /** + * True if interrupt handlers that are are not in the expected kernel or + * module code regions are present. + * + * Generated from protobuf field bool unexpected_interrupt_handler = 8; + */ + protected $unexpected_interrupt_handler = false; + /** + * True if unexpected processes in the scheduler run queue are present. Such + * processes are in the run queue, but not in the process task list. + * + * Generated from protobuf field bool unexpected_processes_in_runqueue = 9; + */ + protected $unexpected_processes_in_runqueue = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Rootkit name, when available. + * @type bool $unexpected_code_modification + * True if unexpected modifications of kernel code memory are present. + * @type bool $unexpected_read_only_data_modification + * True if unexpected modifications of kernel read-only data memory are + * present. + * @type bool $unexpected_ftrace_handler + * True if `ftrace` points are present with callbacks pointing to regions + * that are not in the expected kernel or module code range. + * @type bool $unexpected_kprobe_handler + * True if `kprobe` points are present with callbacks pointing to regions + * that are not in the expected kernel or module code range. + * @type bool $unexpected_kernel_code_pages + * True if kernel code pages that are not in the expected kernel or module + * code regions are present. + * @type bool $unexpected_system_call_handler + * True if system call handlers that are are not in the expected kernel or + * module code regions are present. + * @type bool $unexpected_interrupt_handler + * True if interrupt handlers that are are not in the expected kernel or + * module code regions are present. + * @type bool $unexpected_processes_in_runqueue + * True if unexpected processes in the scheduler run queue are present. Such + * processes are in the run queue, but not in the process task list. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\KernelRootkit::initOnce(); + parent::__construct($data); + } + + /** + * Rootkit name, when available. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Rootkit name, when available. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * True if unexpected modifications of kernel code memory are present. + * + * Generated from protobuf field bool unexpected_code_modification = 2; + * @return bool + */ + public function getUnexpectedCodeModification() + { + return $this->unexpected_code_modification; + } + + /** + * True if unexpected modifications of kernel code memory are present. + * + * Generated from protobuf field bool unexpected_code_modification = 2; + * @param bool $var + * @return $this + */ + public function setUnexpectedCodeModification($var) + { + GPBUtil::checkBool($var); + $this->unexpected_code_modification = $var; + + return $this; + } + + /** + * True if unexpected modifications of kernel read-only data memory are + * present. + * + * Generated from protobuf field bool unexpected_read_only_data_modification = 3; + * @return bool + */ + public function getUnexpectedReadOnlyDataModification() + { + return $this->unexpected_read_only_data_modification; + } + + /** + * True if unexpected modifications of kernel read-only data memory are + * present. + * + * Generated from protobuf field bool unexpected_read_only_data_modification = 3; + * @param bool $var + * @return $this + */ + public function setUnexpectedReadOnlyDataModification($var) + { + GPBUtil::checkBool($var); + $this->unexpected_read_only_data_modification = $var; + + return $this; + } + + /** + * True if `ftrace` points are present with callbacks pointing to regions + * that are not in the expected kernel or module code range. + * + * Generated from protobuf field bool unexpected_ftrace_handler = 4; + * @return bool + */ + public function getUnexpectedFtraceHandler() + { + return $this->unexpected_ftrace_handler; + } + + /** + * True if `ftrace` points are present with callbacks pointing to regions + * that are not in the expected kernel or module code range. + * + * Generated from protobuf field bool unexpected_ftrace_handler = 4; + * @param bool $var + * @return $this + */ + public function setUnexpectedFtraceHandler($var) + { + GPBUtil::checkBool($var); + $this->unexpected_ftrace_handler = $var; + + return $this; + } + + /** + * True if `kprobe` points are present with callbacks pointing to regions + * that are not in the expected kernel or module code range. + * + * Generated from protobuf field bool unexpected_kprobe_handler = 5; + * @return bool + */ + public function getUnexpectedKprobeHandler() + { + return $this->unexpected_kprobe_handler; + } + + /** + * True if `kprobe` points are present with callbacks pointing to regions + * that are not in the expected kernel or module code range. + * + * Generated from protobuf field bool unexpected_kprobe_handler = 5; + * @param bool $var + * @return $this + */ + public function setUnexpectedKprobeHandler($var) + { + GPBUtil::checkBool($var); + $this->unexpected_kprobe_handler = $var; + + return $this; + } + + /** + * True if kernel code pages that are not in the expected kernel or module + * code regions are present. + * + * Generated from protobuf field bool unexpected_kernel_code_pages = 6; + * @return bool + */ + public function getUnexpectedKernelCodePages() + { + return $this->unexpected_kernel_code_pages; + } + + /** + * True if kernel code pages that are not in the expected kernel or module + * code regions are present. + * + * Generated from protobuf field bool unexpected_kernel_code_pages = 6; + * @param bool $var + * @return $this + */ + public function setUnexpectedKernelCodePages($var) + { + GPBUtil::checkBool($var); + $this->unexpected_kernel_code_pages = $var; + + return $this; + } + + /** + * True if system call handlers that are are not in the expected kernel or + * module code regions are present. + * + * Generated from protobuf field bool unexpected_system_call_handler = 7; + * @return bool + */ + public function getUnexpectedSystemCallHandler() + { + return $this->unexpected_system_call_handler; + } + + /** + * True if system call handlers that are are not in the expected kernel or + * module code regions are present. + * + * Generated from protobuf field bool unexpected_system_call_handler = 7; + * @param bool $var + * @return $this + */ + public function setUnexpectedSystemCallHandler($var) + { + GPBUtil::checkBool($var); + $this->unexpected_system_call_handler = $var; + + return $this; + } + + /** + * True if interrupt handlers that are are not in the expected kernel or + * module code regions are present. + * + * Generated from protobuf field bool unexpected_interrupt_handler = 8; + * @return bool + */ + public function getUnexpectedInterruptHandler() + { + return $this->unexpected_interrupt_handler; + } + + /** + * True if interrupt handlers that are are not in the expected kernel or + * module code regions are present. + * + * Generated from protobuf field bool unexpected_interrupt_handler = 8; + * @param bool $var + * @return $this + */ + public function setUnexpectedInterruptHandler($var) + { + GPBUtil::checkBool($var); + $this->unexpected_interrupt_handler = $var; + + return $this; + } + + /** + * True if unexpected processes in the scheduler run queue are present. Such + * processes are in the run queue, but not in the process task list. + * + * Generated from protobuf field bool unexpected_processes_in_runqueue = 9; + * @return bool + */ + public function getUnexpectedProcessesInRunqueue() + { + return $this->unexpected_processes_in_runqueue; + } + + /** + * True if unexpected processes in the scheduler run queue are present. Such + * processes are in the run queue, but not in the process task list. + * + * Generated from protobuf field bool unexpected_processes_in_runqueue = 9; + * @param bool $var + * @return $this + */ + public function setUnexpectedProcessesInRunqueue($var) + { + GPBUtil::checkBool($var); + $this->unexpected_processes_in_runqueue = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes.php new file mode 100644 index 000000000000..0422e87eb6f5 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes.php @@ -0,0 +1,319 @@ +google.cloud.securitycenter.v1.Kubernetes + */ +class Kubernetes extends \Google\Protobuf\Internal\Message +{ + /** + * Kubernetes + * [Pods](https://cloud.google.com/kubernetes-engine/docs/concepts/pod) + * associated with the finding. This field contains Pod records for each + * container that is owned by a Pod. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Pod pods = 1; + */ + private $pods; + /** + * Provides Kubernetes + * [node](https://cloud.google.com/kubernetes-engine/docs/concepts/cluster-architecture#nodes) + * information. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Node nodes = 2; + */ + private $nodes; + /** + * GKE [node + * pools](https://cloud.google.com/kubernetes-engine/docs/concepts/node-pools) + * associated with the finding. This field contains node pool information for + * each node, when it is available. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.NodePool node_pools = 3; + */ + private $node_pools; + /** + * Provides Kubernetes role information for findings that involve [Roles or + * ClusterRoles](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Role roles = 4; + */ + private $roles; + /** + * Provides Kubernetes role binding information for findings that involve + * [RoleBindings or + * ClusterRoleBindings](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Binding bindings = 5; + */ + private $bindings; + /** + * Provides information on any Kubernetes access reviews (privilege checks) + * relevant to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.AccessReview access_reviews = 6; + */ + private $access_reviews; + /** + * Kubernetes objects related to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Object objects = 7; + */ + private $objects; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Pod>|\Google\Protobuf\Internal\RepeatedField $pods + * Kubernetes + * [Pods](https://cloud.google.com/kubernetes-engine/docs/concepts/pod) + * associated with the finding. This field contains Pod records for each + * container that is owned by a Pod. + * @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Node>|\Google\Protobuf\Internal\RepeatedField $nodes + * Provides Kubernetes + * [node](https://cloud.google.com/kubernetes-engine/docs/concepts/cluster-architecture#nodes) + * information. + * @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\NodePool>|\Google\Protobuf\Internal\RepeatedField $node_pools + * GKE [node + * pools](https://cloud.google.com/kubernetes-engine/docs/concepts/node-pools) + * associated with the finding. This field contains node pool information for + * each node, when it is available. + * @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Role>|\Google\Protobuf\Internal\RepeatedField $roles + * Provides Kubernetes role information for findings that involve [Roles or + * ClusterRoles](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). + * @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Binding>|\Google\Protobuf\Internal\RepeatedField $bindings + * Provides Kubernetes role binding information for findings that involve + * [RoleBindings or + * ClusterRoleBindings](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). + * @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\AccessReview>|\Google\Protobuf\Internal\RepeatedField $access_reviews + * Provides information on any Kubernetes access reviews (privilege checks) + * relevant to the finding. + * @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Object>|\Google\Protobuf\Internal\RepeatedField $objects + * Kubernetes objects related to the finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Kubernetes::initOnce(); + parent::__construct($data); + } + + /** + * Kubernetes + * [Pods](https://cloud.google.com/kubernetes-engine/docs/concepts/pod) + * associated with the finding. This field contains Pod records for each + * container that is owned by a Pod. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Pod pods = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPods() + { + return $this->pods; + } + + /** + * Kubernetes + * [Pods](https://cloud.google.com/kubernetes-engine/docs/concepts/pod) + * associated with the finding. This field contains Pod records for each + * container that is owned by a Pod. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Pod pods = 1; + * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Pod>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPods($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\Pod::class); + $this->pods = $arr; + + return $this; + } + + /** + * Provides Kubernetes + * [node](https://cloud.google.com/kubernetes-engine/docs/concepts/cluster-architecture#nodes) + * information. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Node nodes = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getNodes() + { + return $this->nodes; + } + + /** + * Provides Kubernetes + * [node](https://cloud.google.com/kubernetes-engine/docs/concepts/cluster-architecture#nodes) + * information. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Node nodes = 2; + * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Node>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setNodes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\Node::class); + $this->nodes = $arr; + + return $this; + } + + /** + * GKE [node + * pools](https://cloud.google.com/kubernetes-engine/docs/concepts/node-pools) + * associated with the finding. This field contains node pool information for + * each node, when it is available. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.NodePool node_pools = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getNodePools() + { + return $this->node_pools; + } + + /** + * GKE [node + * pools](https://cloud.google.com/kubernetes-engine/docs/concepts/node-pools) + * associated with the finding. This field contains node pool information for + * each node, when it is available. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.NodePool node_pools = 3; + * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\NodePool>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setNodePools($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\NodePool::class); + $this->node_pools = $arr; + + return $this; + } + + /** + * Provides Kubernetes role information for findings that involve [Roles or + * ClusterRoles](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Role roles = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRoles() + { + return $this->roles; + } + + /** + * Provides Kubernetes role information for findings that involve [Roles or + * ClusterRoles](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Role roles = 4; + * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Role>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRoles($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\Role::class); + $this->roles = $arr; + + return $this; + } + + /** + * Provides Kubernetes role binding information for findings that involve + * [RoleBindings or + * ClusterRoleBindings](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Binding bindings = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getBindings() + { + return $this->bindings; + } + + /** + * Provides Kubernetes role binding information for findings that involve + * [RoleBindings or + * ClusterRoleBindings](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Binding bindings = 5; + * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Binding>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setBindings($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\Binding::class); + $this->bindings = $arr; + + return $this; + } + + /** + * Provides information on any Kubernetes access reviews (privilege checks) + * relevant to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.AccessReview access_reviews = 6; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAccessReviews() + { + return $this->access_reviews; + } + + /** + * Provides information on any Kubernetes access reviews (privilege checks) + * relevant to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.AccessReview access_reviews = 6; + * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\AccessReview>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAccessReviews($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\AccessReview::class); + $this->access_reviews = $arr; + + return $this; + } + + /** + * Kubernetes objects related to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Object objects = 7; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getObjects() + { + return $this->objects; + } + + /** + * Kubernetes objects related to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Object objects = 7; + * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Object>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setObjects($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\Object::class); + $this->objects = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/AccessReview.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/AccessReview.php new file mode 100644 index 000000000000..7cfb6f5427f6 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/AccessReview.php @@ -0,0 +1,289 @@ +google.cloud.securitycenter.v1.Kubernetes.AccessReview + */ +class AccessReview extends \Google\Protobuf\Internal\Message +{ + /** + * The API group of the resource. "*" means all. + * + * Generated from protobuf field string group = 1; + */ + protected $group = ''; + /** + * Namespace of the action being requested. Currently, there is no + * distinction between no namespace and all namespaces. Both + * are represented by "" (empty). + * + * Generated from protobuf field string ns = 2; + */ + protected $ns = ''; + /** + * The name of the resource being requested. Empty means all. + * + * Generated from protobuf field string name = 3; + */ + protected $name = ''; + /** + * The optional resource type requested. "*" means all. + * + * Generated from protobuf field string resource = 4; + */ + protected $resource = ''; + /** + * The optional subresource type. + * + * Generated from protobuf field string subresource = 5; + */ + protected $subresource = ''; + /** + * A Kubernetes resource API verb, like get, list, watch, create, update, + * delete, proxy. "*" means all. + * + * Generated from protobuf field string verb = 6; + */ + protected $verb = ''; + /** + * The API version of the resource. "*" means all. + * + * Generated from protobuf field string version = 7; + */ + protected $version = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $group + * The API group of the resource. "*" means all. + * @type string $ns + * Namespace of the action being requested. Currently, there is no + * distinction between no namespace and all namespaces. Both + * are represented by "" (empty). + * @type string $name + * The name of the resource being requested. Empty means all. + * @type string $resource + * The optional resource type requested. "*" means all. + * @type string $subresource + * The optional subresource type. + * @type string $verb + * A Kubernetes resource API verb, like get, list, watch, create, update, + * delete, proxy. "*" means all. + * @type string $version + * The API version of the resource. "*" means all. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Kubernetes::initOnce(); + parent::__construct($data); + } + + /** + * The API group of the resource. "*" means all. + * + * Generated from protobuf field string group = 1; + * @return string + */ + public function getGroup() + { + return $this->group; + } + + /** + * The API group of the resource. "*" means all. + * + * Generated from protobuf field string group = 1; + * @param string $var + * @return $this + */ + public function setGroup($var) + { + GPBUtil::checkString($var, True); + $this->group = $var; + + return $this; + } + + /** + * Namespace of the action being requested. Currently, there is no + * distinction between no namespace and all namespaces. Both + * are represented by "" (empty). + * + * Generated from protobuf field string ns = 2; + * @return string + */ + public function getNs() + { + return $this->ns; + } + + /** + * Namespace of the action being requested. Currently, there is no + * distinction between no namespace and all namespaces. Both + * are represented by "" (empty). + * + * Generated from protobuf field string ns = 2; + * @param string $var + * @return $this + */ + public function setNs($var) + { + GPBUtil::checkString($var, True); + $this->ns = $var; + + return $this; + } + + /** + * The name of the resource being requested. Empty means all. + * + * Generated from protobuf field string name = 3; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the resource being requested. Empty means all. + * + * Generated from protobuf field string name = 3; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The optional resource type requested. "*" means all. + * + * Generated from protobuf field string resource = 4; + * @return string + */ + public function getResource() + { + return $this->resource; + } + + /** + * The optional resource type requested. "*" means all. + * + * Generated from protobuf field string resource = 4; + * @param string $var + * @return $this + */ + public function setResource($var) + { + GPBUtil::checkString($var, True); + $this->resource = $var; + + return $this; + } + + /** + * The optional subresource type. + * + * Generated from protobuf field string subresource = 5; + * @return string + */ + public function getSubresource() + { + return $this->subresource; + } + + /** + * The optional subresource type. + * + * Generated from protobuf field string subresource = 5; + * @param string $var + * @return $this + */ + public function setSubresource($var) + { + GPBUtil::checkString($var, True); + $this->subresource = $var; + + return $this; + } + + /** + * A Kubernetes resource API verb, like get, list, watch, create, update, + * delete, proxy. "*" means all. + * + * Generated from protobuf field string verb = 6; + * @return string + */ + public function getVerb() + { + return $this->verb; + } + + /** + * A Kubernetes resource API verb, like get, list, watch, create, update, + * delete, proxy. "*" means all. + * + * Generated from protobuf field string verb = 6; + * @param string $var + * @return $this + */ + public function setVerb($var) + { + GPBUtil::checkString($var, True); + $this->verb = $var; + + return $this; + } + + /** + * The API version of the resource. "*" means all. + * + * Generated from protobuf field string version = 7; + * @return string + */ + public function getVersion() + { + return $this->version; + } + + /** + * The API version of the resource. "*" means all. + * + * Generated from protobuf field string version = 7; + * @param string $var + * @return $this + */ + public function setVersion($var) + { + GPBUtil::checkString($var, True); + $this->version = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AccessReview::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_AccessReview::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Binding.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Binding.php new file mode 100644 index 000000000000..9751ec36d355 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Binding.php @@ -0,0 +1,186 @@ +google.cloud.securitycenter.v1.Kubernetes.Binding + */ +class Binding extends \Google\Protobuf\Internal\Message +{ + /** + * Namespace for the binding. + * + * Generated from protobuf field string ns = 1; + */ + protected $ns = ''; + /** + * Name for the binding. + * + * Generated from protobuf field string name = 2; + */ + protected $name = ''; + /** + * The Role or ClusterRole referenced by the binding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes.Role role = 3; + */ + protected $role = null; + /** + * Represents one or more subjects that are bound to the role. Not always + * available for PATCH requests. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Subject subjects = 4; + */ + private $subjects; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $ns + * Namespace for the binding. + * @type string $name + * Name for the binding. + * @type \Google\Cloud\SecurityCenter\V1\Kubernetes\Role $role + * The Role or ClusterRole referenced by the binding. + * @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Subject>|\Google\Protobuf\Internal\RepeatedField $subjects + * Represents one or more subjects that are bound to the role. Not always + * available for PATCH requests. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Kubernetes::initOnce(); + parent::__construct($data); + } + + /** + * Namespace for the binding. + * + * Generated from protobuf field string ns = 1; + * @return string + */ + public function getNs() + { + return $this->ns; + } + + /** + * Namespace for the binding. + * + * Generated from protobuf field string ns = 1; + * @param string $var + * @return $this + */ + public function setNs($var) + { + GPBUtil::checkString($var, True); + $this->ns = $var; + + return $this; + } + + /** + * Name for the binding. + * + * Generated from protobuf field string name = 2; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Name for the binding. + * + * Generated from protobuf field string name = 2; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The Role or ClusterRole referenced by the binding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes.Role role = 3; + * @return \Google\Cloud\SecurityCenter\V1\Kubernetes\Role|null + */ + public function getRole() + { + return $this->role; + } + + public function hasRole() + { + return isset($this->role); + } + + public function clearRole() + { + unset($this->role); + } + + /** + * The Role or ClusterRole referenced by the binding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes.Role role = 3; + * @param \Google\Cloud\SecurityCenter\V1\Kubernetes\Role $var + * @return $this + */ + public function setRole($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Kubernetes\Role::class); + $this->role = $var; + + return $this; + } + + /** + * Represents one or more subjects that are bound to the role. Not always + * available for PATCH requests. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Subject subjects = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSubjects() + { + return $this->subjects; + } + + /** + * Represents one or more subjects that are bound to the role. Not always + * available for PATCH requests. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Subject subjects = 4; + * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Subject>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSubjects($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\Subject::class); + $this->subjects = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Binding::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_Binding::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Node.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Node.php new file mode 100644 index 000000000000..edb8e19d7661 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Node.php @@ -0,0 +1,74 @@ +google.cloud.securitycenter.v1.Kubernetes.Node + */ +class Node extends \Google\Protobuf\Internal\Message +{ + /** + * [Full resource name](https://google.aip.dev/122#full-resource-names) of + * the Compute Engine VM running the cluster node. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * [Full resource name](https://google.aip.dev/122#full-resource-names) of + * the Compute Engine VM running the cluster node. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Kubernetes::initOnce(); + parent::__construct($data); + } + + /** + * [Full resource name](https://google.aip.dev/122#full-resource-names) of + * the Compute Engine VM running the cluster node. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * [Full resource name](https://google.aip.dev/122#full-resource-names) of + * the Compute Engine VM running the cluster node. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Node::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_Node::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/NodePool.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/NodePool.php new file mode 100644 index 000000000000..cf2dce61c43f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/NodePool.php @@ -0,0 +1,104 @@ +google.cloud.securitycenter.v1.Kubernetes.NodePool + */ +class NodePool extends \Google\Protobuf\Internal\Message +{ + /** + * Kubernetes node pool name. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Nodes associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Node nodes = 2; + */ + private $nodes; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Kubernetes node pool name. + * @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Node>|\Google\Protobuf\Internal\RepeatedField $nodes + * Nodes associated with the finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Kubernetes::initOnce(); + parent::__construct($data); + } + + /** + * Kubernetes node pool name. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Kubernetes node pool name. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Nodes associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Node nodes = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getNodes() + { + return $this->nodes; + } + + /** + * Nodes associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Node nodes = 2; + * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Node>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setNodes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\Node::class); + $this->nodes = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(NodePool::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_NodePool::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Object.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Object.php new file mode 100644 index 000000000000..ecdff6fb8032 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Object.php @@ -0,0 +1,220 @@ +google.cloud.securitycenter.v1.Kubernetes.Object + */ +class Object extends \Google\Protobuf\Internal\Message +{ + /** + * Kubernetes object group, such as "policy.k8s.io/v1". + * + * Generated from protobuf field string group = 1; + */ + protected $group = ''; + /** + * Kubernetes object kind, such as "Namespace". + * + * Generated from protobuf field string kind = 2; + */ + protected $kind = ''; + /** + * Kubernetes object namespace. Must be a valid DNS label. Named + * "ns" to avoid collision with C++ namespace keyword. For details see + * https://kubernetes.io/docs/tasks/administer-cluster/namespaces/. + * + * Generated from protobuf field string ns = 3; + */ + protected $ns = ''; + /** + * Kubernetes object name. For details see + * https://kubernetes.io/docs/concepts/overview/working-with-objects/names/. + * + * Generated from protobuf field string name = 4; + */ + protected $name = ''; + /** + * Pod containers associated with this finding, if any. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Container containers = 5; + */ + private $containers; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $group + * Kubernetes object group, such as "policy.k8s.io/v1". + * @type string $kind + * Kubernetes object kind, such as "Namespace". + * @type string $ns + * Kubernetes object namespace. Must be a valid DNS label. Named + * "ns" to avoid collision with C++ namespace keyword. For details see + * https://kubernetes.io/docs/tasks/administer-cluster/namespaces/. + * @type string $name + * Kubernetes object name. For details see + * https://kubernetes.io/docs/concepts/overview/working-with-objects/names/. + * @type array<\Google\Cloud\SecurityCenter\V1\Container>|\Google\Protobuf\Internal\RepeatedField $containers + * Pod containers associated with this finding, if any. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Kubernetes::initOnce(); + parent::__construct($data); + } + + /** + * Kubernetes object group, such as "policy.k8s.io/v1". + * + * Generated from protobuf field string group = 1; + * @return string + */ + public function getGroup() + { + return $this->group; + } + + /** + * Kubernetes object group, such as "policy.k8s.io/v1". + * + * Generated from protobuf field string group = 1; + * @param string $var + * @return $this + */ + public function setGroup($var) + { + GPBUtil::checkString($var, True); + $this->group = $var; + + return $this; + } + + /** + * Kubernetes object kind, such as "Namespace". + * + * Generated from protobuf field string kind = 2; + * @return string + */ + public function getKind() + { + return $this->kind; + } + + /** + * Kubernetes object kind, such as "Namespace". + * + * Generated from protobuf field string kind = 2; + * @param string $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkString($var, True); + $this->kind = $var; + + return $this; + } + + /** + * Kubernetes object namespace. Must be a valid DNS label. Named + * "ns" to avoid collision with C++ namespace keyword. For details see + * https://kubernetes.io/docs/tasks/administer-cluster/namespaces/. + * + * Generated from protobuf field string ns = 3; + * @return string + */ + public function getNs() + { + return $this->ns; + } + + /** + * Kubernetes object namespace. Must be a valid DNS label. Named + * "ns" to avoid collision with C++ namespace keyword. For details see + * https://kubernetes.io/docs/tasks/administer-cluster/namespaces/. + * + * Generated from protobuf field string ns = 3; + * @param string $var + * @return $this + */ + public function setNs($var) + { + GPBUtil::checkString($var, True); + $this->ns = $var; + + return $this; + } + + /** + * Kubernetes object name. For details see + * https://kubernetes.io/docs/concepts/overview/working-with-objects/names/. + * + * Generated from protobuf field string name = 4; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Kubernetes object name. For details see + * https://kubernetes.io/docs/concepts/overview/working-with-objects/names/. + * + * Generated from protobuf field string name = 4; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Pod containers associated with this finding, if any. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Container containers = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getContainers() + { + return $this->containers; + } + + /** + * Pod containers associated with this finding, if any. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Container containers = 5; + * @param array<\Google\Cloud\SecurityCenter\V1\Container>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setContainers($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Container::class); + $this->containers = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Object::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_Object::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Pod.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Pod.php new file mode 100644 index 000000000000..7d051a9a87a0 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Pod.php @@ -0,0 +1,176 @@ +google.cloud.securitycenter.v1.Kubernetes.Pod + */ +class Pod extends \Google\Protobuf\Internal\Message +{ + /** + * Kubernetes Pod namespace. + * + * Generated from protobuf field string ns = 1; + */ + protected $ns = ''; + /** + * Kubernetes Pod name. + * + * Generated from protobuf field string name = 2; + */ + protected $name = ''; + /** + * Pod labels. For Kubernetes containers, these are applied to the + * container. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Label labels = 3; + */ + private $labels; + /** + * Pod containers associated with this finding, if any. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Container containers = 4; + */ + private $containers; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $ns + * Kubernetes Pod namespace. + * @type string $name + * Kubernetes Pod name. + * @type array<\Google\Cloud\SecurityCenter\V1\Label>|\Google\Protobuf\Internal\RepeatedField $labels + * Pod labels. For Kubernetes containers, these are applied to the + * container. + * @type array<\Google\Cloud\SecurityCenter\V1\Container>|\Google\Protobuf\Internal\RepeatedField $containers + * Pod containers associated with this finding, if any. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Kubernetes::initOnce(); + parent::__construct($data); + } + + /** + * Kubernetes Pod namespace. + * + * Generated from protobuf field string ns = 1; + * @return string + */ + public function getNs() + { + return $this->ns; + } + + /** + * Kubernetes Pod namespace. + * + * Generated from protobuf field string ns = 1; + * @param string $var + * @return $this + */ + public function setNs($var) + { + GPBUtil::checkString($var, True); + $this->ns = $var; + + return $this; + } + + /** + * Kubernetes Pod name. + * + * Generated from protobuf field string name = 2; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Kubernetes Pod name. + * + * Generated from protobuf field string name = 2; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Pod labels. For Kubernetes containers, these are applied to the + * container. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Label labels = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getLabels() + { + return $this->labels; + } + + /** + * Pod labels. For Kubernetes containers, these are applied to the + * container. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Label labels = 3; + * @param array<\Google\Cloud\SecurityCenter\V1\Label>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setLabels($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Label::class); + $this->labels = $arr; + + return $this; + } + + /** + * Pod containers associated with this finding, if any. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Container containers = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getContainers() + { + return $this->containers; + } + + /** + * Pod containers associated with this finding, if any. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Container containers = 4; + * @param array<\Google\Cloud\SecurityCenter\V1\Container>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setContainers($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Container::class); + $this->containers = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Pod::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_Pod::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Role.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Role.php new file mode 100644 index 000000000000..87c452fbdc16 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Role.php @@ -0,0 +1,138 @@ +google.cloud.securitycenter.v1.Kubernetes.Role + */ +class Role extends \Google\Protobuf\Internal\Message +{ + /** + * Role type. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes.Role.Kind kind = 1; + */ + protected $kind = 0; + /** + * Role namespace. + * + * Generated from protobuf field string ns = 2; + */ + protected $ns = ''; + /** + * Role name. + * + * Generated from protobuf field string name = 3; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $kind + * Role type. + * @type string $ns + * Role namespace. + * @type string $name + * Role name. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Kubernetes::initOnce(); + parent::__construct($data); + } + + /** + * Role type. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes.Role.Kind kind = 1; + * @return int + */ + public function getKind() + { + return $this->kind; + } + + /** + * Role type. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes.Role.Kind kind = 1; + * @param int $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Kubernetes\Role\Kind::class); + $this->kind = $var; + + return $this; + } + + /** + * Role namespace. + * + * Generated from protobuf field string ns = 2; + * @return string + */ + public function getNs() + { + return $this->ns; + } + + /** + * Role namespace. + * + * Generated from protobuf field string ns = 2; + * @param string $var + * @return $this + */ + public function setNs($var) + { + GPBUtil::checkString($var, True); + $this->ns = $var; + + return $this; + } + + /** + * Role name. + * + * Generated from protobuf field string name = 3; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Role name. + * + * Generated from protobuf field string name = 3; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Role::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_Role::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Role/Kind.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Role/Kind.php new file mode 100644 index 000000000000..36dd17cbb47b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Role/Kind.php @@ -0,0 +1,64 @@ +google.cloud.securitycenter.v1.Kubernetes.Role.Kind + */ +class Kind +{ + /** + * Role type is not specified. + * + * Generated from protobuf enum KIND_UNSPECIFIED = 0; + */ + const KIND_UNSPECIFIED = 0; + /** + * Kubernetes Role. + * + * Generated from protobuf enum ROLE = 1; + */ + const ROLE = 1; + /** + * Kubernetes ClusterRole. + * + * Generated from protobuf enum CLUSTER_ROLE = 2; + */ + const CLUSTER_ROLE = 2; + + private static $valueToName = [ + self::KIND_UNSPECIFIED => 'KIND_UNSPECIFIED', + self::ROLE => 'ROLE', + self::CLUSTER_ROLE => 'CLUSTER_ROLE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Kind::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_Role_Kind::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Subject.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Subject.php new file mode 100644 index 000000000000..a23b790cbed7 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Subject.php @@ -0,0 +1,138 @@ +google.cloud.securitycenter.v1.Kubernetes.Subject + */ +class Subject extends \Google\Protobuf\Internal\Message +{ + /** + * Authentication type for the subject. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes.Subject.AuthType kind = 1; + */ + protected $kind = 0; + /** + * Namespace for the subject. + * + * Generated from protobuf field string ns = 2; + */ + protected $ns = ''; + /** + * Name for the subject. + * + * Generated from protobuf field string name = 3; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $kind + * Authentication type for the subject. + * @type string $ns + * Namespace for the subject. + * @type string $name + * Name for the subject. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Kubernetes::initOnce(); + parent::__construct($data); + } + + /** + * Authentication type for the subject. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes.Subject.AuthType kind = 1; + * @return int + */ + public function getKind() + { + return $this->kind; + } + + /** + * Authentication type for the subject. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes.Subject.AuthType kind = 1; + * @param int $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Kubernetes\Subject\AuthType::class); + $this->kind = $var; + + return $this; + } + + /** + * Namespace for the subject. + * + * Generated from protobuf field string ns = 2; + * @return string + */ + public function getNs() + { + return $this->ns; + } + + /** + * Namespace for the subject. + * + * Generated from protobuf field string ns = 2; + * @param string $var + * @return $this + */ + public function setNs($var) + { + GPBUtil::checkString($var, True); + $this->ns = $var; + + return $this; + } + + /** + * Name for the subject. + * + * Generated from protobuf field string name = 3; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Name for the subject. + * + * Generated from protobuf field string name = 3; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Subject::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_Subject::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Subject/AuthType.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Subject/AuthType.php new file mode 100644 index 000000000000..0b3c6046a837 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Subject/AuthType.php @@ -0,0 +1,71 @@ +google.cloud.securitycenter.v1.Kubernetes.Subject.AuthType + */ +class AuthType +{ + /** + * Authentication is not specified. + * + * Generated from protobuf enum AUTH_TYPE_UNSPECIFIED = 0; + */ + const AUTH_TYPE_UNSPECIFIED = 0; + /** + * User with valid certificate. + * + * Generated from protobuf enum USER = 1; + */ + const USER = 1; + /** + * Users managed by Kubernetes API with credentials stored as secrets. + * + * Generated from protobuf enum SERVICEACCOUNT = 2; + */ + const SERVICEACCOUNT = 2; + /** + * Collection of users. + * + * Generated from protobuf enum GROUP = 3; + */ + const GROUP = 3; + + private static $valueToName = [ + self::AUTH_TYPE_UNSPECIFIED => 'AUTH_TYPE_UNSPECIFIED', + self::USER => 'USER', + self::SERVICEACCOUNT => 'SERVICEACCOUNT', + self::GROUP => 'GROUP', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AuthType::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_Subject_AuthType::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Label.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Label.php new file mode 100644 index 000000000000..20cb2f555c39 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Label.php @@ -0,0 +1,104 @@ +google.cloud.securitycenter.v1.Label + */ +class Label extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the label. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Value that corresponds to the label's name. + * + * Generated from protobuf field string value = 2; + */ + protected $value = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Name of the label. + * @type string $value + * Value that corresponds to the label's name. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Label::initOnce(); + parent::__construct($data); + } + + /** + * Name of the label. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Name of the label. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Value that corresponds to the label's name. + * + * Generated from protobuf field string value = 2; + * @return string + */ + public function getValue() + { + return $this->value; + } + + /** + * Value that corresponds to the label's name. + * + * Generated from protobuf field string value = 2; + * @param string $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkString($var, True); + $this->value = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsRequest.php new file mode 100644 index 000000000000..0601a927e3bc --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsRequest.php @@ -0,0 +1,719 @@ +google.cloud.securitycenter.v1.ListAssetsRequest + */ +class ListAssetsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the parent resource that contains the assets. The + * value that you can specify on parent depends on the method in which you + * specify parent. You can specify one of the following values: + * "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following are the allowed field and operator combinations: + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * For example, `resource_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * + * Generated from protobuf field string filter = 2; + */ + protected $filter = ''; + /** + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,resource_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,resource_properties.a_property" and " + * name desc , resource_properties.a_property " are equivalent. + * The following fields are supported: + * name + * update_time + * resource_properties + * security_marks.marks + * security_center_properties.resource_name + * security_center_properties.resource_display_name + * security_center_properties.resource_parent + * security_center_properties.resource_parent_display_name + * security_center_properties.resource_project + * security_center_properties.resource_project_display_name + * security_center_properties.resource_type + * + * Generated from protobuf field string order_by = 3; + */ + protected $order_by = ''; + /** + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; + */ + protected $read_time = null; + /** + * When compare_duration is set, the ListAssetsResult's "state_change" + * attribute is updated to indicate whether the asset was added, removed, or + * remained present during the compare_duration period of time that precedes + * the read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state_change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * Possible "state_change" values when compare_duration is specified: + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at read_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at read_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; + */ + protected $compare_duration = null; + /** + * A field mask to specify the ListAssetsResult fields to be listed in the + * response. + * An empty field mask will list all fields. + * + * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; + */ + protected $field_mask = null; + /** + * The value returned by the last `ListAssetsResponse`; indicates + * that this is a continuation of a prior `ListAssets` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 8; + */ + protected $page_token = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 9; + */ + protected $page_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The name of the parent resource that contains the assets. The + * value that you can specify on parent depends on the method in which you + * specify parent. You can specify one of the following values: + * "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * @type string $filter + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following are the allowed field and operator combinations: + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * For example, `resource_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * @type string $order_by + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,resource_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,resource_properties.a_property" and " + * name desc , resource_properties.a_property " are equivalent. + * The following fields are supported: + * name + * update_time + * resource_properties + * security_marks.marks + * security_center_properties.resource_name + * security_center_properties.resource_display_name + * security_center_properties.resource_parent + * security_center_properties.resource_parent_display_name + * security_center_properties.resource_project + * security_center_properties.resource_project_display_name + * security_center_properties.resource_type + * @type \Google\Protobuf\Timestamp $read_time + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * @type \Google\Protobuf\Duration $compare_duration + * When compare_duration is set, the ListAssetsResult's "state_change" + * attribute is updated to indicate whether the asset was added, removed, or + * remained present during the compare_duration period of time that precedes + * the read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state_change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * Possible "state_change" values when compare_duration is specified: + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at read_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at read_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * @type \Google\Protobuf\FieldMask $field_mask + * A field mask to specify the ListAssetsResult fields to be listed in the + * response. + * An empty field mask will list all fields. + * @type string $page_token + * The value returned by the last `ListAssetsResponse`; indicates + * that this is a continuation of a prior `ListAssets` call, and + * that the system should return the next page of data. + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the parent resource that contains the assets. The + * value that you can specify on parent depends on the method in which you + * specify parent. You can specify one of the following values: + * "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The name of the parent resource that contains the assets. The + * value that you can specify on parent depends on the method in which you + * specify parent. You can specify one of the following values: + * "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following are the allowed field and operator combinations: + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * For example, `resource_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * + * Generated from protobuf field string filter = 2; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following are the allowed field and operator combinations: + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * For example, `resource_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * + * Generated from protobuf field string filter = 2; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,resource_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,resource_properties.a_property" and " + * name desc , resource_properties.a_property " are equivalent. + * The following fields are supported: + * name + * update_time + * resource_properties + * security_marks.marks + * security_center_properties.resource_name + * security_center_properties.resource_display_name + * security_center_properties.resource_parent + * security_center_properties.resource_parent_display_name + * security_center_properties.resource_project + * security_center_properties.resource_project_display_name + * security_center_properties.resource_type + * + * Generated from protobuf field string order_by = 3; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,resource_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,resource_properties.a_property" and " + * name desc , resource_properties.a_property " are equivalent. + * The following fields are supported: + * name + * update_time + * resource_properties + * security_marks.marks + * security_center_properties.resource_name + * security_center_properties.resource_display_name + * security_center_properties.resource_parent + * security_center_properties.resource_parent_display_name + * security_center_properties.resource_project + * security_center_properties.resource_project_display_name + * security_center_properties.resource_type + * + * Generated from protobuf field string order_by = 3; + * @param string $var + * @return $this + */ + public function setOrderBy($var) + { + GPBUtil::checkString($var, True); + $this->order_by = $var; + + return $this; + } + + /** + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; + * @return \Google\Protobuf\Timestamp|null + */ + public function getReadTime() + { + return $this->read_time; + } + + public function hasReadTime() + { + return isset($this->read_time); + } + + public function clearReadTime() + { + unset($this->read_time); + } + + /** + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setReadTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->read_time = $var; + + return $this; + } + + /** + * When compare_duration is set, the ListAssetsResult's "state_change" + * attribute is updated to indicate whether the asset was added, removed, or + * remained present during the compare_duration period of time that precedes + * the read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state_change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * Possible "state_change" values when compare_duration is specified: + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at read_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at read_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; + * @return \Google\Protobuf\Duration|null + */ + public function getCompareDuration() + { + return $this->compare_duration; + } + + public function hasCompareDuration() + { + return isset($this->compare_duration); + } + + public function clearCompareDuration() + { + unset($this->compare_duration); + } + + /** + * When compare_duration is set, the ListAssetsResult's "state_change" + * attribute is updated to indicate whether the asset was added, removed, or + * remained present during the compare_duration period of time that precedes + * the read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state_change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * Possible "state_change" values when compare_duration is specified: + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at read_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at read_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setCompareDuration($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->compare_duration = $var; + + return $this; + } + + /** + * A field mask to specify the ListAssetsResult fields to be listed in the + * response. + * An empty field mask will list all fields. + * + * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; + * @return \Google\Protobuf\FieldMask|null + */ + public function getFieldMask() + { + return $this->field_mask; + } + + public function hasFieldMask() + { + return isset($this->field_mask); + } + + public function clearFieldMask() + { + unset($this->field_mask); + } + + /** + * A field mask to specify the ListAssetsResult fields to be listed in the + * response. + * An empty field mask will list all fields. + * + * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setFieldMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->field_mask = $var; + + return $this; + } + + /** + * The value returned by the last `ListAssetsResponse`; indicates + * that this is a continuation of a prior `ListAssets` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 8; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last `ListAssetsResponse`; indicates + * that this is a continuation of a prior `ListAssets` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 8; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 9; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 9; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse.php new file mode 100644 index 000000000000..0628a39e7ed7 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse.php @@ -0,0 +1,183 @@ +google.cloud.securitycenter.v1.ListAssetsResponse + */ +class ListAssetsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Assets matching the list request. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult list_assets_results = 1; + */ + private $list_assets_results; + /** + * Time used for executing the list request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + */ + protected $read_time = null; + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + */ + protected $next_page_token = ''; + /** + * The total number of assets matching the query. + * + * Generated from protobuf field int32 total_size = 4; + */ + protected $total_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1\ListAssetsResponse\ListAssetsResult>|\Google\Protobuf\Internal\RepeatedField $list_assets_results + * Assets matching the list request. + * @type \Google\Protobuf\Timestamp $read_time + * Time used for executing the list request. + * @type string $next_page_token + * Token to retrieve the next page of results, or empty if there are no more + * results. + * @type int $total_size + * The total number of assets matching the query. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Assets matching the list request. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult list_assets_results = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getListAssetsResults() + { + return $this->list_assets_results; + } + + /** + * Assets matching the list request. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult list_assets_results = 1; + * @param array<\Google\Cloud\SecurityCenter\V1\ListAssetsResponse\ListAssetsResult>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setListAssetsResults($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\ListAssetsResponse\ListAssetsResult::class); + $this->list_assets_results = $arr; + + return $this; + } + + /** + * Time used for executing the list request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + * @return \Google\Protobuf\Timestamp|null + */ + public function getReadTime() + { + return $this->read_time; + } + + public function hasReadTime() + { + return isset($this->read_time); + } + + public function clearReadTime() + { + unset($this->read_time); + } + + /** + * Time used for executing the list request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setReadTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->read_time = $var; + + return $this; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + + /** + * The total number of assets matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @return int + */ + public function getTotalSize() + { + return $this->total_size; + } + + /** + * The total number of assets matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @param int $var + * @return $this + */ + public function setTotalSize($var) + { + GPBUtil::checkInt32($var); + $this->total_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse/ListAssetsResult.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse/ListAssetsResult.php new file mode 100644 index 000000000000..32294763c7cc --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse/ListAssetsResult.php @@ -0,0 +1,114 @@ +google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult + */ +class ListAssetsResult extends \Google\Protobuf\Internal\Message +{ + /** + * Asset matching the search request. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Asset asset = 1; + */ + protected $asset = null; + /** + * State change of the asset between the points in time. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult.StateChange state_change = 2; + */ + protected $state_change = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1\Asset $asset + * Asset matching the search request. + * @type int $state_change + * State change of the asset between the points in time. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Asset matching the search request. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Asset asset = 1; + * @return \Google\Cloud\SecurityCenter\V1\Asset|null + */ + public function getAsset() + { + return $this->asset; + } + + public function hasAsset() + { + return isset($this->asset); + } + + public function clearAsset() + { + unset($this->asset); + } + + /** + * Asset matching the search request. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Asset asset = 1; + * @param \Google\Cloud\SecurityCenter\V1\Asset $var + * @return $this + */ + public function setAsset($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Asset::class); + $this->asset = $var; + + return $this; + } + + /** + * State change of the asset between the points in time. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult.StateChange state_change = 2; + * @return int + */ + public function getStateChange() + { + return $this->state_change; + } + + /** + * State change of the asset between the points in time. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult.StateChange state_change = 2; + * @param int $var + * @return $this + */ + public function setStateChange($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\ListAssetsResponse\ListAssetsResult\StateChange::class); + $this->state_change = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ListAssetsResult::class, \Google\Cloud\SecurityCenter\V1\ListAssetsResponse_ListAssetsResult::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse/ListAssetsResult/StateChange.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse/ListAssetsResult/StateChange.php new file mode 100644 index 000000000000..54ae768528cb --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse/ListAssetsResult/StateChange.php @@ -0,0 +1,75 @@ +google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult.StateChange + */ +class StateChange +{ + /** + * State change is unused, this is the canonical default for this enum. + * + * Generated from protobuf enum UNUSED = 0; + */ + const UNUSED = 0; + /** + * Asset was added between the points in time. + * + * Generated from protobuf enum ADDED = 1; + */ + const ADDED = 1; + /** + * Asset was removed between the points in time. + * + * Generated from protobuf enum REMOVED = 2; + */ + const REMOVED = 2; + /** + * Asset was present at both point(s) in time. + * + * Generated from protobuf enum ACTIVE = 3; + */ + const ACTIVE = 3; + + private static $valueToName = [ + self::UNUSED => 'UNUSED', + self::ADDED => 'ADDED', + self::REMOVED => 'REMOVED', + self::ACTIVE => 'ACTIVE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(StateChange::class, \Google\Cloud\SecurityCenter\V1\ListAssetsResponse_ListAssetsResult_StateChange::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListBigQueryExportsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListBigQueryExportsRequest.php new file mode 100644 index 000000000000..eef9cf7d0748 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListBigQueryExportsRequest.php @@ -0,0 +1,184 @@ +google.cloud.securitycenter.v1.ListBigQueryExportsRequest + */ +class ListBigQueryExportsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The parent, which owns the collection of BigQuery exports. Its + * format is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListBigQueryExports` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListBigQueryExports` + * must match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + + /** + * @param string $parent Required. The parent, which owns the collection of BigQuery exports. Its + * format is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]". Please see + * {@see SecurityCenterClient::projectName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V1\ListBigQueryExportsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The parent, which owns the collection of BigQuery exports. Its + * format is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]". + * @type int $page_size + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * @type string $page_token + * A page token, received from a previous `ListBigQueryExports` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListBigQueryExports` + * must match the call that provided the page token. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The parent, which owns the collection of BigQuery exports. Its + * format is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The parent, which owns the collection of BigQuery exports. Its + * format is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 2; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * A page token, received from a previous `ListBigQueryExports` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListBigQueryExports` + * must match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * A page token, received from a previous `ListBigQueryExports` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListBigQueryExports` + * must match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListBigQueryExportsResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListBigQueryExportsResponse.php new file mode 100644 index 000000000000..6a4c6adae970 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListBigQueryExportsResponse.php @@ -0,0 +1,105 @@ +google.cloud.securitycenter.v1.ListBigQueryExportsResponse + */ +class ListBigQueryExportsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The BigQuery exports from the specified parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.BigQueryExport big_query_exports = 1; + */ + private $big_query_exports; + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1\BigQueryExport>|\Google\Protobuf\Internal\RepeatedField $big_query_exports + * The BigQuery exports from the specified parent. + * @type string $next_page_token + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * The BigQuery exports from the specified parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.BigQueryExport big_query_exports = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getBigQueryExports() + { + return $this->big_query_exports; + } + + /** + * The BigQuery exports from the specified parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.BigQueryExport big_query_exports = 1; + * @param array<\Google\Cloud\SecurityCenter\V1\BigQueryExport>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setBigQueryExports($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\BigQueryExport::class); + $this->big_query_exports = $arr; + + return $this; + } + + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListDescendantSecurityHealthAnalyticsCustomModulesRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListDescendantSecurityHealthAnalyticsCustomModulesRequest.php new file mode 100644 index 000000000000..cea1a56e75a1 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListDescendantSecurityHealthAnalyticsCustomModulesRequest.php @@ -0,0 +1,169 @@ +google.cloud.securitycenter.v1.ListDescendantSecurityHealthAnalyticsCustomModulesRequest + */ +class ListDescendantSecurityHealthAnalyticsCustomModulesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of parent to list descendant custom modules. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * The value returned by the last call indicating a continuation + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + + /** + * @param string $parent Required. Name of parent to list descendant custom modules. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * Please see {@see SecurityCenterClient::securityHealthAnalyticsSettingsName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V1\ListDescendantSecurityHealthAnalyticsCustomModulesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Name of parent to list descendant custom modules. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * @type string $page_token + * The value returned by the last call indicating a continuation + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of parent to list descendant custom modules. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Name of parent to list descendant custom modules. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 2; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * The value returned by the last call indicating a continuation + * + * Generated from protobuf field string page_token = 3; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last call indicating a continuation + * + * Generated from protobuf field string page_token = 3; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListDescendantSecurityHealthAnalyticsCustomModulesResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListDescendantSecurityHealthAnalyticsCustomModulesResponse.php new file mode 100644 index 000000000000..765ae2dcf51f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListDescendantSecurityHealthAnalyticsCustomModulesResponse.php @@ -0,0 +1,106 @@ +google.cloud.securitycenter.v1.ListDescendantSecurityHealthAnalyticsCustomModulesResponse + */ +class ListDescendantSecurityHealthAnalyticsCustomModulesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Custom modules belonging to the requested parent and its descendants. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_modules = 1; + */ + private $security_health_analytics_custom_modules; + /** + * If not empty, indicates that there may be more custom modules to be + * returned. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule>|\Google\Protobuf\Internal\RepeatedField $security_health_analytics_custom_modules + * Custom modules belonging to the requested parent and its descendants. + * @type string $next_page_token + * If not empty, indicates that there may be more custom modules to be + * returned. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Custom modules belonging to the requested parent and its descendants. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_modules = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSecurityHealthAnalyticsCustomModules() + { + return $this->security_health_analytics_custom_modules; + } + + /** + * Custom modules belonging to the requested parent and its descendants. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_modules = 1; + * @param array<\Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSecurityHealthAnalyticsCustomModules($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule::class); + $this->security_health_analytics_custom_modules = $arr; + + return $this; + } + + /** + * If not empty, indicates that there may be more custom modules to be + * returned. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * If not empty, indicates that there may be more custom modules to be + * returned. + * + * Generated from protobuf field string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListEffectiveSecurityHealthAnalyticsCustomModulesRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListEffectiveSecurityHealthAnalyticsCustomModulesRequest.php new file mode 100644 index 000000000000..b1f166b2b70a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListEffectiveSecurityHealthAnalyticsCustomModulesRequest.php @@ -0,0 +1,169 @@ +google.cloud.securitycenter.v1.ListEffectiveSecurityHealthAnalyticsCustomModulesRequest + */ +class ListEffectiveSecurityHealthAnalyticsCustomModulesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of parent to list effective custom modules. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * The value returned by the last call indicating a continuation + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + + /** + * @param string $parent Required. Name of parent to list effective custom modules. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * Please see {@see SecurityCenterClient::securityHealthAnalyticsSettingsName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V1\ListEffectiveSecurityHealthAnalyticsCustomModulesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Name of parent to list effective custom modules. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * @type string $page_token + * The value returned by the last call indicating a continuation + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of parent to list effective custom modules. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Name of parent to list effective custom modules. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 2; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * The value returned by the last call indicating a continuation + * + * Generated from protobuf field string page_token = 3; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last call indicating a continuation + * + * Generated from protobuf field string page_token = 3; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListEffectiveSecurityHealthAnalyticsCustomModulesResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListEffectiveSecurityHealthAnalyticsCustomModulesResponse.php new file mode 100644 index 000000000000..5a7206c77cdb --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListEffectiveSecurityHealthAnalyticsCustomModulesResponse.php @@ -0,0 +1,106 @@ +google.cloud.securitycenter.v1.ListEffectiveSecurityHealthAnalyticsCustomModulesResponse + */ +class ListEffectiveSecurityHealthAnalyticsCustomModulesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Effective custom modules belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule effective_security_health_analytics_custom_modules = 1; + */ + private $effective_security_health_analytics_custom_modules; + /** + * If not empty, indicates that there may be more effective custom modules to + * be returned. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1\EffectiveSecurityHealthAnalyticsCustomModule>|\Google\Protobuf\Internal\RepeatedField $effective_security_health_analytics_custom_modules + * Effective custom modules belonging to the requested parent. + * @type string $next_page_token + * If not empty, indicates that there may be more effective custom modules to + * be returned. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Effective custom modules belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule effective_security_health_analytics_custom_modules = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getEffectiveSecurityHealthAnalyticsCustomModules() + { + return $this->effective_security_health_analytics_custom_modules; + } + + /** + * Effective custom modules belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule effective_security_health_analytics_custom_modules = 1; + * @param array<\Google\Cloud\SecurityCenter\V1\EffectiveSecurityHealthAnalyticsCustomModule>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setEffectiveSecurityHealthAnalyticsCustomModules($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\EffectiveSecurityHealthAnalyticsCustomModule::class); + $this->effective_security_health_analytics_custom_modules = $arr; + + return $this; + } + + /** + * If not empty, indicates that there may be more effective custom modules to + * be returned. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * If not empty, indicates that there may be more effective custom modules to + * be returned. + * + * Generated from protobuf field string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsRequest.php new file mode 100644 index 000000000000..20a7ef23ff7f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsRequest.php @@ -0,0 +1,735 @@ +google.cloud.securitycenter.v1.ListFindingsRequest + */ +class ListFindingsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the source the findings belong to. Its format is + * "organizations/[organization_id]/sources/[source_id], + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]". To list across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or + * projects/{projects_id}/sources/- + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * severity: `=`, `:` + * * workflow_state: `=`, `:` + * * security_marks.marks: `=`, `:` + * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * For example, `source_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * * resource: + * * resource.name: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.type: `=`, `:` + * * resource.folders.resource_folder: `=`, `:` + * * resource.display_name: `=`, `:` + * + * Generated from protobuf field string filter = 2; + */ + protected $filter = ''; + /** + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,source_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,source_properties.a_property" and " + * name desc , source_properties.a_property " are equivalent. + * The following fields are supported: + * name + * parent + * state + * category + * resource_name + * event_time + * source_properties + * security_marks.marks + * + * Generated from protobuf field string order_by = 3; + */ + protected $order_by = ''; + /** + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; + */ + protected $read_time = null; + /** + * When compare_duration is set, the ListFindingsResult's "state_change" + * attribute is updated to indicate whether the finding had its state changed, + * the finding's state remained unchanged, or if the finding was added in any + * state during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * Possible "state_change" values when compare_duration is specified: + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present at + * read_time. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; + */ + protected $compare_duration = null; + /** + * A field mask to specify the Finding fields to be listed in the response. + * An empty field mask will list all fields. + * + * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; + */ + protected $field_mask = null; + /** + * The value returned by the last `ListFindingsResponse`; indicates + * that this is a continuation of a prior `ListFindings` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 8; + */ + protected $page_token = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 9; + */ + protected $page_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Name of the source the findings belong to. Its format is + * "organizations/[organization_id]/sources/[source_id], + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]". To list across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or + * projects/{projects_id}/sources/- + * @type string $filter + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * severity: `=`, `:` + * * workflow_state: `=`, `:` + * * security_marks.marks: `=`, `:` + * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * For example, `source_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * * resource: + * * resource.name: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.type: `=`, `:` + * * resource.folders.resource_folder: `=`, `:` + * * resource.display_name: `=`, `:` + * @type string $order_by + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,source_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,source_properties.a_property" and " + * name desc , source_properties.a_property " are equivalent. + * The following fields are supported: + * name + * parent + * state + * category + * resource_name + * event_time + * source_properties + * security_marks.marks + * @type \Google\Protobuf\Timestamp $read_time + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * @type \Google\Protobuf\Duration $compare_duration + * When compare_duration is set, the ListFindingsResult's "state_change" + * attribute is updated to indicate whether the finding had its state changed, + * the finding's state remained unchanged, or if the finding was added in any + * state during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * Possible "state_change" values when compare_duration is specified: + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present at + * read_time. + * @type \Google\Protobuf\FieldMask $field_mask + * A field mask to specify the Finding fields to be listed in the response. + * An empty field mask will list all fields. + * @type string $page_token + * The value returned by the last `ListFindingsResponse`; indicates + * that this is a continuation of a prior `ListFindings` call, and + * that the system should return the next page of data. + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the source the findings belong to. Its format is + * "organizations/[organization_id]/sources/[source_id], + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]". To list across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or + * projects/{projects_id}/sources/- + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Name of the source the findings belong to. Its format is + * "organizations/[organization_id]/sources/[source_id], + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]". To list across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or + * projects/{projects_id}/sources/- + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * severity: `=`, `:` + * * workflow_state: `=`, `:` + * * security_marks.marks: `=`, `:` + * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * For example, `source_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * * resource: + * * resource.name: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.type: `=`, `:` + * * resource.folders.resource_folder: `=`, `:` + * * resource.display_name: `=`, `:` + * + * Generated from protobuf field string filter = 2; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * severity: `=`, `:` + * * workflow_state: `=`, `:` + * * security_marks.marks: `=`, `:` + * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * For example, `source_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * * resource: + * * resource.name: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.type: `=`, `:` + * * resource.folders.resource_folder: `=`, `:` + * * resource.display_name: `=`, `:` + * + * Generated from protobuf field string filter = 2; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,source_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,source_properties.a_property" and " + * name desc , source_properties.a_property " are equivalent. + * The following fields are supported: + * name + * parent + * state + * category + * resource_name + * event_time + * source_properties + * security_marks.marks + * + * Generated from protobuf field string order_by = 3; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,source_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,source_properties.a_property" and " + * name desc , source_properties.a_property " are equivalent. + * The following fields are supported: + * name + * parent + * state + * category + * resource_name + * event_time + * source_properties + * security_marks.marks + * + * Generated from protobuf field string order_by = 3; + * @param string $var + * @return $this + */ + public function setOrderBy($var) + { + GPBUtil::checkString($var, True); + $this->order_by = $var; + + return $this; + } + + /** + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; + * @return \Google\Protobuf\Timestamp|null + */ + public function getReadTime() + { + return $this->read_time; + } + + public function hasReadTime() + { + return isset($this->read_time); + } + + public function clearReadTime() + { + unset($this->read_time); + } + + /** + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setReadTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->read_time = $var; + + return $this; + } + + /** + * When compare_duration is set, the ListFindingsResult's "state_change" + * attribute is updated to indicate whether the finding had its state changed, + * the finding's state remained unchanged, or if the finding was added in any + * state during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * Possible "state_change" values when compare_duration is specified: + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present at + * read_time. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; + * @return \Google\Protobuf\Duration|null + */ + public function getCompareDuration() + { + return $this->compare_duration; + } + + public function hasCompareDuration() + { + return isset($this->compare_duration); + } + + public function clearCompareDuration() + { + unset($this->compare_duration); + } + + /** + * When compare_duration is set, the ListFindingsResult's "state_change" + * attribute is updated to indicate whether the finding had its state changed, + * the finding's state remained unchanged, or if the finding was added in any + * state during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * Possible "state_change" values when compare_duration is specified: + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present at + * read_time. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setCompareDuration($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->compare_duration = $var; + + return $this; + } + + /** + * A field mask to specify the Finding fields to be listed in the response. + * An empty field mask will list all fields. + * + * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; + * @return \Google\Protobuf\FieldMask|null + */ + public function getFieldMask() + { + return $this->field_mask; + } + + public function hasFieldMask() + { + return isset($this->field_mask); + } + + public function clearFieldMask() + { + unset($this->field_mask); + } + + /** + * A field mask to specify the Finding fields to be listed in the response. + * An empty field mask will list all fields. + * + * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setFieldMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->field_mask = $var; + + return $this; + } + + /** + * The value returned by the last `ListFindingsResponse`; indicates + * that this is a continuation of a prior `ListFindings` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 8; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last `ListFindingsResponse`; indicates + * that this is a continuation of a prior `ListFindings` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 8; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 9; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 9; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse.php new file mode 100644 index 000000000000..f0f409419e18 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse.php @@ -0,0 +1,183 @@ +google.cloud.securitycenter.v1.ListFindingsResponse + */ +class ListFindingsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Findings matching the list request. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult list_findings_results = 1; + */ + private $list_findings_results; + /** + * Time used for executing the list request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + */ + protected $read_time = null; + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + */ + protected $next_page_token = ''; + /** + * The total number of findings matching the query. + * + * Generated from protobuf field int32 total_size = 4; + */ + protected $total_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1\ListFindingsResponse\ListFindingsResult>|\Google\Protobuf\Internal\RepeatedField $list_findings_results + * Findings matching the list request. + * @type \Google\Protobuf\Timestamp $read_time + * Time used for executing the list request. + * @type string $next_page_token + * Token to retrieve the next page of results, or empty if there are no more + * results. + * @type int $total_size + * The total number of findings matching the query. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Findings matching the list request. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult list_findings_results = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getListFindingsResults() + { + return $this->list_findings_results; + } + + /** + * Findings matching the list request. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult list_findings_results = 1; + * @param array<\Google\Cloud\SecurityCenter\V1\ListFindingsResponse\ListFindingsResult>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setListFindingsResults($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\ListFindingsResponse\ListFindingsResult::class); + $this->list_findings_results = $arr; + + return $this; + } + + /** + * Time used for executing the list request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + * @return \Google\Protobuf\Timestamp|null + */ + public function getReadTime() + { + return $this->read_time; + } + + public function hasReadTime() + { + return isset($this->read_time); + } + + public function clearReadTime() + { + unset($this->read_time); + } + + /** + * Time used for executing the list request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setReadTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->read_time = $var; + + return $this; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + + /** + * The total number of findings matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @return int + */ + public function getTotalSize() + { + return $this->total_size; + } + + /** + * The total number of findings matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @param int $var + * @return $this + */ + public function setTotalSize($var) + { + GPBUtil::checkInt32($var); + $this->total_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult.php new file mode 100644 index 000000000000..f24a6f2dedd5 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult.php @@ -0,0 +1,158 @@ +google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult + */ +class ListFindingsResult extends \Google\Protobuf\Internal\Message +{ + /** + * Finding matching the search request. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 1; + */ + protected $finding = null; + /** + * State change of the finding between the points in time. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.StateChange state_change = 2; + */ + protected $state_change = 0; + /** + * Output only. Resource that is associated with this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.Resource resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $resource = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1\Finding $finding + * Finding matching the search request. + * @type int $state_change + * State change of the finding between the points in time. + * @type \Google\Cloud\SecurityCenter\V1\ListFindingsResponse\ListFindingsResult\Resource $resource + * Output only. Resource that is associated with this finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Finding matching the search request. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 1; + * @return \Google\Cloud\SecurityCenter\V1\Finding|null + */ + public function getFinding() + { + return $this->finding; + } + + public function hasFinding() + { + return isset($this->finding); + } + + public function clearFinding() + { + unset($this->finding); + } + + /** + * Finding matching the search request. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 1; + * @param \Google\Cloud\SecurityCenter\V1\Finding $var + * @return $this + */ + public function setFinding($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Finding::class); + $this->finding = $var; + + return $this; + } + + /** + * State change of the finding between the points in time. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.StateChange state_change = 2; + * @return int + */ + public function getStateChange() + { + return $this->state_change; + } + + /** + * State change of the finding between the points in time. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.StateChange state_change = 2; + * @param int $var + * @return $this + */ + public function setStateChange($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\ListFindingsResponse\ListFindingsResult\StateChange::class); + $this->state_change = $var; + + return $this; + } + + /** + * Output only. Resource that is associated with this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.Resource resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Cloud\SecurityCenter\V1\ListFindingsResponse\ListFindingsResult\Resource|null + */ + public function getResource() + { + return $this->resource; + } + + public function hasResource() + { + return isset($this->resource); + } + + public function clearResource() + { + unset($this->resource); + } + + /** + * Output only. Resource that is associated with this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.Resource resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\SecurityCenter\V1\ListFindingsResponse\ListFindingsResult\Resource $var + * @return $this + */ + public function setResource($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\ListFindingsResponse\ListFindingsResult\Resource::class); + $this->resource = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ListFindingsResult::class, \Google\Cloud\SecurityCenter\V1\ListFindingsResponse_ListFindingsResult::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult/Resource.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult/Resource.php new file mode 100644 index 000000000000..be2d2d246150 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult/Resource.php @@ -0,0 +1,321 @@ +google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.Resource + */ +class Resource extends \Google\Protobuf\Internal\Message +{ + /** + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The human readable name of the resource. + * + * Generated from protobuf field string display_name = 8; + */ + protected $display_name = ''; + /** + * The full resource type of the resource. + * + * Generated from protobuf field string type = 6; + */ + protected $type = ''; + /** + * The full resource name of project that the resource belongs to. + * + * Generated from protobuf field string project_name = 2; + */ + protected $project_name = ''; + /** + * The project ID that the resource belongs to. + * + * Generated from protobuf field string project_display_name = 3; + */ + protected $project_display_name = ''; + /** + * The full resource name of resource's parent. + * + * Generated from protobuf field string parent_name = 4; + */ + protected $parent_name = ''; + /** + * The human readable name of resource's parent. + * + * Generated from protobuf field string parent_display_name = 5; + */ + protected $parent_display_name = ''; + /** + * Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is + * the folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Folder folders = 7; + */ + private $folders; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * @type string $display_name + * The human readable name of the resource. + * @type string $type + * The full resource type of the resource. + * @type string $project_name + * The full resource name of project that the resource belongs to. + * @type string $project_display_name + * The project ID that the resource belongs to. + * @type string $parent_name + * The full resource name of resource's parent. + * @type string $parent_display_name + * The human readable name of resource's parent. + * @type array<\Google\Cloud\SecurityCenter\V1\Folder>|\Google\Protobuf\Internal\RepeatedField $folders + * Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is + * the folder directly under the Organization. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The human readable name of the resource. + * + * Generated from protobuf field string display_name = 8; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * The human readable name of the resource. + * + * Generated from protobuf field string display_name = 8; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * The full resource type of the resource. + * + * Generated from protobuf field string type = 6; + * @return string + */ + public function getType() + { + return $this->type; + } + + /** + * The full resource type of the resource. + * + * Generated from protobuf field string type = 6; + * @param string $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkString($var, True); + $this->type = $var; + + return $this; + } + + /** + * The full resource name of project that the resource belongs to. + * + * Generated from protobuf field string project_name = 2; + * @return string + */ + public function getProjectName() + { + return $this->project_name; + } + + /** + * The full resource name of project that the resource belongs to. + * + * Generated from protobuf field string project_name = 2; + * @param string $var + * @return $this + */ + public function setProjectName($var) + { + GPBUtil::checkString($var, True); + $this->project_name = $var; + + return $this; + } + + /** + * The project ID that the resource belongs to. + * + * Generated from protobuf field string project_display_name = 3; + * @return string + */ + public function getProjectDisplayName() + { + return $this->project_display_name; + } + + /** + * The project ID that the resource belongs to. + * + * Generated from protobuf field string project_display_name = 3; + * @param string $var + * @return $this + */ + public function setProjectDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->project_display_name = $var; + + return $this; + } + + /** + * The full resource name of resource's parent. + * + * Generated from protobuf field string parent_name = 4; + * @return string + */ + public function getParentName() + { + return $this->parent_name; + } + + /** + * The full resource name of resource's parent. + * + * Generated from protobuf field string parent_name = 4; + * @param string $var + * @return $this + */ + public function setParentName($var) + { + GPBUtil::checkString($var, True); + $this->parent_name = $var; + + return $this; + } + + /** + * The human readable name of resource's parent. + * + * Generated from protobuf field string parent_display_name = 5; + * @return string + */ + public function getParentDisplayName() + { + return $this->parent_display_name; + } + + /** + * The human readable name of resource's parent. + * + * Generated from protobuf field string parent_display_name = 5; + * @param string $var + * @return $this + */ + public function setParentDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->parent_display_name = $var; + + return $this; + } + + /** + * Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is + * the folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Folder folders = 7; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFolders() + { + return $this->folders; + } + + /** + * Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is + * the folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Folder folders = 7; + * @param array<\Google\Cloud\SecurityCenter\V1\Folder>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFolders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Folder::class); + $this->folders = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Resource::class, \Google\Cloud\SecurityCenter\V1\ListFindingsResponse_ListFindingsResult_Resource::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult/StateChange.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult/StateChange.php new file mode 100644 index 000000000000..f723d59d4747 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult/StateChange.php @@ -0,0 +1,87 @@ +google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.StateChange + */ +class StateChange +{ + /** + * State change is unused, this is the canonical default for this enum. + * + * Generated from protobuf enum UNUSED = 0; + */ + const UNUSED = 0; + /** + * The finding has changed state in some way between the points in time + * and existed at both points. + * + * Generated from protobuf enum CHANGED = 1; + */ + const CHANGED = 1; + /** + * The finding has not changed state between the points in time and + * existed at both points. + * + * Generated from protobuf enum UNCHANGED = 2; + */ + const UNCHANGED = 2; + /** + * The finding was created between the points in time. + * + * Generated from protobuf enum ADDED = 3; + */ + const ADDED = 3; + /** + * The finding at timestamp does not match the filter specified, but it + * did at timestamp - compare_duration. + * + * Generated from protobuf enum REMOVED = 4; + */ + const REMOVED = 4; + + private static $valueToName = [ + self::UNUSED => 'UNUSED', + self::CHANGED => 'CHANGED', + self::UNCHANGED => 'UNCHANGED', + self::ADDED => 'ADDED', + self::REMOVED => 'REMOVED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(StateChange::class, \Google\Cloud\SecurityCenter\V1\ListFindingsResponse_ListFindingsResult_StateChange::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListMuteConfigsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListMuteConfigsRequest.php new file mode 100644 index 000000000000..9fd7c1ca01cc --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListMuteConfigsRequest.php @@ -0,0 +1,184 @@ +google.cloud.securitycenter.v1.ListMuteConfigsRequest + */ +class ListMuteConfigsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The parent, which owns the collection of mute configs. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListMuteConfigs` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListMuteConfigs` must + * match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + + /** + * @param string $parent Required. The parent, which owns the collection of mute configs. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]". Please see + * {@see SecurityCenterClient::projectName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V1\ListMuteConfigsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The parent, which owns the collection of mute configs. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]". + * @type int $page_size + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * @type string $page_token + * A page token, received from a previous `ListMuteConfigs` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListMuteConfigs` must + * match the call that provided the page token. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The parent, which owns the collection of mute configs. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The parent, which owns the collection of mute configs. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 2; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * A page token, received from a previous `ListMuteConfigs` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListMuteConfigs` must + * match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * A page token, received from a previous `ListMuteConfigs` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListMuteConfigs` must + * match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListMuteConfigsResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListMuteConfigsResponse.php new file mode 100644 index 000000000000..31b493a80a68 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListMuteConfigsResponse.php @@ -0,0 +1,105 @@ +google.cloud.securitycenter.v1.ListMuteConfigsResponse + */ +class ListMuteConfigsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The mute configs from the specified parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MuteConfig mute_configs = 1; + */ + private $mute_configs; + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1\MuteConfig>|\Google\Protobuf\Internal\RepeatedField $mute_configs + * The mute configs from the specified parent. + * @type string $next_page_token + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * The mute configs from the specified parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MuteConfig mute_configs = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMuteConfigs() + { + return $this->mute_configs; + } + + /** + * The mute configs from the specified parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MuteConfig mute_configs = 1; + * @param array<\Google\Cloud\SecurityCenter\V1\MuteConfig>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMuteConfigs($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\MuteConfig::class); + $this->mute_configs = $arr; + + return $this; + } + + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListNotificationConfigsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListNotificationConfigsRequest.php new file mode 100644 index 000000000000..185cfdac2f68 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListNotificationConfigsRequest.php @@ -0,0 +1,171 @@ +google.cloud.securitycenter.v1.ListNotificationConfigsRequest + */ +class ListNotificationConfigsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the parent in which to list the notification + * configurations. Its format is "organizations/[organization_id]", + * "folders/[folder_id]", or "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The value returned by the last `ListNotificationConfigsResponse`; indicates + * that this is a continuation of a prior `ListNotificationConfigs` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 2; + */ + protected $page_token = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 3; + */ + protected $page_size = 0; + + /** + * @param string $parent Required. The name of the parent in which to list the notification + * configurations. Its format is "organizations/[organization_id]", + * "folders/[folder_id]", or "projects/[project_id]". Please see + * {@see SecurityCenterClient::projectName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V1\ListNotificationConfigsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The name of the parent in which to list the notification + * configurations. Its format is "organizations/[organization_id]", + * "folders/[folder_id]", or "projects/[project_id]". + * @type string $page_token + * The value returned by the last `ListNotificationConfigsResponse`; indicates + * that this is a continuation of a prior `ListNotificationConfigs` call, and + * that the system should return the next page of data. + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the parent in which to list the notification + * configurations. Its format is "organizations/[organization_id]", + * "folders/[folder_id]", or "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The name of the parent in which to list the notification + * configurations. Its format is "organizations/[organization_id]", + * "folders/[folder_id]", or "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The value returned by the last `ListNotificationConfigsResponse`; indicates + * that this is a continuation of a prior `ListNotificationConfigs` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 2; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last `ListNotificationConfigsResponse`; indicates + * that this is a continuation of a prior `ListNotificationConfigs` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 2; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 3; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 3; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListNotificationConfigsResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListNotificationConfigsResponse.php new file mode 100644 index 000000000000..a6fa6d4a15b2 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListNotificationConfigsResponse.php @@ -0,0 +1,105 @@ +google.cloud.securitycenter.v1.ListNotificationConfigsResponse + */ +class ListNotificationConfigsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Notification configs belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.NotificationConfig notification_configs = 1; + */ + private $notification_configs; + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1\NotificationConfig>|\Google\Protobuf\Internal\RepeatedField $notification_configs + * Notification configs belonging to the requested parent. + * @type string $next_page_token + * Token to retrieve the next page of results, or empty if there are no more + * results. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Notification configs belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.NotificationConfig notification_configs = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getNotificationConfigs() + { + return $this->notification_configs; + } + + /** + * Notification configs belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.NotificationConfig notification_configs = 1; + * @param array<\Google\Cloud\SecurityCenter\V1\NotificationConfig>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setNotificationConfigs($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\NotificationConfig::class); + $this->notification_configs = $arr; + + return $this; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSecurityHealthAnalyticsCustomModulesRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSecurityHealthAnalyticsCustomModulesRequest.php new file mode 100644 index 000000000000..de60b910d294 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSecurityHealthAnalyticsCustomModulesRequest.php @@ -0,0 +1,168 @@ +google.cloud.securitycenter.v1.ListSecurityHealthAnalyticsCustomModulesRequest + */ +class ListSecurityHealthAnalyticsCustomModulesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of parent to list custom modules. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * The value returned by the last call indicating a continuation + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + + /** + * @param string $parent Required. Name of parent to list custom modules. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * Please see {@see SecurityCenterClient::securityHealthAnalyticsSettingsName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V1\ListSecurityHealthAnalyticsCustomModulesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Name of parent to list custom modules. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * @type string $page_token + * The value returned by the last call indicating a continuation + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of parent to list custom modules. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Name of parent to list custom modules. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 2; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * The value returned by the last call indicating a continuation + * + * Generated from protobuf field string page_token = 3; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last call indicating a continuation + * + * Generated from protobuf field string page_token = 3; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSecurityHealthAnalyticsCustomModulesResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSecurityHealthAnalyticsCustomModulesResponse.php new file mode 100644 index 000000000000..7b27b9e9c9d1 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSecurityHealthAnalyticsCustomModulesResponse.php @@ -0,0 +1,105 @@ +google.cloud.securitycenter.v1.ListSecurityHealthAnalyticsCustomModulesResponse + */ +class ListSecurityHealthAnalyticsCustomModulesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Custom modules belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_modules = 1; + */ + private $security_health_analytics_custom_modules; + /** + * If not empty, indicates that there may be more custom modules to be + * returned. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule>|\Google\Protobuf\Internal\RepeatedField $security_health_analytics_custom_modules + * Custom modules belonging to the requested parent. + * @type string $next_page_token + * If not empty, indicates that there may be more custom modules to be + * returned. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Custom modules belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_modules = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSecurityHealthAnalyticsCustomModules() + { + return $this->security_health_analytics_custom_modules; + } + + /** + * Custom modules belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_modules = 1; + * @param array<\Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSecurityHealthAnalyticsCustomModules($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule::class); + $this->security_health_analytics_custom_modules = $arr; + + return $this; + } + + /** + * If not empty, indicates that there may be more custom modules to be + * returned. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * If not empty, indicates that there may be more custom modules to be + * returned. + * + * Generated from protobuf field string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSourcesRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSourcesRequest.php new file mode 100644 index 000000000000..48a8424926c5 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSourcesRequest.php @@ -0,0 +1,171 @@ +google.cloud.securitycenter.v1.ListSourcesRequest + */ +class ListSourcesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the parent of sources to list. Its format should + * be "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The value returned by the last `ListSourcesResponse`; indicates + * that this is a continuation of a prior `ListSources` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 2; + */ + protected $page_token = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 7; + */ + protected $page_size = 0; + + /** + * @param string $parent Required. Resource name of the parent of sources to list. Its format should + * be "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". Please see + * {@see SecurityCenterClient::projectName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V1\ListSourcesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Resource name of the parent of sources to list. Its format should + * be "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * @type string $page_token + * The value returned by the last `ListSourcesResponse`; indicates + * that this is a continuation of a prior `ListSources` call, and + * that the system should return the next page of data. + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the parent of sources to list. Its format should + * be "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Resource name of the parent of sources to list. Its format should + * be "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The value returned by the last `ListSourcesResponse`; indicates + * that this is a continuation of a prior `ListSources` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 2; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last `ListSourcesResponse`; indicates + * that this is a continuation of a prior `ListSources` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 2; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 7; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 7; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSourcesResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSourcesResponse.php new file mode 100644 index 000000000000..97309f3b340f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSourcesResponse.php @@ -0,0 +1,105 @@ +google.cloud.securitycenter.v1.ListSourcesResponse + */ +class ListSourcesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Sources belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Source sources = 1; + */ + private $sources; + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1\Source>|\Google\Protobuf\Internal\RepeatedField $sources + * Sources belonging to the requested parent. + * @type string $next_page_token + * Token to retrieve the next page of results, or empty if there are no more + * results. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Sources belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Source sources = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSources() + { + return $this->sources; + } + + /** + * Sources belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Source sources = 1; + * @param array<\Google\Cloud\SecurityCenter\V1\Source>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSources($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Source::class); + $this->sources = $arr; + + return $this; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/LoadBalancer.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/LoadBalancer.php new file mode 100644 index 000000000000..b67df9f32eeb --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/LoadBalancer.php @@ -0,0 +1,68 @@ +google.cloud.securitycenter.v1.LoadBalancer + */ +class LoadBalancer extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the load balancer associated with the finding. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the load balancer associated with the finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\LoadBalancer::initOnce(); + parent::__construct($data); + } + + /** + * The name of the load balancer associated with the finding. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the load balancer associated with the finding. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/LogEntry.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/LogEntry.php new file mode 100644 index 000000000000..474562b7ae80 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/LogEntry.php @@ -0,0 +1,75 @@ +google.cloud.securitycenter.v1.LogEntry + */ +class LogEntry extends \Google\Protobuf\Internal\Message +{ + protected $log_entry; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1\CloudLoggingEntry $cloud_logging_entry + * An individual entry in a log stored in Cloud Logging. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\LogEntry::initOnce(); + parent::__construct($data); + } + + /** + * An individual entry in a log stored in Cloud Logging. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CloudLoggingEntry cloud_logging_entry = 1; + * @return \Google\Cloud\SecurityCenter\V1\CloudLoggingEntry|null + */ + public function getCloudLoggingEntry() + { + return $this->readOneof(1); + } + + public function hasCloudLoggingEntry() + { + return $this->hasOneof(1); + } + + /** + * An individual entry in a log stored in Cloud Logging. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CloudLoggingEntry cloud_logging_entry = 1; + * @param \Google\Cloud\SecurityCenter\V1\CloudLoggingEntry $var + * @return $this + */ + public function setCloudLoggingEntry($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\CloudLoggingEntry::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * @return string + */ + public function getLogEntry() + { + return $this->whichOneof("log_entry"); + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack.php new file mode 100644 index 000000000000..77ad4a2a0770 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack.php @@ -0,0 +1,228 @@ +google.cloud.securitycenter.v1.MitreAttack + */ +class MitreAttack extends \Google\Protobuf\Internal\Message +{ + /** + * The MITRE ATT&CK tactic most closely represented by this finding, if any. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.MitreAttack.Tactic primary_tactic = 1; + */ + protected $primary_tactic = 0; + /** + * The MITRE ATT&CK technique most closely represented by this finding, if + * any. primary_techniques is a repeated field because there are multiple + * levels of MITRE ATT&CK techniques. If the technique most closely + * represented by this finding is a sub-technique (e.g. `SCANNING_IP_BLOCKS`), + * both the sub-technique and its parent technique(s) will be listed (e.g. + * `SCANNING_IP_BLOCKS`, `ACTIVE_SCANNING`). + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MitreAttack.Technique primary_techniques = 2; + */ + private $primary_techniques; + /** + * Additional MITRE ATT&CK tactics related to this finding, if any. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MitreAttack.Tactic additional_tactics = 3; + */ + private $additional_tactics; + /** + * Additional MITRE ATT&CK techniques related to this finding, if any, along + * with any of their respective parent techniques. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MitreAttack.Technique additional_techniques = 4; + */ + private $additional_techniques; + /** + * The MITRE ATT&CK version referenced by the above fields. E.g. "8". + * + * Generated from protobuf field string version = 5; + */ + protected $version = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $primary_tactic + * The MITRE ATT&CK tactic most closely represented by this finding, if any. + * @type array|\Google\Protobuf\Internal\RepeatedField $primary_techniques + * The MITRE ATT&CK technique most closely represented by this finding, if + * any. primary_techniques is a repeated field because there are multiple + * levels of MITRE ATT&CK techniques. If the technique most closely + * represented by this finding is a sub-technique (e.g. `SCANNING_IP_BLOCKS`), + * both the sub-technique and its parent technique(s) will be listed (e.g. + * `SCANNING_IP_BLOCKS`, `ACTIVE_SCANNING`). + * @type array|\Google\Protobuf\Internal\RepeatedField $additional_tactics + * Additional MITRE ATT&CK tactics related to this finding, if any. + * @type array|\Google\Protobuf\Internal\RepeatedField $additional_techniques + * Additional MITRE ATT&CK techniques related to this finding, if any, along + * with any of their respective parent techniques. + * @type string $version + * The MITRE ATT&CK version referenced by the above fields. E.g. "8". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\MitreAttack::initOnce(); + parent::__construct($data); + } + + /** + * The MITRE ATT&CK tactic most closely represented by this finding, if any. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.MitreAttack.Tactic primary_tactic = 1; + * @return int + */ + public function getPrimaryTactic() + { + return $this->primary_tactic; + } + + /** + * The MITRE ATT&CK tactic most closely represented by this finding, if any. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.MitreAttack.Tactic primary_tactic = 1; + * @param int $var + * @return $this + */ + public function setPrimaryTactic($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\MitreAttack\Tactic::class); + $this->primary_tactic = $var; + + return $this; + } + + /** + * The MITRE ATT&CK technique most closely represented by this finding, if + * any. primary_techniques is a repeated field because there are multiple + * levels of MITRE ATT&CK techniques. If the technique most closely + * represented by this finding is a sub-technique (e.g. `SCANNING_IP_BLOCKS`), + * both the sub-technique and its parent technique(s) will be listed (e.g. + * `SCANNING_IP_BLOCKS`, `ACTIVE_SCANNING`). + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MitreAttack.Technique primary_techniques = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPrimaryTechniques() + { + return $this->primary_techniques; + } + + /** + * The MITRE ATT&CK technique most closely represented by this finding, if + * any. primary_techniques is a repeated field because there are multiple + * levels of MITRE ATT&CK techniques. If the technique most closely + * represented by this finding is a sub-technique (e.g. `SCANNING_IP_BLOCKS`), + * both the sub-technique and its parent technique(s) will be listed (e.g. + * `SCANNING_IP_BLOCKS`, `ACTIVE_SCANNING`). + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MitreAttack.Technique primary_techniques = 2; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPrimaryTechniques($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\SecurityCenter\V1\MitreAttack\Technique::class); + $this->primary_techniques = $arr; + + return $this; + } + + /** + * Additional MITRE ATT&CK tactics related to this finding, if any. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MitreAttack.Tactic additional_tactics = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAdditionalTactics() + { + return $this->additional_tactics; + } + + /** + * Additional MITRE ATT&CK tactics related to this finding, if any. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MitreAttack.Tactic additional_tactics = 3; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAdditionalTactics($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\SecurityCenter\V1\MitreAttack\Tactic::class); + $this->additional_tactics = $arr; + + return $this; + } + + /** + * Additional MITRE ATT&CK techniques related to this finding, if any, along + * with any of their respective parent techniques. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MitreAttack.Technique additional_techniques = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAdditionalTechniques() + { + return $this->additional_techniques; + } + + /** + * Additional MITRE ATT&CK techniques related to this finding, if any, along + * with any of their respective parent techniques. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MitreAttack.Technique additional_techniques = 4; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAdditionalTechniques($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\SecurityCenter\V1\MitreAttack\Technique::class); + $this->additional_techniques = $arr; + + return $this; + } + + /** + * The MITRE ATT&CK version referenced by the above fields. E.g. "8". + * + * Generated from protobuf field string version = 5; + * @return string + */ + public function getVersion() + { + return $this->version; + } + + /** + * The MITRE ATT&CK version referenced by the above fields. E.g. "8". + * + * Generated from protobuf field string version = 5; + * @param string $var + * @return $this + */ + public function setVersion($var) + { + GPBUtil::checkString($var, True); + $this->version = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack/Tactic.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack/Tactic.php new file mode 100644 index 000000000000..d59277981594 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack/Tactic.php @@ -0,0 +1,149 @@ +google.cloud.securitycenter.v1.MitreAttack.Tactic + */ +class Tactic +{ + /** + * Unspecified value. + * + * Generated from protobuf enum TACTIC_UNSPECIFIED = 0; + */ + const TACTIC_UNSPECIFIED = 0; + /** + * TA0043 + * + * Generated from protobuf enum RECONNAISSANCE = 1; + */ + const RECONNAISSANCE = 1; + /** + * TA0042 + * + * Generated from protobuf enum RESOURCE_DEVELOPMENT = 2; + */ + const RESOURCE_DEVELOPMENT = 2; + /** + * TA0001 + * + * Generated from protobuf enum INITIAL_ACCESS = 5; + */ + const INITIAL_ACCESS = 5; + /** + * TA0002 + * + * Generated from protobuf enum EXECUTION = 3; + */ + const EXECUTION = 3; + /** + * TA0003 + * + * Generated from protobuf enum PERSISTENCE = 6; + */ + const PERSISTENCE = 6; + /** + * TA0004 + * + * Generated from protobuf enum PRIVILEGE_ESCALATION = 8; + */ + const PRIVILEGE_ESCALATION = 8; + /** + * TA0005 + * + * Generated from protobuf enum DEFENSE_EVASION = 7; + */ + const DEFENSE_EVASION = 7; + /** + * TA0006 + * + * Generated from protobuf enum CREDENTIAL_ACCESS = 9; + */ + const CREDENTIAL_ACCESS = 9; + /** + * TA0007 + * + * Generated from protobuf enum DISCOVERY = 10; + */ + const DISCOVERY = 10; + /** + * TA0008 + * + * Generated from protobuf enum LATERAL_MOVEMENT = 11; + */ + const LATERAL_MOVEMENT = 11; + /** + * TA0009 + * + * Generated from protobuf enum COLLECTION = 12; + */ + const COLLECTION = 12; + /** + * TA0011 + * + * Generated from protobuf enum COMMAND_AND_CONTROL = 4; + */ + const COMMAND_AND_CONTROL = 4; + /** + * TA0010 + * + * Generated from protobuf enum EXFILTRATION = 13; + */ + const EXFILTRATION = 13; + /** + * TA0040 + * + * Generated from protobuf enum IMPACT = 14; + */ + const IMPACT = 14; + + private static $valueToName = [ + self::TACTIC_UNSPECIFIED => 'TACTIC_UNSPECIFIED', + self::RECONNAISSANCE => 'RECONNAISSANCE', + self::RESOURCE_DEVELOPMENT => 'RESOURCE_DEVELOPMENT', + self::INITIAL_ACCESS => 'INITIAL_ACCESS', + self::EXECUTION => 'EXECUTION', + self::PERSISTENCE => 'PERSISTENCE', + self::PRIVILEGE_ESCALATION => 'PRIVILEGE_ESCALATION', + self::DEFENSE_EVASION => 'DEFENSE_EVASION', + self::CREDENTIAL_ACCESS => 'CREDENTIAL_ACCESS', + self::DISCOVERY => 'DISCOVERY', + self::LATERAL_MOVEMENT => 'LATERAL_MOVEMENT', + self::COLLECTION => 'COLLECTION', + self::COMMAND_AND_CONTROL => 'COMMAND_AND_CONTROL', + self::EXFILTRATION => 'EXFILTRATION', + self::IMPACT => 'IMPACT', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Tactic::class, \Google\Cloud\SecurityCenter\V1\MitreAttack_Tactic::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack/Technique.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack/Technique.php new file mode 100644 index 000000000000..967ff400fc7e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack/Technique.php @@ -0,0 +1,458 @@ +google.cloud.securitycenter.v1.MitreAttack.Technique + */ +class Technique +{ + /** + * Unspecified value. + * + * Generated from protobuf enum TECHNIQUE_UNSPECIFIED = 0; + */ + const TECHNIQUE_UNSPECIFIED = 0; + /** + * T1036 + * + * Generated from protobuf enum MASQUERADING = 49; + */ + const MASQUERADING = 49; + /** + * T1036.005 + * + * Generated from protobuf enum MATCH_LEGITIMATE_NAME_OR_LOCATION = 50; + */ + const MATCH_LEGITIMATE_NAME_OR_LOCATION = 50; + /** + * T1037 + * + * Generated from protobuf enum BOOT_OR_LOGON_INITIALIZATION_SCRIPTS = 37; + */ + const BOOT_OR_LOGON_INITIALIZATION_SCRIPTS = 37; + /** + * T1037.005 + * + * Generated from protobuf enum STARTUP_ITEMS = 38; + */ + const STARTUP_ITEMS = 38; + /** + * T1046 + * + * Generated from protobuf enum NETWORK_SERVICE_DISCOVERY = 32; + */ + const NETWORK_SERVICE_DISCOVERY = 32; + /** + * T1057 + * + * Generated from protobuf enum PROCESS_DISCOVERY = 56; + */ + const PROCESS_DISCOVERY = 56; + /** + * T1059 + * + * Generated from protobuf enum COMMAND_AND_SCRIPTING_INTERPRETER = 6; + */ + const COMMAND_AND_SCRIPTING_INTERPRETER = 6; + /** + * T1059.004 + * + * Generated from protobuf enum UNIX_SHELL = 7; + */ + const UNIX_SHELL = 7; + /** + * T1069 + * + * Generated from protobuf enum PERMISSION_GROUPS_DISCOVERY = 18; + */ + const PERMISSION_GROUPS_DISCOVERY = 18; + /** + * T1069.003 + * + * Generated from protobuf enum CLOUD_GROUPS = 19; + */ + const CLOUD_GROUPS = 19; + /** + * T1071 + * + * Generated from protobuf enum APPLICATION_LAYER_PROTOCOL = 45; + */ + const APPLICATION_LAYER_PROTOCOL = 45; + /** + * T1071.004 + * + * Generated from protobuf enum DNS = 46; + */ + const DNS = 46; + /** + * T1072 + * + * Generated from protobuf enum SOFTWARE_DEPLOYMENT_TOOLS = 47; + */ + const SOFTWARE_DEPLOYMENT_TOOLS = 47; + /** + * T1078 + * + * Generated from protobuf enum VALID_ACCOUNTS = 14; + */ + const VALID_ACCOUNTS = 14; + /** + * T1078.001 + * + * Generated from protobuf enum DEFAULT_ACCOUNTS = 35; + */ + const DEFAULT_ACCOUNTS = 35; + /** + * T1078.003 + * + * Generated from protobuf enum LOCAL_ACCOUNTS = 15; + */ + const LOCAL_ACCOUNTS = 15; + /** + * T1078.004 + * + * Generated from protobuf enum CLOUD_ACCOUNTS = 16; + */ + const CLOUD_ACCOUNTS = 16; + /** + * T1090 + * + * Generated from protobuf enum PROXY = 9; + */ + const PROXY = 9; + /** + * T1090.002 + * + * Generated from protobuf enum EXTERNAL_PROXY = 10; + */ + const EXTERNAL_PROXY = 10; + /** + * T1090.003 + * + * Generated from protobuf enum MULTI_HOP_PROXY = 11; + */ + const MULTI_HOP_PROXY = 11; + /** + * T1098 + * + * Generated from protobuf enum ACCOUNT_MANIPULATION = 22; + */ + const ACCOUNT_MANIPULATION = 22; + /** + * T1098.001 + * + * Generated from protobuf enum ADDITIONAL_CLOUD_CREDENTIALS = 40; + */ + const ADDITIONAL_CLOUD_CREDENTIALS = 40; + /** + * T1098.004 + * + * Generated from protobuf enum SSH_AUTHORIZED_KEYS = 23; + */ + const SSH_AUTHORIZED_KEYS = 23; + /** + * T1098.006 + * + * Generated from protobuf enum ADDITIONAL_CONTAINER_CLUSTER_ROLES = 58; + */ + const ADDITIONAL_CONTAINER_CLUSTER_ROLES = 58; + /** + * T1105 + * + * Generated from protobuf enum INGRESS_TOOL_TRANSFER = 3; + */ + const INGRESS_TOOL_TRANSFER = 3; + /** + * T1106 + * + * Generated from protobuf enum NATIVE_API = 4; + */ + const NATIVE_API = 4; + /** + * T1110 + * + * Generated from protobuf enum BRUTE_FORCE = 44; + */ + const BRUTE_FORCE = 44; + /** + * T1129 + * + * Generated from protobuf enum SHARED_MODULES = 5; + */ + const SHARED_MODULES = 5; + /** + * T1134 + * + * Generated from protobuf enum ACCESS_TOKEN_MANIPULATION = 33; + */ + const ACCESS_TOKEN_MANIPULATION = 33; + /** + * T1134.001 + * + * Generated from protobuf enum TOKEN_IMPERSONATION_OR_THEFT = 39; + */ + const TOKEN_IMPERSONATION_OR_THEFT = 39; + /** + * T1190 + * + * Generated from protobuf enum EXPLOIT_PUBLIC_FACING_APPLICATION = 27; + */ + const EXPLOIT_PUBLIC_FACING_APPLICATION = 27; + /** + * T1484 + * + * Generated from protobuf enum DOMAIN_POLICY_MODIFICATION = 30; + */ + const DOMAIN_POLICY_MODIFICATION = 30; + /** + * T1485 + * + * Generated from protobuf enum DATA_DESTRUCTION = 29; + */ + const DATA_DESTRUCTION = 29; + /** + * T1489 + * + * Generated from protobuf enum SERVICE_STOP = 52; + */ + const SERVICE_STOP = 52; + /** + * T1490 + * + * Generated from protobuf enum INHIBIT_SYSTEM_RECOVERY = 36; + */ + const INHIBIT_SYSTEM_RECOVERY = 36; + /** + * T1496 + * + * Generated from protobuf enum RESOURCE_HIJACKING = 8; + */ + const RESOURCE_HIJACKING = 8; + /** + * T1498 + * + * Generated from protobuf enum NETWORK_DENIAL_OF_SERVICE = 17; + */ + const NETWORK_DENIAL_OF_SERVICE = 17; + /** + * T1526 + * + * Generated from protobuf enum CLOUD_SERVICE_DISCOVERY = 48; + */ + const CLOUD_SERVICE_DISCOVERY = 48; + /** + * T1528 + * + * Generated from protobuf enum STEAL_APPLICATION_ACCESS_TOKEN = 42; + */ + const STEAL_APPLICATION_ACCESS_TOKEN = 42; + /** + * T1531 + * + * Generated from protobuf enum ACCOUNT_ACCESS_REMOVAL = 51; + */ + const ACCOUNT_ACCESS_REMOVAL = 51; + /** + * T1539 + * + * Generated from protobuf enum STEAL_WEB_SESSION_COOKIE = 25; + */ + const STEAL_WEB_SESSION_COOKIE = 25; + /** + * T1543 + * + * Generated from protobuf enum CREATE_OR_MODIFY_SYSTEM_PROCESS = 24; + */ + const CREATE_OR_MODIFY_SYSTEM_PROCESS = 24; + /** + * T1548 + * + * Generated from protobuf enum ABUSE_ELEVATION_CONTROL_MECHANISM = 34; + */ + const ABUSE_ELEVATION_CONTROL_MECHANISM = 34; + /** + * T1552 + * + * Generated from protobuf enum UNSECURED_CREDENTIALS = 13; + */ + const UNSECURED_CREDENTIALS = 13; + /** + * T1556 + * + * Generated from protobuf enum MODIFY_AUTHENTICATION_PROCESS = 28; + */ + const MODIFY_AUTHENTICATION_PROCESS = 28; + /** + * T1562 + * + * Generated from protobuf enum IMPAIR_DEFENSES = 31; + */ + const IMPAIR_DEFENSES = 31; + /** + * T1562.001 + * + * Generated from protobuf enum DISABLE_OR_MODIFY_TOOLS = 55; + */ + const DISABLE_OR_MODIFY_TOOLS = 55; + /** + * T1567 + * + * Generated from protobuf enum EXFILTRATION_OVER_WEB_SERVICE = 20; + */ + const EXFILTRATION_OVER_WEB_SERVICE = 20; + /** + * T1567.002 + * + * Generated from protobuf enum EXFILTRATION_TO_CLOUD_STORAGE = 21; + */ + const EXFILTRATION_TO_CLOUD_STORAGE = 21; + /** + * T1568 + * + * Generated from protobuf enum DYNAMIC_RESOLUTION = 12; + */ + const DYNAMIC_RESOLUTION = 12; + /** + * T1570 + * + * Generated from protobuf enum LATERAL_TOOL_TRANSFER = 41; + */ + const LATERAL_TOOL_TRANSFER = 41; + /** + * T1578 + * + * Generated from protobuf enum MODIFY_CLOUD_COMPUTE_INFRASTRUCTURE = 26; + */ + const MODIFY_CLOUD_COMPUTE_INFRASTRUCTURE = 26; + /** + * T1578.001 + * + * Generated from protobuf enum CREATE_SNAPSHOT = 54; + */ + const CREATE_SNAPSHOT = 54; + /** + * T1580 + * + * Generated from protobuf enum CLOUD_INFRASTRUCTURE_DISCOVERY = 53; + */ + const CLOUD_INFRASTRUCTURE_DISCOVERY = 53; + /** + * T1588 + * + * Generated from protobuf enum OBTAIN_CAPABILITIES = 43; + */ + const OBTAIN_CAPABILITIES = 43; + /** + * T1595 + * + * Generated from protobuf enum ACTIVE_SCANNING = 1; + */ + const ACTIVE_SCANNING = 1; + /** + * T1595.001 + * + * Generated from protobuf enum SCANNING_IP_BLOCKS = 2; + */ + const SCANNING_IP_BLOCKS = 2; + /** + * T1613 + * + * Generated from protobuf enum CONTAINER_AND_RESOURCE_DISCOVERY = 57; + */ + const CONTAINER_AND_RESOURCE_DISCOVERY = 57; + + private static $valueToName = [ + self::TECHNIQUE_UNSPECIFIED => 'TECHNIQUE_UNSPECIFIED', + self::MASQUERADING => 'MASQUERADING', + self::MATCH_LEGITIMATE_NAME_OR_LOCATION => 'MATCH_LEGITIMATE_NAME_OR_LOCATION', + self::BOOT_OR_LOGON_INITIALIZATION_SCRIPTS => 'BOOT_OR_LOGON_INITIALIZATION_SCRIPTS', + self::STARTUP_ITEMS => 'STARTUP_ITEMS', + self::NETWORK_SERVICE_DISCOVERY => 'NETWORK_SERVICE_DISCOVERY', + self::PROCESS_DISCOVERY => 'PROCESS_DISCOVERY', + self::COMMAND_AND_SCRIPTING_INTERPRETER => 'COMMAND_AND_SCRIPTING_INTERPRETER', + self::UNIX_SHELL => 'UNIX_SHELL', + self::PERMISSION_GROUPS_DISCOVERY => 'PERMISSION_GROUPS_DISCOVERY', + self::CLOUD_GROUPS => 'CLOUD_GROUPS', + self::APPLICATION_LAYER_PROTOCOL => 'APPLICATION_LAYER_PROTOCOL', + self::DNS => 'DNS', + self::SOFTWARE_DEPLOYMENT_TOOLS => 'SOFTWARE_DEPLOYMENT_TOOLS', + self::VALID_ACCOUNTS => 'VALID_ACCOUNTS', + self::DEFAULT_ACCOUNTS => 'DEFAULT_ACCOUNTS', + self::LOCAL_ACCOUNTS => 'LOCAL_ACCOUNTS', + self::CLOUD_ACCOUNTS => 'CLOUD_ACCOUNTS', + self::PROXY => 'PROXY', + self::EXTERNAL_PROXY => 'EXTERNAL_PROXY', + self::MULTI_HOP_PROXY => 'MULTI_HOP_PROXY', + self::ACCOUNT_MANIPULATION => 'ACCOUNT_MANIPULATION', + self::ADDITIONAL_CLOUD_CREDENTIALS => 'ADDITIONAL_CLOUD_CREDENTIALS', + self::SSH_AUTHORIZED_KEYS => 'SSH_AUTHORIZED_KEYS', + self::ADDITIONAL_CONTAINER_CLUSTER_ROLES => 'ADDITIONAL_CONTAINER_CLUSTER_ROLES', + self::INGRESS_TOOL_TRANSFER => 'INGRESS_TOOL_TRANSFER', + self::NATIVE_API => 'NATIVE_API', + self::BRUTE_FORCE => 'BRUTE_FORCE', + self::SHARED_MODULES => 'SHARED_MODULES', + self::ACCESS_TOKEN_MANIPULATION => 'ACCESS_TOKEN_MANIPULATION', + self::TOKEN_IMPERSONATION_OR_THEFT => 'TOKEN_IMPERSONATION_OR_THEFT', + self::EXPLOIT_PUBLIC_FACING_APPLICATION => 'EXPLOIT_PUBLIC_FACING_APPLICATION', + self::DOMAIN_POLICY_MODIFICATION => 'DOMAIN_POLICY_MODIFICATION', + self::DATA_DESTRUCTION => 'DATA_DESTRUCTION', + self::SERVICE_STOP => 'SERVICE_STOP', + self::INHIBIT_SYSTEM_RECOVERY => 'INHIBIT_SYSTEM_RECOVERY', + self::RESOURCE_HIJACKING => 'RESOURCE_HIJACKING', + self::NETWORK_DENIAL_OF_SERVICE => 'NETWORK_DENIAL_OF_SERVICE', + self::CLOUD_SERVICE_DISCOVERY => 'CLOUD_SERVICE_DISCOVERY', + self::STEAL_APPLICATION_ACCESS_TOKEN => 'STEAL_APPLICATION_ACCESS_TOKEN', + self::ACCOUNT_ACCESS_REMOVAL => 'ACCOUNT_ACCESS_REMOVAL', + self::STEAL_WEB_SESSION_COOKIE => 'STEAL_WEB_SESSION_COOKIE', + self::CREATE_OR_MODIFY_SYSTEM_PROCESS => 'CREATE_OR_MODIFY_SYSTEM_PROCESS', + self::ABUSE_ELEVATION_CONTROL_MECHANISM => 'ABUSE_ELEVATION_CONTROL_MECHANISM', + self::UNSECURED_CREDENTIALS => 'UNSECURED_CREDENTIALS', + self::MODIFY_AUTHENTICATION_PROCESS => 'MODIFY_AUTHENTICATION_PROCESS', + self::IMPAIR_DEFENSES => 'IMPAIR_DEFENSES', + self::DISABLE_OR_MODIFY_TOOLS => 'DISABLE_OR_MODIFY_TOOLS', + self::EXFILTRATION_OVER_WEB_SERVICE => 'EXFILTRATION_OVER_WEB_SERVICE', + self::EXFILTRATION_TO_CLOUD_STORAGE => 'EXFILTRATION_TO_CLOUD_STORAGE', + self::DYNAMIC_RESOLUTION => 'DYNAMIC_RESOLUTION', + self::LATERAL_TOOL_TRANSFER => 'LATERAL_TOOL_TRANSFER', + self::MODIFY_CLOUD_COMPUTE_INFRASTRUCTURE => 'MODIFY_CLOUD_COMPUTE_INFRASTRUCTURE', + self::CREATE_SNAPSHOT => 'CREATE_SNAPSHOT', + self::CLOUD_INFRASTRUCTURE_DISCOVERY => 'CLOUD_INFRASTRUCTURE_DISCOVERY', + self::OBTAIN_CAPABILITIES => 'OBTAIN_CAPABILITIES', + self::ACTIVE_SCANNING => 'ACTIVE_SCANNING', + self::SCANNING_IP_BLOCKS => 'SCANNING_IP_BLOCKS', + self::CONTAINER_AND_RESOURCE_DISCOVERY => 'CONTAINER_AND_RESOURCE_DISCOVERY', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Technique::class, \Google\Cloud\SecurityCenter\V1\MitreAttack_Technique::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MuteConfig.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MuteConfig.php new file mode 100644 index 000000000000..98d8cb519340 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MuteConfig.php @@ -0,0 +1,401 @@ +google.cloud.securitycenter.v1.MuteConfig + */ +class MuteConfig extends \Google\Protobuf\Internal\Message +{ + /** + * This field will be ignored if provided on config creation. Format + * "organizations/{organization}/muteConfigs/{mute_config}" + * "folders/{folder}/muteConfigs/{mute_config}" + * "projects/{project}/muteConfigs/{mute_config}" + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The human readable name to be displayed for the mute config. + * + * Generated from protobuf field string display_name = 2 [deprecated = true]; + * @deprecated + */ + protected $display_name = ''; + /** + * A description of the mute config. + * + * Generated from protobuf field string description = 3; + */ + protected $description = ''; + /** + * Required. An expression that defines the filter to apply across + * create/update events of findings. While creating a filter string, be + * mindful of the scope in which the mute configuration is being created. + * E.g., If a filter contains project = X but is created under the project = Y + * scope, it might not match any findings. + * The following field and operator combinations are supported: + * * severity: `=`, `:` + * * category: `=`, `:` + * * resource.name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.folders.resource_folder: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.type: `=`, `:` + * * finding_class: `=`, `:` + * * indicator.ip_addresses: `=`, `:` + * * indicator.domains: `=`, `:` + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $filter = ''; + /** + * Output only. The time at which the mute config was created. + * This field is set by the server and will be ignored if provided on config + * creation. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. The most recent time at which the mute config was updated. + * This field is set by the server and will be ignored if provided on config + * creation or update. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Output only. Email address of the user who last edited the mute config. + * This field is set by the server and will be ignored if provided on config + * creation or update. + * + * Generated from protobuf field string most_recent_editor = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $most_recent_editor = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * This field will be ignored if provided on config creation. Format + * "organizations/{organization}/muteConfigs/{mute_config}" + * "folders/{folder}/muteConfigs/{mute_config}" + * "projects/{project}/muteConfigs/{mute_config}" + * @type string $display_name + * The human readable name to be displayed for the mute config. + * @type string $description + * A description of the mute config. + * @type string $filter + * Required. An expression that defines the filter to apply across + * create/update events of findings. While creating a filter string, be + * mindful of the scope in which the mute configuration is being created. + * E.g., If a filter contains project = X but is created under the project = Y + * scope, it might not match any findings. + * The following field and operator combinations are supported: + * * severity: `=`, `:` + * * category: `=`, `:` + * * resource.name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.folders.resource_folder: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.type: `=`, `:` + * * finding_class: `=`, `:` + * * indicator.ip_addresses: `=`, `:` + * * indicator.domains: `=`, `:` + * @type \Google\Protobuf\Timestamp $create_time + * Output only. The time at which the mute config was created. + * This field is set by the server and will be ignored if provided on config + * creation. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. The most recent time at which the mute config was updated. + * This field is set by the server and will be ignored if provided on config + * creation or update. + * @type string $most_recent_editor + * Output only. Email address of the user who last edited the mute config. + * This field is set by the server and will be ignored if provided on config + * creation or update. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\MuteConfig::initOnce(); + parent::__construct($data); + } + + /** + * This field will be ignored if provided on config creation. Format + * "organizations/{organization}/muteConfigs/{mute_config}" + * "folders/{folder}/muteConfigs/{mute_config}" + * "projects/{project}/muteConfigs/{mute_config}" + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * This field will be ignored if provided on config creation. Format + * "organizations/{organization}/muteConfigs/{mute_config}" + * "folders/{folder}/muteConfigs/{mute_config}" + * "projects/{project}/muteConfigs/{mute_config}" + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The human readable name to be displayed for the mute config. + * + * Generated from protobuf field string display_name = 2 [deprecated = true]; + * @return string + * @deprecated + */ + public function getDisplayName() + { + @trigger_error('display_name is deprecated.', E_USER_DEPRECATED); + return $this->display_name; + } + + /** + * The human readable name to be displayed for the mute config. + * + * Generated from protobuf field string display_name = 2 [deprecated = true]; + * @param string $var + * @return $this + * @deprecated + */ + public function setDisplayName($var) + { + @trigger_error('display_name is deprecated.', E_USER_DEPRECATED); + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * A description of the mute config. + * + * Generated from protobuf field string description = 3; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * A description of the mute config. + * + * Generated from protobuf field string description = 3; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * Required. An expression that defines the filter to apply across + * create/update events of findings. While creating a filter string, be + * mindful of the scope in which the mute configuration is being created. + * E.g., If a filter contains project = X but is created under the project = Y + * scope, it might not match any findings. + * The following field and operator combinations are supported: + * * severity: `=`, `:` + * * category: `=`, `:` + * * resource.name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.folders.resource_folder: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.type: `=`, `:` + * * finding_class: `=`, `:` + * * indicator.ip_addresses: `=`, `:` + * * indicator.domains: `=`, `:` + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Required. An expression that defines the filter to apply across + * create/update events of findings. While creating a filter string, be + * mindful of the scope in which the mute configuration is being created. + * E.g., If a filter contains project = X but is created under the project = Y + * scope, it might not match any findings. + * The following field and operator combinations are supported: + * * severity: `=`, `:` + * * category: `=`, `:` + * * resource.name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.folders.resource_folder: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.type: `=`, `:` + * * finding_class: `=`, `:` + * * indicator.ip_addresses: `=`, `:` + * * indicator.domains: `=`, `:` + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * Output only. The time at which the mute config was created. + * This field is set by the server and will be ignored if provided on config + * creation. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCreateTime() + { + return $this->create_time; + } + + public function hasCreateTime() + { + return isset($this->create_time); + } + + public function clearCreateTime() + { + unset($this->create_time); + } + + /** + * Output only. The time at which the mute config was created. + * This field is set by the server and will be ignored if provided on config + * creation. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->create_time = $var; + + return $this; + } + + /** + * Output only. The most recent time at which the mute config was updated. + * This field is set by the server and will be ignored if provided on config + * creation or update. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getUpdateTime() + { + return $this->update_time; + } + + public function hasUpdateTime() + { + return isset($this->update_time); + } + + public function clearUpdateTime() + { + unset($this->update_time); + } + + /** + * Output only. The most recent time at which the mute config was updated. + * This field is set by the server and will be ignored if provided on config + * creation or update. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->update_time = $var; + + return $this; + } + + /** + * Output only. Email address of the user who last edited the mute config. + * This field is set by the server and will be ignored if provided on config + * creation or update. + * + * Generated from protobuf field string most_recent_editor = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getMostRecentEditor() + { + return $this->most_recent_editor; + } + + /** + * Output only. Email address of the user who last edited the mute config. + * This field is set by the server and will be ignored if provided on config + * creation or update. + * + * Generated from protobuf field string most_recent_editor = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setMostRecentEditor($var) + { + GPBUtil::checkString($var, True); + $this->most_recent_editor = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Notebook.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Notebook.php new file mode 100644 index 000000000000..3aec64dfc6a6 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Notebook.php @@ -0,0 +1,181 @@ +google.cloud.securitycenter.v1.Notebook + */ +class Notebook extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the notebook. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The source notebook service, for example, "Colab Enterprise". + * + * Generated from protobuf field string service = 2; + */ + protected $service = ''; + /** + * The user ID of the latest author to modify the notebook. + * + * Generated from protobuf field string last_author = 3; + */ + protected $last_author = ''; + /** + * The most recent time the notebook was updated. + * + * Generated from protobuf field .google.protobuf.Timestamp notebook_update_time = 4; + */ + protected $notebook_update_time = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the notebook. + * @type string $service + * The source notebook service, for example, "Colab Enterprise". + * @type string $last_author + * The user ID of the latest author to modify the notebook. + * @type \Google\Protobuf\Timestamp $notebook_update_time + * The most recent time the notebook was updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Notebook::initOnce(); + parent::__construct($data); + } + + /** + * The name of the notebook. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the notebook. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The source notebook service, for example, "Colab Enterprise". + * + * Generated from protobuf field string service = 2; + * @return string + */ + public function getService() + { + return $this->service; + } + + /** + * The source notebook service, for example, "Colab Enterprise". + * + * Generated from protobuf field string service = 2; + * @param string $var + * @return $this + */ + public function setService($var) + { + GPBUtil::checkString($var, True); + $this->service = $var; + + return $this; + } + + /** + * The user ID of the latest author to modify the notebook. + * + * Generated from protobuf field string last_author = 3; + * @return string + */ + public function getLastAuthor() + { + return $this->last_author; + } + + /** + * The user ID of the latest author to modify the notebook. + * + * Generated from protobuf field string last_author = 3; + * @param string $var + * @return $this + */ + public function setLastAuthor($var) + { + GPBUtil::checkString($var, True); + $this->last_author = $var; + + return $this; + } + + /** + * The most recent time the notebook was updated. + * + * Generated from protobuf field .google.protobuf.Timestamp notebook_update_time = 4; + * @return \Google\Protobuf\Timestamp|null + */ + public function getNotebookUpdateTime() + { + return $this->notebook_update_time; + } + + public function hasNotebookUpdateTime() + { + return isset($this->notebook_update_time); + } + + public function clearNotebookUpdateTime() + { + unset($this->notebook_update_time); + } + + /** + * The most recent time the notebook was updated. + * + * Generated from protobuf field .google.protobuf.Timestamp notebook_update_time = 4; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setNotebookUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->notebook_update_time = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationConfig.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationConfig.php new file mode 100644 index 000000000000..5638bbb45c82 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationConfig.php @@ -0,0 +1,241 @@ +google.cloud.securitycenter.v1.NotificationConfig + */ +class NotificationConfig extends \Google\Protobuf\Internal\Message +{ + /** + * The relative resource name of this notification config. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/notificationConfigs/notify_public_bucket", + * "folders/{folder_id}/notificationConfigs/notify_public_bucket", + * or "projects/{project_id}/notificationConfigs/notify_public_bucket". + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The description of the notification config (max of 1024 characters). + * + * Generated from protobuf field string description = 2; + */ + protected $description = ''; + /** + * The Pub/Sub topic to send notifications to. Its format is + * "projects/[project_id]/topics/[topic]". + * + * Generated from protobuf field string pubsub_topic = 3 [(.google.api.resource_reference) = { + */ + protected $pubsub_topic = ''; + /** + * Output only. The service account that needs "pubsub.topics.publish" + * permission to publish to the Pub/Sub topic. + * + * Generated from protobuf field string service_account = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $service_account = ''; + protected $notify_config; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The relative resource name of this notification config. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/notificationConfigs/notify_public_bucket", + * "folders/{folder_id}/notificationConfigs/notify_public_bucket", + * or "projects/{project_id}/notificationConfigs/notify_public_bucket". + * @type string $description + * The description of the notification config (max of 1024 characters). + * @type string $pubsub_topic + * The Pub/Sub topic to send notifications to. Its format is + * "projects/[project_id]/topics/[topic]". + * @type string $service_account + * Output only. The service account that needs "pubsub.topics.publish" + * permission to publish to the Pub/Sub topic. + * @type \Google\Cloud\SecurityCenter\V1\NotificationConfig\StreamingConfig $streaming_config + * The config for triggering streaming-based notifications. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\NotificationConfig::initOnce(); + parent::__construct($data); + } + + /** + * The relative resource name of this notification config. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/notificationConfigs/notify_public_bucket", + * "folders/{folder_id}/notificationConfigs/notify_public_bucket", + * or "projects/{project_id}/notificationConfigs/notify_public_bucket". + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The relative resource name of this notification config. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/notificationConfigs/notify_public_bucket", + * "folders/{folder_id}/notificationConfigs/notify_public_bucket", + * or "projects/{project_id}/notificationConfigs/notify_public_bucket". + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The description of the notification config (max of 1024 characters). + * + * Generated from protobuf field string description = 2; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * The description of the notification config (max of 1024 characters). + * + * Generated from protobuf field string description = 2; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * The Pub/Sub topic to send notifications to. Its format is + * "projects/[project_id]/topics/[topic]". + * + * Generated from protobuf field string pubsub_topic = 3 [(.google.api.resource_reference) = { + * @return string + */ + public function getPubsubTopic() + { + return $this->pubsub_topic; + } + + /** + * The Pub/Sub topic to send notifications to. Its format is + * "projects/[project_id]/topics/[topic]". + * + * Generated from protobuf field string pubsub_topic = 3 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setPubsubTopic($var) + { + GPBUtil::checkString($var, True); + $this->pubsub_topic = $var; + + return $this; + } + + /** + * Output only. The service account that needs "pubsub.topics.publish" + * permission to publish to the Pub/Sub topic. + * + * Generated from protobuf field string service_account = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getServiceAccount() + { + return $this->service_account; + } + + /** + * Output only. The service account that needs "pubsub.topics.publish" + * permission to publish to the Pub/Sub topic. + * + * Generated from protobuf field string service_account = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setServiceAccount($var) + { + GPBUtil::checkString($var, True); + $this->service_account = $var; + + return $this; + } + + /** + * The config for triggering streaming-based notifications. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.NotificationConfig.StreamingConfig streaming_config = 5; + * @return \Google\Cloud\SecurityCenter\V1\NotificationConfig\StreamingConfig|null + */ + public function getStreamingConfig() + { + return $this->readOneof(5); + } + + public function hasStreamingConfig() + { + return $this->hasOneof(5); + } + + /** + * The config for triggering streaming-based notifications. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.NotificationConfig.StreamingConfig streaming_config = 5; + * @param \Google\Cloud\SecurityCenter\V1\NotificationConfig\StreamingConfig $var + * @return $this + */ + public function setStreamingConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\NotificationConfig\StreamingConfig::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * @return string + */ + public function getNotifyConfig() + { + return $this->whichOneof("notify_config"); + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationConfig/StreamingConfig.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationConfig/StreamingConfig.php new file mode 100644 index 000000000000..7f332dbc44a0 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationConfig/StreamingConfig.php @@ -0,0 +1,131 @@ +google.cloud.securitycenter.v1.NotificationConfig.StreamingConfig + */ +class StreamingConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Expression that defines the filter to apply across create/update events + * of assets or findings as specified by the event type. The expression is a + * list of zero or more restrictions combined via logical operators `AND` + * and `OR`. Parentheses are supported, and `OR` has higher precedence than + * `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 1; + */ + protected $filter = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $filter + * Expression that defines the filter to apply across create/update events + * of assets or findings as specified by the event type. The expression is a + * list of zero or more restrictions combined via logical operators `AND` + * and `OR`. Parentheses are supported, and `OR` has higher precedence than + * `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\NotificationConfig::initOnce(); + parent::__construct($data); + } + + /** + * Expression that defines the filter to apply across create/update events + * of assets or findings as specified by the event type. The expression is a + * list of zero or more restrictions combined via logical operators `AND` + * and `OR`. Parentheses are supported, and `OR` has higher precedence than + * `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 1; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Expression that defines the filter to apply across create/update events + * of assets or findings as specified by the event type. The expression is a + * list of zero or more restrictions combined via logical operators `AND` + * and `OR`. Parentheses are supported, and `OR` has higher precedence than + * `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 1; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(StreamingConfig::class, \Google\Cloud\SecurityCenter\V1\NotificationConfig_StreamingConfig::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationMessage.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationMessage.php new file mode 100644 index 000000000000..cbec635bd336 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationMessage.php @@ -0,0 +1,156 @@ +google.cloud.securitycenter.v1.NotificationMessage + */ +class NotificationMessage extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the notification config that generated current notification. + * + * Generated from protobuf field string notification_config_name = 1; + */ + protected $notification_config_name = ''; + /** + * The Cloud resource tied to this notification's Finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Resource resource = 3; + */ + protected $resource = null; + protected $event; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $notification_config_name + * Name of the notification config that generated current notification. + * @type \Google\Cloud\SecurityCenter\V1\Finding $finding + * If it's a Finding based notification config, this field will be + * populated. + * @type \Google\Cloud\SecurityCenter\V1\Resource $resource + * The Cloud resource tied to this notification's Finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\NotificationMessage::initOnce(); + parent::__construct($data); + } + + /** + * Name of the notification config that generated current notification. + * + * Generated from protobuf field string notification_config_name = 1; + * @return string + */ + public function getNotificationConfigName() + { + return $this->notification_config_name; + } + + /** + * Name of the notification config that generated current notification. + * + * Generated from protobuf field string notification_config_name = 1; + * @param string $var + * @return $this + */ + public function setNotificationConfigName($var) + { + GPBUtil::checkString($var, True); + $this->notification_config_name = $var; + + return $this; + } + + /** + * If it's a Finding based notification config, this field will be + * populated. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 2; + * @return \Google\Cloud\SecurityCenter\V1\Finding|null + */ + public function getFinding() + { + return $this->readOneof(2); + } + + public function hasFinding() + { + return $this->hasOneof(2); + } + + /** + * If it's a Finding based notification config, this field will be + * populated. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 2; + * @param \Google\Cloud\SecurityCenter\V1\Finding $var + * @return $this + */ + public function setFinding($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Finding::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * The Cloud resource tied to this notification's Finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Resource resource = 3; + * @return \Google\Cloud\SecurityCenter\V1\Resource|null + */ + public function getResource() + { + return $this->resource; + } + + public function hasResource() + { + return isset($this->resource); + } + + public function clearResource() + { + unset($this->resource); + } + + /** + * The Cloud resource tied to this notification's Finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Resource resource = 3; + * @param \Google\Cloud\SecurityCenter\V1\Resource $var + * @return $this + */ + public function setResource($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Resource::class); + $this->resource = $var; + + return $this; + } + + /** + * @return string + */ + public function getEvent() + { + return $this->whichOneof("event"); + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrgPolicy.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrgPolicy.php new file mode 100644 index 000000000000..0da4e2cafc7b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrgPolicy.php @@ -0,0 +1,75 @@ +google.cloud.securitycenter.v1.OrgPolicy + */ +class OrgPolicy extends \Google\Protobuf\Internal\Message +{ + /** + * The resource name of the org policy. + * Example: + * "organizations/{organization_id}/policies/{constraint_name}" + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The resource name of the org policy. + * Example: + * "organizations/{organization_id}/policies/{constraint_name}" + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\OrgPolicy::initOnce(); + parent::__construct($data); + } + + /** + * The resource name of the org policy. + * Example: + * "organizations/{organization_id}/policies/{constraint_name}" + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The resource name of the org policy. + * Example: + * "organizations/{organization_id}/policies/{constraint_name}" + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings.php new file mode 100644 index 000000000000..ae410fea0a5a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings.php @@ -0,0 +1,170 @@ +google.cloud.securitycenter.v1.OrganizationSettings + */ +class OrganizationSettings extends \Google\Protobuf\Internal\Message +{ + /** + * The relative resource name of the settings. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/organizationSettings". + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * A flag that indicates if Asset Discovery should be enabled. If the flag is + * set to `true`, then discovery of assets will occur. If it is set to + * `false`, all historical assets will remain, but discovery of future assets + * will not occur. + * + * Generated from protobuf field bool enable_asset_discovery = 2; + */ + protected $enable_asset_discovery = false; + /** + * The configuration used for Asset Discovery runs. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.OrganizationSettings.AssetDiscoveryConfig asset_discovery_config = 3; + */ + protected $asset_discovery_config = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The relative resource name of the settings. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/organizationSettings". + * @type bool $enable_asset_discovery + * A flag that indicates if Asset Discovery should be enabled. If the flag is + * set to `true`, then discovery of assets will occur. If it is set to + * `false`, all historical assets will remain, but discovery of future assets + * will not occur. + * @type \Google\Cloud\SecurityCenter\V1\OrganizationSettings\AssetDiscoveryConfig $asset_discovery_config + * The configuration used for Asset Discovery runs. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\OrganizationSettings::initOnce(); + parent::__construct($data); + } + + /** + * The relative resource name of the settings. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/organizationSettings". + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The relative resource name of the settings. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/organizationSettings". + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * A flag that indicates if Asset Discovery should be enabled. If the flag is + * set to `true`, then discovery of assets will occur. If it is set to + * `false`, all historical assets will remain, but discovery of future assets + * will not occur. + * + * Generated from protobuf field bool enable_asset_discovery = 2; + * @return bool + */ + public function getEnableAssetDiscovery() + { + return $this->enable_asset_discovery; + } + + /** + * A flag that indicates if Asset Discovery should be enabled. If the flag is + * set to `true`, then discovery of assets will occur. If it is set to + * `false`, all historical assets will remain, but discovery of future assets + * will not occur. + * + * Generated from protobuf field bool enable_asset_discovery = 2; + * @param bool $var + * @return $this + */ + public function setEnableAssetDiscovery($var) + { + GPBUtil::checkBool($var); + $this->enable_asset_discovery = $var; + + return $this; + } + + /** + * The configuration used for Asset Discovery runs. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.OrganizationSettings.AssetDiscoveryConfig asset_discovery_config = 3; + * @return \Google\Cloud\SecurityCenter\V1\OrganizationSettings\AssetDiscoveryConfig|null + */ + public function getAssetDiscoveryConfig() + { + return $this->asset_discovery_config; + } + + public function hasAssetDiscoveryConfig() + { + return isset($this->asset_discovery_config); + } + + public function clearAssetDiscoveryConfig() + { + unset($this->asset_discovery_config); + } + + /** + * The configuration used for Asset Discovery runs. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.OrganizationSettings.AssetDiscoveryConfig asset_discovery_config = 3; + * @param \Google\Cloud\SecurityCenter\V1\OrganizationSettings\AssetDiscoveryConfig $var + * @return $this + */ + public function setAssetDiscoveryConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\OrganizationSettings\AssetDiscoveryConfig::class); + $this->asset_discovery_config = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings/AssetDiscoveryConfig.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings/AssetDiscoveryConfig.php new file mode 100644 index 000000000000..bfa7935a6f48 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings/AssetDiscoveryConfig.php @@ -0,0 +1,142 @@ +google.cloud.securitycenter.v1.OrganizationSettings.AssetDiscoveryConfig + */ +class AssetDiscoveryConfig extends \Google\Protobuf\Internal\Message +{ + /** + * The project ids to use for filtering asset discovery. + * + * Generated from protobuf field repeated string project_ids = 1; + */ + private $project_ids; + /** + * The mode to use for filtering asset discovery. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.OrganizationSettings.AssetDiscoveryConfig.InclusionMode inclusion_mode = 2; + */ + protected $inclusion_mode = 0; + /** + * The folder ids to use for filtering asset discovery. + * It consists of only digits, e.g., 756619654966. + * + * Generated from protobuf field repeated string folder_ids = 3; + */ + private $folder_ids; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\RepeatedField $project_ids + * The project ids to use for filtering asset discovery. + * @type int $inclusion_mode + * The mode to use for filtering asset discovery. + * @type array|\Google\Protobuf\Internal\RepeatedField $folder_ids + * The folder ids to use for filtering asset discovery. + * It consists of only digits, e.g., 756619654966. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\OrganizationSettings::initOnce(); + parent::__construct($data); + } + + /** + * The project ids to use for filtering asset discovery. + * + * Generated from protobuf field repeated string project_ids = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getProjectIds() + { + return $this->project_ids; + } + + /** + * The project ids to use for filtering asset discovery. + * + * Generated from protobuf field repeated string project_ids = 1; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setProjectIds($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->project_ids = $arr; + + return $this; + } + + /** + * The mode to use for filtering asset discovery. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.OrganizationSettings.AssetDiscoveryConfig.InclusionMode inclusion_mode = 2; + * @return int + */ + public function getInclusionMode() + { + return $this->inclusion_mode; + } + + /** + * The mode to use for filtering asset discovery. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.OrganizationSettings.AssetDiscoveryConfig.InclusionMode inclusion_mode = 2; + * @param int $var + * @return $this + */ + public function setInclusionMode($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\OrganizationSettings\AssetDiscoveryConfig\InclusionMode::class); + $this->inclusion_mode = $var; + + return $this; + } + + /** + * The folder ids to use for filtering asset discovery. + * It consists of only digits, e.g., 756619654966. + * + * Generated from protobuf field repeated string folder_ids = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFolderIds() + { + return $this->folder_ids; + } + + /** + * The folder ids to use for filtering asset discovery. + * It consists of only digits, e.g., 756619654966. + * + * Generated from protobuf field repeated string folder_ids = 3; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFolderIds($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->folder_ids = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AssetDiscoveryConfig::class, \Google\Cloud\SecurityCenter\V1\OrganizationSettings_AssetDiscoveryConfig::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings/AssetDiscoveryConfig/InclusionMode.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings/AssetDiscoveryConfig/InclusionMode.php new file mode 100644 index 000000000000..33dd51cd818b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings/AssetDiscoveryConfig/InclusionMode.php @@ -0,0 +1,74 @@ +google.cloud.securitycenter.v1.OrganizationSettings.AssetDiscoveryConfig.InclusionMode + */ +class InclusionMode +{ + /** + * Unspecified. Setting the mode with this value will disable + * inclusion/exclusion filtering for Asset Discovery. + * + * Generated from protobuf enum INCLUSION_MODE_UNSPECIFIED = 0; + */ + const INCLUSION_MODE_UNSPECIFIED = 0; + /** + * Asset Discovery will capture only the resources within the projects + * specified. All other resources will be ignored. + * + * Generated from protobuf enum INCLUDE_ONLY = 1; + */ + const INCLUDE_ONLY = 1; + /** + * Asset Discovery will ignore all resources under the projects specified. + * All other resources will be retrieved. + * + * Generated from protobuf enum EXCLUDE = 2; + */ + const EXCLUDE = 2; + + private static $valueToName = [ + self::INCLUSION_MODE_UNSPECIFIED => 'INCLUSION_MODE_UNSPECIFIED', + self::INCLUDE_ONLY => 'INCLUDE_ONLY', + self::EXCLUDE => 'EXCLUDE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(InclusionMode::class, \Google\Cloud\SecurityCenter\V1\OrganizationSettings_AssetDiscoveryConfig_InclusionMode::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Package.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Package.php new file mode 100644 index 000000000000..99df9caedfb8 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Package.php @@ -0,0 +1,169 @@ +google.cloud.securitycenter.v1.Package + */ +class Package extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the package where the vulnerability was detected. + * + * Generated from protobuf field string package_name = 1; + */ + protected $package_name = ''; + /** + * The CPE URI where the vulnerability was detected. + * + * Generated from protobuf field string cpe_uri = 2; + */ + protected $cpe_uri = ''; + /** + * Type of package, for example, os, maven, or go. + * + * Generated from protobuf field string package_type = 3; + */ + protected $package_type = ''; + /** + * The version of the package. + * + * Generated from protobuf field string package_version = 4; + */ + protected $package_version = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $package_name + * The name of the package where the vulnerability was detected. + * @type string $cpe_uri + * The CPE URI where the vulnerability was detected. + * @type string $package_type + * Type of package, for example, os, maven, or go. + * @type string $package_version + * The version of the package. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Vulnerability::initOnce(); + parent::__construct($data); + } + + /** + * The name of the package where the vulnerability was detected. + * + * Generated from protobuf field string package_name = 1; + * @return string + */ + public function getPackageName() + { + return $this->package_name; + } + + /** + * The name of the package where the vulnerability was detected. + * + * Generated from protobuf field string package_name = 1; + * @param string $var + * @return $this + */ + public function setPackageName($var) + { + GPBUtil::checkString($var, True); + $this->package_name = $var; + + return $this; + } + + /** + * The CPE URI where the vulnerability was detected. + * + * Generated from protobuf field string cpe_uri = 2; + * @return string + */ + public function getCpeUri() + { + return $this->cpe_uri; + } + + /** + * The CPE URI where the vulnerability was detected. + * + * Generated from protobuf field string cpe_uri = 2; + * @param string $var + * @return $this + */ + public function setCpeUri($var) + { + GPBUtil::checkString($var, True); + $this->cpe_uri = $var; + + return $this; + } + + /** + * Type of package, for example, os, maven, or go. + * + * Generated from protobuf field string package_type = 3; + * @return string + */ + public function getPackageType() + { + return $this->package_type; + } + + /** + * Type of package, for example, os, maven, or go. + * + * Generated from protobuf field string package_type = 3; + * @param string $var + * @return $this + */ + public function setPackageType($var) + { + GPBUtil::checkString($var, True); + $this->package_type = $var; + + return $this; + } + + /** + * The version of the package. + * + * Generated from protobuf field string package_version = 4; + * @return string + */ + public function getPackageVersion() + { + return $this->package_version; + } + + /** + * The version of the package. + * + * Generated from protobuf field string package_version = 4; + * @param string $var + * @return $this + */ + public function setPackageVersion($var) + { + GPBUtil::checkString($var, True); + $this->package_version = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Process.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Process.php new file mode 100644 index 000000000000..56de3cc68d1b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Process.php @@ -0,0 +1,409 @@ +google.cloud.securitycenter.v1.Process + */ +class Process extends \Google\Protobuf\Internal\Message +{ + /** + * The process name, as displayed in utilities like `top` and `ps`. This name + * can be accessed through `/proc/[pid]/comm` and changed with + * `prctl(PR_SET_NAME)`. + * + * Generated from protobuf field string name = 12; + */ + protected $name = ''; + /** + * File information for the process executable. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.File binary = 3; + */ + protected $binary = null; + /** + * File information for libraries loaded by the process. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.File libraries = 4; + */ + private $libraries; + /** + * When the process represents the invocation of a script, `binary` provides + * information about the interpreter, while `script` provides information + * about the script file provided to the interpreter. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.File script = 5; + */ + protected $script = null; + /** + * Process arguments as JSON encoded strings. + * + * Generated from protobuf field repeated string args = 6; + */ + private $args; + /** + * True if `args` is incomplete. + * + * Generated from protobuf field bool arguments_truncated = 7; + */ + protected $arguments_truncated = false; + /** + * Process environment variables. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.EnvironmentVariable env_variables = 8; + */ + private $env_variables; + /** + * True if `env_variables` is incomplete. + * + * Generated from protobuf field bool env_variables_truncated = 9; + */ + protected $env_variables_truncated = false; + /** + * The process ID. + * + * Generated from protobuf field int64 pid = 10; + */ + protected $pid = 0; + /** + * The parent process ID. + * + * Generated from protobuf field int64 parent_pid = 11; + */ + protected $parent_pid = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The process name, as displayed in utilities like `top` and `ps`. This name + * can be accessed through `/proc/[pid]/comm` and changed with + * `prctl(PR_SET_NAME)`. + * @type \Google\Cloud\SecurityCenter\V1\File $binary + * File information for the process executable. + * @type array<\Google\Cloud\SecurityCenter\V1\File>|\Google\Protobuf\Internal\RepeatedField $libraries + * File information for libraries loaded by the process. + * @type \Google\Cloud\SecurityCenter\V1\File $script + * When the process represents the invocation of a script, `binary` provides + * information about the interpreter, while `script` provides information + * about the script file provided to the interpreter. + * @type array|\Google\Protobuf\Internal\RepeatedField $args + * Process arguments as JSON encoded strings. + * @type bool $arguments_truncated + * True if `args` is incomplete. + * @type array<\Google\Cloud\SecurityCenter\V1\EnvironmentVariable>|\Google\Protobuf\Internal\RepeatedField $env_variables + * Process environment variables. + * @type bool $env_variables_truncated + * True if `env_variables` is incomplete. + * @type int|string $pid + * The process ID. + * @type int|string $parent_pid + * The parent process ID. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Process::initOnce(); + parent::__construct($data); + } + + /** + * The process name, as displayed in utilities like `top` and `ps`. This name + * can be accessed through `/proc/[pid]/comm` and changed with + * `prctl(PR_SET_NAME)`. + * + * Generated from protobuf field string name = 12; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The process name, as displayed in utilities like `top` and `ps`. This name + * can be accessed through `/proc/[pid]/comm` and changed with + * `prctl(PR_SET_NAME)`. + * + * Generated from protobuf field string name = 12; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * File information for the process executable. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.File binary = 3; + * @return \Google\Cloud\SecurityCenter\V1\File|null + */ + public function getBinary() + { + return $this->binary; + } + + public function hasBinary() + { + return isset($this->binary); + } + + public function clearBinary() + { + unset($this->binary); + } + + /** + * File information for the process executable. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.File binary = 3; + * @param \Google\Cloud\SecurityCenter\V1\File $var + * @return $this + */ + public function setBinary($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\File::class); + $this->binary = $var; + + return $this; + } + + /** + * File information for libraries loaded by the process. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.File libraries = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getLibraries() + { + return $this->libraries; + } + + /** + * File information for libraries loaded by the process. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.File libraries = 4; + * @param array<\Google\Cloud\SecurityCenter\V1\File>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setLibraries($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\File::class); + $this->libraries = $arr; + + return $this; + } + + /** + * When the process represents the invocation of a script, `binary` provides + * information about the interpreter, while `script` provides information + * about the script file provided to the interpreter. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.File script = 5; + * @return \Google\Cloud\SecurityCenter\V1\File|null + */ + public function getScript() + { + return $this->script; + } + + public function hasScript() + { + return isset($this->script); + } + + public function clearScript() + { + unset($this->script); + } + + /** + * When the process represents the invocation of a script, `binary` provides + * information about the interpreter, while `script` provides information + * about the script file provided to the interpreter. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.File script = 5; + * @param \Google\Cloud\SecurityCenter\V1\File $var + * @return $this + */ + public function setScript($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\File::class); + $this->script = $var; + + return $this; + } + + /** + * Process arguments as JSON encoded strings. + * + * Generated from protobuf field repeated string args = 6; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getArgs() + { + return $this->args; + } + + /** + * Process arguments as JSON encoded strings. + * + * Generated from protobuf field repeated string args = 6; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setArgs($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->args = $arr; + + return $this; + } + + /** + * True if `args` is incomplete. + * + * Generated from protobuf field bool arguments_truncated = 7; + * @return bool + */ + public function getArgumentsTruncated() + { + return $this->arguments_truncated; + } + + /** + * True if `args` is incomplete. + * + * Generated from protobuf field bool arguments_truncated = 7; + * @param bool $var + * @return $this + */ + public function setArgumentsTruncated($var) + { + GPBUtil::checkBool($var); + $this->arguments_truncated = $var; + + return $this; + } + + /** + * Process environment variables. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.EnvironmentVariable env_variables = 8; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getEnvVariables() + { + return $this->env_variables; + } + + /** + * Process environment variables. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.EnvironmentVariable env_variables = 8; + * @param array<\Google\Cloud\SecurityCenter\V1\EnvironmentVariable>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setEnvVariables($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\EnvironmentVariable::class); + $this->env_variables = $arr; + + return $this; + } + + /** + * True if `env_variables` is incomplete. + * + * Generated from protobuf field bool env_variables_truncated = 9; + * @return bool + */ + public function getEnvVariablesTruncated() + { + return $this->env_variables_truncated; + } + + /** + * True if `env_variables` is incomplete. + * + * Generated from protobuf field bool env_variables_truncated = 9; + * @param bool $var + * @return $this + */ + public function setEnvVariablesTruncated($var) + { + GPBUtil::checkBool($var); + $this->env_variables_truncated = $var; + + return $this; + } + + /** + * The process ID. + * + * Generated from protobuf field int64 pid = 10; + * @return int|string + */ + public function getPid() + { + return $this->pid; + } + + /** + * The process ID. + * + * Generated from protobuf field int64 pid = 10; + * @param int|string $var + * @return $this + */ + public function setPid($var) + { + GPBUtil::checkInt64($var); + $this->pid = $var; + + return $this; + } + + /** + * The parent process ID. + * + * Generated from protobuf field int64 parent_pid = 11; + * @return int|string + */ + public function getParentPid() + { + return $this->parent_pid; + } + + /** + * The parent process ID. + * + * Generated from protobuf field int64 parent_pid = 11; + * @param int|string $var + * @return $this + */ + public function setParentPid($var) + { + GPBUtil::checkInt64($var); + $this->parent_pid = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Reference.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Reference.php new file mode 100644 index 000000000000..0dead12073c9 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Reference.php @@ -0,0 +1,105 @@ +google.cloud.securitycenter.v1.Reference + */ +class Reference extends \Google\Protobuf\Internal\Message +{ + /** + * Source of the reference e.g. NVD + * + * Generated from protobuf field string source = 1; + */ + protected $source = ''; + /** + * Uri for the mentioned source e.g. + * https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527. + * + * Generated from protobuf field string uri = 2; + */ + protected $uri = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $source + * Source of the reference e.g. NVD + * @type string $uri + * Uri for the mentioned source e.g. + * https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Vulnerability::initOnce(); + parent::__construct($data); + } + + /** + * Source of the reference e.g. NVD + * + * Generated from protobuf field string source = 1; + * @return string + */ + public function getSource() + { + return $this->source; + } + + /** + * Source of the reference e.g. NVD + * + * Generated from protobuf field string source = 1; + * @param string $var + * @return $this + */ + public function setSource($var) + { + GPBUtil::checkString($var, True); + $this->source = $var; + + return $this; + } + + /** + * Uri for the mentioned source e.g. + * https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527. + * + * Generated from protobuf field string uri = 2; + * @return string + */ + public function getUri() + { + return $this->uri; + } + + /** + * Uri for the mentioned source e.g. + * https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527. + * + * Generated from protobuf field string uri = 2; + * @param string $var + * @return $this + */ + public function setUri($var) + { + GPBUtil::checkString($var, True); + $this->uri = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Requests.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Requests.php new file mode 100644 index 000000000000..f8903e49e17f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Requests.php @@ -0,0 +1,177 @@ +google.cloud.securitycenter.v1.Requests + */ +class Requests extends \Google\Protobuf\Internal\Message +{ + /** + * For 'Increasing deny ratio', the ratio is the denied traffic divided by the + * allowed traffic. For 'Allowed traffic spike', the ratio is the allowed + * traffic in the short term divided by allowed traffic in the long term. + * + * Generated from protobuf field double ratio = 1; + */ + protected $ratio = 0.0; + /** + * Allowed RPS (requests per second) in the short term. + * + * Generated from protobuf field int32 short_term_allowed = 2; + */ + protected $short_term_allowed = 0; + /** + * Allowed RPS (requests per second) over the long term. + * + * Generated from protobuf field int32 long_term_allowed = 3; + */ + protected $long_term_allowed = 0; + /** + * Denied RPS (requests per second) over the long term. + * + * Generated from protobuf field int32 long_term_denied = 4; + */ + protected $long_term_denied = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type float $ratio + * For 'Increasing deny ratio', the ratio is the denied traffic divided by the + * allowed traffic. For 'Allowed traffic spike', the ratio is the allowed + * traffic in the short term divided by allowed traffic in the long term. + * @type int $short_term_allowed + * Allowed RPS (requests per second) in the short term. + * @type int $long_term_allowed + * Allowed RPS (requests per second) over the long term. + * @type int $long_term_denied + * Denied RPS (requests per second) over the long term. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\CloudArmor::initOnce(); + parent::__construct($data); + } + + /** + * For 'Increasing deny ratio', the ratio is the denied traffic divided by the + * allowed traffic. For 'Allowed traffic spike', the ratio is the allowed + * traffic in the short term divided by allowed traffic in the long term. + * + * Generated from protobuf field double ratio = 1; + * @return float + */ + public function getRatio() + { + return $this->ratio; + } + + /** + * For 'Increasing deny ratio', the ratio is the denied traffic divided by the + * allowed traffic. For 'Allowed traffic spike', the ratio is the allowed + * traffic in the short term divided by allowed traffic in the long term. + * + * Generated from protobuf field double ratio = 1; + * @param float $var + * @return $this + */ + public function setRatio($var) + { + GPBUtil::checkDouble($var); + $this->ratio = $var; + + return $this; + } + + /** + * Allowed RPS (requests per second) in the short term. + * + * Generated from protobuf field int32 short_term_allowed = 2; + * @return int + */ + public function getShortTermAllowed() + { + return $this->short_term_allowed; + } + + /** + * Allowed RPS (requests per second) in the short term. + * + * Generated from protobuf field int32 short_term_allowed = 2; + * @param int $var + * @return $this + */ + public function setShortTermAllowed($var) + { + GPBUtil::checkInt32($var); + $this->short_term_allowed = $var; + + return $this; + } + + /** + * Allowed RPS (requests per second) over the long term. + * + * Generated from protobuf field int32 long_term_allowed = 3; + * @return int + */ + public function getLongTermAllowed() + { + return $this->long_term_allowed; + } + + /** + * Allowed RPS (requests per second) over the long term. + * + * Generated from protobuf field int32 long_term_allowed = 3; + * @param int $var + * @return $this + */ + public function setLongTermAllowed($var) + { + GPBUtil::checkInt32($var); + $this->long_term_allowed = $var; + + return $this; + } + + /** + * Denied RPS (requests per second) over the long term. + * + * Generated from protobuf field int32 long_term_denied = 4; + * @return int + */ + public function getLongTermDenied() + { + return $this->long_term_denied; + } + + /** + * Denied RPS (requests per second) over the long term. + * + * Generated from protobuf field int32 long_term_denied = 4; + * @param int $var + * @return $this + */ + public function setLongTermDenied($var) + { + GPBUtil::checkInt32($var); + $this->long_term_denied = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Resource.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Resource.php new file mode 100644 index 000000000000..44f8ef85d5ed --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Resource.php @@ -0,0 +1,317 @@ +google.cloud.securitycenter.v1.Resource + */ +class Resource extends \Google\Protobuf\Internal\Message +{ + /** + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The human readable name of the resource. + * + * Generated from protobuf field string display_name = 8; + */ + protected $display_name = ''; + /** + * The full resource type of the resource. + * + * Generated from protobuf field string type = 6; + */ + protected $type = ''; + /** + * The full resource name of project that the resource belongs to. + * + * Generated from protobuf field string project = 2; + */ + protected $project = ''; + /** + * The project ID that the resource belongs to. + * + * Generated from protobuf field string project_display_name = 3; + */ + protected $project_display_name = ''; + /** + * The full resource name of resource's parent. + * + * Generated from protobuf field string parent = 4; + */ + protected $parent = ''; + /** + * The human readable name of resource's parent. + * + * Generated from protobuf field string parent_display_name = 5; + */ + protected $parent_display_name = ''; + /** + * Output only. Contains a Folder message for each folder in the assets + * ancestry. The first folder is the deepest nested folder, and the last + * folder is the folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Folder folders = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $folders; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * @type string $display_name + * The human readable name of the resource. + * @type string $type + * The full resource type of the resource. + * @type string $project + * The full resource name of project that the resource belongs to. + * @type string $project_display_name + * The project ID that the resource belongs to. + * @type string $parent + * The full resource name of resource's parent. + * @type string $parent_display_name + * The human readable name of resource's parent. + * @type array<\Google\Cloud\SecurityCenter\V1\Folder>|\Google\Protobuf\Internal\RepeatedField $folders + * Output only. Contains a Folder message for each folder in the assets + * ancestry. The first folder is the deepest nested folder, and the last + * folder is the folder directly under the Organization. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Resource::initOnce(); + parent::__construct($data); + } + + /** + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The human readable name of the resource. + * + * Generated from protobuf field string display_name = 8; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * The human readable name of the resource. + * + * Generated from protobuf field string display_name = 8; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * The full resource type of the resource. + * + * Generated from protobuf field string type = 6; + * @return string + */ + public function getType() + { + return $this->type; + } + + /** + * The full resource type of the resource. + * + * Generated from protobuf field string type = 6; + * @param string $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkString($var, True); + $this->type = $var; + + return $this; + } + + /** + * The full resource name of project that the resource belongs to. + * + * Generated from protobuf field string project = 2; + * @return string + */ + public function getProject() + { + return $this->project; + } + + /** + * The full resource name of project that the resource belongs to. + * + * Generated from protobuf field string project = 2; + * @param string $var + * @return $this + */ + public function setProject($var) + { + GPBUtil::checkString($var, True); + $this->project = $var; + + return $this; + } + + /** + * The project ID that the resource belongs to. + * + * Generated from protobuf field string project_display_name = 3; + * @return string + */ + public function getProjectDisplayName() + { + return $this->project_display_name; + } + + /** + * The project ID that the resource belongs to. + * + * Generated from protobuf field string project_display_name = 3; + * @param string $var + * @return $this + */ + public function setProjectDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->project_display_name = $var; + + return $this; + } + + /** + * The full resource name of resource's parent. + * + * Generated from protobuf field string parent = 4; + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * The full resource name of resource's parent. + * + * Generated from protobuf field string parent = 4; + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The human readable name of resource's parent. + * + * Generated from protobuf field string parent_display_name = 5; + * @return string + */ + public function getParentDisplayName() + { + return $this->parent_display_name; + } + + /** + * The human readable name of resource's parent. + * + * Generated from protobuf field string parent_display_name = 5; + * @param string $var + * @return $this + */ + public function setParentDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->parent_display_name = $var; + + return $this; + } + + /** + * Output only. Contains a Folder message for each folder in the assets + * ancestry. The first folder is the deepest nested folder, and the last + * folder is the folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Folder folders = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFolders() + { + return $this->folders; + } + + /** + * Output only. Contains a Folder message for each folder in the assets + * ancestry. The first folder is the deepest nested folder, and the last + * folder is the folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Folder folders = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param array<\Google\Cloud\SecurityCenter\V1\Folder>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFolders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Folder::class); + $this->folders = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryRequest.php new file mode 100644 index 000000000000..a8601f52cc00 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryRequest.php @@ -0,0 +1,86 @@ +google.cloud.securitycenter.v1.RunAssetDiscoveryRequest + */ +class RunAssetDiscoveryRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the organization to run asset discovery for. Its format + * is "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + + /** + * @param string $parent Required. Name of the organization to run asset discovery for. Its format + * is "organizations/[organization_id]". Please see + * {@see SecurityCenterClient::organizationName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V1\RunAssetDiscoveryRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Name of the organization to run asset discovery for. Its format + * is "organizations/[organization_id]". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the organization to run asset discovery for. Its format + * is "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Name of the organization to run asset discovery for. Its format + * is "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryResponse.php new file mode 100644 index 000000000000..ff4858d1b647 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryResponse.php @@ -0,0 +1,111 @@ +google.cloud.securitycenter.v1.RunAssetDiscoveryResponse + */ +class RunAssetDiscoveryResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The state of an asset discovery run. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.RunAssetDiscoveryResponse.State state = 1; + */ + protected $state = 0; + /** + * The duration between asset discovery run start and end + * + * Generated from protobuf field .google.protobuf.Duration duration = 2; + */ + protected $duration = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $state + * The state of an asset discovery run. + * @type \Google\Protobuf\Duration $duration + * The duration between asset discovery run start and end + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\RunAssetDiscoveryResponse::initOnce(); + parent::__construct($data); + } + + /** + * The state of an asset discovery run. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.RunAssetDiscoveryResponse.State state = 1; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * The state of an asset discovery run. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.RunAssetDiscoveryResponse.State state = 1; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\RunAssetDiscoveryResponse\State::class); + $this->state = $var; + + return $this; + } + + /** + * The duration between asset discovery run start and end + * + * Generated from protobuf field .google.protobuf.Duration duration = 2; + * @return \Google\Protobuf\Duration|null + */ + public function getDuration() + { + return $this->duration; + } + + public function hasDuration() + { + return isset($this->duration); + } + + public function clearDuration() + { + unset($this->duration); + } + + /** + * The duration between asset discovery run start and end + * + * Generated from protobuf field .google.protobuf.Duration duration = 2; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setDuration($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->duration = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryResponse/State.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryResponse/State.php new file mode 100644 index 000000000000..51273e889fe3 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryResponse/State.php @@ -0,0 +1,72 @@ +google.cloud.securitycenter.v1.RunAssetDiscoveryResponse.State + */ +class State +{ + /** + * Asset discovery run state was unspecified. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * Asset discovery run completed successfully. + * + * Generated from protobuf enum COMPLETED = 1; + */ + const COMPLETED = 1; + /** + * Asset discovery run was cancelled with tasks still pending, as another + * run for the same organization was started with a higher priority. + * + * Generated from protobuf enum SUPERSEDED = 2; + */ + const SUPERSEDED = 2; + /** + * Asset discovery run was killed and terminated. + * + * Generated from protobuf enum TERMINATED = 3; + */ + const TERMINATED = 3; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::COMPLETED => 'COMPLETED', + self::SUPERSEDED => 'SUPERSEDED', + self::TERMINATED => 'TERMINATED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(State::class, \Google\Cloud\SecurityCenter\V1\RunAssetDiscoveryResponse_State::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityBulletin.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityBulletin.php new file mode 100644 index 000000000000..44d92323ed02 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityBulletin.php @@ -0,0 +1,149 @@ +google.cloud.securitycenter.v1.SecurityBulletin + */ +class SecurityBulletin extends \Google\Protobuf\Internal\Message +{ + /** + * ID of the bulletin corresponding to the vulnerability. + * + * Generated from protobuf field string bulletin_id = 1; + */ + protected $bulletin_id = ''; + /** + * Submission time of this Security Bulletin. + * + * Generated from protobuf field .google.protobuf.Timestamp submission_time = 2; + */ + protected $submission_time = null; + /** + * This represents a version that the cluster receiving this notification + * should be upgraded to, based on its current version. For example, 1.15.0 + * + * Generated from protobuf field string suggested_upgrade_version = 3; + */ + protected $suggested_upgrade_version = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $bulletin_id + * ID of the bulletin corresponding to the vulnerability. + * @type \Google\Protobuf\Timestamp $submission_time + * Submission time of this Security Bulletin. + * @type string $suggested_upgrade_version + * This represents a version that the cluster receiving this notification + * should be upgraded to, based on its current version. For example, 1.15.0 + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Vulnerability::initOnce(); + parent::__construct($data); + } + + /** + * ID of the bulletin corresponding to the vulnerability. + * + * Generated from protobuf field string bulletin_id = 1; + * @return string + */ + public function getBulletinId() + { + return $this->bulletin_id; + } + + /** + * ID of the bulletin corresponding to the vulnerability. + * + * Generated from protobuf field string bulletin_id = 1; + * @param string $var + * @return $this + */ + public function setBulletinId($var) + { + GPBUtil::checkString($var, True); + $this->bulletin_id = $var; + + return $this; + } + + /** + * Submission time of this Security Bulletin. + * + * Generated from protobuf field .google.protobuf.Timestamp submission_time = 2; + * @return \Google\Protobuf\Timestamp|null + */ + public function getSubmissionTime() + { + return $this->submission_time; + } + + public function hasSubmissionTime() + { + return isset($this->submission_time); + } + + public function clearSubmissionTime() + { + unset($this->submission_time); + } + + /** + * Submission time of this Security Bulletin. + * + * Generated from protobuf field .google.protobuf.Timestamp submission_time = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setSubmissionTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->submission_time = $var; + + return $this; + } + + /** + * This represents a version that the cluster receiving this notification + * should be upgraded to, based on its current version. For example, 1.15.0 + * + * Generated from protobuf field string suggested_upgrade_version = 3; + * @return string + */ + public function getSuggestedUpgradeVersion() + { + return $this->suggested_upgrade_version; + } + + /** + * This represents a version that the cluster receiving this notification + * should be upgraded to, based on its current version. For example, 1.15.0 + * + * Generated from protobuf field string suggested_upgrade_version = 3; + * @param string $var + * @return $this + */ + public function setSuggestedUpgradeVersion($var) + { + GPBUtil::checkString($var, True); + $this->suggested_upgrade_version = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityHealthAnalyticsCustomModule.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityHealthAnalyticsCustomModule.php new file mode 100644 index 000000000000..27bd1aefd400 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityHealthAnalyticsCustomModule.php @@ -0,0 +1,355 @@ +google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule + */ +class SecurityHealthAnalyticsCustomModule extends \Google\Protobuf\Internal\Message +{ + /** + * Immutable. The resource name of the custom module. + * Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" + * The id {customModule} is server-generated and is not user settable. + * It will be a numeric id containing 1-20 digits. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; + */ + protected $name = ''; + /** + * The display name of the Security Health Analytics custom module. This + * display name becomes the finding category for all findings that are + * returned by this custom module. The display name must be between 1 and + * 128 characters, start with a lowercase letter, and contain alphanumeric + * characters or underscores only. + * + * Generated from protobuf field string display_name = 2; + */ + protected $display_name = ''; + /** + * The enablement state of the custom module. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule.EnablementState enablement_state = 4; + */ + protected $enablement_state = 0; + /** + * Output only. The time at which the custom module was last updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Output only. The editor that last updated the custom module. + * + * Generated from protobuf field string last_editor = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $last_editor = ''; + /** + * Output only. If empty, indicates that the custom module was created in the + * organization, folder, or project in which you are viewing the custom + * module. Otherwise, `ancestor_module` specifies the organization or folder + * from which the custom module is inherited. + * + * Generated from protobuf field string ancestor_module = 7 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + */ + protected $ancestor_module = ''; + /** + * The user specified custom configuration for the module. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig custom_config = 8; + */ + protected $custom_config = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Immutable. The resource name of the custom module. + * Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" + * The id {customModule} is server-generated and is not user settable. + * It will be a numeric id containing 1-20 digits. + * @type string $display_name + * The display name of the Security Health Analytics custom module. This + * display name becomes the finding category for all findings that are + * returned by this custom module. The display name must be between 1 and + * 128 characters, start with a lowercase letter, and contain alphanumeric + * characters or underscores only. + * @type int $enablement_state + * The enablement state of the custom module. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. The time at which the custom module was last updated. + * @type string $last_editor + * Output only. The editor that last updated the custom module. + * @type string $ancestor_module + * Output only. If empty, indicates that the custom module was created in the + * organization, folder, or project in which you are viewing the custom + * module. Otherwise, `ancestor_module` specifies the organization or folder + * from which the custom module is inherited. + * @type \Google\Cloud\SecurityCenter\V1\CustomConfig $custom_config + * The user specified custom configuration for the module. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecurityHealthAnalyticsCustomModule::initOnce(); + parent::__construct($data); + } + + /** + * Immutable. The resource name of the custom module. + * Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" + * The id {customModule} is server-generated and is not user settable. + * It will be a numeric id containing 1-20 digits. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Immutable. The resource name of the custom module. + * Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" + * The id {customModule} is server-generated and is not user settable. + * It will be a numeric id containing 1-20 digits. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The display name of the Security Health Analytics custom module. This + * display name becomes the finding category for all findings that are + * returned by this custom module. The display name must be between 1 and + * 128 characters, start with a lowercase letter, and contain alphanumeric + * characters or underscores only. + * + * Generated from protobuf field string display_name = 2; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * The display name of the Security Health Analytics custom module. This + * display name becomes the finding category for all findings that are + * returned by this custom module. The display name must be between 1 and + * 128 characters, start with a lowercase letter, and contain alphanumeric + * characters or underscores only. + * + * Generated from protobuf field string display_name = 2; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * The enablement state of the custom module. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule.EnablementState enablement_state = 4; + * @return int + */ + public function getEnablementState() + { + return $this->enablement_state; + } + + /** + * The enablement state of the custom module. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule.EnablementState enablement_state = 4; + * @param int $var + * @return $this + */ + public function setEnablementState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule\EnablementState::class); + $this->enablement_state = $var; + + return $this; + } + + /** + * Output only. The time at which the custom module was last updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getUpdateTime() + { + return $this->update_time; + } + + public function hasUpdateTime() + { + return isset($this->update_time); + } + + public function clearUpdateTime() + { + unset($this->update_time); + } + + /** + * Output only. The time at which the custom module was last updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->update_time = $var; + + return $this; + } + + /** + * Output only. The editor that last updated the custom module. + * + * Generated from protobuf field string last_editor = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getLastEditor() + { + return $this->last_editor; + } + + /** + * Output only. The editor that last updated the custom module. + * + * Generated from protobuf field string last_editor = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setLastEditor($var) + { + GPBUtil::checkString($var, True); + $this->last_editor = $var; + + return $this; + } + + /** + * Output only. If empty, indicates that the custom module was created in the + * organization, folder, or project in which you are viewing the custom + * module. Otherwise, `ancestor_module` specifies the organization or folder + * from which the custom module is inherited. + * + * Generated from protobuf field string ancestor_module = 7 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @return string + */ + public function getAncestorModule() + { + return $this->ancestor_module; + } + + /** + * Output only. If empty, indicates that the custom module was created in the + * organization, folder, or project in which you are viewing the custom + * module. Otherwise, `ancestor_module` specifies the organization or folder + * from which the custom module is inherited. + * + * Generated from protobuf field string ancestor_module = 7 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setAncestorModule($var) + { + GPBUtil::checkString($var, True); + $this->ancestor_module = $var; + + return $this; + } + + /** + * The user specified custom configuration for the module. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig custom_config = 8; + * @return \Google\Cloud\SecurityCenter\V1\CustomConfig|null + */ + public function getCustomConfig() + { + return $this->custom_config; + } + + public function hasCustomConfig() + { + return isset($this->custom_config); + } + + public function clearCustomConfig() + { + unset($this->custom_config); + } + + /** + * The user specified custom configuration for the module. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig custom_config = 8; + * @param \Google\Cloud\SecurityCenter\V1\CustomConfig $var + * @return $this + */ + public function setCustomConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\CustomConfig::class); + $this->custom_config = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityHealthAnalyticsCustomModule/EnablementState.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityHealthAnalyticsCustomModule/EnablementState.php new file mode 100644 index 000000000000..918e7ee654bf --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityHealthAnalyticsCustomModule/EnablementState.php @@ -0,0 +1,73 @@ +google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule.EnablementState + */ +class EnablementState +{ + /** + * Unspecified enablement state. + * + * Generated from protobuf enum ENABLEMENT_STATE_UNSPECIFIED = 0; + */ + const ENABLEMENT_STATE_UNSPECIFIED = 0; + /** + * The module is enabled at the given CRM resource. + * + * Generated from protobuf enum ENABLED = 1; + */ + const ENABLED = 1; + /** + * The module is disabled at the given CRM resource. + * + * Generated from protobuf enum DISABLED = 2; + */ + const DISABLED = 2; + /** + * State is inherited from an ancestor module. The module will either + * be effectively ENABLED or DISABLED based on its closest non-inherited + * ancestor module in the CRM hierarchy. + * + * Generated from protobuf enum INHERITED = 3; + */ + const INHERITED = 3; + + private static $valueToName = [ + self::ENABLEMENT_STATE_UNSPECIFIED => 'ENABLEMENT_STATE_UNSPECIFIED', + self::ENABLED => 'ENABLED', + self::DISABLED => 'DISABLED', + self::INHERITED => 'INHERITED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(EnablementState::class, \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule_EnablementState::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityMarks.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityMarks.php new file mode 100644 index 000000000000..d5a9c82d0fbc --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityMarks.php @@ -0,0 +1,206 @@ +google.cloud.securitycenter.v1.SecurityMarks + */ +class SecurityMarks extends \Google\Protobuf\Internal\Message +{ + /** + * The relative resource name of the SecurityMarks. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Examples: + * "organizations/{organization_id}/assets/{asset_id}/securityMarks" + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks". + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Mutable user specified security marks belonging to the parent resource. + * Constraints are as follows: + * * Keys and values are treated as case insensitive + * * Keys must be between 1 - 256 characters (inclusive) + * * Keys must be letters, numbers, underscores, or dashes + * * Values have leading and trailing whitespace trimmed, remaining + * characters must be between 1 - 4096 characters (inclusive) + * + * Generated from protobuf field map marks = 2; + */ + private $marks; + /** + * The canonical name of the marks. + * Examples: + * "organizations/{organization_id}/assets/{asset_id}/securityMarks" + * "folders/{folder_id}/assets/{asset_id}/securityMarks" + * "projects/{project_number}/assets/{asset_id}/securityMarks" + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks" + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks" + * "projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks" + * + * Generated from protobuf field string canonical_name = 3; + */ + protected $canonical_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The relative resource name of the SecurityMarks. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Examples: + * "organizations/{organization_id}/assets/{asset_id}/securityMarks" + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks". + * @type array|\Google\Protobuf\Internal\MapField $marks + * Mutable user specified security marks belonging to the parent resource. + * Constraints are as follows: + * * Keys and values are treated as case insensitive + * * Keys must be between 1 - 256 characters (inclusive) + * * Keys must be letters, numbers, underscores, or dashes + * * Values have leading and trailing whitespace trimmed, remaining + * characters must be between 1 - 4096 characters (inclusive) + * @type string $canonical_name + * The canonical name of the marks. + * Examples: + * "organizations/{organization_id}/assets/{asset_id}/securityMarks" + * "folders/{folder_id}/assets/{asset_id}/securityMarks" + * "projects/{project_number}/assets/{asset_id}/securityMarks" + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks" + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks" + * "projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks" + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecurityMarks::initOnce(); + parent::__construct($data); + } + + /** + * The relative resource name of the SecurityMarks. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Examples: + * "organizations/{organization_id}/assets/{asset_id}/securityMarks" + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks". + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The relative resource name of the SecurityMarks. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Examples: + * "organizations/{organization_id}/assets/{asset_id}/securityMarks" + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks". + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Mutable user specified security marks belonging to the parent resource. + * Constraints are as follows: + * * Keys and values are treated as case insensitive + * * Keys must be between 1 - 256 characters (inclusive) + * * Keys must be letters, numbers, underscores, or dashes + * * Values have leading and trailing whitespace trimmed, remaining + * characters must be between 1 - 4096 characters (inclusive) + * + * Generated from protobuf field map marks = 2; + * @return \Google\Protobuf\Internal\MapField + */ + public function getMarks() + { + return $this->marks; + } + + /** + * Mutable user specified security marks belonging to the parent resource. + * Constraints are as follows: + * * Keys and values are treated as case insensitive + * * Keys must be between 1 - 256 characters (inclusive) + * * Keys must be letters, numbers, underscores, or dashes + * * Values have leading and trailing whitespace trimmed, remaining + * characters must be between 1 - 4096 characters (inclusive) + * + * Generated from protobuf field map marks = 2; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setMarks($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); + $this->marks = $arr; + + return $this; + } + + /** + * The canonical name of the marks. + * Examples: + * "organizations/{organization_id}/assets/{asset_id}/securityMarks" + * "folders/{folder_id}/assets/{asset_id}/securityMarks" + * "projects/{project_number}/assets/{asset_id}/securityMarks" + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks" + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks" + * "projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks" + * + * Generated from protobuf field string canonical_name = 3; + * @return string + */ + public function getCanonicalName() + { + return $this->canonical_name; + } + + /** + * The canonical name of the marks. + * Examples: + * "organizations/{organization_id}/assets/{asset_id}/securityMarks" + * "folders/{folder_id}/assets/{asset_id}/securityMarks" + * "projects/{project_number}/assets/{asset_id}/securityMarks" + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks" + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks" + * "projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks" + * + * Generated from protobuf field string canonical_name = 3; + * @param string $var + * @return $this + */ + public function setCanonicalName($var) + { + GPBUtil::checkString($var, True); + $this->canonical_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPolicy.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPolicy.php new file mode 100644 index 000000000000..e08925f0b5a0 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPolicy.php @@ -0,0 +1,149 @@ +google.cloud.securitycenter.v1.SecurityPolicy + */ +class SecurityPolicy extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the Google Cloud Armor security policy, for example, + * "my-security-policy". + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The type of Google Cloud Armor security policy for example, ‘backend + * security policy’, ‘edge security policy’, ‘network edge security policy’, + * or ‘always-on DDoS protection’. + * + * Generated from protobuf field string type = 2; + */ + protected $type = ''; + /** + * Whether or not the associated rule or policy is in preview mode. + * + * Generated from protobuf field bool preview = 3; + */ + protected $preview = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the Google Cloud Armor security policy, for example, + * "my-security-policy". + * @type string $type + * The type of Google Cloud Armor security policy for example, ‘backend + * security policy’, ‘edge security policy’, ‘network edge security policy’, + * or ‘always-on DDoS protection’. + * @type bool $preview + * Whether or not the associated rule or policy is in preview mode. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\CloudArmor::initOnce(); + parent::__construct($data); + } + + /** + * The name of the Google Cloud Armor security policy, for example, + * "my-security-policy". + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the Google Cloud Armor security policy, for example, + * "my-security-policy". + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The type of Google Cloud Armor security policy for example, ‘backend + * security policy’, ‘edge security policy’, ‘network edge security policy’, + * or ‘always-on DDoS protection’. + * + * Generated from protobuf field string type = 2; + * @return string + */ + public function getType() + { + return $this->type; + } + + /** + * The type of Google Cloud Armor security policy for example, ‘backend + * security policy’, ‘edge security policy’, ‘network edge security policy’, + * or ‘always-on DDoS protection’. + * + * Generated from protobuf field string type = 2; + * @param string $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkString($var, True); + $this->type = $var; + + return $this; + } + + /** + * Whether or not the associated rule or policy is in preview mode. + * + * Generated from protobuf field bool preview = 3; + * @return bool + */ + public function getPreview() + { + return $this->preview; + } + + /** + * Whether or not the associated rule or policy is in preview mode. + * + * Generated from protobuf field bool preview = 3; + * @param bool $var + * @return $this + */ + public function setPreview($var) + { + GPBUtil::checkBool($var); + $this->preview = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPosture.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPosture.php new file mode 100644 index 000000000000..76779c96b647 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPosture.php @@ -0,0 +1,325 @@ +google.cloud.securitycenter.v1.SecurityPosture + */ +class SecurityPosture extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the posture, for example, `CIS-Posture`. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The version of the posture, for example, `c7cfa2a8`. + * + * Generated from protobuf field string revision_id = 2; + */ + protected $revision_id = ''; + /** + * The project, folder, or organization on which the posture is deployed, + * for example, `projects/{project_number}`. + * + * Generated from protobuf field string posture_deployment_resource = 3; + */ + protected $posture_deployment_resource = ''; + /** + * The name of the posture deployment, for example, + * `organizations/{org_id}/posturedeployments/{posture_deployment_id}`. + * + * Generated from protobuf field string posture_deployment = 4; + */ + protected $posture_deployment = ''; + /** + * The name of the updated policy, for example, + * `projects/{project_id}/policies/{constraint_name}`. + * + * Generated from protobuf field string changed_policy = 5; + */ + protected $changed_policy = ''; + /** + * The name of the updated policyset, for example, `cis-policyset`. + * + * Generated from protobuf field string policy_set = 6; + */ + protected $policy_set = ''; + /** + * The ID of the updated policy, for example, `compute-policy-1`. + * + * Generated from protobuf field string policy = 7; + */ + protected $policy = ''; + /** + * The details about a change in an updated policy that violates the deployed + * posture. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.SecurityPosture.PolicyDriftDetails policy_drift_details = 8; + */ + private $policy_drift_details; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Name of the posture, for example, `CIS-Posture`. + * @type string $revision_id + * The version of the posture, for example, `c7cfa2a8`. + * @type string $posture_deployment_resource + * The project, folder, or organization on which the posture is deployed, + * for example, `projects/{project_number}`. + * @type string $posture_deployment + * The name of the posture deployment, for example, + * `organizations/{org_id}/posturedeployments/{posture_deployment_id}`. + * @type string $changed_policy + * The name of the updated policy, for example, + * `projects/{project_id}/policies/{constraint_name}`. + * @type string $policy_set + * The name of the updated policyset, for example, `cis-policyset`. + * @type string $policy + * The ID of the updated policy, for example, `compute-policy-1`. + * @type array<\Google\Cloud\SecurityCenter\V1\SecurityPosture\PolicyDriftDetails>|\Google\Protobuf\Internal\RepeatedField $policy_drift_details + * The details about a change in an updated policy that violates the deployed + * posture. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecurityPosture::initOnce(); + parent::__construct($data); + } + + /** + * Name of the posture, for example, `CIS-Posture`. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Name of the posture, for example, `CIS-Posture`. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The version of the posture, for example, `c7cfa2a8`. + * + * Generated from protobuf field string revision_id = 2; + * @return string + */ + public function getRevisionId() + { + return $this->revision_id; + } + + /** + * The version of the posture, for example, `c7cfa2a8`. + * + * Generated from protobuf field string revision_id = 2; + * @param string $var + * @return $this + */ + public function setRevisionId($var) + { + GPBUtil::checkString($var, True); + $this->revision_id = $var; + + return $this; + } + + /** + * The project, folder, or organization on which the posture is deployed, + * for example, `projects/{project_number}`. + * + * Generated from protobuf field string posture_deployment_resource = 3; + * @return string + */ + public function getPostureDeploymentResource() + { + return $this->posture_deployment_resource; + } + + /** + * The project, folder, or organization on which the posture is deployed, + * for example, `projects/{project_number}`. + * + * Generated from protobuf field string posture_deployment_resource = 3; + * @param string $var + * @return $this + */ + public function setPostureDeploymentResource($var) + { + GPBUtil::checkString($var, True); + $this->posture_deployment_resource = $var; + + return $this; + } + + /** + * The name of the posture deployment, for example, + * `organizations/{org_id}/posturedeployments/{posture_deployment_id}`. + * + * Generated from protobuf field string posture_deployment = 4; + * @return string + */ + public function getPostureDeployment() + { + return $this->posture_deployment; + } + + /** + * The name of the posture deployment, for example, + * `organizations/{org_id}/posturedeployments/{posture_deployment_id}`. + * + * Generated from protobuf field string posture_deployment = 4; + * @param string $var + * @return $this + */ + public function setPostureDeployment($var) + { + GPBUtil::checkString($var, True); + $this->posture_deployment = $var; + + return $this; + } + + /** + * The name of the updated policy, for example, + * `projects/{project_id}/policies/{constraint_name}`. + * + * Generated from protobuf field string changed_policy = 5; + * @return string + */ + public function getChangedPolicy() + { + return $this->changed_policy; + } + + /** + * The name of the updated policy, for example, + * `projects/{project_id}/policies/{constraint_name}`. + * + * Generated from protobuf field string changed_policy = 5; + * @param string $var + * @return $this + */ + public function setChangedPolicy($var) + { + GPBUtil::checkString($var, True); + $this->changed_policy = $var; + + return $this; + } + + /** + * The name of the updated policyset, for example, `cis-policyset`. + * + * Generated from protobuf field string policy_set = 6; + * @return string + */ + public function getPolicySet() + { + return $this->policy_set; + } + + /** + * The name of the updated policyset, for example, `cis-policyset`. + * + * Generated from protobuf field string policy_set = 6; + * @param string $var + * @return $this + */ + public function setPolicySet($var) + { + GPBUtil::checkString($var, True); + $this->policy_set = $var; + + return $this; + } + + /** + * The ID of the updated policy, for example, `compute-policy-1`. + * + * Generated from protobuf field string policy = 7; + * @return string + */ + public function getPolicy() + { + return $this->policy; + } + + /** + * The ID of the updated policy, for example, `compute-policy-1`. + * + * Generated from protobuf field string policy = 7; + * @param string $var + * @return $this + */ + public function setPolicy($var) + { + GPBUtil::checkString($var, True); + $this->policy = $var; + + return $this; + } + + /** + * The details about a change in an updated policy that violates the deployed + * posture. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.SecurityPosture.PolicyDriftDetails policy_drift_details = 8; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPolicyDriftDetails() + { + return $this->policy_drift_details; + } + + /** + * The details about a change in an updated policy that violates the deployed + * posture. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1.SecurityPosture.PolicyDriftDetails policy_drift_details = 8; + * @param array<\Google\Cloud\SecurityCenter\V1\SecurityPosture\PolicyDriftDetails>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPolicyDriftDetails($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\SecurityPosture\PolicyDriftDetails::class); + $this->policy_drift_details = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPosture/PolicyDriftDetails.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPosture/PolicyDriftDetails.php new file mode 100644 index 000000000000..991b3c1a83e4 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPosture/PolicyDriftDetails.php @@ -0,0 +1,151 @@ +google.cloud.securitycenter.v1.SecurityPosture.PolicyDriftDetails + */ +class PolicyDriftDetails extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the updated field, for example + * constraint.implementation.policy_rules[0].enforce + * + * Generated from protobuf field string field = 1; + */ + protected $field = ''; + /** + * The value of this field that was configured in a posture, for example, + * `true` or `allowed_values={"projects/29831892"}`. + * + * Generated from protobuf field string expected_value = 2; + */ + protected $expected_value = ''; + /** + * The detected value that violates the deployed posture, for example, + * `false` or `allowed_values={"projects/22831892"}`. + * + * Generated from protobuf field string detected_value = 3; + */ + protected $detected_value = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $field + * The name of the updated field, for example + * constraint.implementation.policy_rules[0].enforce + * @type string $expected_value + * The value of this field that was configured in a posture, for example, + * `true` or `allowed_values={"projects/29831892"}`. + * @type string $detected_value + * The detected value that violates the deployed posture, for example, + * `false` or `allowed_values={"projects/22831892"}`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecurityPosture::initOnce(); + parent::__construct($data); + } + + /** + * The name of the updated field, for example + * constraint.implementation.policy_rules[0].enforce + * + * Generated from protobuf field string field = 1; + * @return string + */ + public function getField() + { + return $this->field; + } + + /** + * The name of the updated field, for example + * constraint.implementation.policy_rules[0].enforce + * + * Generated from protobuf field string field = 1; + * @param string $var + * @return $this + */ + public function setField($var) + { + GPBUtil::checkString($var, True); + $this->field = $var; + + return $this; + } + + /** + * The value of this field that was configured in a posture, for example, + * `true` or `allowed_values={"projects/29831892"}`. + * + * Generated from protobuf field string expected_value = 2; + * @return string + */ + public function getExpectedValue() + { + return $this->expected_value; + } + + /** + * The value of this field that was configured in a posture, for example, + * `true` or `allowed_values={"projects/29831892"}`. + * + * Generated from protobuf field string expected_value = 2; + * @param string $var + * @return $this + */ + public function setExpectedValue($var) + { + GPBUtil::checkString($var, True); + $this->expected_value = $var; + + return $this; + } + + /** + * The detected value that violates the deployed posture, for example, + * `false` or `allowed_values={"projects/22831892"}`. + * + * Generated from protobuf field string detected_value = 3; + * @return string + */ + public function getDetectedValue() + { + return $this->detected_value; + } + + /** + * The detected value that violates the deployed posture, for example, + * `false` or `allowed_values={"projects/22831892"}`. + * + * Generated from protobuf field string detected_value = 3; + * @param string $var + * @return $this + */ + public function setDetectedValue($var) + { + GPBUtil::checkString($var, True); + $this->detected_value = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(PolicyDriftDetails::class, \Google\Cloud\SecurityCenter\V1\SecurityPosture_PolicyDriftDetails::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ServiceAccountDelegationInfo.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ServiceAccountDelegationInfo.php new file mode 100644 index 000000000000..d6cb5540abbe --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ServiceAccountDelegationInfo.php @@ -0,0 +1,125 @@ +google.cloud.securitycenter.v1.ServiceAccountDelegationInfo + */ +class ServiceAccountDelegationInfo extends \Google\Protobuf\Internal\Message +{ + /** + * The email address of a Google account. + * + * Generated from protobuf field string principal_email = 1; + */ + protected $principal_email = ''; + /** + * A string representing the principal_subject associated with the identity. + * As compared to `principal_email`, supports principals that aren't + * associated with email addresses, such as third party principals. For most + * identities, the format will be `principal://iam.googleapis.com/{identity + * pool name}/subjects/{subject}` except for some GKE identities + * (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy + * format `serviceAccount:{identity pool name}[{subject}]` + * + * Generated from protobuf field string principal_subject = 2; + */ + protected $principal_subject = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $principal_email + * The email address of a Google account. + * @type string $principal_subject + * A string representing the principal_subject associated with the identity. + * As compared to `principal_email`, supports principals that aren't + * associated with email addresses, such as third party principals. For most + * identities, the format will be `principal://iam.googleapis.com/{identity + * pool name}/subjects/{subject}` except for some GKE identities + * (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy + * format `serviceAccount:{identity pool name}[{subject}]` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Access::initOnce(); + parent::__construct($data); + } + + /** + * The email address of a Google account. + * + * Generated from protobuf field string principal_email = 1; + * @return string + */ + public function getPrincipalEmail() + { + return $this->principal_email; + } + + /** + * The email address of a Google account. + * + * Generated from protobuf field string principal_email = 1; + * @param string $var + * @return $this + */ + public function setPrincipalEmail($var) + { + GPBUtil::checkString($var, True); + $this->principal_email = $var; + + return $this; + } + + /** + * A string representing the principal_subject associated with the identity. + * As compared to `principal_email`, supports principals that aren't + * associated with email addresses, such as third party principals. For most + * identities, the format will be `principal://iam.googleapis.com/{identity + * pool name}/subjects/{subject}` except for some GKE identities + * (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy + * format `serviceAccount:{identity pool name}[{subject}]` + * + * Generated from protobuf field string principal_subject = 2; + * @return string + */ + public function getPrincipalSubject() + { + return $this->principal_subject; + } + + /** + * A string representing the principal_subject associated with the identity. + * As compared to `principal_email`, supports principals that aren't + * associated with email addresses, such as third party principals. For most + * identities, the format will be `principal://iam.googleapis.com/{identity + * pool name}/subjects/{subject}` except for some GKE identities + * (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy + * format `serviceAccount:{identity pool name}[{subject}]` + * + * Generated from protobuf field string principal_subject = 2; + * @param string $var + * @return $this + */ + public function setPrincipalSubject($var) + { + GPBUtil::checkString($var, True); + $this->principal_subject = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SetFindingStateRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SetFindingStateRequest.php new file mode 100644 index 000000000000..afc55508447e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SetFindingStateRequest.php @@ -0,0 +1,189 @@ +google.cloud.securitycenter.v1.SetFindingStateRequest + */ +class SetFindingStateRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", + * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Required. The desired State of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.State state = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $state = 0; + /** + * Required. The time at which the updated state takes effect. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $start_time = null; + + /** + * @param string $name Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", + * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". Please see + * {@see SecurityCenterClient::findingName()} for help formatting this field. + * @param int $state Required. The desired State of the finding. + * For allowed values, use constants defined on {@see \Google\Cloud\SecurityCenter\V1\Finding\State} + * @param \Google\Protobuf\Timestamp $startTime Required. The time at which the updated state takes effect. + * + * @return \Google\Cloud\SecurityCenter\V1\SetFindingStateRequest + * + * @experimental + */ + public static function build(string $name, int $state, \Google\Protobuf\Timestamp $startTime): self + { + return (new self()) + ->setName($name) + ->setState($state) + ->setStartTime($startTime); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", + * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". + * @type int $state + * Required. The desired State of the finding. + * @type \Google\Protobuf\Timestamp $start_time + * Required. The time at which the updated state takes effect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", + * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", + * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Required. The desired State of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.State state = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Required. The desired State of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.State state = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Finding\State::class); + $this->state = $var; + + return $this; + } + + /** + * Required. The time at which the updated state takes effect. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getStartTime() + { + return $this->start_time; + } + + public function hasStartTime() + { + return isset($this->start_time); + } + + public function clearStartTime() + { + unset($this->start_time); + } + + /** + * Required. The time at which the updated state takes effect. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setStartTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->start_time = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SetMuteRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SetMuteRequest.php new file mode 100644 index 000000000000..e94e58b515f0 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SetMuteRequest.php @@ -0,0 +1,143 @@ +google.cloud.securitycenter.v1.SetMuteRequest + */ +class SetMuteRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", + * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Required. The desired state of the Mute. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.Mute mute = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $mute = 0; + + /** + * @param string $name Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", + * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". Please see + * {@see SecurityCenterClient::findingName()} for help formatting this field. + * @param int $mute Required. The desired state of the Mute. + * For allowed values, use constants defined on {@see \Google\Cloud\SecurityCenter\V1\Finding\Mute} + * + * @return \Google\Cloud\SecurityCenter\V1\SetMuteRequest + * + * @experimental + */ + public static function build(string $name, int $mute): self + { + return (new self()) + ->setName($name) + ->setMute($mute); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", + * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". + * @type int $mute + * Required. The desired state of the Mute. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", + * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", + * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Required. The desired state of the Mute. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.Mute mute = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getMute() + { + return $this->mute; + } + + /** + * Required. The desired state of the Mute. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.Mute mute = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setMute($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Finding\Mute::class); + $this->mute = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleRequest.php new file mode 100644 index 000000000000..3bc4c0ad7ffd --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleRequest.php @@ -0,0 +1,193 @@ +google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleRequest + */ +class SimulateSecurityHealthAnalyticsCustomModuleRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The relative resource name of the organization, project, or + * folder. For more information about relative resource names, see [Relative + * Resource + * Name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * Example: `organizations/{organization_id}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $parent = ''; + /** + * Required. The custom configuration that you need to test. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig custom_config = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $custom_config = null; + /** + * Required. Resource data to simulate custom module against. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleRequest.SimulatedResource resource = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $resource = null; + + /** + * @param string $parent Required. The relative resource name of the organization, project, or + * folder. For more information about relative resource names, see [Relative + * Resource + * Name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * Example: `organizations/{organization_id}` + * @param \Google\Cloud\SecurityCenter\V1\CustomConfig $customConfig Required. The custom configuration that you need to test. + * @param \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleRequest\SimulatedResource $resource Required. Resource data to simulate custom module against. + * + * @return \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\SecurityCenter\V1\CustomConfig $customConfig, \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleRequest\SimulatedResource $resource): self + { + return (new self()) + ->setParent($parent) + ->setCustomConfig($customConfig) + ->setResource($resource); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The relative resource name of the organization, project, or + * folder. For more information about relative resource names, see [Relative + * Resource + * Name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * Example: `organizations/{organization_id}` + * @type \Google\Cloud\SecurityCenter\V1\CustomConfig $custom_config + * Required. The custom configuration that you need to test. + * @type \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleRequest\SimulatedResource $resource + * Required. Resource data to simulate custom module against. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The relative resource name of the organization, project, or + * folder. For more information about relative resource names, see [Relative + * Resource + * Name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * Example: `organizations/{organization_id}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The relative resource name of the organization, project, or + * folder. For more information about relative resource names, see [Relative + * Resource + * Name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * Example: `organizations/{organization_id}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. The custom configuration that you need to test. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig custom_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1\CustomConfig|null + */ + public function getCustomConfig() + { + return $this->custom_config; + } + + public function hasCustomConfig() + { + return isset($this->custom_config); + } + + public function clearCustomConfig() + { + unset($this->custom_config); + } + + /** + * Required. The custom configuration that you need to test. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig custom_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1\CustomConfig $var + * @return $this + */ + public function setCustomConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\CustomConfig::class); + $this->custom_config = $var; + + return $this; + } + + /** + * Required. Resource data to simulate custom module against. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleRequest.SimulatedResource resource = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleRequest\SimulatedResource|null + */ + public function getResource() + { + return $this->resource; + } + + public function hasResource() + { + return isset($this->resource); + } + + public function clearResource() + { + unset($this->resource); + } + + /** + * Required. Resource data to simulate custom module against. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleRequest.SimulatedResource resource = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleRequest\SimulatedResource $var + * @return $this + */ + public function setResource($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleRequest\SimulatedResource::class); + $this->resource = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleRequest/SimulatedResource.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleRequest/SimulatedResource.php new file mode 100644 index 000000000000..07b581a0ffb0 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleRequest/SimulatedResource.php @@ -0,0 +1,168 @@ +google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleRequest.SimulatedResource + */ +class SimulatedResource extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The type of the resource, for example, + * `compute.googleapis.com/Disk`. + * + * Generated from protobuf field string resource_type = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $resource_type = ''; + /** + * Optional. A representation of the Google Cloud resource. Should match the + * Google Cloud resource JSON format. + * + * Generated from protobuf field .google.protobuf.Struct resource_data = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $resource_data = null; + /** + * Optional. A representation of the IAM policy. + * + * Generated from protobuf field .google.iam.v1.Policy iam_policy_data = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $iam_policy_data = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $resource_type + * Required. The type of the resource, for example, + * `compute.googleapis.com/Disk`. + * @type \Google\Protobuf\Struct $resource_data + * Optional. A representation of the Google Cloud resource. Should match the + * Google Cloud resource JSON format. + * @type \Google\Cloud\Iam\V1\Policy $iam_policy_data + * Optional. A representation of the IAM policy. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The type of the resource, for example, + * `compute.googleapis.com/Disk`. + * + * Generated from protobuf field string resource_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getResourceType() + { + return $this->resource_type; + } + + /** + * Required. The type of the resource, for example, + * `compute.googleapis.com/Disk`. + * + * Generated from protobuf field string resource_type = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setResourceType($var) + { + GPBUtil::checkString($var, True); + $this->resource_type = $var; + + return $this; + } + + /** + * Optional. A representation of the Google Cloud resource. Should match the + * Google Cloud resource JSON format. + * + * Generated from protobuf field .google.protobuf.Struct resource_data = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Struct|null + */ + public function getResourceData() + { + return $this->resource_data; + } + + public function hasResourceData() + { + return isset($this->resource_data); + } + + public function clearResourceData() + { + unset($this->resource_data); + } + + /** + * Optional. A representation of the Google Cloud resource. Should match the + * Google Cloud resource JSON format. + * + * Generated from protobuf field .google.protobuf.Struct resource_data = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Protobuf\Struct $var + * @return $this + */ + public function setResourceData($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); + $this->resource_data = $var; + + return $this; + } + + /** + * Optional. A representation of the IAM policy. + * + * Generated from protobuf field .google.iam.v1.Policy iam_policy_data = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Iam\V1\Policy|null + */ + public function getIamPolicyData() + { + return $this->iam_policy_data; + } + + public function hasIamPolicyData() + { + return isset($this->iam_policy_data); + } + + public function clearIamPolicyData() + { + unset($this->iam_policy_data); + } + + /** + * Optional. A representation of the IAM policy. + * + * Generated from protobuf field .google.iam.v1.Policy iam_policy_data = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Iam\V1\Policy $var + * @return $this + */ + public function setIamPolicyData($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Iam\V1\Policy::class); + $this->iam_policy_data = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SimulatedResource::class, \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleRequest_SimulatedResource::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleResponse.php new file mode 100644 index 000000000000..6418daab5b4d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleResponse.php @@ -0,0 +1,78 @@ +google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleResponse + */ +class SimulateSecurityHealthAnalyticsCustomModuleResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Result for test case in the corresponding request. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleResponse.SimulatedResult result = 1; + */ + protected $result = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleResponse\SimulatedResult $result + * Result for test case in the corresponding request. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Result for test case in the corresponding request. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleResponse.SimulatedResult result = 1; + * @return \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleResponse\SimulatedResult|null + */ + public function getResult() + { + return $this->result; + } + + public function hasResult() + { + return isset($this->result); + } + + public function clearResult() + { + unset($this->result); + } + + /** + * Result for test case in the corresponding request. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleResponse.SimulatedResult result = 1; + * @param \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleResponse\SimulatedResult $var + * @return $this + */ + public function setResult($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleResponse\SimulatedResult::class); + $this->result = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleResponse/SimulatedResult.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleResponse/SimulatedResult.php new file mode 100644 index 000000000000..4c191593a2ee --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleResponse/SimulatedResult.php @@ -0,0 +1,147 @@ +google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleResponse.SimulatedResult + */ +class SimulatedResult extends \Google\Protobuf\Internal\Message +{ + protected $result; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1\Finding $finding + * Finding that would be published for the test case, + * if a violation is detected. + * @type \Google\Protobuf\GPBEmpty $no_violation + * Indicates that the test case does not trigger any violation. + * @type \Google\Rpc\Status $error + * Error encountered during the test. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Finding that would be published for the test case, + * if a violation is detected. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 1; + * @return \Google\Cloud\SecurityCenter\V1\Finding|null + */ + public function getFinding() + { + return $this->readOneof(1); + } + + public function hasFinding() + { + return $this->hasOneof(1); + } + + /** + * Finding that would be published for the test case, + * if a violation is detected. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 1; + * @param \Google\Cloud\SecurityCenter\V1\Finding $var + * @return $this + */ + public function setFinding($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Finding::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Indicates that the test case does not trigger any violation. + * + * Generated from protobuf field .google.protobuf.Empty no_violation = 2; + * @return \Google\Protobuf\GPBEmpty|null + */ + public function getNoViolation() + { + return $this->readOneof(2); + } + + public function hasNoViolation() + { + return $this->hasOneof(2); + } + + /** + * Indicates that the test case does not trigger any violation. + * + * Generated from protobuf field .google.protobuf.Empty no_violation = 2; + * @param \Google\Protobuf\GPBEmpty $var + * @return $this + */ + public function setNoViolation($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\GPBEmpty::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Error encountered during the test. + * + * Generated from protobuf field .google.rpc.Status error = 3; + * @return \Google\Rpc\Status|null + */ + public function getError() + { + return $this->readOneof(3); + } + + public function hasError() + { + return $this->hasOneof(3); + } + + /** + * Error encountered during the test. + * + * Generated from protobuf field .google.rpc.Status error = 3; + * @param \Google\Rpc\Status $var + * @return $this + */ + public function setError($var) + { + GPBUtil::checkMessage($var, \Google\Rpc\Status::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * @return string + */ + public function getResult() + { + return $this->whichOneof("result"); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SimulatedResult::class, \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleResponse_SimulatedResult::class); + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Source.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Source.php new file mode 100644 index 000000000000..e97bce183d3c --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Source.php @@ -0,0 +1,244 @@ +google.cloud.securitycenter.v1.Source + */ +class Source extends \Google\Protobuf\Internal\Message +{ + /** + * The relative resource name of this source. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}" + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The source's display name. + * A source's display name must be unique amongst its siblings, for example, + * two sources with the same parent can't share the same display name. + * The display name must have a length between 1 and 64 characters + * (inclusive). + * + * Generated from protobuf field string display_name = 2; + */ + protected $display_name = ''; + /** + * The description of the source (max of 1024 characters). + * Example: + * "Web Security Scanner is a web security scanner for common + * vulnerabilities in App Engine applications. It can automatically + * scan and detect four common vulnerabilities, including cross-site-scripting + * (XSS), Flash injection, mixed content (HTTP in HTTPS), and + * outdated or insecure libraries." + * + * Generated from protobuf field string description = 3; + */ + protected $description = ''; + /** + * The canonical name of the finding source. It's either + * "organizations/{organization_id}/sources/{source_id}", + * "folders/{folder_id}/sources/{source_id}", or + * "projects/{project_number}/sources/{source_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * + * Generated from protobuf field string canonical_name = 14; + */ + protected $canonical_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The relative resource name of this source. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}" + * @type string $display_name + * The source's display name. + * A source's display name must be unique amongst its siblings, for example, + * two sources with the same parent can't share the same display name. + * The display name must have a length between 1 and 64 characters + * (inclusive). + * @type string $description + * The description of the source (max of 1024 characters). + * Example: + * "Web Security Scanner is a web security scanner for common + * vulnerabilities in App Engine applications. It can automatically + * scan and detect four common vulnerabilities, including cross-site-scripting + * (XSS), Flash injection, mixed content (HTTP in HTTPS), and + * outdated or insecure libraries." + * @type string $canonical_name + * The canonical name of the finding source. It's either + * "organizations/{organization_id}/sources/{source_id}", + * "folders/{folder_id}/sources/{source_id}", or + * "projects/{project_number}/sources/{source_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Source::initOnce(); + parent::__construct($data); + } + + /** + * The relative resource name of this source. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}" + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The relative resource name of this source. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}" + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The source's display name. + * A source's display name must be unique amongst its siblings, for example, + * two sources with the same parent can't share the same display name. + * The display name must have a length between 1 and 64 characters + * (inclusive). + * + * Generated from protobuf field string display_name = 2; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * The source's display name. + * A source's display name must be unique amongst its siblings, for example, + * two sources with the same parent can't share the same display name. + * The display name must have a length between 1 and 64 characters + * (inclusive). + * + * Generated from protobuf field string display_name = 2; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * The description of the source (max of 1024 characters). + * Example: + * "Web Security Scanner is a web security scanner for common + * vulnerabilities in App Engine applications. It can automatically + * scan and detect four common vulnerabilities, including cross-site-scripting + * (XSS), Flash injection, mixed content (HTTP in HTTPS), and + * outdated or insecure libraries." + * + * Generated from protobuf field string description = 3; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * The description of the source (max of 1024 characters). + * Example: + * "Web Security Scanner is a web security scanner for common + * vulnerabilities in App Engine applications. It can automatically + * scan and detect four common vulnerabilities, including cross-site-scripting + * (XSS), Flash injection, mixed content (HTTP in HTTPS), and + * outdated or insecure libraries." + * + * Generated from protobuf field string description = 3; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * The canonical name of the finding source. It's either + * "organizations/{organization_id}/sources/{source_id}", + * "folders/{folder_id}/sources/{source_id}", or + * "projects/{project_number}/sources/{source_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * + * Generated from protobuf field string canonical_name = 14; + * @return string + */ + public function getCanonicalName() + { + return $this->canonical_name; + } + + /** + * The canonical name of the finding source. It's either + * "organizations/{organization_id}/sources/{source_id}", + * "folders/{folder_id}/sources/{source_id}", or + * "projects/{project_number}/sources/{source_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * + * Generated from protobuf field string canonical_name = 14; + * @param string $var + * @return $this + */ + public function setCanonicalName($var) + { + GPBUtil::checkString($var, True); + $this->canonical_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ToxicCombination.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ToxicCombination.php new file mode 100644 index 000000000000..23d845ebfdd7 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ToxicCombination.php @@ -0,0 +1,123 @@ +google.cloud.securitycenter.v1.ToxicCombination + */ +class ToxicCombination extends \Google\Protobuf\Internal\Message +{ + /** + * The + * [Attack exposure + * score](https://cloud.google.com/security-command-center/docs/attack-exposure-learn#attack_exposure_scores) + * of this toxic combination. The score is a measure of how much this toxic + * combination exposes one or more high-value resources to potential attack. + * + * Generated from protobuf field double attack_exposure_score = 1; + */ + protected $attack_exposure_score = 0.0; + /** + * List of resource names of findings associated with this toxic combination. + * For example, `organizations/123/sources/456/findings/789`. + * + * Generated from protobuf field repeated string related_findings = 2; + */ + private $related_findings; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type float $attack_exposure_score + * The + * [Attack exposure + * score](https://cloud.google.com/security-command-center/docs/attack-exposure-learn#attack_exposure_scores) + * of this toxic combination. The score is a measure of how much this toxic + * combination exposes one or more high-value resources to potential attack. + * @type array|\Google\Protobuf\Internal\RepeatedField $related_findings + * List of resource names of findings associated with this toxic combination. + * For example, `organizations/123/sources/456/findings/789`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\ToxicCombination::initOnce(); + parent::__construct($data); + } + + /** + * The + * [Attack exposure + * score](https://cloud.google.com/security-command-center/docs/attack-exposure-learn#attack_exposure_scores) + * of this toxic combination. The score is a measure of how much this toxic + * combination exposes one or more high-value resources to potential attack. + * + * Generated from protobuf field double attack_exposure_score = 1; + * @return float + */ + public function getAttackExposureScore() + { + return $this->attack_exposure_score; + } + + /** + * The + * [Attack exposure + * score](https://cloud.google.com/security-command-center/docs/attack-exposure-learn#attack_exposure_scores) + * of this toxic combination. The score is a measure of how much this toxic + * combination exposes one or more high-value resources to potential attack. + * + * Generated from protobuf field double attack_exposure_score = 1; + * @param float $var + * @return $this + */ + public function setAttackExposureScore($var) + { + GPBUtil::checkDouble($var); + $this->attack_exposure_score = $var; + + return $this; + } + + /** + * List of resource names of findings associated with this toxic combination. + * For example, `organizations/123/sources/456/findings/789`. + * + * Generated from protobuf field repeated string related_findings = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRelatedFindings() + { + return $this->related_findings; + } + + /** + * List of resource names of findings associated with this toxic combination. + * For example, `organizations/123/sources/456/findings/789`. + * + * Generated from protobuf field repeated string related_findings = 2; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRelatedFindings($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->related_findings = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateBigQueryExportRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateBigQueryExportRequest.php new file mode 100644 index 000000000000..5242f30292f0 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateBigQueryExportRequest.php @@ -0,0 +1,141 @@ +google.cloud.securitycenter.v1.UpdateBigQueryExportRequest + */ +class UpdateBigQueryExportRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The BigQuery export being updated. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.BigQueryExport big_query_export = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $big_query_export = null; + /** + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * @param \Google\Cloud\SecurityCenter\V1\BigQueryExport $bigQueryExport Required. The BigQuery export being updated. + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. + * If empty all mutable fields will be updated. + * + * @return \Google\Cloud\SecurityCenter\V1\UpdateBigQueryExportRequest + * + * @experimental + */ + public static function build(\Google\Cloud\SecurityCenter\V1\BigQueryExport $bigQueryExport, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setBigQueryExport($bigQueryExport) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1\BigQueryExport $big_query_export + * Required. The BigQuery export being updated. + * @type \Google\Protobuf\FieldMask $update_mask + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The BigQuery export being updated. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.BigQueryExport big_query_export = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1\BigQueryExport|null + */ + public function getBigQueryExport() + { + return $this->big_query_export; + } + + public function hasBigQueryExport() + { + return isset($this->big_query_export); + } + + public function clearBigQueryExport() + { + unset($this->big_query_export); + } + + /** + * Required. The BigQuery export being updated. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.BigQueryExport big_query_export = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1\BigQueryExport $var + * @return $this + */ + public function setBigQueryExport($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\BigQueryExport::class); + $this->big_query_export = $var; + + return $this; + } + + /** + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateExternalSystemRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateExternalSystemRequest.php new file mode 100644 index 000000000000..ceaa44f6abf7 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateExternalSystemRequest.php @@ -0,0 +1,142 @@ +google.cloud.securitycenter.v1.UpdateExternalSystemRequest + */ +class UpdateExternalSystemRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The external system resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.ExternalSystem external_system = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $external_system = null; + /** + * The FieldMask to use when updating the external system resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * @param \Google\Cloud\SecurityCenter\V1\ExternalSystem $externalSystem Required. The external system resource to update. + * @param \Google\Protobuf\FieldMask $updateMask The FieldMask to use when updating the external system resource. + * + * If empty all mutable fields will be updated. + * + * @return \Google\Cloud\SecurityCenter\V1\UpdateExternalSystemRequest + * + * @experimental + */ + public static function build(\Google\Cloud\SecurityCenter\V1\ExternalSystem $externalSystem, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setExternalSystem($externalSystem) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1\ExternalSystem $external_system + * Required. The external system resource to update. + * @type \Google\Protobuf\FieldMask $update_mask + * The FieldMask to use when updating the external system resource. + * If empty all mutable fields will be updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The external system resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.ExternalSystem external_system = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1\ExternalSystem|null + */ + public function getExternalSystem() + { + return $this->external_system; + } + + public function hasExternalSystem() + { + return isset($this->external_system); + } + + public function clearExternalSystem() + { + unset($this->external_system); + } + + /** + * Required. The external system resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.ExternalSystem external_system = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1\ExternalSystem $var + * @return $this + */ + public function setExternalSystem($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\ExternalSystem::class); + $this->external_system = $var; + + return $this; + } + + /** + * The FieldMask to use when updating the external system resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The FieldMask to use when updating the external system resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateFindingRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateFindingRequest.php new file mode 100644 index 000000000000..365c64c12143 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateFindingRequest.php @@ -0,0 +1,175 @@ +google.cloud.securitycenter.v1.UpdateFindingRequest + */ +class UpdateFindingRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The finding resource to update or create if it does not already + * exist. parent, security_marks, and update_time will be ignored. + * In the case of creation, the finding id portion of the name must be + * alphanumeric and less than or equal to 32 characters and greater than 0 + * characters in length. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $finding = null; + /** + * The FieldMask to use when updating the finding resource. This field should + * not be specified when creating a finding. + * When updating a finding, an empty mask is treated as updating all mutable + * fields and replacing source_properties. Individual source_properties can + * be added/updated by using "source_properties." in the field + * mask. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * @param \Google\Cloud\SecurityCenter\V1\Finding $finding Required. The finding resource to update or create if it does not already + * exist. parent, security_marks, and update_time will be ignored. + * + * In the case of creation, the finding id portion of the name must be + * alphanumeric and less than or equal to 32 characters and greater than 0 + * characters in length. + * + * @return \Google\Cloud\SecurityCenter\V1\UpdateFindingRequest + * + * @experimental + */ + public static function build(\Google\Cloud\SecurityCenter\V1\Finding $finding): self + { + return (new self()) + ->setFinding($finding); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1\Finding $finding + * Required. The finding resource to update or create if it does not already + * exist. parent, security_marks, and update_time will be ignored. + * In the case of creation, the finding id portion of the name must be + * alphanumeric and less than or equal to 32 characters and greater than 0 + * characters in length. + * @type \Google\Protobuf\FieldMask $update_mask + * The FieldMask to use when updating the finding resource. This field should + * not be specified when creating a finding. + * When updating a finding, an empty mask is treated as updating all mutable + * fields and replacing source_properties. Individual source_properties can + * be added/updated by using "source_properties." in the field + * mask. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The finding resource to update or create if it does not already + * exist. parent, security_marks, and update_time will be ignored. + * In the case of creation, the finding id portion of the name must be + * alphanumeric and less than or equal to 32 characters and greater than 0 + * characters in length. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1\Finding|null + */ + public function getFinding() + { + return $this->finding; + } + + public function hasFinding() + { + return isset($this->finding); + } + + public function clearFinding() + { + unset($this->finding); + } + + /** + * Required. The finding resource to update or create if it does not already + * exist. parent, security_marks, and update_time will be ignored. + * In the case of creation, the finding id portion of the name must be + * alphanumeric and less than or equal to 32 characters and greater than 0 + * characters in length. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1\Finding $var + * @return $this + */ + public function setFinding($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Finding::class); + $this->finding = $var; + + return $this; + } + + /** + * The FieldMask to use when updating the finding resource. This field should + * not be specified when creating a finding. + * When updating a finding, an empty mask is treated as updating all mutable + * fields and replacing source_properties. Individual source_properties can + * be added/updated by using "source_properties." in the field + * mask. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The FieldMask to use when updating the finding resource. This field should + * not be specified when creating a finding. + * When updating a finding, an empty mask is treated as updating all mutable + * fields and replacing source_properties. Individual source_properties can + * be added/updated by using "source_properties." in the field + * mask. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateMuteConfigRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateMuteConfigRequest.php new file mode 100644 index 000000000000..deae46e7e6ac --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateMuteConfigRequest.php @@ -0,0 +1,141 @@ +google.cloud.securitycenter.v1.UpdateMuteConfigRequest + */ +class UpdateMuteConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The mute config being updated. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.MuteConfig mute_config = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $mute_config = null; + /** + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * @param \Google\Cloud\SecurityCenter\V1\MuteConfig $muteConfig Required. The mute config being updated. + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. + * If empty all mutable fields will be updated. + * + * @return \Google\Cloud\SecurityCenter\V1\UpdateMuteConfigRequest + * + * @experimental + */ + public static function build(\Google\Cloud\SecurityCenter\V1\MuteConfig $muteConfig, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setMuteConfig($muteConfig) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1\MuteConfig $mute_config + * Required. The mute config being updated. + * @type \Google\Protobuf\FieldMask $update_mask + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The mute config being updated. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.MuteConfig mute_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1\MuteConfig|null + */ + public function getMuteConfig() + { + return $this->mute_config; + } + + public function hasMuteConfig() + { + return isset($this->mute_config); + } + + public function clearMuteConfig() + { + unset($this->mute_config); + } + + /** + * Required. The mute config being updated. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.MuteConfig mute_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1\MuteConfig $var + * @return $this + */ + public function setMuteConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\MuteConfig::class); + $this->mute_config = $var; + + return $this; + } + + /** + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateNotificationConfigRequest.php new file mode 100644 index 000000000000..2fd6dd439c34 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateNotificationConfigRequest.php @@ -0,0 +1,155 @@ +google.cloud.securitycenter.v1.UpdateNotificationConfigRequest + */ +class UpdateNotificationConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The notification config to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.NotificationConfig notification_config = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $notification_config = null; + /** + * The FieldMask to use when updating the notification config. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * @param \Google\Cloud\SecurityCenter\V1\NotificationConfig $notificationConfig Required. The notification config to update. + * + * @return \Google\Cloud\SecurityCenter\V1\UpdateNotificationConfigRequest + * + * @experimental + */ + public static function build(\Google\Cloud\SecurityCenter\V1\NotificationConfig $notificationConfig): self + { + return (new self()) + ->setNotificationConfig($notificationConfig); + } + + /** + * @param \Google\Cloud\SecurityCenter\V1\NotificationConfig $notificationConfig Required. The notification config to update. + * @param \Google\Protobuf\FieldMask $updateMask The FieldMask to use when updating the notification config. + * + * If empty all mutable fields will be updated. + * + * @return \Google\Cloud\SecurityCenter\V1\UpdateNotificationConfigRequest + * + * @experimental + */ + public static function buildFromNotificationConfigUpdateMask(\Google\Cloud\SecurityCenter\V1\NotificationConfig $notificationConfig, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setNotificationConfig($notificationConfig) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1\NotificationConfig $notification_config + * Required. The notification config to update. + * @type \Google\Protobuf\FieldMask $update_mask + * The FieldMask to use when updating the notification config. + * If empty all mutable fields will be updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The notification config to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.NotificationConfig notification_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1\NotificationConfig|null + */ + public function getNotificationConfig() + { + return $this->notification_config; + } + + public function hasNotificationConfig() + { + return isset($this->notification_config); + } + + public function clearNotificationConfig() + { + unset($this->notification_config); + } + + /** + * Required. The notification config to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.NotificationConfig notification_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1\NotificationConfig $var + * @return $this + */ + public function setNotificationConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\NotificationConfig::class); + $this->notification_config = $var; + + return $this; + } + + /** + * The FieldMask to use when updating the notification config. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The FieldMask to use when updating the notification config. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateOrganizationSettingsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateOrganizationSettingsRequest.php new file mode 100644 index 000000000000..57cf776c0bef --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateOrganizationSettingsRequest.php @@ -0,0 +1,138 @@ +google.cloud.securitycenter.v1.UpdateOrganizationSettingsRequest + */ +class UpdateOrganizationSettingsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The organization settings resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.OrganizationSettings organization_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $organization_settings = null; + /** + * The FieldMask to use when updating the settings resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * @param \Google\Cloud\SecurityCenter\V1\OrganizationSettings $organizationSettings Required. The organization settings resource to update. + * + * @return \Google\Cloud\SecurityCenter\V1\UpdateOrganizationSettingsRequest + * + * @experimental + */ + public static function build(\Google\Cloud\SecurityCenter\V1\OrganizationSettings $organizationSettings): self + { + return (new self()) + ->setOrganizationSettings($organizationSettings); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1\OrganizationSettings $organization_settings + * Required. The organization settings resource to update. + * @type \Google\Protobuf\FieldMask $update_mask + * The FieldMask to use when updating the settings resource. + * If empty all mutable fields will be updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The organization settings resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.OrganizationSettings organization_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1\OrganizationSettings|null + */ + public function getOrganizationSettings() + { + return $this->organization_settings; + } + + public function hasOrganizationSettings() + { + return isset($this->organization_settings); + } + + public function clearOrganizationSettings() + { + unset($this->organization_settings); + } + + /** + * Required. The organization settings resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.OrganizationSettings organization_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1\OrganizationSettings $var + * @return $this + */ + public function setOrganizationSettings($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\OrganizationSettings::class); + $this->organization_settings = $var; + + return $this; + } + + /** + * The FieldMask to use when updating the settings resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The FieldMask to use when updating the settings resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSecurityHealthAnalyticsCustomModuleRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSecurityHealthAnalyticsCustomModuleRequest.php new file mode 100644 index 000000000000..5d08afcbd681 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSecurityHealthAnalyticsCustomModuleRequest.php @@ -0,0 +1,136 @@ +google.cloud.securitycenter.v1.UpdateSecurityHealthAnalyticsCustomModuleRequest + */ +class UpdateSecurityHealthAnalyticsCustomModuleRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The SecurityHealthAnalytics custom module to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_module = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $security_health_analytics_custom_module = null; + /** + * The list of fields to update. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * @param \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule $securityHealthAnalyticsCustomModule Required. The SecurityHealthAnalytics custom module to update. + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to update. + * + * @return \Google\Cloud\SecurityCenter\V1\UpdateSecurityHealthAnalyticsCustomModuleRequest + * + * @experimental + */ + public static function build(\Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule $securityHealthAnalyticsCustomModule, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule $security_health_analytics_custom_module + * Required. The SecurityHealthAnalytics custom module to update. + * @type \Google\Protobuf\FieldMask $update_mask + * The list of fields to update. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The SecurityHealthAnalytics custom module to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_module = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule|null + */ + public function getSecurityHealthAnalyticsCustomModule() + { + return $this->security_health_analytics_custom_module; + } + + public function hasSecurityHealthAnalyticsCustomModule() + { + return isset($this->security_health_analytics_custom_module); + } + + public function clearSecurityHealthAnalyticsCustomModule() + { + unset($this->security_health_analytics_custom_module); + } + + /** + * Required. The SecurityHealthAnalytics custom module to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_module = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule $var + * @return $this + */ + public function setSecurityHealthAnalyticsCustomModule($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule::class); + $this->security_health_analytics_custom_module = $var; + + return $this; + } + + /** + * The list of fields to update. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The list of fields to update. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSecurityMarksRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSecurityMarksRequest.php new file mode 100644 index 000000000000..25ecb2d7b10e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSecurityMarksRequest.php @@ -0,0 +1,202 @@ +google.cloud.securitycenter.v1.UpdateSecurityMarksRequest + */ +class UpdateSecurityMarksRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The security marks resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityMarks security_marks = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $security_marks = null; + /** + * The FieldMask to use when updating the security marks resource. + * The field mask must not contain duplicate fields. + * If empty or set to "marks", all marks will be replaced. Individual + * marks can be updated using "marks.". + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + /** + * The time at which the updated SecurityMarks take effect. + * If not set uses current server time. Updates will be applied to the + * SecurityMarks that are active immediately preceding this time. Must be + * earlier or equal to the server time. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 3; + */ + protected $start_time = null; + + /** + * @param \Google\Cloud\SecurityCenter\V1\SecurityMarks $securityMarks Required. The security marks resource to update. + * + * @return \Google\Cloud\SecurityCenter\V1\UpdateSecurityMarksRequest + * + * @experimental + */ + public static function build(\Google\Cloud\SecurityCenter\V1\SecurityMarks $securityMarks): self + { + return (new self()) + ->setSecurityMarks($securityMarks); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1\SecurityMarks $security_marks + * Required. The security marks resource to update. + * @type \Google\Protobuf\FieldMask $update_mask + * The FieldMask to use when updating the security marks resource. + * The field mask must not contain duplicate fields. + * If empty or set to "marks", all marks will be replaced. Individual + * marks can be updated using "marks.". + * @type \Google\Protobuf\Timestamp $start_time + * The time at which the updated SecurityMarks take effect. + * If not set uses current server time. Updates will be applied to the + * SecurityMarks that are active immediately preceding this time. Must be + * earlier or equal to the server time. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The security marks resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityMarks security_marks = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1\SecurityMarks|null + */ + public function getSecurityMarks() + { + return $this->security_marks; + } + + public function hasSecurityMarks() + { + return isset($this->security_marks); + } + + public function clearSecurityMarks() + { + unset($this->security_marks); + } + + /** + * Required. The security marks resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityMarks security_marks = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1\SecurityMarks $var + * @return $this + */ + public function setSecurityMarks($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SecurityMarks::class); + $this->security_marks = $var; + + return $this; + } + + /** + * The FieldMask to use when updating the security marks resource. + * The field mask must not contain duplicate fields. + * If empty or set to "marks", all marks will be replaced. Individual + * marks can be updated using "marks.". + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The FieldMask to use when updating the security marks resource. + * The field mask must not contain duplicate fields. + * If empty or set to "marks", all marks will be replaced. Individual + * marks can be updated using "marks.". + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + + /** + * The time at which the updated SecurityMarks take effect. + * If not set uses current server time. Updates will be applied to the + * SecurityMarks that are active immediately preceding this time. Must be + * earlier or equal to the server time. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 3; + * @return \Google\Protobuf\Timestamp|null + */ + public function getStartTime() + { + return $this->start_time; + } + + public function hasStartTime() + { + return isset($this->start_time); + } + + public function clearStartTime() + { + unset($this->start_time); + } + + /** + * The time at which the updated SecurityMarks take effect. + * If not set uses current server time. Updates will be applied to the + * SecurityMarks that are active immediately preceding this time. Must be + * earlier or equal to the server time. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 3; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setStartTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->start_time = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSourceRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSourceRequest.php new file mode 100644 index 000000000000..5556e978062e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSourceRequest.php @@ -0,0 +1,138 @@ +google.cloud.securitycenter.v1.UpdateSourceRequest + */ +class UpdateSourceRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The source resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Source source = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $source = null; + /** + * The FieldMask to use when updating the source resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * @param \Google\Cloud\SecurityCenter\V1\Source $source Required. The source resource to update. + * + * @return \Google\Cloud\SecurityCenter\V1\UpdateSourceRequest + * + * @experimental + */ + public static function build(\Google\Cloud\SecurityCenter\V1\Source $source): self + { + return (new self()) + ->setSource($source); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1\Source $source + * Required. The source resource to update. + * @type \Google\Protobuf\FieldMask $update_mask + * The FieldMask to use when updating the source resource. + * If empty all mutable fields will be updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The source resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Source source = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1\Source|null + */ + public function getSource() + { + return $this->source; + } + + public function hasSource() + { + return isset($this->source); + } + + public function clearSource() + { + unset($this->source); + } + + /** + * Required. The source resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Source source = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1\Source $var + * @return $this + */ + public function setSource($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Source::class); + $this->source = $var; + + return $this; + } + + /** + * The FieldMask to use when updating the source resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The FieldMask to use when updating the source resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Vulnerability.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Vulnerability.php new file mode 100644 index 000000000000..961cb0210a9e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Vulnerability.php @@ -0,0 +1,213 @@ +google.cloud.securitycenter.v1.Vulnerability + */ +class Vulnerability extends \Google\Protobuf\Internal\Message +{ + /** + * CVE stands for Common Vulnerabilities and Exposures + * (https://cve.mitre.org/about/) + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cve cve = 1; + */ + protected $cve = null; + /** + * The offending package is relevant to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Package offending_package = 2; + */ + protected $offending_package = null; + /** + * The fixed package is relevant to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Package fixed_package = 3; + */ + protected $fixed_package = null; + /** + * The security bulletin is relevant to this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityBulletin security_bulletin = 4; + */ + protected $security_bulletin = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1\Cve $cve + * CVE stands for Common Vulnerabilities and Exposures + * (https://cve.mitre.org/about/) + * @type \Google\Cloud\SecurityCenter\V1\Package $offending_package + * The offending package is relevant to the finding. + * @type \Google\Cloud\SecurityCenter\V1\Package $fixed_package + * The fixed package is relevant to the finding. + * @type \Google\Cloud\SecurityCenter\V1\SecurityBulletin $security_bulletin + * The security bulletin is relevant to this finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1\Vulnerability::initOnce(); + parent::__construct($data); + } + + /** + * CVE stands for Common Vulnerabilities and Exposures + * (https://cve.mitre.org/about/) + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cve cve = 1; + * @return \Google\Cloud\SecurityCenter\V1\Cve|null + */ + public function getCve() + { + return $this->cve; + } + + public function hasCve() + { + return isset($this->cve); + } + + public function clearCve() + { + unset($this->cve); + } + + /** + * CVE stands for Common Vulnerabilities and Exposures + * (https://cve.mitre.org/about/) + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Cve cve = 1; + * @param \Google\Cloud\SecurityCenter\V1\Cve $var + * @return $this + */ + public function setCve($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Cve::class); + $this->cve = $var; + + return $this; + } + + /** + * The offending package is relevant to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Package offending_package = 2; + * @return \Google\Cloud\SecurityCenter\V1\Package|null + */ + public function getOffendingPackage() + { + return $this->offending_package; + } + + public function hasOffendingPackage() + { + return isset($this->offending_package); + } + + public function clearOffendingPackage() + { + unset($this->offending_package); + } + + /** + * The offending package is relevant to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Package offending_package = 2; + * @param \Google\Cloud\SecurityCenter\V1\Package $var + * @return $this + */ + public function setOffendingPackage($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Package::class); + $this->offending_package = $var; + + return $this; + } + + /** + * The fixed package is relevant to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Package fixed_package = 3; + * @return \Google\Cloud\SecurityCenter\V1\Package|null + */ + public function getFixedPackage() + { + return $this->fixed_package; + } + + public function hasFixedPackage() + { + return isset($this->fixed_package); + } + + public function clearFixedPackage() + { + unset($this->fixed_package); + } + + /** + * The fixed package is relevant to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.Package fixed_package = 3; + * @param \Google\Cloud\SecurityCenter\V1\Package $var + * @return $this + */ + public function setFixedPackage($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Package::class); + $this->fixed_package = $var; + + return $this; + } + + /** + * The security bulletin is relevant to this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityBulletin security_bulletin = 4; + * @return \Google\Cloud\SecurityCenter\V1\SecurityBulletin|null + */ + public function getSecurityBulletin() + { + return $this->security_bulletin; + } + + public function hasSecurityBulletin() + { + return isset($this->security_bulletin); + } + + public function clearSecurityBulletin() + { + unset($this->security_bulletin); + } + + /** + * The security bulletin is relevant to this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityBulletin security_bulletin = 4; + * @param \Google\Cloud\SecurityCenter\V1\SecurityBulletin $var + * @return $this + */ + public function setSecurityBulletin($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SecurityBulletin::class); + $this->security_bulletin = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/bulk_mute_findings.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/bulk_mute_findings.php new file mode 100644 index 000000000000..80feebddbebc --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/bulk_mute_findings.php @@ -0,0 +1,86 @@ +setParent($parent); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $securityCenterClient->bulkMuteFindings($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var BulkMuteFindingsResponse $result */ + $result = $response->getResult(); + printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString()); + } else { + /** @var Status $error */ + $error = $response->getError(); + printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $parent = '[PARENT]'; + + bulk_mute_findings_sample($parent); +} +// [END securitycenter_v1_generated_SecurityCenter_BulkMuteFindings_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_big_query_export.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_big_query_export.php new file mode 100644 index 000000000000..fdd1f5ab23eb --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_big_query_export.php @@ -0,0 +1,81 @@ +setParent($formattedParent) + ->setBigQueryExport($bigQueryExport) + ->setBigQueryExportId($bigQueryExportId); + + // Call the API and handle any network failures. + try { + /** @var BigQueryExport $response */ + $response = $securityCenterClient->createBigQueryExport($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); + $bigQueryExportId = '[BIG_QUERY_EXPORT_ID]'; + + create_big_query_export_sample($formattedParent, $bigQueryExportId); +} +// [END securitycenter_v1_generated_SecurityCenter_CreateBigQueryExport_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_finding.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_finding.php new file mode 100644 index 000000000000..dc2277172523 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_finding.php @@ -0,0 +1,80 @@ +setParent($formattedParent) + ->setFindingId($findingId) + ->setFinding($finding); + + // Call the API and handle any network failures. + try { + /** @var Finding $response */ + $response = $securityCenterClient->createFinding($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); + $findingId = '[FINDING_ID]'; + + create_finding_sample($formattedParent, $findingId); +} +// [END securitycenter_v1_generated_SecurityCenter_CreateFinding_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_mute_config.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_mute_config.php new file mode 100644 index 000000000000..70bd67210518 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_mute_config.php @@ -0,0 +1,106 @@ +setFilter($muteConfigFilter); + $request = (new CreateMuteConfigRequest()) + ->setParent($formattedParent) + ->setMuteConfig($muteConfig) + ->setMuteConfigId($muteConfigId); + + // Call the API and handle any network failures. + try { + /** @var MuteConfig $response */ + $response = $securityCenterClient->createMuteConfig($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); + $muteConfigFilter = '[FILTER]'; + $muteConfigId = '[MUTE_CONFIG_ID]'; + + create_mute_config_sample($formattedParent, $muteConfigFilter, $muteConfigId); +} +// [END securitycenter_v1_generated_SecurityCenter_CreateMuteConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_notification_config.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_notification_config.php new file mode 100644 index 000000000000..aa00064b0625 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_notification_config.php @@ -0,0 +1,81 @@ +setParent($formattedParent) + ->setConfigId($configId) + ->setNotificationConfig($notificationConfig); + + // Call the API and handle any network failures. + try { + /** @var NotificationConfig $response */ + $response = $securityCenterClient->createNotificationConfig($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); + $configId = '[CONFIG_ID]'; + + create_notification_config_sample($formattedParent, $configId); +} +// [END securitycenter_v1_generated_SecurityCenter_CreateNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_security_health_analytics_custom_module.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_security_health_analytics_custom_module.php new file mode 100644 index 000000000000..442f66ce7363 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_security_health_analytics_custom_module.php @@ -0,0 +1,79 @@ +setParent($formattedParent) + ->setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); + + // Call the API and handle any network failures. + try { + /** @var SecurityHealthAnalyticsCustomModule $response */ + $response = $securityCenterClient->createSecurityHealthAnalyticsCustomModule($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + + create_security_health_analytics_custom_module_sample($formattedParent); +} +// [END securitycenter_v1_generated_SecurityCenter_CreateSecurityHealthAnalyticsCustomModule_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_source.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_source.php new file mode 100644 index 000000000000..bddbfa2e99bc --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_source.php @@ -0,0 +1,74 @@ +setParent($formattedParent) + ->setSource($source); + + // Call the API and handle any network failures. + try { + /** @var Source $response */ + $response = $securityCenterClient->createSource($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::organizationName('[ORGANIZATION]'); + + create_source_sample($formattedParent); +} +// [END securitycenter_v1_generated_SecurityCenter_CreateSource_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_big_query_export.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_big_query_export.php new file mode 100644 index 000000000000..1930b7c0678c --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_big_query_export.php @@ -0,0 +1,72 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + $securityCenterClient->deleteBigQueryExport($request); + printf('Call completed successfully.' . PHP_EOL); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); + + delete_big_query_export_sample($formattedName); +} +// [END securitycenter_v1_generated_SecurityCenter_DeleteBigQueryExport_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_mute_config.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_mute_config.php new file mode 100644 index 000000000000..375bafb853e6 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_mute_config.php @@ -0,0 +1,72 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + $securityCenterClient->deleteMuteConfig($request); + printf('Call completed successfully.' . PHP_EOL); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); + + delete_mute_config_sample($formattedName); +} +// [END securitycenter_v1_generated_SecurityCenter_DeleteMuteConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_notification_config.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_notification_config.php new file mode 100644 index 000000000000..a4532eb5eb2c --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_notification_config.php @@ -0,0 +1,75 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + $securityCenterClient->deleteNotificationConfig($request); + printf('Call completed successfully.' . PHP_EOL); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::notificationConfigName( + '[ORGANIZATION]', + '[NOTIFICATION_CONFIG]' + ); + + delete_notification_config_sample($formattedName); +} +// [END securitycenter_v1_generated_SecurityCenter_DeleteNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_security_health_analytics_custom_module.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_security_health_analytics_custom_module.php new file mode 100644 index 000000000000..0285b1386476 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_security_health_analytics_custom_module.php @@ -0,0 +1,78 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + $securityCenterClient->deleteSecurityHealthAnalyticsCustomModule($request); + printf('Call completed successfully.' . PHP_EOL); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::securityHealthAnalyticsCustomModuleName( + '[ORGANIZATION]', + '[CUSTOM_MODULE]' + ); + + delete_security_health_analytics_custom_module_sample($formattedName); +} +// [END securitycenter_v1_generated_SecurityCenter_DeleteSecurityHealthAnalyticsCustomModule_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_big_query_export.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_big_query_export.php new file mode 100644 index 000000000000..955db018e902 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_big_query_export.php @@ -0,0 +1,74 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var BigQueryExport $response */ + $response = $securityCenterClient->getBigQueryExport($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); + + get_big_query_export_sample($formattedName); +} +// [END securitycenter_v1_generated_SecurityCenter_GetBigQueryExport_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_effective_security_health_analytics_custom_module.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_effective_security_health_analytics_custom_module.php new file mode 100644 index 000000000000..c6ba7eb70944 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_effective_security_health_analytics_custom_module.php @@ -0,0 +1,78 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var EffectiveSecurityHealthAnalyticsCustomModule $response */ + $response = $securityCenterClient->getEffectiveSecurityHealthAnalyticsCustomModule($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::effectiveSecurityHealthAnalyticsCustomModuleName( + '[ORGANIZATION]', + '[EFFECTIVE_CUSTOM_MODULE]' + ); + + get_effective_security_health_analytics_custom_module_sample($formattedName); +} +// [END securitycenter_v1_generated_SecurityCenter_GetEffectiveSecurityHealthAnalyticsCustomModule_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_iam_policy.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_iam_policy.php new file mode 100644 index 000000000000..3ffb39b0d6d6 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_iam_policy.php @@ -0,0 +1,71 @@ +setResource($resource); + + // Call the API and handle any network failures. + try { + /** @var Policy $response */ + $response = $securityCenterClient->getIamPolicy($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $resource = '[RESOURCE]'; + + get_iam_policy_sample($resource); +} +// [END securitycenter_v1_generated_SecurityCenter_GetIamPolicy_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_mute_config.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_mute_config.php new file mode 100644 index 000000000000..99477532741d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_mute_config.php @@ -0,0 +1,74 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var MuteConfig $response */ + $response = $securityCenterClient->getMuteConfig($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); + + get_mute_config_sample($formattedName); +} +// [END securitycenter_v1_generated_SecurityCenter_GetMuteConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_notification_config.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_notification_config.php new file mode 100644 index 000000000000..564c7cf8540b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_notification_config.php @@ -0,0 +1,77 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var NotificationConfig $response */ + $response = $securityCenterClient->getNotificationConfig($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::notificationConfigName( + '[ORGANIZATION]', + '[NOTIFICATION_CONFIG]' + ); + + get_notification_config_sample($formattedName); +} +// [END securitycenter_v1_generated_SecurityCenter_GetNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_organization_settings.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_organization_settings.php new file mode 100644 index 000000000000..dfc3175045d1 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_organization_settings.php @@ -0,0 +1,72 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OrganizationSettings $response */ + $response = $securityCenterClient->getOrganizationSettings($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::organizationSettingsName('[ORGANIZATION]'); + + get_organization_settings_sample($formattedName); +} +// [END securitycenter_v1_generated_SecurityCenter_GetOrganizationSettings_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_security_health_analytics_custom_module.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_security_health_analytics_custom_module.php new file mode 100644 index 000000000000..9c9bea04f859 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_security_health_analytics_custom_module.php @@ -0,0 +1,78 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var SecurityHealthAnalyticsCustomModule $response */ + $response = $securityCenterClient->getSecurityHealthAnalyticsCustomModule($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::securityHealthAnalyticsCustomModuleName( + '[ORGANIZATION]', + '[CUSTOM_MODULE]' + ); + + get_security_health_analytics_custom_module_sample($formattedName); +} +// [END securitycenter_v1_generated_SecurityCenter_GetSecurityHealthAnalyticsCustomModule_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_source.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_source.php new file mode 100644 index 000000000000..b94b2259d9d9 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_source.php @@ -0,0 +1,72 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var Source $response */ + $response = $securityCenterClient->getSource($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); + + get_source_sample($formattedName); +} +// [END securitycenter_v1_generated_SecurityCenter_GetSource_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/group_assets.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/group_assets.php new file mode 100644 index 000000000000..43591738c3cf --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/group_assets.php @@ -0,0 +1,99 @@ +setParent($formattedParent) + ->setGroupBy($groupBy); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->groupAssets($request); + + /** @var GroupResult $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); + $groupBy = '[GROUP_BY]'; + + group_assets_sample($formattedParent, $groupBy); +} +// [END securitycenter_v1_generated_SecurityCenter_GroupAssets_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/group_findings.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/group_findings.php new file mode 100644 index 000000000000..5476ffe0cdcf --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/group_findings.php @@ -0,0 +1,105 @@ +setParent($formattedParent) + ->setGroupBy($groupBy); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->groupFindings($request); + + /** @var GroupResult $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); + $groupBy = '[GROUP_BY]'; + + group_findings_sample($formattedParent, $groupBy); +} +// [END securitycenter_v1_generated_SecurityCenter_GroupFindings_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_assets.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_assets.php new file mode 100644 index 000000000000..e7560d13a4f3 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_assets.php @@ -0,0 +1,80 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->listAssets($request); + + /** @var ListAssetsResult $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); + + list_assets_sample($formattedParent); +} +// [END securitycenter_v1_generated_SecurityCenter_ListAssets_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_big_query_exports.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_big_query_exports.php new file mode 100644 index 000000000000..b54603a1d336 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_big_query_exports.php @@ -0,0 +1,82 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->listBigQueryExports($request); + + /** @var BigQueryExport $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); + + list_big_query_exports_sample($formattedParent); +} +// [END securitycenter_v1_generated_SecurityCenter_ListBigQueryExports_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_descendant_security_health_analytics_custom_modules.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_descendant_security_health_analytics_custom_modules.php new file mode 100644 index 000000000000..d0257ba9ff25 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_descendant_security_health_analytics_custom_modules.php @@ -0,0 +1,81 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->listDescendantSecurityHealthAnalyticsCustomModules($request); + + /** @var SecurityHealthAnalyticsCustomModule $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + + list_descendant_security_health_analytics_custom_modules_sample($formattedParent); +} +// [END securitycenter_v1_generated_SecurityCenter_ListDescendantSecurityHealthAnalyticsCustomModules_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_effective_security_health_analytics_custom_modules.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_effective_security_health_analytics_custom_modules.php new file mode 100644 index 000000000000..2c6fcbbaeff1 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_effective_security_health_analytics_custom_modules.php @@ -0,0 +1,82 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->listEffectiveSecurityHealthAnalyticsCustomModules($request); + + /** @var EffectiveSecurityHealthAnalyticsCustomModule $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + + list_effective_security_health_analytics_custom_modules_sample($formattedParent); +} +// [END securitycenter_v1_generated_SecurityCenter_ListEffectiveSecurityHealthAnalyticsCustomModules_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_findings.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_findings.php new file mode 100644 index 000000000000..c786a7416e57 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_findings.php @@ -0,0 +1,85 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->listFindings($request); + + /** @var ListFindingsResult $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); + + list_findings_sample($formattedParent); +} +// [END securitycenter_v1_generated_SecurityCenter_ListFindings_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_mute_configs.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_mute_configs.php new file mode 100644 index 000000000000..65bc0f73a734 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_mute_configs.php @@ -0,0 +1,78 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->listMuteConfigs($request); + + /** @var MuteConfig $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); + + list_mute_configs_sample($formattedParent); +} +// [END securitycenter_v1_generated_SecurityCenter_ListMuteConfigs_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_notification_configs.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_notification_configs.php new file mode 100644 index 000000000000..be548b5de10f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_notification_configs.php @@ -0,0 +1,78 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->listNotificationConfigs($request); + + /** @var NotificationConfig $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); + + list_notification_configs_sample($formattedParent); +} +// [END securitycenter_v1_generated_SecurityCenter_ListNotificationConfigs_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_security_health_analytics_custom_modules.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_security_health_analytics_custom_modules.php new file mode 100644 index 000000000000..2f7e96bb712d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_security_health_analytics_custom_modules.php @@ -0,0 +1,81 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->listSecurityHealthAnalyticsCustomModules($request); + + /** @var SecurityHealthAnalyticsCustomModule $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + + list_security_health_analytics_custom_modules_sample($formattedParent); +} +// [END securitycenter_v1_generated_SecurityCenter_ListSecurityHealthAnalyticsCustomModules_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_sources.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_sources.php new file mode 100644 index 000000000000..95ec1a19185a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_sources.php @@ -0,0 +1,78 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->listSources($request); + + /** @var Source $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); + + list_sources_sample($formattedParent); +} +// [END securitycenter_v1_generated_SecurityCenter_ListSources_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/run_asset_discovery.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/run_asset_discovery.php new file mode 100644 index 000000000000..af586cf40157 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/run_asset_discovery.php @@ -0,0 +1,89 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $securityCenterClient->runAssetDiscovery($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var RunAssetDiscoveryResponse $result */ + $result = $response->getResult(); + printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString()); + } else { + /** @var Status $error */ + $error = $response->getError(); + printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::organizationName('[ORGANIZATION]'); + + run_asset_discovery_sample($formattedParent); +} +// [END securitycenter_v1_generated_SecurityCenter_RunAssetDiscovery_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_finding_state.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_finding_state.php new file mode 100644 index 000000000000..e9b370ef7502 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_finding_state.php @@ -0,0 +1,83 @@ +setName($formattedName) + ->setState($state) + ->setStartTime($startTime); + + // Call the API and handle any network failures. + try { + /** @var Finding $response */ + $response = $securityCenterClient->setFindingState($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + $state = State::STATE_UNSPECIFIED; + + set_finding_state_sample($formattedName, $state); +} +// [END securitycenter_v1_generated_SecurityCenter_SetFindingState_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_iam_policy.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_iam_policy.php new file mode 100644 index 000000000000..4ab864d1b55a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_iam_policy.php @@ -0,0 +1,73 @@ +setResource($resource) + ->setPolicy($policy); + + // Call the API and handle any network failures. + try { + /** @var Policy $response */ + $response = $securityCenterClient->setIamPolicy($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $resource = '[RESOURCE]'; + + set_iam_policy_sample($resource); +} +// [END securitycenter_v1_generated_SecurityCenter_SetIamPolicy_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_mute.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_mute.php new file mode 100644 index 000000000000..03a4c9a86b54 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_mute.php @@ -0,0 +1,80 @@ +setName($formattedName) + ->setMute($mute); + + // Call the API and handle any network failures. + try { + /** @var Finding $response */ + $response = $securityCenterClient->setMute($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + $mute = Mute::MUTE_UNSPECIFIED; + + set_mute_sample($formattedName, $mute); +} +// [END securitycenter_v1_generated_SecurityCenter_SetMute_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/simulate_security_health_analytics_custom_module.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/simulate_security_health_analytics_custom_module.php new file mode 100644 index 000000000000..1ba3284c5d28 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/simulate_security_health_analytics_custom_module.php @@ -0,0 +1,86 @@ +setResourceType($resourceResourceType); + $request = (new SimulateSecurityHealthAnalyticsCustomModuleRequest()) + ->setParent($parent) + ->setCustomConfig($customConfig) + ->setResource($resource); + + // Call the API and handle any network failures. + try { + /** @var SimulateSecurityHealthAnalyticsCustomModuleResponse $response */ + $response = $securityCenterClient->simulateSecurityHealthAnalyticsCustomModule($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $parent = '[PARENT]'; + $resourceResourceType = '[RESOURCE_TYPE]'; + + simulate_security_health_analytics_custom_module_sample($parent, $resourceResourceType); +} +// [END securitycenter_v1_generated_SecurityCenter_SimulateSecurityHealthAnalyticsCustomModule_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/test_iam_permissions.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/test_iam_permissions.php new file mode 100644 index 000000000000..307d0e363f5b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/test_iam_permissions.php @@ -0,0 +1,78 @@ +setResource($resource) + ->setPermissions($permissions); + + // Call the API and handle any network failures. + try { + /** @var TestIamPermissionsResponse $response */ + $response = $securityCenterClient->testIamPermissions($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $resource = '[RESOURCE]'; + $permissionsElement = '[PERMISSIONS]'; + + test_iam_permissions_sample($resource, $permissionsElement); +} +// [END securitycenter_v1_generated_SecurityCenter_TestIamPermissions_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_big_query_export.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_big_query_export.php new file mode 100644 index 000000000000..48f972ee0ae6 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_big_query_export.php @@ -0,0 +1,59 @@ +setBigQueryExport($bigQueryExport); + + // Call the API and handle any network failures. + try { + /** @var BigQueryExport $response */ + $response = $securityCenterClient->updateBigQueryExport($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END securitycenter_v1_generated_SecurityCenter_UpdateBigQueryExport_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_external_system.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_external_system.php new file mode 100644 index 000000000000..682b53415973 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_external_system.php @@ -0,0 +1,59 @@ +setExternalSystem($externalSystem); + + // Call the API and handle any network failures. + try { + /** @var ExternalSystem $response */ + $response = $securityCenterClient->updateExternalSystem($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END securitycenter_v1_generated_SecurityCenter_UpdateExternalSystem_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_finding.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_finding.php new file mode 100644 index 000000000000..c6f695d3246c --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_finding.php @@ -0,0 +1,60 @@ +setFinding($finding); + + // Call the API and handle any network failures. + try { + /** @var Finding $response */ + $response = $securityCenterClient->updateFinding($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END securitycenter_v1_generated_SecurityCenter_UpdateFinding_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_mute_config.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_mute_config.php new file mode 100644 index 000000000000..ae056f031403 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_mute_config.php @@ -0,0 +1,91 @@ +setFilter($muteConfigFilter); + $request = (new UpdateMuteConfigRequest()) + ->setMuteConfig($muteConfig); + + // Call the API and handle any network failures. + try { + /** @var MuteConfig $response */ + $response = $securityCenterClient->updateMuteConfig($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $muteConfigFilter = '[FILTER]'; + + update_mute_config_sample($muteConfigFilter); +} +// [END securitycenter_v1_generated_SecurityCenter_UpdateMuteConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_notification_config.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_notification_config.php new file mode 100644 index 000000000000..ec39139cb19e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_notification_config.php @@ -0,0 +1,61 @@ +setNotificationConfig($notificationConfig); + + // Call the API and handle any network failures. + try { + /** @var NotificationConfig $response */ + $response = $securityCenterClient->updateNotificationConfig($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END securitycenter_v1_generated_SecurityCenter_UpdateNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_organization_settings.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_organization_settings.php new file mode 100644 index 000000000000..4443cc5ed796 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_organization_settings.php @@ -0,0 +1,59 @@ +setOrganizationSettings($organizationSettings); + + // Call the API and handle any network failures. + try { + /** @var OrganizationSettings $response */ + $response = $securityCenterClient->updateOrganizationSettings($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END securitycenter_v1_generated_SecurityCenter_UpdateOrganizationSettings_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_security_health_analytics_custom_module.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_security_health_analytics_custom_module.php new file mode 100644 index 000000000000..24c2c65791fc --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_security_health_analytics_custom_module.php @@ -0,0 +1,63 @@ +setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); + + // Call the API and handle any network failures. + try { + /** @var SecurityHealthAnalyticsCustomModule $response */ + $response = $securityCenterClient->updateSecurityHealthAnalyticsCustomModule($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END securitycenter_v1_generated_SecurityCenter_UpdateSecurityHealthAnalyticsCustomModule_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_security_marks.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_security_marks.php new file mode 100644 index 000000000000..b6621f3eaea4 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_security_marks.php @@ -0,0 +1,59 @@ +setSecurityMarks($securityMarks); + + // Call the API and handle any network failures. + try { + /** @var SecurityMarks $response */ + $response = $securityCenterClient->updateSecurityMarks($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END securitycenter_v1_generated_SecurityCenter_UpdateSecurityMarks_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_source.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_source.php new file mode 100644 index 000000000000..61688c301805 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_source.php @@ -0,0 +1,59 @@ +setSource($source); + + // Call the API and handle any network failures. + try { + /** @var Source $response */ + $response = $securityCenterClient->updateSource($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END securitycenter_v1_generated_SecurityCenter_UpdateSource_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/src/V1/Client/SecurityCenterClient.php b/owl-bot-staging/SecurityCenter/v1/src/V1/Client/SecurityCenterClient.php new file mode 100644 index 000000000000..53ad9049aa0a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/src/V1/Client/SecurityCenterClient.php @@ -0,0 +1,2617 @@ + self::SERVICE_NAME, + 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, + 'clientConfig' => __DIR__ . '/../resources/security_center_client_config.json', + 'descriptorsConfigPath' => __DIR__ . '/../resources/security_center_descriptor_config.php', + 'gcpApiConfigPath' => __DIR__ . '/../resources/security_center_grpc_config.json', + 'credentialsConfig' => [ + 'defaultScopes' => self::$serviceScopes, + ], + 'transportConfig' => [ + 'rest' => [ + 'restClientConfigPath' => __DIR__ . '/../resources/security_center_rest_client_config.php', + ], + ], + ]; + } + + /** + * Return an OperationsClient object with the same endpoint as $this. + * + * @return OperationsClient + */ + public function getOperationsClient() + { + return $this->operationsClient; + } + + /** + * Resume an existing long running operation that was previously started by a long + * running API method. If $methodName is not provided, or does not match a long + * running API method, then the operation can still be resumed, but the + * OperationResponse object will not deserialize the final response. + * + * @param string $operationName The name of the long running operation + * @param string $methodName The name of the method used to start the operation + * + * @return OperationResponse + */ + public function resumeOperation($operationName, $methodName = null) + { + $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; + $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); + $operation->reload(); + return $operation; + } + + /** + * Formats a string containing the fully-qualified path to represent a + * big_query_export resource. + * + * @param string $organization + * @param string $export + * + * @return string The formatted big_query_export resource. + */ + public static function bigQueryExportName(string $organization, string $export): string + { + return self::getPathTemplate('bigQueryExport')->render([ + 'organization' => $organization, + 'export' => $export, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a dlp_job + * resource. + * + * @param string $project + * @param string $dlpJob + * + * @return string The formatted dlp_job resource. + */ + public static function dlpJobName(string $project, string $dlpJob): string + { + return self::getPathTemplate('dlpJob')->render([ + 'project' => $project, + 'dlp_job' => $dlpJob, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * effective_security_health_analytics_custom_module resource. + * + * @param string $organization + * @param string $effectiveCustomModule + * + * @return string The formatted effective_security_health_analytics_custom_module resource. + */ + public static function effectiveSecurityHealthAnalyticsCustomModuleName(string $organization, string $effectiveCustomModule): string + { + return self::getPathTemplate('effectiveSecurityHealthAnalyticsCustomModule')->render([ + 'organization' => $organization, + 'effective_custom_module' => $effectiveCustomModule, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * external_system resource. + * + * @param string $organization + * @param string $source + * @param string $finding + * @param string $externalsystem + * + * @return string The formatted external_system resource. + */ + public static function externalSystemName(string $organization, string $source, string $finding, string $externalsystem): string + { + return self::getPathTemplate('externalSystem')->render([ + 'organization' => $organization, + 'source' => $source, + 'finding' => $finding, + 'externalsystem' => $externalsystem, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a finding + * resource. + * + * @param string $organization + * @param string $source + * @param string $finding + * + * @return string The formatted finding resource. + */ + public static function findingName(string $organization, string $source, string $finding): string + { + return self::getPathTemplate('finding')->render([ + 'organization' => $organization, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a folder + * resource. + * + * @param string $folder + * + * @return string The formatted folder resource. + */ + public static function folderName(string $folder): string + { + return self::getPathTemplate('folder')->render([ + 'folder' => $folder, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_asset_securityMarks resource. + * + * @param string $folder + * @param string $asset + * + * @return string The formatted folder_asset_securityMarks resource. + */ + public static function folderAssetSecurityMarksName(string $folder, string $asset): string + { + return self::getPathTemplate('folderAssetSecurityMarks')->render([ + 'folder' => $folder, + 'asset' => $asset, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_constraint_name resource. + * + * @param string $folder + * @param string $constraintName + * + * @return string The formatted folder_constraint_name resource. + */ + public static function folderConstraintNameName(string $folder, string $constraintName): string + { + return self::getPathTemplate('folderConstraintName')->render([ + 'folder' => $folder, + 'constraint_name' => $constraintName, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_custom_module resource. + * + * @param string $folder + * @param string $customModule + * + * @return string The formatted folder_custom_module resource. + */ + public static function folderCustomModuleName(string $folder, string $customModule): string + { + return self::getPathTemplate('folderCustomModule')->render([ + 'folder' => $folder, + 'custom_module' => $customModule, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_effective_custom_module resource. + * + * @param string $folder + * @param string $effectiveCustomModule + * + * @return string The formatted folder_effective_custom_module resource. + */ + public static function folderEffectiveCustomModuleName(string $folder, string $effectiveCustomModule): string + { + return self::getPathTemplate('folderEffectiveCustomModule')->render([ + 'folder' => $folder, + 'effective_custom_module' => $effectiveCustomModule, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_export resource. + * + * @param string $folder + * @param string $export + * + * @return string The formatted folder_export resource. + */ + public static function folderExportName(string $folder, string $export): string + { + return self::getPathTemplate('folderExport')->render([ + 'folder' => $folder, + 'export' => $export, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_mute_config resource. + * + * @param string $folder + * @param string $muteConfig + * + * @return string The formatted folder_mute_config resource. + */ + public static function folderMuteConfigName(string $folder, string $muteConfig): string + { + return self::getPathTemplate('folderMuteConfig')->render([ + 'folder' => $folder, + 'mute_config' => $muteConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_notification_config resource. + * + * @param string $folder + * @param string $notificationConfig + * + * @return string The formatted folder_notification_config resource. + */ + public static function folderNotificationConfigName(string $folder, string $notificationConfig): string + { + return self::getPathTemplate('folderNotificationConfig')->render([ + 'folder' => $folder, + 'notification_config' => $notificationConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_securityHealthAnalyticsSettings resource. + * + * @param string $folder + * + * @return string The formatted folder_securityHealthAnalyticsSettings resource. + */ + public static function folderSecurityHealthAnalyticsSettingsName(string $folder): string + { + return self::getPathTemplate('folderSecurityHealthAnalyticsSettings')->render([ + 'folder' => $folder, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_source resource. + * + * @param string $folder + * @param string $source + * + * @return string The formatted folder_source resource. + */ + public static function folderSourceName(string $folder, string $source): string + { + return self::getPathTemplate('folderSource')->render([ + 'folder' => $folder, + 'source' => $source, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_source_finding resource. + * + * @param string $folder + * @param string $source + * @param string $finding + * + * @return string The formatted folder_source_finding resource. + */ + public static function folderSourceFindingName(string $folder, string $source, string $finding): string + { + return self::getPathTemplate('folderSourceFinding')->render([ + 'folder' => $folder, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_source_finding_externalsystem resource. + * + * @param string $folder + * @param string $source + * @param string $finding + * @param string $externalsystem + * + * @return string The formatted folder_source_finding_externalsystem resource. + */ + public static function folderSourceFindingExternalsystemName(string $folder, string $source, string $finding, string $externalsystem): string + { + return self::getPathTemplate('folderSourceFindingExternalsystem')->render([ + 'folder' => $folder, + 'source' => $source, + 'finding' => $finding, + 'externalsystem' => $externalsystem, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_source_finding_securityMarks resource. + * + * @param string $folder + * @param string $source + * @param string $finding + * + * @return string The formatted folder_source_finding_securityMarks resource. + */ + public static function folderSourceFindingSecurityMarksName(string $folder, string $source, string $finding): string + { + return self::getPathTemplate('folderSourceFindingSecurityMarks')->render([ + 'folder' => $folder, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a mute_config + * resource. + * + * @param string $organization + * @param string $muteConfig + * + * @return string The formatted mute_config resource. + */ + public static function muteConfigName(string $organization, string $muteConfig): string + { + return self::getPathTemplate('muteConfig')->render([ + 'organization' => $organization, + 'mute_config' => $muteConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * notification_config resource. + * + * @param string $organization + * @param string $notificationConfig + * + * @return string The formatted notification_config resource. + */ + public static function notificationConfigName(string $organization, string $notificationConfig): string + { + return self::getPathTemplate('notificationConfig')->render([ + 'organization' => $organization, + 'notification_config' => $notificationConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a organization + * resource. + * + * @param string $organization + * + * @return string The formatted organization resource. + */ + public static function organizationName(string $organization): string + { + return self::getPathTemplate('organization')->render([ + 'organization' => $organization, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_asset_securityMarks resource. + * + * @param string $organization + * @param string $asset + * + * @return string The formatted organization_asset_securityMarks resource. + */ + public static function organizationAssetSecurityMarksName(string $organization, string $asset): string + { + return self::getPathTemplate('organizationAssetSecurityMarks')->render([ + 'organization' => $organization, + 'asset' => $asset, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_constraint_name resource. + * + * @param string $organization + * @param string $constraintName + * + * @return string The formatted organization_constraint_name resource. + */ + public static function organizationConstraintNameName(string $organization, string $constraintName): string + { + return self::getPathTemplate('organizationConstraintName')->render([ + 'organization' => $organization, + 'constraint_name' => $constraintName, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_custom_module resource. + * + * @param string $organization + * @param string $customModule + * + * @return string The formatted organization_custom_module resource. + */ + public static function organizationCustomModuleName(string $organization, string $customModule): string + { + return self::getPathTemplate('organizationCustomModule')->render([ + 'organization' => $organization, + 'custom_module' => $customModule, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_effective_custom_module resource. + * + * @param string $organization + * @param string $effectiveCustomModule + * + * @return string The formatted organization_effective_custom_module resource. + */ + public static function organizationEffectiveCustomModuleName(string $organization, string $effectiveCustomModule): string + { + return self::getPathTemplate('organizationEffectiveCustomModule')->render([ + 'organization' => $organization, + 'effective_custom_module' => $effectiveCustomModule, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_export resource. + * + * @param string $organization + * @param string $export + * + * @return string The formatted organization_export resource. + */ + public static function organizationExportName(string $organization, string $export): string + { + return self::getPathTemplate('organizationExport')->render([ + 'organization' => $organization, + 'export' => $export, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_mute_config resource. + * + * @param string $organization + * @param string $muteConfig + * + * @return string The formatted organization_mute_config resource. + */ + public static function organizationMuteConfigName(string $organization, string $muteConfig): string + { + return self::getPathTemplate('organizationMuteConfig')->render([ + 'organization' => $organization, + 'mute_config' => $muteConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_notification_config resource. + * + * @param string $organization + * @param string $notificationConfig + * + * @return string The formatted organization_notification_config resource. + */ + public static function organizationNotificationConfigName(string $organization, string $notificationConfig): string + { + return self::getPathTemplate('organizationNotificationConfig')->render([ + 'organization' => $organization, + 'notification_config' => $notificationConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_securityHealthAnalyticsSettings resource. + * + * @param string $organization + * + * @return string The formatted organization_securityHealthAnalyticsSettings resource. + */ + public static function organizationSecurityHealthAnalyticsSettingsName(string $organization): string + { + return self::getPathTemplate('organizationSecurityHealthAnalyticsSettings')->render([ + 'organization' => $organization, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_settings resource. + * + * @param string $organization + * + * @return string The formatted organization_settings resource. + */ + public static function organizationSettingsName(string $organization): string + { + return self::getPathTemplate('organizationSettings')->render([ + 'organization' => $organization, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_source resource. + * + * @param string $organization + * @param string $source + * + * @return string The formatted organization_source resource. + */ + public static function organizationSourceName(string $organization, string $source): string + { + return self::getPathTemplate('organizationSource')->render([ + 'organization' => $organization, + 'source' => $source, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_source_finding resource. + * + * @param string $organization + * @param string $source + * @param string $finding + * + * @return string The formatted organization_source_finding resource. + */ + public static function organizationSourceFindingName(string $organization, string $source, string $finding): string + { + return self::getPathTemplate('organizationSourceFinding')->render([ + 'organization' => $organization, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_source_finding_externalsystem resource. + * + * @param string $organization + * @param string $source + * @param string $finding + * @param string $externalsystem + * + * @return string The formatted organization_source_finding_externalsystem resource. + */ + public static function organizationSourceFindingExternalsystemName(string $organization, string $source, string $finding, string $externalsystem): string + { + return self::getPathTemplate('organizationSourceFindingExternalsystem')->render([ + 'organization' => $organization, + 'source' => $source, + 'finding' => $finding, + 'externalsystem' => $externalsystem, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_source_finding_securityMarks resource. + * + * @param string $organization + * @param string $source + * @param string $finding + * + * @return string The formatted organization_source_finding_securityMarks resource. + */ + public static function organizationSourceFindingSecurityMarksName(string $organization, string $source, string $finding): string + { + return self::getPathTemplate('organizationSourceFindingSecurityMarks')->render([ + 'organization' => $organization, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a policy + * resource. + * + * @param string $organization + * @param string $constraintName + * + * @return string The formatted policy resource. + */ + public static function policyName(string $organization, string $constraintName): string + { + return self::getPathTemplate('policy')->render([ + 'organization' => $organization, + 'constraint_name' => $constraintName, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a project + * resource. + * + * @param string $project + * + * @return string The formatted project resource. + */ + public static function projectName(string $project): string + { + return self::getPathTemplate('project')->render([ + 'project' => $project, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_asset_securityMarks resource. + * + * @param string $project + * @param string $asset + * + * @return string The formatted project_asset_securityMarks resource. + */ + public static function projectAssetSecurityMarksName(string $project, string $asset): string + { + return self::getPathTemplate('projectAssetSecurityMarks')->render([ + 'project' => $project, + 'asset' => $asset, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_constraint_name resource. + * + * @param string $project + * @param string $constraintName + * + * @return string The formatted project_constraint_name resource. + */ + public static function projectConstraintNameName(string $project, string $constraintName): string + { + return self::getPathTemplate('projectConstraintName')->render([ + 'project' => $project, + 'constraint_name' => $constraintName, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_custom_module resource. + * + * @param string $project + * @param string $customModule + * + * @return string The formatted project_custom_module resource. + */ + public static function projectCustomModuleName(string $project, string $customModule): string + { + return self::getPathTemplate('projectCustomModule')->render([ + 'project' => $project, + 'custom_module' => $customModule, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_dlp_job resource. + * + * @param string $project + * @param string $dlpJob + * + * @return string The formatted project_dlp_job resource. + */ + public static function projectDlpJobName(string $project, string $dlpJob): string + { + return self::getPathTemplate('projectDlpJob')->render([ + 'project' => $project, + 'dlp_job' => $dlpJob, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_effective_custom_module resource. + * + * @param string $project + * @param string $effectiveCustomModule + * + * @return string The formatted project_effective_custom_module resource. + */ + public static function projectEffectiveCustomModuleName(string $project, string $effectiveCustomModule): string + { + return self::getPathTemplate('projectEffectiveCustomModule')->render([ + 'project' => $project, + 'effective_custom_module' => $effectiveCustomModule, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_export resource. + * + * @param string $project + * @param string $export + * + * @return string The formatted project_export resource. + */ + public static function projectExportName(string $project, string $export): string + { + return self::getPathTemplate('projectExport')->render([ + 'project' => $project, + 'export' => $export, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_dlp_job resource. + * + * @param string $project + * @param string $location + * @param string $dlpJob + * + * @return string The formatted project_location_dlp_job resource. + */ + public static function projectLocationDlpJobName(string $project, string $location, string $dlpJob): string + { + return self::getPathTemplate('projectLocationDlpJob')->render([ + 'project' => $project, + 'location' => $location, + 'dlp_job' => $dlpJob, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_table_profile resource. + * + * @param string $project + * @param string $location + * @param string $tableProfile + * + * @return string The formatted project_location_table_profile resource. + */ + public static function projectLocationTableProfileName(string $project, string $location, string $tableProfile): string + { + return self::getPathTemplate('projectLocationTableProfile')->render([ + 'project' => $project, + 'location' => $location, + 'table_profile' => $tableProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_mute_config resource. + * + * @param string $project + * @param string $muteConfig + * + * @return string The formatted project_mute_config resource. + */ + public static function projectMuteConfigName(string $project, string $muteConfig): string + { + return self::getPathTemplate('projectMuteConfig')->render([ + 'project' => $project, + 'mute_config' => $muteConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_notification_config resource. + * + * @param string $project + * @param string $notificationConfig + * + * @return string The formatted project_notification_config resource. + */ + public static function projectNotificationConfigName(string $project, string $notificationConfig): string + { + return self::getPathTemplate('projectNotificationConfig')->render([ + 'project' => $project, + 'notification_config' => $notificationConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_securityHealthAnalyticsSettings resource. + * + * @param string $project + * + * @return string The formatted project_securityHealthAnalyticsSettings resource. + */ + public static function projectSecurityHealthAnalyticsSettingsName(string $project): string + { + return self::getPathTemplate('projectSecurityHealthAnalyticsSettings')->render([ + 'project' => $project, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_source resource. + * + * @param string $project + * @param string $source + * + * @return string The formatted project_source resource. + */ + public static function projectSourceName(string $project, string $source): string + { + return self::getPathTemplate('projectSource')->render([ + 'project' => $project, + 'source' => $source, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_source_finding resource. + * + * @param string $project + * @param string $source + * @param string $finding + * + * @return string The formatted project_source_finding resource. + */ + public static function projectSourceFindingName(string $project, string $source, string $finding): string + { + return self::getPathTemplate('projectSourceFinding')->render([ + 'project' => $project, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_source_finding_externalsystem resource. + * + * @param string $project + * @param string $source + * @param string $finding + * @param string $externalsystem + * + * @return string The formatted project_source_finding_externalsystem resource. + */ + public static function projectSourceFindingExternalsystemName(string $project, string $source, string $finding, string $externalsystem): string + { + return self::getPathTemplate('projectSourceFindingExternalsystem')->render([ + 'project' => $project, + 'source' => $source, + 'finding' => $finding, + 'externalsystem' => $externalsystem, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_source_finding_securityMarks resource. + * + * @param string $project + * @param string $source + * @param string $finding + * + * @return string The formatted project_source_finding_securityMarks resource. + */ + public static function projectSourceFindingSecurityMarksName(string $project, string $source, string $finding): string + { + return self::getPathTemplate('projectSourceFindingSecurityMarks')->render([ + 'project' => $project, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_table_profile resource. + * + * @param string $project + * @param string $tableProfile + * + * @return string The formatted project_table_profile resource. + */ + public static function projectTableProfileName(string $project, string $tableProfile): string + { + return self::getPathTemplate('projectTableProfile')->render([ + 'project' => $project, + 'table_profile' => $tableProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * security_health_analytics_custom_module resource. + * + * @param string $organization + * @param string $customModule + * + * @return string The formatted security_health_analytics_custom_module resource. + */ + public static function securityHealthAnalyticsCustomModuleName(string $organization, string $customModule): string + { + return self::getPathTemplate('securityHealthAnalyticsCustomModule')->render([ + 'organization' => $organization, + 'custom_module' => $customModule, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * security_health_analytics_settings resource. + * + * @param string $organization + * + * @return string The formatted security_health_analytics_settings resource. + */ + public static function securityHealthAnalyticsSettingsName(string $organization): string + { + return self::getPathTemplate('securityHealthAnalyticsSettings')->render([ + 'organization' => $organization, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * security_marks resource. + * + * @param string $organization + * @param string $asset + * + * @return string The formatted security_marks resource. + */ + public static function securityMarksName(string $organization, string $asset): string + { + return self::getPathTemplate('securityMarks')->render([ + 'organization' => $organization, + 'asset' => $asset, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a source + * resource. + * + * @param string $organization + * @param string $source + * + * @return string The formatted source resource. + */ + public static function sourceName(string $organization, string $source): string + { + return self::getPathTemplate('source')->render([ + 'organization' => $organization, + 'source' => $source, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * table_data_profile resource. + * + * @param string $project + * @param string $tableProfile + * + * @return string The formatted table_data_profile resource. + */ + public static function tableDataProfileName(string $project, string $tableProfile): string + { + return self::getPathTemplate('tableDataProfile')->render([ + 'project' => $project, + 'table_profile' => $tableProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a topic + * resource. + * + * @param string $project + * @param string $topic + * + * @return string The formatted topic resource. + */ + public static function topicName(string $project, string $topic): string + { + return self::getPathTemplate('topic')->render([ + 'project' => $project, + 'topic' => $topic, + ]); + } + + /** + * Parses a formatted name string and returns an associative array of the components in the name. + * The following name formats are supported: + * Template: Pattern + * - bigQueryExport: organizations/{organization}/bigQueryExports/{export} + * - dlpJob: projects/{project}/dlpJobs/{dlp_job} + * - effectiveSecurityHealthAnalyticsCustomModule: organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module} + * - externalSystem: organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} + * - finding: organizations/{organization}/sources/{source}/findings/{finding} + * - folder: folders/{folder} + * - folderAssetSecurityMarks: folders/{folder}/assets/{asset}/securityMarks + * - folderConstraintName: folders/{folder}/policies/{constraint_name} + * - folderCustomModule: folders/{folder}/securityHealthAnalyticsSettings/customModules/{custom_module} + * - folderEffectiveCustomModule: folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module} + * - folderExport: folders/{folder}/bigQueryExports/{export} + * - folderMuteConfig: folders/{folder}/muteConfigs/{mute_config} + * - folderNotificationConfig: folders/{folder}/notificationConfigs/{notification_config} + * - folderSecurityHealthAnalyticsSettings: folders/{folder}/securityHealthAnalyticsSettings + * - folderSource: folders/{folder}/sources/{source} + * - folderSourceFinding: folders/{folder}/sources/{source}/findings/{finding} + * - folderSourceFindingExternalsystem: folders/{folder}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} + * - folderSourceFindingSecurityMarks: folders/{folder}/sources/{source}/findings/{finding}/securityMarks + * - muteConfig: organizations/{organization}/muteConfigs/{mute_config} + * - notificationConfig: organizations/{organization}/notificationConfigs/{notification_config} + * - organization: organizations/{organization} + * - organizationAssetSecurityMarks: organizations/{organization}/assets/{asset}/securityMarks + * - organizationConstraintName: organizations/{organization}/policies/{constraint_name} + * - organizationCustomModule: organizations/{organization}/securityHealthAnalyticsSettings/customModules/{custom_module} + * - organizationEffectiveCustomModule: organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module} + * - organizationExport: organizations/{organization}/bigQueryExports/{export} + * - organizationMuteConfig: organizations/{organization}/muteConfigs/{mute_config} + * - organizationNotificationConfig: organizations/{organization}/notificationConfigs/{notification_config} + * - organizationSecurityHealthAnalyticsSettings: organizations/{organization}/securityHealthAnalyticsSettings + * - organizationSettings: organizations/{organization}/organizationSettings + * - organizationSource: organizations/{organization}/sources/{source} + * - organizationSourceFinding: organizations/{organization}/sources/{source}/findings/{finding} + * - organizationSourceFindingExternalsystem: organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} + * - organizationSourceFindingSecurityMarks: organizations/{organization}/sources/{source}/findings/{finding}/securityMarks + * - policy: organizations/{organization}/policies/{constraint_name} + * - project: projects/{project} + * - projectAssetSecurityMarks: projects/{project}/assets/{asset}/securityMarks + * - projectConstraintName: projects/{project}/policies/{constraint_name} + * - projectCustomModule: projects/{project}/securityHealthAnalyticsSettings/customModules/{custom_module} + * - projectDlpJob: projects/{project}/dlpJobs/{dlp_job} + * - projectEffectiveCustomModule: projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module} + * - projectExport: projects/{project}/bigQueryExports/{export} + * - projectLocationDlpJob: projects/{project}/locations/{location}/dlpJobs/{dlp_job} + * - projectLocationTableProfile: projects/{project}/locations/{location}/tableProfiles/{table_profile} + * - projectMuteConfig: projects/{project}/muteConfigs/{mute_config} + * - projectNotificationConfig: projects/{project}/notificationConfigs/{notification_config} + * - projectSecurityHealthAnalyticsSettings: projects/{project}/securityHealthAnalyticsSettings + * - projectSource: projects/{project}/sources/{source} + * - projectSourceFinding: projects/{project}/sources/{source}/findings/{finding} + * - projectSourceFindingExternalsystem: projects/{project}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} + * - projectSourceFindingSecurityMarks: projects/{project}/sources/{source}/findings/{finding}/securityMarks + * - projectTableProfile: projects/{project}/tableProfiles/{table_profile} + * - securityHealthAnalyticsCustomModule: organizations/{organization}/securityHealthAnalyticsSettings/customModules/{custom_module} + * - securityHealthAnalyticsSettings: organizations/{organization}/securityHealthAnalyticsSettings + * - securityMarks: organizations/{organization}/assets/{asset}/securityMarks + * - source: organizations/{organization}/sources/{source} + * - tableDataProfile: projects/{project}/tableProfiles/{table_profile} + * - topic: projects/{project}/topics/{topic} + * + * The optional $template argument can be supplied to specify a particular pattern, + * and must match one of the templates listed above. If no $template argument is + * provided, or if the $template argument does not match one of the templates + * listed, then parseName will check each of the supported templates, and return + * the first match. + * + * @param string $formattedName The formatted name string + * @param string $template Optional name of template to match + * + * @return array An associative array from name component IDs to component values. + * + * @throws ValidationException If $formattedName could not be matched. + */ + public static function parseName(string $formattedName, string $template = null): array + { + return self::parseFormattedName($formattedName, $template); + } + + /** + * Constructor. + * + * @param array $options { + * Optional. Options for configuring the service API wrapper. + * + * @type string $apiEndpoint + * The address of the API remote host. May optionally include the port, formatted + * as ":". Default 'securitycenter.googleapis.com:443'. + * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials + * The credentials to be used by the client to authorize API calls. This option + * accepts either a path to a credentials file, or a decoded credentials file as a + * PHP array. + * *Advanced usage*: In addition, this option can also accept a pre-constructed + * {@see \Google\Auth\FetchAuthTokenInterface} object or + * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these + * objects are provided, any settings in $credentialsConfig will be ignored. + * @type array $credentialsConfig + * Options used to configure credentials, including auth token caching, for the + * client. For a full list of supporting configuration options, see + * {@see \Google\ApiCore\CredentialsWrapper::build()} . + * @type bool $disableRetries + * Determines whether or not retries defined by the client configuration should be + * disabled. Defaults to `false`. + * @type string|array $clientConfig + * Client method configuration, including retry settings. This option can be either + * a path to a JSON file, or a PHP array containing the decoded JSON data. By + * default this settings points to the default client config file, which is + * provided in the resources folder. + * @type string|TransportInterface $transport + * The transport used for executing network requests. May be either the string + * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. + * *Advanced usage*: Additionally, it is possible to pass in an already + * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note + * that when this object is provided, any settings in $transportConfig, and any + * $apiEndpoint setting, will be ignored. + * @type array $transportConfig + * Configuration options that will be used to construct the transport. Options for + * each supported transport type should be passed in a key for that transport. For + * example: + * $transportConfig = [ + * 'grpc' => [...], + * 'rest' => [...], + * ]; + * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and + * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the + * supported options. + * @type callable $clientCertSource + * A callable which returns the client cert as a string. This can be used to + * provide a certificate and private key to the transport layer for mTLS. + * } + * + * @throws ValidationException + */ + public function __construct(array $options = []) + { + $clientOptions = $this->buildClientOptions($options); + $this->setClientOptions($clientOptions); + $this->operationsClient = $this->createOperationsClient($clientOptions); + } + + /** Handles execution of the async variants for each documented method. */ + public function __call($method, $args) + { + if (substr($method, -5) !== 'Async') { + trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); + } + + array_unshift($args, substr($method, 0, -5)); + return call_user_func_array([$this, 'startAsyncCall'], $args); + } + + /** + * Kicks off an LRO to bulk mute findings for a parent based on a filter. The + * parent can be either an organization, folder or project. The findings + * matched by the filter will be muted after the LRO is done. + * + * The async variant is {@see SecurityCenterClient::bulkMuteFindingsAsync()} . + * + * @example samples/V1/SecurityCenterClient/bulk_mute_findings.php + * + * @param BulkMuteFindingsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function bulkMuteFindings(BulkMuteFindingsRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('BulkMuteFindings', $request, $callOptions)->wait(); + } + + /** + * Creates a BigQuery export. + * + * The async variant is {@see SecurityCenterClient::createBigQueryExportAsync()} . + * + * @example samples/V1/SecurityCenterClient/create_big_query_export.php + * + * @param CreateBigQueryExportRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return BigQueryExport + * + * @throws ApiException Thrown if the API call fails. + */ + public function createBigQueryExport(CreateBigQueryExportRequest $request, array $callOptions = []): BigQueryExport + { + return $this->startApiCall('CreateBigQueryExport', $request, $callOptions)->wait(); + } + + /** + * Creates a finding. The corresponding source must exist for finding creation + * to succeed. + * + * The async variant is {@see SecurityCenterClient::createFindingAsync()} . + * + * @example samples/V1/SecurityCenterClient/create_finding.php + * + * @param CreateFindingRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Finding + * + * @throws ApiException Thrown if the API call fails. + */ + public function createFinding(CreateFindingRequest $request, array $callOptions = []): Finding + { + return $this->startApiCall('CreateFinding', $request, $callOptions)->wait(); + } + + /** + * Creates a mute config. + * + * The async variant is {@see SecurityCenterClient::createMuteConfigAsync()} . + * + * @example samples/V1/SecurityCenterClient/create_mute_config.php + * + * @param CreateMuteConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return MuteConfig + * + * @throws ApiException Thrown if the API call fails. + */ + public function createMuteConfig(CreateMuteConfigRequest $request, array $callOptions = []): MuteConfig + { + return $this->startApiCall('CreateMuteConfig', $request, $callOptions)->wait(); + } + + /** + * Creates a notification config. + * + * The async variant is + * {@see SecurityCenterClient::createNotificationConfigAsync()} . + * + * @example samples/V1/SecurityCenterClient/create_notification_config.php + * + * @param CreateNotificationConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return NotificationConfig + * + * @throws ApiException Thrown if the API call fails. + */ + public function createNotificationConfig(CreateNotificationConfigRequest $request, array $callOptions = []): NotificationConfig + { + return $this->startApiCall('CreateNotificationConfig', $request, $callOptions)->wait(); + } + + /** + * Creates a resident SecurityHealthAnalyticsCustomModule at the scope of the + * given CRM parent, and also creates inherited + * SecurityHealthAnalyticsCustomModules for all CRM descendants of the given + * parent. These modules are enabled by default. + * + * The async variant is + * {@see SecurityCenterClient::createSecurityHealthAnalyticsCustomModuleAsync()} . + * + * @example samples/V1/SecurityCenterClient/create_security_health_analytics_custom_module.php + * + * @param CreateSecurityHealthAnalyticsCustomModuleRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return SecurityHealthAnalyticsCustomModule + * + * @throws ApiException Thrown if the API call fails. + */ + public function createSecurityHealthAnalyticsCustomModule(CreateSecurityHealthAnalyticsCustomModuleRequest $request, array $callOptions = []): SecurityHealthAnalyticsCustomModule + { + return $this->startApiCall('CreateSecurityHealthAnalyticsCustomModule', $request, $callOptions)->wait(); + } + + /** + * Creates a source. + * + * The async variant is {@see SecurityCenterClient::createSourceAsync()} . + * + * @example samples/V1/SecurityCenterClient/create_source.php + * + * @param CreateSourceRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Source + * + * @throws ApiException Thrown if the API call fails. + */ + public function createSource(CreateSourceRequest $request, array $callOptions = []): Source + { + return $this->startApiCall('CreateSource', $request, $callOptions)->wait(); + } + + /** + * Deletes an existing BigQuery export. + * + * The async variant is {@see SecurityCenterClient::deleteBigQueryExportAsync()} . + * + * @example samples/V1/SecurityCenterClient/delete_big_query_export.php + * + * @param DeleteBigQueryExportRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteBigQueryExport(DeleteBigQueryExportRequest $request, array $callOptions = []): void + { + $this->startApiCall('DeleteBigQueryExport', $request, $callOptions)->wait(); + } + + /** + * Deletes an existing mute config. + * + * The async variant is {@see SecurityCenterClient::deleteMuteConfigAsync()} . + * + * @example samples/V1/SecurityCenterClient/delete_mute_config.php + * + * @param DeleteMuteConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteMuteConfig(DeleteMuteConfigRequest $request, array $callOptions = []): void + { + $this->startApiCall('DeleteMuteConfig', $request, $callOptions)->wait(); + } + + /** + * Deletes a notification config. + * + * The async variant is + * {@see SecurityCenterClient::deleteNotificationConfigAsync()} . + * + * @example samples/V1/SecurityCenterClient/delete_notification_config.php + * + * @param DeleteNotificationConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteNotificationConfig(DeleteNotificationConfigRequest $request, array $callOptions = []): void + { + $this->startApiCall('DeleteNotificationConfig', $request, $callOptions)->wait(); + } + + /** + * Deletes the specified SecurityHealthAnalyticsCustomModule and all of its + * descendants in the CRM hierarchy. This method is only supported for + * resident custom modules. + * + * The async variant is + * {@see SecurityCenterClient::deleteSecurityHealthAnalyticsCustomModuleAsync()} . + * + * @example samples/V1/SecurityCenterClient/delete_security_health_analytics_custom_module.php + * + * @param DeleteSecurityHealthAnalyticsCustomModuleRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteSecurityHealthAnalyticsCustomModule(DeleteSecurityHealthAnalyticsCustomModuleRequest $request, array $callOptions = []): void + { + $this->startApiCall('DeleteSecurityHealthAnalyticsCustomModule', $request, $callOptions)->wait(); + } + + /** + * Gets a BigQuery export. + * + * The async variant is {@see SecurityCenterClient::getBigQueryExportAsync()} . + * + * @example samples/V1/SecurityCenterClient/get_big_query_export.php + * + * @param GetBigQueryExportRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return BigQueryExport + * + * @throws ApiException Thrown if the API call fails. + */ + public function getBigQueryExport(GetBigQueryExportRequest $request, array $callOptions = []): BigQueryExport + { + return $this->startApiCall('GetBigQueryExport', $request, $callOptions)->wait(); + } + + /** + * Retrieves an EffectiveSecurityHealthAnalyticsCustomModule. + * + * The async variant is + * {@see SecurityCenterClient::getEffectiveSecurityHealthAnalyticsCustomModuleAsync()} + * . + * + * @example samples/V1/SecurityCenterClient/get_effective_security_health_analytics_custom_module.php + * + * @param GetEffectiveSecurityHealthAnalyticsCustomModuleRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return EffectiveSecurityHealthAnalyticsCustomModule + * + * @throws ApiException Thrown if the API call fails. + */ + public function getEffectiveSecurityHealthAnalyticsCustomModule(GetEffectiveSecurityHealthAnalyticsCustomModuleRequest $request, array $callOptions = []): EffectiveSecurityHealthAnalyticsCustomModule + { + return $this->startApiCall('GetEffectiveSecurityHealthAnalyticsCustomModule', $request, $callOptions)->wait(); + } + + /** + * Gets the access control policy on the specified Source. + * + * The async variant is {@see SecurityCenterClient::getIamPolicyAsync()} . + * + * @example samples/V1/SecurityCenterClient/get_iam_policy.php + * + * @param GetIamPolicyRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Policy + * + * @throws ApiException Thrown if the API call fails. + */ + public function getIamPolicy(GetIamPolicyRequest $request, array $callOptions = []): Policy + { + return $this->startApiCall('GetIamPolicy', $request, $callOptions)->wait(); + } + + /** + * Gets a mute config. + * + * The async variant is {@see SecurityCenterClient::getMuteConfigAsync()} . + * + * @example samples/V1/SecurityCenterClient/get_mute_config.php + * + * @param GetMuteConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return MuteConfig + * + * @throws ApiException Thrown if the API call fails. + */ + public function getMuteConfig(GetMuteConfigRequest $request, array $callOptions = []): MuteConfig + { + return $this->startApiCall('GetMuteConfig', $request, $callOptions)->wait(); + } + + /** + * Gets a notification config. + * + * The async variant is {@see SecurityCenterClient::getNotificationConfigAsync()} . + * + * @example samples/V1/SecurityCenterClient/get_notification_config.php + * + * @param GetNotificationConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return NotificationConfig + * + * @throws ApiException Thrown if the API call fails. + */ + public function getNotificationConfig(GetNotificationConfigRequest $request, array $callOptions = []): NotificationConfig + { + return $this->startApiCall('GetNotificationConfig', $request, $callOptions)->wait(); + } + + /** + * Gets the settings for an organization. + * + * The async variant is {@see SecurityCenterClient::getOrganizationSettingsAsync()} + * . + * + * @example samples/V1/SecurityCenterClient/get_organization_settings.php + * + * @param GetOrganizationSettingsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return OrganizationSettings + * + * @throws ApiException Thrown if the API call fails. + */ + public function getOrganizationSettings(GetOrganizationSettingsRequest $request, array $callOptions = []): OrganizationSettings + { + return $this->startApiCall('GetOrganizationSettings', $request, $callOptions)->wait(); + } + + /** + * Retrieves a SecurityHealthAnalyticsCustomModule. + * + * The async variant is + * {@see SecurityCenterClient::getSecurityHealthAnalyticsCustomModuleAsync()} . + * + * @example samples/V1/SecurityCenterClient/get_security_health_analytics_custom_module.php + * + * @param GetSecurityHealthAnalyticsCustomModuleRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return SecurityHealthAnalyticsCustomModule + * + * @throws ApiException Thrown if the API call fails. + */ + public function getSecurityHealthAnalyticsCustomModule(GetSecurityHealthAnalyticsCustomModuleRequest $request, array $callOptions = []): SecurityHealthAnalyticsCustomModule + { + return $this->startApiCall('GetSecurityHealthAnalyticsCustomModule', $request, $callOptions)->wait(); + } + + /** + * Gets a source. + * + * The async variant is {@see SecurityCenterClient::getSourceAsync()} . + * + * @example samples/V1/SecurityCenterClient/get_source.php + * + * @param GetSourceRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Source + * + * @throws ApiException Thrown if the API call fails. + */ + public function getSource(GetSourceRequest $request, array $callOptions = []): Source + { + return $this->startApiCall('GetSource', $request, $callOptions)->wait(); + } + + /** + * Filters an organization's assets and groups them by their specified + * properties. + * + * The async variant is {@see SecurityCenterClient::groupAssetsAsync()} . + * + * @example samples/V1/SecurityCenterClient/group_assets.php + * + * @param GroupAssetsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @deprecated This method will be removed in the next major version update. + */ + public function groupAssets(GroupAssetsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('GroupAssets', $request, $callOptions); + } + + /** + * Filters an organization or source's findings and groups them by their + * specified properties. + * + * To group across all sources provide a `-` as the source id. + * Example: /v1/organizations/{organization_id}/sources/-/findings, + * /v1/folders/{folder_id}/sources/-/findings, + * /v1/projects/{project_id}/sources/-/findings + * + * The async variant is {@see SecurityCenterClient::groupFindingsAsync()} . + * + * @example samples/V1/SecurityCenterClient/group_findings.php + * + * @param GroupFindingsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function groupFindings(GroupFindingsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('GroupFindings', $request, $callOptions); + } + + /** + * Lists an organization's assets. + * + * The async variant is {@see SecurityCenterClient::listAssetsAsync()} . + * + * @example samples/V1/SecurityCenterClient/list_assets.php + * + * @param ListAssetsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @deprecated This method will be removed in the next major version update. + */ + public function listAssets(ListAssetsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListAssets', $request, $callOptions); + } + + /** + * Lists BigQuery exports. Note that when requesting BigQuery exports at a + * given level all exports under that level are also returned e.g. if + * requesting BigQuery exports under a folder, then all BigQuery exports + * immediately under the folder plus the ones created under the projects + * within the folder are returned. + * + * The async variant is {@see SecurityCenterClient::listBigQueryExportsAsync()} . + * + * @example samples/V1/SecurityCenterClient/list_big_query_exports.php + * + * @param ListBigQueryExportsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listBigQueryExports(ListBigQueryExportsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListBigQueryExports', $request, $callOptions); + } + + /** + * Returns a list of all resident SecurityHealthAnalyticsCustomModules under + * the given CRM parent and all of the parent’s CRM descendants. + * + * The async variant is + * {@see SecurityCenterClient::listDescendantSecurityHealthAnalyticsCustomModulesAsync()} + * . + * + * @example samples/V1/SecurityCenterClient/list_descendant_security_health_analytics_custom_modules.php + * + * @param ListDescendantSecurityHealthAnalyticsCustomModulesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listDescendantSecurityHealthAnalyticsCustomModules(ListDescendantSecurityHealthAnalyticsCustomModulesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListDescendantSecurityHealthAnalyticsCustomModules', $request, $callOptions); + } + + /** + * Returns a list of all EffectiveSecurityHealthAnalyticsCustomModules for the + * given parent. This includes resident modules defined at the scope of the + * parent, and inherited modules, inherited from CRM ancestors. + * + * The async variant is + * {@see SecurityCenterClient::listEffectiveSecurityHealthAnalyticsCustomModulesAsync()} + * . + * + * @example samples/V1/SecurityCenterClient/list_effective_security_health_analytics_custom_modules.php + * + * @param ListEffectiveSecurityHealthAnalyticsCustomModulesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listEffectiveSecurityHealthAnalyticsCustomModules(ListEffectiveSecurityHealthAnalyticsCustomModulesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListEffectiveSecurityHealthAnalyticsCustomModules', $request, $callOptions); + } + + /** + * Lists an organization or source's findings. + * + * To list across all sources provide a `-` as the source id. + * Example: /v1/organizations/{organization_id}/sources/-/findings + * + * The async variant is {@see SecurityCenterClient::listFindingsAsync()} . + * + * @example samples/V1/SecurityCenterClient/list_findings.php + * + * @param ListFindingsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listFindings(ListFindingsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListFindings', $request, $callOptions); + } + + /** + * Lists mute configs. + * + * The async variant is {@see SecurityCenterClient::listMuteConfigsAsync()} . + * + * @example samples/V1/SecurityCenterClient/list_mute_configs.php + * + * @param ListMuteConfigsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listMuteConfigs(ListMuteConfigsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListMuteConfigs', $request, $callOptions); + } + + /** + * Lists notification configs. + * + * The async variant is {@see SecurityCenterClient::listNotificationConfigsAsync()} + * . + * + * @example samples/V1/SecurityCenterClient/list_notification_configs.php + * + * @param ListNotificationConfigsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listNotificationConfigs(ListNotificationConfigsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListNotificationConfigs', $request, $callOptions); + } + + /** + * Returns a list of all SecurityHealthAnalyticsCustomModules for the given + * parent. This includes resident modules defined at the scope of the parent, + * and inherited modules, inherited from CRM ancestors. + * + * The async variant is + * {@see SecurityCenterClient::listSecurityHealthAnalyticsCustomModulesAsync()} . + * + * @example samples/V1/SecurityCenterClient/list_security_health_analytics_custom_modules.php + * + * @param ListSecurityHealthAnalyticsCustomModulesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listSecurityHealthAnalyticsCustomModules(ListSecurityHealthAnalyticsCustomModulesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListSecurityHealthAnalyticsCustomModules', $request, $callOptions); + } + + /** + * Lists all sources belonging to an organization. + * + * The async variant is {@see SecurityCenterClient::listSourcesAsync()} . + * + * @example samples/V1/SecurityCenterClient/list_sources.php + * + * @param ListSourcesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listSources(ListSourcesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListSources', $request, $callOptions); + } + + /** + * Runs asset discovery. The discovery is tracked with a long-running + * operation. + * + * This API can only be called with limited frequency for an organization. If + * it is called too frequently the caller will receive a TOO_MANY_REQUESTS + * error. + * + * The async variant is {@see SecurityCenterClient::runAssetDiscoveryAsync()} . + * + * @example samples/V1/SecurityCenterClient/run_asset_discovery.php + * + * @param RunAssetDiscoveryRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return OperationResponse + * + * @throws ApiException Thrown if the API call fails. + * + * @deprecated This method will be removed in the next major version update. + */ + public function runAssetDiscovery(RunAssetDiscoveryRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('RunAssetDiscovery', $request, $callOptions)->wait(); + } + + /** + * Updates the state of a finding. + * + * The async variant is {@see SecurityCenterClient::setFindingStateAsync()} . + * + * @example samples/V1/SecurityCenterClient/set_finding_state.php + * + * @param SetFindingStateRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Finding + * + * @throws ApiException Thrown if the API call fails. + */ + public function setFindingState(SetFindingStateRequest $request, array $callOptions = []): Finding + { + return $this->startApiCall('SetFindingState', $request, $callOptions)->wait(); + } + + /** + * Sets the access control policy on the specified Source. + * + * The async variant is {@see SecurityCenterClient::setIamPolicyAsync()} . + * + * @example samples/V1/SecurityCenterClient/set_iam_policy.php + * + * @param SetIamPolicyRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Policy + * + * @throws ApiException Thrown if the API call fails. + */ + public function setIamPolicy(SetIamPolicyRequest $request, array $callOptions = []): Policy + { + return $this->startApiCall('SetIamPolicy', $request, $callOptions)->wait(); + } + + /** + * Updates the mute state of a finding. + * + * The async variant is {@see SecurityCenterClient::setMuteAsync()} . + * + * @example samples/V1/SecurityCenterClient/set_mute.php + * + * @param SetMuteRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Finding + * + * @throws ApiException Thrown if the API call fails. + */ + public function setMute(SetMuteRequest $request, array $callOptions = []): Finding + { + return $this->startApiCall('SetMute', $request, $callOptions)->wait(); + } + + /** + * Simulates a given SecurityHealthAnalyticsCustomModule and Resource. + * + * The async variant is + * {@see SecurityCenterClient::simulateSecurityHealthAnalyticsCustomModuleAsync()} + * . + * + * @example samples/V1/SecurityCenterClient/simulate_security_health_analytics_custom_module.php + * + * @param SimulateSecurityHealthAnalyticsCustomModuleRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return SimulateSecurityHealthAnalyticsCustomModuleResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function simulateSecurityHealthAnalyticsCustomModule(SimulateSecurityHealthAnalyticsCustomModuleRequest $request, array $callOptions = []): SimulateSecurityHealthAnalyticsCustomModuleResponse + { + return $this->startApiCall('SimulateSecurityHealthAnalyticsCustomModule', $request, $callOptions)->wait(); + } + + /** + * Returns the permissions that a caller has on the specified source. + * + * The async variant is {@see SecurityCenterClient::testIamPermissionsAsync()} . + * + * @example samples/V1/SecurityCenterClient/test_iam_permissions.php + * + * @param TestIamPermissionsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return TestIamPermissionsResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function testIamPermissions(TestIamPermissionsRequest $request, array $callOptions = []): TestIamPermissionsResponse + { + return $this->startApiCall('TestIamPermissions', $request, $callOptions)->wait(); + } + + /** + * Updates a BigQuery export. + * + * The async variant is {@see SecurityCenterClient::updateBigQueryExportAsync()} . + * + * @example samples/V1/SecurityCenterClient/update_big_query_export.php + * + * @param UpdateBigQueryExportRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return BigQueryExport + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateBigQueryExport(UpdateBigQueryExportRequest $request, array $callOptions = []): BigQueryExport + { + return $this->startApiCall('UpdateBigQueryExport', $request, $callOptions)->wait(); + } + + /** + * Updates external system. This is for a given finding. + * + * The async variant is {@see SecurityCenterClient::updateExternalSystemAsync()} . + * + * @example samples/V1/SecurityCenterClient/update_external_system.php + * + * @param UpdateExternalSystemRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return ExternalSystem + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateExternalSystem(UpdateExternalSystemRequest $request, array $callOptions = []): ExternalSystem + { + return $this->startApiCall('UpdateExternalSystem', $request, $callOptions)->wait(); + } + + /** + * Creates or updates a finding. The corresponding source must exist for a + * finding creation to succeed. + * + * The async variant is {@see SecurityCenterClient::updateFindingAsync()} . + * + * @example samples/V1/SecurityCenterClient/update_finding.php + * + * @param UpdateFindingRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Finding + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateFinding(UpdateFindingRequest $request, array $callOptions = []): Finding + { + return $this->startApiCall('UpdateFinding', $request, $callOptions)->wait(); + } + + /** + * Updates a mute config. + * + * The async variant is {@see SecurityCenterClient::updateMuteConfigAsync()} . + * + * @example samples/V1/SecurityCenterClient/update_mute_config.php + * + * @param UpdateMuteConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return MuteConfig + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateMuteConfig(UpdateMuteConfigRequest $request, array $callOptions = []): MuteConfig + { + return $this->startApiCall('UpdateMuteConfig', $request, $callOptions)->wait(); + } + + /** + * + * Updates a notification config. The following update + * fields are allowed: description, pubsub_topic, streaming_config.filter + * + * The async variant is + * {@see SecurityCenterClient::updateNotificationConfigAsync()} . + * + * @example samples/V1/SecurityCenterClient/update_notification_config.php + * + * @param UpdateNotificationConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return NotificationConfig + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateNotificationConfig(UpdateNotificationConfigRequest $request, array $callOptions = []): NotificationConfig + { + return $this->startApiCall('UpdateNotificationConfig', $request, $callOptions)->wait(); + } + + /** + * Updates an organization's settings. + * + * The async variant is + * {@see SecurityCenterClient::updateOrganizationSettingsAsync()} . + * + * @example samples/V1/SecurityCenterClient/update_organization_settings.php + * + * @param UpdateOrganizationSettingsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return OrganizationSettings + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateOrganizationSettings(UpdateOrganizationSettingsRequest $request, array $callOptions = []): OrganizationSettings + { + return $this->startApiCall('UpdateOrganizationSettings', $request, $callOptions)->wait(); + } + + /** + * Updates the SecurityHealthAnalyticsCustomModule under the given name based + * on the given update mask. Updating the enablement state is supported on + * both resident and inherited modules (though resident modules cannot have an + * enablement state of "inherited"). Updating the display name and custom + * config of a module is supported on resident modules only. + * + * The async variant is + * {@see SecurityCenterClient::updateSecurityHealthAnalyticsCustomModuleAsync()} . + * + * @example samples/V1/SecurityCenterClient/update_security_health_analytics_custom_module.php + * + * @param UpdateSecurityHealthAnalyticsCustomModuleRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return SecurityHealthAnalyticsCustomModule + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateSecurityHealthAnalyticsCustomModule(UpdateSecurityHealthAnalyticsCustomModuleRequest $request, array $callOptions = []): SecurityHealthAnalyticsCustomModule + { + return $this->startApiCall('UpdateSecurityHealthAnalyticsCustomModule', $request, $callOptions)->wait(); + } + + /** + * Updates security marks. + * + * The async variant is {@see SecurityCenterClient::updateSecurityMarksAsync()} . + * + * @example samples/V1/SecurityCenterClient/update_security_marks.php + * + * @param UpdateSecurityMarksRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return SecurityMarks + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateSecurityMarks(UpdateSecurityMarksRequest $request, array $callOptions = []): SecurityMarks + { + return $this->startApiCall('UpdateSecurityMarks', $request, $callOptions)->wait(); + } + + /** + * Updates a source. + * + * The async variant is {@see SecurityCenterClient::updateSourceAsync()} . + * + * @example samples/V1/SecurityCenterClient/update_source.php + * + * @param UpdateSourceRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Source + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateSource(UpdateSourceRequest $request, array $callOptions = []): Source + { + return $this->startApiCall('UpdateSource', $request, $callOptions)->wait(); + } +} diff --git a/owl-bot-staging/SecurityCenter/v1/src/V1/Gapic/SecurityCenterGapicClient.php b/owl-bot-staging/SecurityCenter/v1/src/V1/Gapic/SecurityCenterGapicClient.php new file mode 100644 index 000000000000..01a38f3241d4 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/src/V1/Gapic/SecurityCenterGapicClient.php @@ -0,0 +1,5120 @@ +bulkMuteFindings($parent); + * $operationResponse->pollUntilComplete(); + * if ($operationResponse->operationSucceeded()) { + * $result = $operationResponse->getResult(); + * // doSomethingWith($result) + * } else { + * $error = $operationResponse->getError(); + * // handleError($error) + * } + * // Alternatively: + * // start the operation, keep the operation name, and resume later + * $operationResponse = $securityCenterClient->bulkMuteFindings($parent); + * $operationName = $operationResponse->getName(); + * // ... do other work + * $newOperationResponse = $securityCenterClient->resumeOperation($operationName, 'bulkMuteFindings'); + * while (!$newOperationResponse->isDone()) { + * // ... do other work + * $newOperationResponse->reload(); + * } + * if ($newOperationResponse->operationSucceeded()) { + * $result = $newOperationResponse->getResult(); + * // doSomethingWith($result) + * } else { + * $error = $newOperationResponse->getError(); + * // handleError($error) + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * Many parameters require resource names to be formatted in a particular way. To + * assist with these names, this class includes a format method for each type of + * name, and additionally a parseName method to extract the individual identifiers + * contained within formatted names that are returned by the API. + * + * @deprecated Please use the new service client {@see \Google\Cloud\SecurityCenter\V1\Client\SecurityCenterClient}. + */ +class SecurityCenterGapicClient +{ + use GapicClientTrait; + + /** The name of the service. */ + const SERVICE_NAME = 'google.cloud.securitycenter.v1.SecurityCenter'; + + /** + * The default address of the service. + * + * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. + */ + const SERVICE_ADDRESS = 'securitycenter.googleapis.com'; + + /** The address template of the service. */ + private const SERVICE_ADDRESS_TEMPLATE = 'securitycenter.UNIVERSE_DOMAIN'; + + /** The default port of the service. */ + const DEFAULT_SERVICE_PORT = 443; + + /** The name of the code generator, to be included in the agent header. */ + const CODEGEN_NAME = 'gapic'; + + /** The default scopes required by the service. */ + public static $serviceScopes = [ + 'https://www.googleapis.com/auth/cloud-platform', + ]; + + private static $bigQueryExportNameTemplate; + + private static $dlpJobNameTemplate; + + private static $effectiveSecurityHealthAnalyticsCustomModuleNameTemplate; + + private static $externalSystemNameTemplate; + + private static $findingNameTemplate; + + private static $folderNameTemplate; + + private static $folderAssetSecurityMarksNameTemplate; + + private static $folderConstraintNameNameTemplate; + + private static $folderCustomModuleNameTemplate; + + private static $folderEffectiveCustomModuleNameTemplate; + + private static $folderExportNameTemplate; + + private static $folderMuteConfigNameTemplate; + + private static $folderNotificationConfigNameTemplate; + + private static $folderSecurityHealthAnalyticsSettingsNameTemplate; + + private static $folderSourceNameTemplate; + + private static $folderSourceFindingNameTemplate; + + private static $folderSourceFindingExternalsystemNameTemplate; + + private static $folderSourceFindingSecurityMarksNameTemplate; + + private static $muteConfigNameTemplate; + + private static $notificationConfigNameTemplate; + + private static $organizationNameTemplate; + + private static $organizationAssetSecurityMarksNameTemplate; + + private static $organizationConstraintNameNameTemplate; + + private static $organizationCustomModuleNameTemplate; + + private static $organizationEffectiveCustomModuleNameTemplate; + + private static $organizationExportNameTemplate; + + private static $organizationMuteConfigNameTemplate; + + private static $organizationNotificationConfigNameTemplate; + + private static $organizationSecurityHealthAnalyticsSettingsNameTemplate; + + private static $organizationSettingsNameTemplate; + + private static $organizationSourceNameTemplate; + + private static $organizationSourceFindingNameTemplate; + + private static $organizationSourceFindingExternalsystemNameTemplate; + + private static $organizationSourceFindingSecurityMarksNameTemplate; + + private static $policyNameTemplate; + + private static $projectNameTemplate; + + private static $projectAssetSecurityMarksNameTemplate; + + private static $projectConstraintNameNameTemplate; + + private static $projectCustomModuleNameTemplate; + + private static $projectDlpJobNameTemplate; + + private static $projectEffectiveCustomModuleNameTemplate; + + private static $projectExportNameTemplate; + + private static $projectLocationDlpJobNameTemplate; + + private static $projectLocationTableProfileNameTemplate; + + private static $projectMuteConfigNameTemplate; + + private static $projectNotificationConfigNameTemplate; + + private static $projectSecurityHealthAnalyticsSettingsNameTemplate; + + private static $projectSourceNameTemplate; + + private static $projectSourceFindingNameTemplate; + + private static $projectSourceFindingExternalsystemNameTemplate; + + private static $projectSourceFindingSecurityMarksNameTemplate; + + private static $projectTableProfileNameTemplate; + + private static $securityHealthAnalyticsCustomModuleNameTemplate; + + private static $securityHealthAnalyticsSettingsNameTemplate; + + private static $securityMarksNameTemplate; + + private static $sourceNameTemplate; + + private static $tableDataProfileNameTemplate; + + private static $topicNameTemplate; + + private static $pathTemplateMap; + + private $operationsClient; + + private static function getClientDefaults() + { + return [ + 'serviceName' => self::SERVICE_NAME, + 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, + 'clientConfig' => __DIR__ . '/../resources/security_center_client_config.json', + 'descriptorsConfigPath' => __DIR__ . '/../resources/security_center_descriptor_config.php', + 'gcpApiConfigPath' => __DIR__ . '/../resources/security_center_grpc_config.json', + 'credentialsConfig' => [ + 'defaultScopes' => self::$serviceScopes, + ], + 'transportConfig' => [ + 'rest' => [ + 'restClientConfigPath' => __DIR__ . '/../resources/security_center_rest_client_config.php', + ], + ], + ]; + } + + private static function getBigQueryExportNameTemplate() + { + if (self::$bigQueryExportNameTemplate == null) { + self::$bigQueryExportNameTemplate = new PathTemplate('organizations/{organization}/bigQueryExports/{export}'); + } + + return self::$bigQueryExportNameTemplate; + } + + private static function getDlpJobNameTemplate() + { + if (self::$dlpJobNameTemplate == null) { + self::$dlpJobNameTemplate = new PathTemplate('projects/{project}/dlpJobs/{dlp_job}'); + } + + return self::$dlpJobNameTemplate; + } + + private static function getEffectiveSecurityHealthAnalyticsCustomModuleNameTemplate() + { + if (self::$effectiveSecurityHealthAnalyticsCustomModuleNameTemplate == null) { + self::$effectiveSecurityHealthAnalyticsCustomModuleNameTemplate = new PathTemplate('organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module}'); + } + + return self::$effectiveSecurityHealthAnalyticsCustomModuleNameTemplate; + } + + private static function getExternalSystemNameTemplate() + { + if (self::$externalSystemNameTemplate == null) { + self::$externalSystemNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}'); + } + + return self::$externalSystemNameTemplate; + } + + private static function getFindingNameTemplate() + { + if (self::$findingNameTemplate == null) { + self::$findingNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}/findings/{finding}'); + } + + return self::$findingNameTemplate; + } + + private static function getFolderNameTemplate() + { + if (self::$folderNameTemplate == null) { + self::$folderNameTemplate = new PathTemplate('folders/{folder}'); + } + + return self::$folderNameTemplate; + } + + private static function getFolderAssetSecurityMarksNameTemplate() + { + if (self::$folderAssetSecurityMarksNameTemplate == null) { + self::$folderAssetSecurityMarksNameTemplate = new PathTemplate('folders/{folder}/assets/{asset}/securityMarks'); + } + + return self::$folderAssetSecurityMarksNameTemplate; + } + + private static function getFolderConstraintNameNameTemplate() + { + if (self::$folderConstraintNameNameTemplate == null) { + self::$folderConstraintNameNameTemplate = new PathTemplate('folders/{folder}/policies/{constraint_name}'); + } + + return self::$folderConstraintNameNameTemplate; + } + + private static function getFolderCustomModuleNameTemplate() + { + if (self::$folderCustomModuleNameTemplate == null) { + self::$folderCustomModuleNameTemplate = new PathTemplate('folders/{folder}/securityHealthAnalyticsSettings/customModules/{custom_module}'); + } + + return self::$folderCustomModuleNameTemplate; + } + + private static function getFolderEffectiveCustomModuleNameTemplate() + { + if (self::$folderEffectiveCustomModuleNameTemplate == null) { + self::$folderEffectiveCustomModuleNameTemplate = new PathTemplate('folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module}'); + } + + return self::$folderEffectiveCustomModuleNameTemplate; + } + + private static function getFolderExportNameTemplate() + { + if (self::$folderExportNameTemplate == null) { + self::$folderExportNameTemplate = new PathTemplate('folders/{folder}/bigQueryExports/{export}'); + } + + return self::$folderExportNameTemplate; + } + + private static function getFolderMuteConfigNameTemplate() + { + if (self::$folderMuteConfigNameTemplate == null) { + self::$folderMuteConfigNameTemplate = new PathTemplate('folders/{folder}/muteConfigs/{mute_config}'); + } + + return self::$folderMuteConfigNameTemplate; + } + + private static function getFolderNotificationConfigNameTemplate() + { + if (self::$folderNotificationConfigNameTemplate == null) { + self::$folderNotificationConfigNameTemplate = new PathTemplate('folders/{folder}/notificationConfigs/{notification_config}'); + } + + return self::$folderNotificationConfigNameTemplate; + } + + private static function getFolderSecurityHealthAnalyticsSettingsNameTemplate() + { + if (self::$folderSecurityHealthAnalyticsSettingsNameTemplate == null) { + self::$folderSecurityHealthAnalyticsSettingsNameTemplate = new PathTemplate('folders/{folder}/securityHealthAnalyticsSettings'); + } + + return self::$folderSecurityHealthAnalyticsSettingsNameTemplate; + } + + private static function getFolderSourceNameTemplate() + { + if (self::$folderSourceNameTemplate == null) { + self::$folderSourceNameTemplate = new PathTemplate('folders/{folder}/sources/{source}'); + } + + return self::$folderSourceNameTemplate; + } + + private static function getFolderSourceFindingNameTemplate() + { + if (self::$folderSourceFindingNameTemplate == null) { + self::$folderSourceFindingNameTemplate = new PathTemplate('folders/{folder}/sources/{source}/findings/{finding}'); + } + + return self::$folderSourceFindingNameTemplate; + } + + private static function getFolderSourceFindingExternalsystemNameTemplate() + { + if (self::$folderSourceFindingExternalsystemNameTemplate == null) { + self::$folderSourceFindingExternalsystemNameTemplate = new PathTemplate('folders/{folder}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}'); + } + + return self::$folderSourceFindingExternalsystemNameTemplate; + } + + private static function getFolderSourceFindingSecurityMarksNameTemplate() + { + if (self::$folderSourceFindingSecurityMarksNameTemplate == null) { + self::$folderSourceFindingSecurityMarksNameTemplate = new PathTemplate('folders/{folder}/sources/{source}/findings/{finding}/securityMarks'); + } + + return self::$folderSourceFindingSecurityMarksNameTemplate; + } + + private static function getMuteConfigNameTemplate() + { + if (self::$muteConfigNameTemplate == null) { + self::$muteConfigNameTemplate = new PathTemplate('organizations/{organization}/muteConfigs/{mute_config}'); + } + + return self::$muteConfigNameTemplate; + } + + private static function getNotificationConfigNameTemplate() + { + if (self::$notificationConfigNameTemplate == null) { + self::$notificationConfigNameTemplate = new PathTemplate('organizations/{organization}/notificationConfigs/{notification_config}'); + } + + return self::$notificationConfigNameTemplate; + } + + private static function getOrganizationNameTemplate() + { + if (self::$organizationNameTemplate == null) { + self::$organizationNameTemplate = new PathTemplate('organizations/{organization}'); + } + + return self::$organizationNameTemplate; + } + + private static function getOrganizationAssetSecurityMarksNameTemplate() + { + if (self::$organizationAssetSecurityMarksNameTemplate == null) { + self::$organizationAssetSecurityMarksNameTemplate = new PathTemplate('organizations/{organization}/assets/{asset}/securityMarks'); + } + + return self::$organizationAssetSecurityMarksNameTemplate; + } + + private static function getOrganizationConstraintNameNameTemplate() + { + if (self::$organizationConstraintNameNameTemplate == null) { + self::$organizationConstraintNameNameTemplate = new PathTemplate('organizations/{organization}/policies/{constraint_name}'); + } + + return self::$organizationConstraintNameNameTemplate; + } + + private static function getOrganizationCustomModuleNameTemplate() + { + if (self::$organizationCustomModuleNameTemplate == null) { + self::$organizationCustomModuleNameTemplate = new PathTemplate('organizations/{organization}/securityHealthAnalyticsSettings/customModules/{custom_module}'); + } + + return self::$organizationCustomModuleNameTemplate; + } + + private static function getOrganizationEffectiveCustomModuleNameTemplate() + { + if (self::$organizationEffectiveCustomModuleNameTemplate == null) { + self::$organizationEffectiveCustomModuleNameTemplate = new PathTemplate('organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module}'); + } + + return self::$organizationEffectiveCustomModuleNameTemplate; + } + + private static function getOrganizationExportNameTemplate() + { + if (self::$organizationExportNameTemplate == null) { + self::$organizationExportNameTemplate = new PathTemplate('organizations/{organization}/bigQueryExports/{export}'); + } + + return self::$organizationExportNameTemplate; + } + + private static function getOrganizationMuteConfigNameTemplate() + { + if (self::$organizationMuteConfigNameTemplate == null) { + self::$organizationMuteConfigNameTemplate = new PathTemplate('organizations/{organization}/muteConfigs/{mute_config}'); + } + + return self::$organizationMuteConfigNameTemplate; + } + + private static function getOrganizationNotificationConfigNameTemplate() + { + if (self::$organizationNotificationConfigNameTemplate == null) { + self::$organizationNotificationConfigNameTemplate = new PathTemplate('organizations/{organization}/notificationConfigs/{notification_config}'); + } + + return self::$organizationNotificationConfigNameTemplate; + } + + private static function getOrganizationSecurityHealthAnalyticsSettingsNameTemplate() + { + if (self::$organizationSecurityHealthAnalyticsSettingsNameTemplate == null) { + self::$organizationSecurityHealthAnalyticsSettingsNameTemplate = new PathTemplate('organizations/{organization}/securityHealthAnalyticsSettings'); + } + + return self::$organizationSecurityHealthAnalyticsSettingsNameTemplate; + } + + private static function getOrganizationSettingsNameTemplate() + { + if (self::$organizationSettingsNameTemplate == null) { + self::$organizationSettingsNameTemplate = new PathTemplate('organizations/{organization}/organizationSettings'); + } + + return self::$organizationSettingsNameTemplate; + } + + private static function getOrganizationSourceNameTemplate() + { + if (self::$organizationSourceNameTemplate == null) { + self::$organizationSourceNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}'); + } + + return self::$organizationSourceNameTemplate; + } + + private static function getOrganizationSourceFindingNameTemplate() + { + if (self::$organizationSourceFindingNameTemplate == null) { + self::$organizationSourceFindingNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}/findings/{finding}'); + } + + return self::$organizationSourceFindingNameTemplate; + } + + private static function getOrganizationSourceFindingExternalsystemNameTemplate() + { + if (self::$organizationSourceFindingExternalsystemNameTemplate == null) { + self::$organizationSourceFindingExternalsystemNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}'); + } + + return self::$organizationSourceFindingExternalsystemNameTemplate; + } + + private static function getOrganizationSourceFindingSecurityMarksNameTemplate() + { + if (self::$organizationSourceFindingSecurityMarksNameTemplate == null) { + self::$organizationSourceFindingSecurityMarksNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}/findings/{finding}/securityMarks'); + } + + return self::$organizationSourceFindingSecurityMarksNameTemplate; + } + + private static function getPolicyNameTemplate() + { + if (self::$policyNameTemplate == null) { + self::$policyNameTemplate = new PathTemplate('organizations/{organization}/policies/{constraint_name}'); + } + + return self::$policyNameTemplate; + } + + private static function getProjectNameTemplate() + { + if (self::$projectNameTemplate == null) { + self::$projectNameTemplate = new PathTemplate('projects/{project}'); + } + + return self::$projectNameTemplate; + } + + private static function getProjectAssetSecurityMarksNameTemplate() + { + if (self::$projectAssetSecurityMarksNameTemplate == null) { + self::$projectAssetSecurityMarksNameTemplate = new PathTemplate('projects/{project}/assets/{asset}/securityMarks'); + } + + return self::$projectAssetSecurityMarksNameTemplate; + } + + private static function getProjectConstraintNameNameTemplate() + { + if (self::$projectConstraintNameNameTemplate == null) { + self::$projectConstraintNameNameTemplate = new PathTemplate('projects/{project}/policies/{constraint_name}'); + } + + return self::$projectConstraintNameNameTemplate; + } + + private static function getProjectCustomModuleNameTemplate() + { + if (self::$projectCustomModuleNameTemplate == null) { + self::$projectCustomModuleNameTemplate = new PathTemplate('projects/{project}/securityHealthAnalyticsSettings/customModules/{custom_module}'); + } + + return self::$projectCustomModuleNameTemplate; + } + + private static function getProjectDlpJobNameTemplate() + { + if (self::$projectDlpJobNameTemplate == null) { + self::$projectDlpJobNameTemplate = new PathTemplate('projects/{project}/dlpJobs/{dlp_job}'); + } + + return self::$projectDlpJobNameTemplate; + } + + private static function getProjectEffectiveCustomModuleNameTemplate() + { + if (self::$projectEffectiveCustomModuleNameTemplate == null) { + self::$projectEffectiveCustomModuleNameTemplate = new PathTemplate('projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module}'); + } + + return self::$projectEffectiveCustomModuleNameTemplate; + } + + private static function getProjectExportNameTemplate() + { + if (self::$projectExportNameTemplate == null) { + self::$projectExportNameTemplate = new PathTemplate('projects/{project}/bigQueryExports/{export}'); + } + + return self::$projectExportNameTemplate; + } + + private static function getProjectLocationDlpJobNameTemplate() + { + if (self::$projectLocationDlpJobNameTemplate == null) { + self::$projectLocationDlpJobNameTemplate = new PathTemplate('projects/{project}/locations/{location}/dlpJobs/{dlp_job}'); + } + + return self::$projectLocationDlpJobNameTemplate; + } + + private static function getProjectLocationTableProfileNameTemplate() + { + if (self::$projectLocationTableProfileNameTemplate == null) { + self::$projectLocationTableProfileNameTemplate = new PathTemplate('projects/{project}/locations/{location}/tableProfiles/{table_profile}'); + } + + return self::$projectLocationTableProfileNameTemplate; + } + + private static function getProjectMuteConfigNameTemplate() + { + if (self::$projectMuteConfigNameTemplate == null) { + self::$projectMuteConfigNameTemplate = new PathTemplate('projects/{project}/muteConfigs/{mute_config}'); + } + + return self::$projectMuteConfigNameTemplate; + } + + private static function getProjectNotificationConfigNameTemplate() + { + if (self::$projectNotificationConfigNameTemplate == null) { + self::$projectNotificationConfigNameTemplate = new PathTemplate('projects/{project}/notificationConfigs/{notification_config}'); + } + + return self::$projectNotificationConfigNameTemplate; + } + + private static function getProjectSecurityHealthAnalyticsSettingsNameTemplate() + { + if (self::$projectSecurityHealthAnalyticsSettingsNameTemplate == null) { + self::$projectSecurityHealthAnalyticsSettingsNameTemplate = new PathTemplate('projects/{project}/securityHealthAnalyticsSettings'); + } + + return self::$projectSecurityHealthAnalyticsSettingsNameTemplate; + } + + private static function getProjectSourceNameTemplate() + { + if (self::$projectSourceNameTemplate == null) { + self::$projectSourceNameTemplate = new PathTemplate('projects/{project}/sources/{source}'); + } + + return self::$projectSourceNameTemplate; + } + + private static function getProjectSourceFindingNameTemplate() + { + if (self::$projectSourceFindingNameTemplate == null) { + self::$projectSourceFindingNameTemplate = new PathTemplate('projects/{project}/sources/{source}/findings/{finding}'); + } + + return self::$projectSourceFindingNameTemplate; + } + + private static function getProjectSourceFindingExternalsystemNameTemplate() + { + if (self::$projectSourceFindingExternalsystemNameTemplate == null) { + self::$projectSourceFindingExternalsystemNameTemplate = new PathTemplate('projects/{project}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}'); + } + + return self::$projectSourceFindingExternalsystemNameTemplate; + } + + private static function getProjectSourceFindingSecurityMarksNameTemplate() + { + if (self::$projectSourceFindingSecurityMarksNameTemplate == null) { + self::$projectSourceFindingSecurityMarksNameTemplate = new PathTemplate('projects/{project}/sources/{source}/findings/{finding}/securityMarks'); + } + + return self::$projectSourceFindingSecurityMarksNameTemplate; + } + + private static function getProjectTableProfileNameTemplate() + { + if (self::$projectTableProfileNameTemplate == null) { + self::$projectTableProfileNameTemplate = new PathTemplate('projects/{project}/tableProfiles/{table_profile}'); + } + + return self::$projectTableProfileNameTemplate; + } + + private static function getSecurityHealthAnalyticsCustomModuleNameTemplate() + { + if (self::$securityHealthAnalyticsCustomModuleNameTemplate == null) { + self::$securityHealthAnalyticsCustomModuleNameTemplate = new PathTemplate('organizations/{organization}/securityHealthAnalyticsSettings/customModules/{custom_module}'); + } + + return self::$securityHealthAnalyticsCustomModuleNameTemplate; + } + + private static function getSecurityHealthAnalyticsSettingsNameTemplate() + { + if (self::$securityHealthAnalyticsSettingsNameTemplate == null) { + self::$securityHealthAnalyticsSettingsNameTemplate = new PathTemplate('organizations/{organization}/securityHealthAnalyticsSettings'); + } + + return self::$securityHealthAnalyticsSettingsNameTemplate; + } + + private static function getSecurityMarksNameTemplate() + { + if (self::$securityMarksNameTemplate == null) { + self::$securityMarksNameTemplate = new PathTemplate('organizations/{organization}/assets/{asset}/securityMarks'); + } + + return self::$securityMarksNameTemplate; + } + + private static function getSourceNameTemplate() + { + if (self::$sourceNameTemplate == null) { + self::$sourceNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}'); + } + + return self::$sourceNameTemplate; + } + + private static function getTableDataProfileNameTemplate() + { + if (self::$tableDataProfileNameTemplate == null) { + self::$tableDataProfileNameTemplate = new PathTemplate('projects/{project}/tableProfiles/{table_profile}'); + } + + return self::$tableDataProfileNameTemplate; + } + + private static function getTopicNameTemplate() + { + if (self::$topicNameTemplate == null) { + self::$topicNameTemplate = new PathTemplate('projects/{project}/topics/{topic}'); + } + + return self::$topicNameTemplate; + } + + private static function getPathTemplateMap() + { + if (self::$pathTemplateMap == null) { + self::$pathTemplateMap = [ + 'bigQueryExport' => self::getBigQueryExportNameTemplate(), + 'dlpJob' => self::getDlpJobNameTemplate(), + 'effectiveSecurityHealthAnalyticsCustomModule' => self::getEffectiveSecurityHealthAnalyticsCustomModuleNameTemplate(), + 'externalSystem' => self::getExternalSystemNameTemplate(), + 'finding' => self::getFindingNameTemplate(), + 'folder' => self::getFolderNameTemplate(), + 'folderAssetSecurityMarks' => self::getFolderAssetSecurityMarksNameTemplate(), + 'folderConstraintName' => self::getFolderConstraintNameNameTemplate(), + 'folderCustomModule' => self::getFolderCustomModuleNameTemplate(), + 'folderEffectiveCustomModule' => self::getFolderEffectiveCustomModuleNameTemplate(), + 'folderExport' => self::getFolderExportNameTemplate(), + 'folderMuteConfig' => self::getFolderMuteConfigNameTemplate(), + 'folderNotificationConfig' => self::getFolderNotificationConfigNameTemplate(), + 'folderSecurityHealthAnalyticsSettings' => self::getFolderSecurityHealthAnalyticsSettingsNameTemplate(), + 'folderSource' => self::getFolderSourceNameTemplate(), + 'folderSourceFinding' => self::getFolderSourceFindingNameTemplate(), + 'folderSourceFindingExternalsystem' => self::getFolderSourceFindingExternalsystemNameTemplate(), + 'folderSourceFindingSecurityMarks' => self::getFolderSourceFindingSecurityMarksNameTemplate(), + 'muteConfig' => self::getMuteConfigNameTemplate(), + 'notificationConfig' => self::getNotificationConfigNameTemplate(), + 'organization' => self::getOrganizationNameTemplate(), + 'organizationAssetSecurityMarks' => self::getOrganizationAssetSecurityMarksNameTemplate(), + 'organizationConstraintName' => self::getOrganizationConstraintNameNameTemplate(), + 'organizationCustomModule' => self::getOrganizationCustomModuleNameTemplate(), + 'organizationEffectiveCustomModule' => self::getOrganizationEffectiveCustomModuleNameTemplate(), + 'organizationExport' => self::getOrganizationExportNameTemplate(), + 'organizationMuteConfig' => self::getOrganizationMuteConfigNameTemplate(), + 'organizationNotificationConfig' => self::getOrganizationNotificationConfigNameTemplate(), + 'organizationSecurityHealthAnalyticsSettings' => self::getOrganizationSecurityHealthAnalyticsSettingsNameTemplate(), + 'organizationSettings' => self::getOrganizationSettingsNameTemplate(), + 'organizationSource' => self::getOrganizationSourceNameTemplate(), + 'organizationSourceFinding' => self::getOrganizationSourceFindingNameTemplate(), + 'organizationSourceFindingExternalsystem' => self::getOrganizationSourceFindingExternalsystemNameTemplate(), + 'organizationSourceFindingSecurityMarks' => self::getOrganizationSourceFindingSecurityMarksNameTemplate(), + 'policy' => self::getPolicyNameTemplate(), + 'project' => self::getProjectNameTemplate(), + 'projectAssetSecurityMarks' => self::getProjectAssetSecurityMarksNameTemplate(), + 'projectConstraintName' => self::getProjectConstraintNameNameTemplate(), + 'projectCustomModule' => self::getProjectCustomModuleNameTemplate(), + 'projectDlpJob' => self::getProjectDlpJobNameTemplate(), + 'projectEffectiveCustomModule' => self::getProjectEffectiveCustomModuleNameTemplate(), + 'projectExport' => self::getProjectExportNameTemplate(), + 'projectLocationDlpJob' => self::getProjectLocationDlpJobNameTemplate(), + 'projectLocationTableProfile' => self::getProjectLocationTableProfileNameTemplate(), + 'projectMuteConfig' => self::getProjectMuteConfigNameTemplate(), + 'projectNotificationConfig' => self::getProjectNotificationConfigNameTemplate(), + 'projectSecurityHealthAnalyticsSettings' => self::getProjectSecurityHealthAnalyticsSettingsNameTemplate(), + 'projectSource' => self::getProjectSourceNameTemplate(), + 'projectSourceFinding' => self::getProjectSourceFindingNameTemplate(), + 'projectSourceFindingExternalsystem' => self::getProjectSourceFindingExternalsystemNameTemplate(), + 'projectSourceFindingSecurityMarks' => self::getProjectSourceFindingSecurityMarksNameTemplate(), + 'projectTableProfile' => self::getProjectTableProfileNameTemplate(), + 'securityHealthAnalyticsCustomModule' => self::getSecurityHealthAnalyticsCustomModuleNameTemplate(), + 'securityHealthAnalyticsSettings' => self::getSecurityHealthAnalyticsSettingsNameTemplate(), + 'securityMarks' => self::getSecurityMarksNameTemplate(), + 'source' => self::getSourceNameTemplate(), + 'tableDataProfile' => self::getTableDataProfileNameTemplate(), + 'topic' => self::getTopicNameTemplate(), + ]; + } + + return self::$pathTemplateMap; + } + + /** + * Formats a string containing the fully-qualified path to represent a + * big_query_export resource. + * + * @param string $organization + * @param string $export + * + * @return string The formatted big_query_export resource. + */ + public static function bigQueryExportName($organization, $export) + { + return self::getBigQueryExportNameTemplate()->render([ + 'organization' => $organization, + 'export' => $export, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a dlp_job + * resource. + * + * @param string $project + * @param string $dlpJob + * + * @return string The formatted dlp_job resource. + */ + public static function dlpJobName($project, $dlpJob) + { + return self::getDlpJobNameTemplate()->render([ + 'project' => $project, + 'dlp_job' => $dlpJob, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * effective_security_health_analytics_custom_module resource. + * + * @param string $organization + * @param string $effectiveCustomModule + * + * @return string The formatted effective_security_health_analytics_custom_module resource. + */ + public static function effectiveSecurityHealthAnalyticsCustomModuleName($organization, $effectiveCustomModule) + { + return self::getEffectiveSecurityHealthAnalyticsCustomModuleNameTemplate()->render([ + 'organization' => $organization, + 'effective_custom_module' => $effectiveCustomModule, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * external_system resource. + * + * @param string $organization + * @param string $source + * @param string $finding + * @param string $externalsystem + * + * @return string The formatted external_system resource. + */ + public static function externalSystemName($organization, $source, $finding, $externalsystem) + { + return self::getExternalSystemNameTemplate()->render([ + 'organization' => $organization, + 'source' => $source, + 'finding' => $finding, + 'externalsystem' => $externalsystem, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a finding + * resource. + * + * @param string $organization + * @param string $source + * @param string $finding + * + * @return string The formatted finding resource. + */ + public static function findingName($organization, $source, $finding) + { + return self::getFindingNameTemplate()->render([ + 'organization' => $organization, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a folder + * resource. + * + * @param string $folder + * + * @return string The formatted folder resource. + */ + public static function folderName($folder) + { + return self::getFolderNameTemplate()->render([ + 'folder' => $folder, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_asset_securityMarks resource. + * + * @param string $folder + * @param string $asset + * + * @return string The formatted folder_asset_securityMarks resource. + */ + public static function folderAssetSecurityMarksName($folder, $asset) + { + return self::getFolderAssetSecurityMarksNameTemplate()->render([ + 'folder' => $folder, + 'asset' => $asset, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_constraint_name resource. + * + * @param string $folder + * @param string $constraintName + * + * @return string The formatted folder_constraint_name resource. + */ + public static function folderConstraintNameName($folder, $constraintName) + { + return self::getFolderConstraintNameNameTemplate()->render([ + 'folder' => $folder, + 'constraint_name' => $constraintName, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_custom_module resource. + * + * @param string $folder + * @param string $customModule + * + * @return string The formatted folder_custom_module resource. + */ + public static function folderCustomModuleName($folder, $customModule) + { + return self::getFolderCustomModuleNameTemplate()->render([ + 'folder' => $folder, + 'custom_module' => $customModule, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_effective_custom_module resource. + * + * @param string $folder + * @param string $effectiveCustomModule + * + * @return string The formatted folder_effective_custom_module resource. + */ + public static function folderEffectiveCustomModuleName($folder, $effectiveCustomModule) + { + return self::getFolderEffectiveCustomModuleNameTemplate()->render([ + 'folder' => $folder, + 'effective_custom_module' => $effectiveCustomModule, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_export resource. + * + * @param string $folder + * @param string $export + * + * @return string The formatted folder_export resource. + */ + public static function folderExportName($folder, $export) + { + return self::getFolderExportNameTemplate()->render([ + 'folder' => $folder, + 'export' => $export, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_mute_config resource. + * + * @param string $folder + * @param string $muteConfig + * + * @return string The formatted folder_mute_config resource. + */ + public static function folderMuteConfigName($folder, $muteConfig) + { + return self::getFolderMuteConfigNameTemplate()->render([ + 'folder' => $folder, + 'mute_config' => $muteConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_notification_config resource. + * + * @param string $folder + * @param string $notificationConfig + * + * @return string The formatted folder_notification_config resource. + */ + public static function folderNotificationConfigName($folder, $notificationConfig) + { + return self::getFolderNotificationConfigNameTemplate()->render([ + 'folder' => $folder, + 'notification_config' => $notificationConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_securityHealthAnalyticsSettings resource. + * + * @param string $folder + * + * @return string The formatted folder_securityHealthAnalyticsSettings resource. + */ + public static function folderSecurityHealthAnalyticsSettingsName($folder) + { + return self::getFolderSecurityHealthAnalyticsSettingsNameTemplate()->render([ + 'folder' => $folder, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_source resource. + * + * @param string $folder + * @param string $source + * + * @return string The formatted folder_source resource. + */ + public static function folderSourceName($folder, $source) + { + return self::getFolderSourceNameTemplate()->render([ + 'folder' => $folder, + 'source' => $source, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_source_finding resource. + * + * @param string $folder + * @param string $source + * @param string $finding + * + * @return string The formatted folder_source_finding resource. + */ + public static function folderSourceFindingName($folder, $source, $finding) + { + return self::getFolderSourceFindingNameTemplate()->render([ + 'folder' => $folder, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_source_finding_externalsystem resource. + * + * @param string $folder + * @param string $source + * @param string $finding + * @param string $externalsystem + * + * @return string The formatted folder_source_finding_externalsystem resource. + */ + public static function folderSourceFindingExternalsystemName($folder, $source, $finding, $externalsystem) + { + return self::getFolderSourceFindingExternalsystemNameTemplate()->render([ + 'folder' => $folder, + 'source' => $source, + 'finding' => $finding, + 'externalsystem' => $externalsystem, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_source_finding_securityMarks resource. + * + * @param string $folder + * @param string $source + * @param string $finding + * + * @return string The formatted folder_source_finding_securityMarks resource. + */ + public static function folderSourceFindingSecurityMarksName($folder, $source, $finding) + { + return self::getFolderSourceFindingSecurityMarksNameTemplate()->render([ + 'folder' => $folder, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a mute_config + * resource. + * + * @param string $organization + * @param string $muteConfig + * + * @return string The formatted mute_config resource. + */ + public static function muteConfigName($organization, $muteConfig) + { + return self::getMuteConfigNameTemplate()->render([ + 'organization' => $organization, + 'mute_config' => $muteConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * notification_config resource. + * + * @param string $organization + * @param string $notificationConfig + * + * @return string The formatted notification_config resource. + */ + public static function notificationConfigName($organization, $notificationConfig) + { + return self::getNotificationConfigNameTemplate()->render([ + 'organization' => $organization, + 'notification_config' => $notificationConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a organization + * resource. + * + * @param string $organization + * + * @return string The formatted organization resource. + */ + public static function organizationName($organization) + { + return self::getOrganizationNameTemplate()->render([ + 'organization' => $organization, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_asset_securityMarks resource. + * + * @param string $organization + * @param string $asset + * + * @return string The formatted organization_asset_securityMarks resource. + */ + public static function organizationAssetSecurityMarksName($organization, $asset) + { + return self::getOrganizationAssetSecurityMarksNameTemplate()->render([ + 'organization' => $organization, + 'asset' => $asset, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_constraint_name resource. + * + * @param string $organization + * @param string $constraintName + * + * @return string The formatted organization_constraint_name resource. + */ + public static function organizationConstraintNameName($organization, $constraintName) + { + return self::getOrganizationConstraintNameNameTemplate()->render([ + 'organization' => $organization, + 'constraint_name' => $constraintName, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_custom_module resource. + * + * @param string $organization + * @param string $customModule + * + * @return string The formatted organization_custom_module resource. + */ + public static function organizationCustomModuleName($organization, $customModule) + { + return self::getOrganizationCustomModuleNameTemplate()->render([ + 'organization' => $organization, + 'custom_module' => $customModule, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_effective_custom_module resource. + * + * @param string $organization + * @param string $effectiveCustomModule + * + * @return string The formatted organization_effective_custom_module resource. + */ + public static function organizationEffectiveCustomModuleName($organization, $effectiveCustomModule) + { + return self::getOrganizationEffectiveCustomModuleNameTemplate()->render([ + 'organization' => $organization, + 'effective_custom_module' => $effectiveCustomModule, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_export resource. + * + * @param string $organization + * @param string $export + * + * @return string The formatted organization_export resource. + */ + public static function organizationExportName($organization, $export) + { + return self::getOrganizationExportNameTemplate()->render([ + 'organization' => $organization, + 'export' => $export, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_mute_config resource. + * + * @param string $organization + * @param string $muteConfig + * + * @return string The formatted organization_mute_config resource. + */ + public static function organizationMuteConfigName($organization, $muteConfig) + { + return self::getOrganizationMuteConfigNameTemplate()->render([ + 'organization' => $organization, + 'mute_config' => $muteConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_notification_config resource. + * + * @param string $organization + * @param string $notificationConfig + * + * @return string The formatted organization_notification_config resource. + */ + public static function organizationNotificationConfigName($organization, $notificationConfig) + { + return self::getOrganizationNotificationConfigNameTemplate()->render([ + 'organization' => $organization, + 'notification_config' => $notificationConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_securityHealthAnalyticsSettings resource. + * + * @param string $organization + * + * @return string The formatted organization_securityHealthAnalyticsSettings resource. + */ + public static function organizationSecurityHealthAnalyticsSettingsName($organization) + { + return self::getOrganizationSecurityHealthAnalyticsSettingsNameTemplate()->render([ + 'organization' => $organization, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_settings resource. + * + * @param string $organization + * + * @return string The formatted organization_settings resource. + */ + public static function organizationSettingsName($organization) + { + return self::getOrganizationSettingsNameTemplate()->render([ + 'organization' => $organization, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_source resource. + * + * @param string $organization + * @param string $source + * + * @return string The formatted organization_source resource. + */ + public static function organizationSourceName($organization, $source) + { + return self::getOrganizationSourceNameTemplate()->render([ + 'organization' => $organization, + 'source' => $source, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_source_finding resource. + * + * @param string $organization + * @param string $source + * @param string $finding + * + * @return string The formatted organization_source_finding resource. + */ + public static function organizationSourceFindingName($organization, $source, $finding) + { + return self::getOrganizationSourceFindingNameTemplate()->render([ + 'organization' => $organization, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_source_finding_externalsystem resource. + * + * @param string $organization + * @param string $source + * @param string $finding + * @param string $externalsystem + * + * @return string The formatted organization_source_finding_externalsystem resource. + */ + public static function organizationSourceFindingExternalsystemName($organization, $source, $finding, $externalsystem) + { + return self::getOrganizationSourceFindingExternalsystemNameTemplate()->render([ + 'organization' => $organization, + 'source' => $source, + 'finding' => $finding, + 'externalsystem' => $externalsystem, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_source_finding_securityMarks resource. + * + * @param string $organization + * @param string $source + * @param string $finding + * + * @return string The formatted organization_source_finding_securityMarks resource. + */ + public static function organizationSourceFindingSecurityMarksName($organization, $source, $finding) + { + return self::getOrganizationSourceFindingSecurityMarksNameTemplate()->render([ + 'organization' => $organization, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a policy + * resource. + * + * @param string $organization + * @param string $constraintName + * + * @return string The formatted policy resource. + */ + public static function policyName($organization, $constraintName) + { + return self::getPolicyNameTemplate()->render([ + 'organization' => $organization, + 'constraint_name' => $constraintName, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a project + * resource. + * + * @param string $project + * + * @return string The formatted project resource. + */ + public static function projectName($project) + { + return self::getProjectNameTemplate()->render([ + 'project' => $project, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_asset_securityMarks resource. + * + * @param string $project + * @param string $asset + * + * @return string The formatted project_asset_securityMarks resource. + */ + public static function projectAssetSecurityMarksName($project, $asset) + { + return self::getProjectAssetSecurityMarksNameTemplate()->render([ + 'project' => $project, + 'asset' => $asset, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_constraint_name resource. + * + * @param string $project + * @param string $constraintName + * + * @return string The formatted project_constraint_name resource. + */ + public static function projectConstraintNameName($project, $constraintName) + { + return self::getProjectConstraintNameNameTemplate()->render([ + 'project' => $project, + 'constraint_name' => $constraintName, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_custom_module resource. + * + * @param string $project + * @param string $customModule + * + * @return string The formatted project_custom_module resource. + */ + public static function projectCustomModuleName($project, $customModule) + { + return self::getProjectCustomModuleNameTemplate()->render([ + 'project' => $project, + 'custom_module' => $customModule, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_dlp_job resource. + * + * @param string $project + * @param string $dlpJob + * + * @return string The formatted project_dlp_job resource. + */ + public static function projectDlpJobName($project, $dlpJob) + { + return self::getProjectDlpJobNameTemplate()->render([ + 'project' => $project, + 'dlp_job' => $dlpJob, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_effective_custom_module resource. + * + * @param string $project + * @param string $effectiveCustomModule + * + * @return string The formatted project_effective_custom_module resource. + */ + public static function projectEffectiveCustomModuleName($project, $effectiveCustomModule) + { + return self::getProjectEffectiveCustomModuleNameTemplate()->render([ + 'project' => $project, + 'effective_custom_module' => $effectiveCustomModule, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_export resource. + * + * @param string $project + * @param string $export + * + * @return string The formatted project_export resource. + */ + public static function projectExportName($project, $export) + { + return self::getProjectExportNameTemplate()->render([ + 'project' => $project, + 'export' => $export, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_dlp_job resource. + * + * @param string $project + * @param string $location + * @param string $dlpJob + * + * @return string The formatted project_location_dlp_job resource. + */ + public static function projectLocationDlpJobName($project, $location, $dlpJob) + { + return self::getProjectLocationDlpJobNameTemplate()->render([ + 'project' => $project, + 'location' => $location, + 'dlp_job' => $dlpJob, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_table_profile resource. + * + * @param string $project + * @param string $location + * @param string $tableProfile + * + * @return string The formatted project_location_table_profile resource. + */ + public static function projectLocationTableProfileName($project, $location, $tableProfile) + { + return self::getProjectLocationTableProfileNameTemplate()->render([ + 'project' => $project, + 'location' => $location, + 'table_profile' => $tableProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_mute_config resource. + * + * @param string $project + * @param string $muteConfig + * + * @return string The formatted project_mute_config resource. + */ + public static function projectMuteConfigName($project, $muteConfig) + { + return self::getProjectMuteConfigNameTemplate()->render([ + 'project' => $project, + 'mute_config' => $muteConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_notification_config resource. + * + * @param string $project + * @param string $notificationConfig + * + * @return string The formatted project_notification_config resource. + */ + public static function projectNotificationConfigName($project, $notificationConfig) + { + return self::getProjectNotificationConfigNameTemplate()->render([ + 'project' => $project, + 'notification_config' => $notificationConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_securityHealthAnalyticsSettings resource. + * + * @param string $project + * + * @return string The formatted project_securityHealthAnalyticsSettings resource. + */ + public static function projectSecurityHealthAnalyticsSettingsName($project) + { + return self::getProjectSecurityHealthAnalyticsSettingsNameTemplate()->render([ + 'project' => $project, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_source resource. + * + * @param string $project + * @param string $source + * + * @return string The formatted project_source resource. + */ + public static function projectSourceName($project, $source) + { + return self::getProjectSourceNameTemplate()->render([ + 'project' => $project, + 'source' => $source, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_source_finding resource. + * + * @param string $project + * @param string $source + * @param string $finding + * + * @return string The formatted project_source_finding resource. + */ + public static function projectSourceFindingName($project, $source, $finding) + { + return self::getProjectSourceFindingNameTemplate()->render([ + 'project' => $project, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_source_finding_externalsystem resource. + * + * @param string $project + * @param string $source + * @param string $finding + * @param string $externalsystem + * + * @return string The formatted project_source_finding_externalsystem resource. + */ + public static function projectSourceFindingExternalsystemName($project, $source, $finding, $externalsystem) + { + return self::getProjectSourceFindingExternalsystemNameTemplate()->render([ + 'project' => $project, + 'source' => $source, + 'finding' => $finding, + 'externalsystem' => $externalsystem, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_source_finding_securityMarks resource. + * + * @param string $project + * @param string $source + * @param string $finding + * + * @return string The formatted project_source_finding_securityMarks resource. + */ + public static function projectSourceFindingSecurityMarksName($project, $source, $finding) + { + return self::getProjectSourceFindingSecurityMarksNameTemplate()->render([ + 'project' => $project, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_table_profile resource. + * + * @param string $project + * @param string $tableProfile + * + * @return string The formatted project_table_profile resource. + */ + public static function projectTableProfileName($project, $tableProfile) + { + return self::getProjectTableProfileNameTemplate()->render([ + 'project' => $project, + 'table_profile' => $tableProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * security_health_analytics_custom_module resource. + * + * @param string $organization + * @param string $customModule + * + * @return string The formatted security_health_analytics_custom_module resource. + */ + public static function securityHealthAnalyticsCustomModuleName($organization, $customModule) + { + return self::getSecurityHealthAnalyticsCustomModuleNameTemplate()->render([ + 'organization' => $organization, + 'custom_module' => $customModule, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * security_health_analytics_settings resource. + * + * @param string $organization + * + * @return string The formatted security_health_analytics_settings resource. + */ + public static function securityHealthAnalyticsSettingsName($organization) + { + return self::getSecurityHealthAnalyticsSettingsNameTemplate()->render([ + 'organization' => $organization, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * security_marks resource. + * + * @param string $organization + * @param string $asset + * + * @return string The formatted security_marks resource. + */ + public static function securityMarksName($organization, $asset) + { + return self::getSecurityMarksNameTemplate()->render([ + 'organization' => $organization, + 'asset' => $asset, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a source + * resource. + * + * @param string $organization + * @param string $source + * + * @return string The formatted source resource. + */ + public static function sourceName($organization, $source) + { + return self::getSourceNameTemplate()->render([ + 'organization' => $organization, + 'source' => $source, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * table_data_profile resource. + * + * @param string $project + * @param string $tableProfile + * + * @return string The formatted table_data_profile resource. + */ + public static function tableDataProfileName($project, $tableProfile) + { + return self::getTableDataProfileNameTemplate()->render([ + 'project' => $project, + 'table_profile' => $tableProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a topic + * resource. + * + * @param string $project + * @param string $topic + * + * @return string The formatted topic resource. + */ + public static function topicName($project, $topic) + { + return self::getTopicNameTemplate()->render([ + 'project' => $project, + 'topic' => $topic, + ]); + } + + /** + * Parses a formatted name string and returns an associative array of the components in the name. + * The following name formats are supported: + * Template: Pattern + * - bigQueryExport: organizations/{organization}/bigQueryExports/{export} + * - dlpJob: projects/{project}/dlpJobs/{dlp_job} + * - effectiveSecurityHealthAnalyticsCustomModule: organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module} + * - externalSystem: organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} + * - finding: organizations/{organization}/sources/{source}/findings/{finding} + * - folder: folders/{folder} + * - folderAssetSecurityMarks: folders/{folder}/assets/{asset}/securityMarks + * - folderConstraintName: folders/{folder}/policies/{constraint_name} + * - folderCustomModule: folders/{folder}/securityHealthAnalyticsSettings/customModules/{custom_module} + * - folderEffectiveCustomModule: folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module} + * - folderExport: folders/{folder}/bigQueryExports/{export} + * - folderMuteConfig: folders/{folder}/muteConfigs/{mute_config} + * - folderNotificationConfig: folders/{folder}/notificationConfigs/{notification_config} + * - folderSecurityHealthAnalyticsSettings: folders/{folder}/securityHealthAnalyticsSettings + * - folderSource: folders/{folder}/sources/{source} + * - folderSourceFinding: folders/{folder}/sources/{source}/findings/{finding} + * - folderSourceFindingExternalsystem: folders/{folder}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} + * - folderSourceFindingSecurityMarks: folders/{folder}/sources/{source}/findings/{finding}/securityMarks + * - muteConfig: organizations/{organization}/muteConfigs/{mute_config} + * - notificationConfig: organizations/{organization}/notificationConfigs/{notification_config} + * - organization: organizations/{organization} + * - organizationAssetSecurityMarks: organizations/{organization}/assets/{asset}/securityMarks + * - organizationConstraintName: organizations/{organization}/policies/{constraint_name} + * - organizationCustomModule: organizations/{organization}/securityHealthAnalyticsSettings/customModules/{custom_module} + * - organizationEffectiveCustomModule: organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module} + * - organizationExport: organizations/{organization}/bigQueryExports/{export} + * - organizationMuteConfig: organizations/{organization}/muteConfigs/{mute_config} + * - organizationNotificationConfig: organizations/{organization}/notificationConfigs/{notification_config} + * - organizationSecurityHealthAnalyticsSettings: organizations/{organization}/securityHealthAnalyticsSettings + * - organizationSettings: organizations/{organization}/organizationSettings + * - organizationSource: organizations/{organization}/sources/{source} + * - organizationSourceFinding: organizations/{organization}/sources/{source}/findings/{finding} + * - organizationSourceFindingExternalsystem: organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} + * - organizationSourceFindingSecurityMarks: organizations/{organization}/sources/{source}/findings/{finding}/securityMarks + * - policy: organizations/{organization}/policies/{constraint_name} + * - project: projects/{project} + * - projectAssetSecurityMarks: projects/{project}/assets/{asset}/securityMarks + * - projectConstraintName: projects/{project}/policies/{constraint_name} + * - projectCustomModule: projects/{project}/securityHealthAnalyticsSettings/customModules/{custom_module} + * - projectDlpJob: projects/{project}/dlpJobs/{dlp_job} + * - projectEffectiveCustomModule: projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module} + * - projectExport: projects/{project}/bigQueryExports/{export} + * - projectLocationDlpJob: projects/{project}/locations/{location}/dlpJobs/{dlp_job} + * - projectLocationTableProfile: projects/{project}/locations/{location}/tableProfiles/{table_profile} + * - projectMuteConfig: projects/{project}/muteConfigs/{mute_config} + * - projectNotificationConfig: projects/{project}/notificationConfigs/{notification_config} + * - projectSecurityHealthAnalyticsSettings: projects/{project}/securityHealthAnalyticsSettings + * - projectSource: projects/{project}/sources/{source} + * - projectSourceFinding: projects/{project}/sources/{source}/findings/{finding} + * - projectSourceFindingExternalsystem: projects/{project}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} + * - projectSourceFindingSecurityMarks: projects/{project}/sources/{source}/findings/{finding}/securityMarks + * - projectTableProfile: projects/{project}/tableProfiles/{table_profile} + * - securityHealthAnalyticsCustomModule: organizations/{organization}/securityHealthAnalyticsSettings/customModules/{custom_module} + * - securityHealthAnalyticsSettings: organizations/{organization}/securityHealthAnalyticsSettings + * - securityMarks: organizations/{organization}/assets/{asset}/securityMarks + * - source: organizations/{organization}/sources/{source} + * - tableDataProfile: projects/{project}/tableProfiles/{table_profile} + * - topic: projects/{project}/topics/{topic} + * + * The optional $template argument can be supplied to specify a particular pattern, + * and must match one of the templates listed above. If no $template argument is + * provided, or if the $template argument does not match one of the templates + * listed, then parseName will check each of the supported templates, and return + * the first match. + * + * @param string $formattedName The formatted name string + * @param string $template Optional name of template to match + * + * @return array An associative array from name component IDs to component values. + * + * @throws ValidationException If $formattedName could not be matched. + */ + public static function parseName($formattedName, $template = null) + { + $templateMap = self::getPathTemplateMap(); + if ($template) { + if (!isset($templateMap[$template])) { + throw new ValidationException("Template name $template does not exist"); + } + + return $templateMap[$template]->match($formattedName); + } + + foreach ($templateMap as $templateName => $pathTemplate) { + try { + return $pathTemplate->match($formattedName); + } catch (ValidationException $ex) { + // Swallow the exception to continue trying other path templates + } + } + + throw new ValidationException("Input did not match any known format. Input: $formattedName"); + } + + /** + * Return an OperationsClient object with the same endpoint as $this. + * + * @return OperationsClient + */ + public function getOperationsClient() + { + return $this->operationsClient; + } + + /** + * Resume an existing long running operation that was previously started by a long + * running API method. If $methodName is not provided, or does not match a long + * running API method, then the operation can still be resumed, but the + * OperationResponse object will not deserialize the final response. + * + * @param string $operationName The name of the long running operation + * @param string $methodName The name of the method used to start the operation + * + * @return OperationResponse + */ + public function resumeOperation($operationName, $methodName = null) + { + $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; + $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); + $operation->reload(); + return $operation; + } + + /** + * Constructor. + * + * @param array $options { + * Optional. Options for configuring the service API wrapper. + * + * @type string $apiEndpoint + * The address of the API remote host. May optionally include the port, formatted + * as ":". Default 'securitycenter.googleapis.com:443'. + * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials + * The credentials to be used by the client to authorize API calls. This option + * accepts either a path to a credentials file, or a decoded credentials file as a + * PHP array. + * *Advanced usage*: In addition, this option can also accept a pre-constructed + * {@see \Google\Auth\FetchAuthTokenInterface} object or + * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these + * objects are provided, any settings in $credentialsConfig will be ignored. + * @type array $credentialsConfig + * Options used to configure credentials, including auth token caching, for the + * client. For a full list of supporting configuration options, see + * {@see \Google\ApiCore\CredentialsWrapper::build()} . + * @type bool $disableRetries + * Determines whether or not retries defined by the client configuration should be + * disabled. Defaults to `false`. + * @type string|array $clientConfig + * Client method configuration, including retry settings. This option can be either + * a path to a JSON file, or a PHP array containing the decoded JSON data. By + * default this settings points to the default client config file, which is + * provided in the resources folder. + * @type string|TransportInterface $transport + * The transport used for executing network requests. May be either the string + * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. + * *Advanced usage*: Additionally, it is possible to pass in an already + * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note + * that when this object is provided, any settings in $transportConfig, and any + * $apiEndpoint setting, will be ignored. + * @type array $transportConfig + * Configuration options that will be used to construct the transport. Options for + * each supported transport type should be passed in a key for that transport. For + * example: + * $transportConfig = [ + * 'grpc' => [...], + * 'rest' => [...], + * ]; + * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and + * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the + * supported options. + * @type callable $clientCertSource + * A callable which returns the client cert as a string. This can be used to + * provide a certificate and private key to the transport layer for mTLS. + * } + * + * @throws ValidationException + */ + public function __construct(array $options = []) + { + $clientOptions = $this->buildClientOptions($options); + $this->setClientOptions($clientOptions); + $this->operationsClient = $this->createOperationsClient($clientOptions); + } + + /** + * Kicks off an LRO to bulk mute findings for a parent based on a filter. The + * parent can be either an organization, folder or project. The findings + * matched by the filter will be muted after the LRO is done. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $parent = 'parent'; + * $operationResponse = $securityCenterClient->bulkMuteFindings($parent); + * $operationResponse->pollUntilComplete(); + * if ($operationResponse->operationSucceeded()) { + * $result = $operationResponse->getResult(); + * // doSomethingWith($result) + * } else { + * $error = $operationResponse->getError(); + * // handleError($error) + * } + * // Alternatively: + * // start the operation, keep the operation name, and resume later + * $operationResponse = $securityCenterClient->bulkMuteFindings($parent); + * $operationName = $operationResponse->getName(); + * // ... do other work + * $newOperationResponse = $securityCenterClient->resumeOperation($operationName, 'bulkMuteFindings'); + * while (!$newOperationResponse->isDone()) { + * // ... do other work + * $newOperationResponse->reload(); + * } + * if ($newOperationResponse->operationSucceeded()) { + * $result = $newOperationResponse->getResult(); + * // doSomethingWith($result) + * } else { + * $error = $newOperationResponse->getError(); + * // handleError($error) + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. The parent, at which bulk action needs to be applied. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]". + * @param array $optionalArgs { + * Optional. + * + * @type string $filter + * Expression that identifies findings that should be updated. + * The expression is a list of zero or more restrictions combined + * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` + * has higher precedence than `AND`. + * + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * + * The supported operators are: + * + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * + * The supported value types are: + * + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * @type string $muteAnnotation + * This can be a mute configuration name or any identifier for mute/unmute + * of findings based on the filter. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\OperationResponse + * + * @throws ApiException if the remote call fails + */ + public function bulkMuteFindings($parent, array $optionalArgs = []) + { + $request = new BulkMuteFindingsRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['filter'])) { + $request->setFilter($optionalArgs['filter']); + } + + if (isset($optionalArgs['muteAnnotation'])) { + $request->setMuteAnnotation($optionalArgs['muteAnnotation']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startOperationsCall('BulkMuteFindings', $optionalArgs, $request, $this->getOperationsClient())->wait(); + } + + /** + * Creates a BigQuery export. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); + * $bigQueryExport = new BigQueryExport(); + * $bigQueryExportId = 'big_query_export_id'; + * $response = $securityCenterClient->createBigQueryExport($formattedParent, $bigQueryExport, $bigQueryExportId); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. The name of the parent resource of the new BigQuery export. Its + * format is "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * @param BigQueryExport $bigQueryExport Required. The BigQuery export being created. + * @param string $bigQueryExportId Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\BigQueryExport + * + * @throws ApiException if the remote call fails + */ + public function createBigQueryExport($parent, $bigQueryExport, $bigQueryExportId, array $optionalArgs = []) + { + $request = new CreateBigQueryExportRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setBigQueryExport($bigQueryExport); + $request->setBigQueryExportId($bigQueryExportId); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CreateBigQueryExport', BigQueryExport::class, $optionalArgs, $request)->wait(); + } + + /** + * Creates a finding. The corresponding source must exist for finding creation + * to succeed. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + * $findingId = 'finding_id'; + * $finding = new Finding(); + * $response = $securityCenterClient->createFinding($formattedParent, $findingId, $finding); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". + * @param string $findingId Required. Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + * @param Finding $finding Required. The Finding being created. The name and security_marks will be + * ignored as they are both output only fields on this resource. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\Finding + * + * @throws ApiException if the remote call fails + */ + public function createFinding($parent, $findingId, $finding, array $optionalArgs = []) + { + $request = new CreateFindingRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setFindingId($findingId); + $request->setFinding($finding); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CreateFinding', Finding::class, $optionalArgs, $request)->wait(); + } + + /** + * Creates a mute config. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); + * $muteConfig = new MuteConfig(); + * $muteConfigId = 'mute_config_id'; + * $response = $securityCenterClient->createMuteConfig($formattedParent, $muteConfig, $muteConfigId); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Resource name of the new mute configs's parent. Its format is + * "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * @param MuteConfig $muteConfig Required. The mute config being created. + * @param string $muteConfigId Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\MuteConfig + * + * @throws ApiException if the remote call fails + */ + public function createMuteConfig($parent, $muteConfig, $muteConfigId, array $optionalArgs = []) + { + $request = new CreateMuteConfigRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setMuteConfig($muteConfig); + $request->setMuteConfigId($muteConfigId); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CreateMuteConfig', MuteConfig::class, $optionalArgs, $request)->wait(); + } + + /** + * Creates a notification config. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); + * $configId = 'config_id'; + * $notificationConfig = new NotificationConfig(); + * $response = $securityCenterClient->createNotificationConfig($formattedParent, $configId, $notificationConfig); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Resource name of the new notification config's parent. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * @param string $configId Required. + * Unique identifier provided by the client within the parent scope. + * It must be between 1 and 128 characters and contain alphanumeric + * characters, underscores, or hyphens only. + * @param NotificationConfig $notificationConfig Required. The notification config being created. The name and the service + * account will be ignored as they are both output only fields on this + * resource. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\NotificationConfig + * + * @throws ApiException if the remote call fails + */ + public function createNotificationConfig($parent, $configId, $notificationConfig, array $optionalArgs = []) + { + $request = new CreateNotificationConfigRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setConfigId($configId); + $request->setNotificationConfig($notificationConfig); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CreateNotificationConfig', NotificationConfig::class, $optionalArgs, $request)->wait(); + } + + /** + * Creates a resident SecurityHealthAnalyticsCustomModule at the scope of the + * given CRM parent, and also creates inherited + * SecurityHealthAnalyticsCustomModules for all CRM descendants of the given + * parent. These modules are enabled by default. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + * $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); + * $response = $securityCenterClient->createSecurityHealthAnalyticsCustomModule($formattedParent, $securityHealthAnalyticsCustomModule); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Resource name of the new custom module's parent. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * @param SecurityHealthAnalyticsCustomModule $securityHealthAnalyticsCustomModule Required. SecurityHealthAnalytics custom module to create. The provided + * name is ignored and reset with provided parent information and + * server-generated ID. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule + * + * @throws ApiException if the remote call fails + */ + public function createSecurityHealthAnalyticsCustomModule($parent, $securityHealthAnalyticsCustomModule, array $optionalArgs = []) + { + $request = new CreateSecurityHealthAnalyticsCustomModuleRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CreateSecurityHealthAnalyticsCustomModule', SecurityHealthAnalyticsCustomModule::class, $optionalArgs, $request)->wait(); + } + + /** + * Creates a source. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->organizationName('[ORGANIZATION]'); + * $source = new Source(); + * $response = $securityCenterClient->createSource($formattedParent, $source); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + * @param Source $source Required. The Source being created, only the display_name and description + * will be used. All other fields will be ignored. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\Source + * + * @throws ApiException if the remote call fails + */ + public function createSource($parent, $source, array $optionalArgs = []) + { + $request = new CreateSourceRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setSource($source); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CreateSource', Source::class, $optionalArgs, $request)->wait(); + } + + /** + * Deletes an existing BigQuery export. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedName = $securityCenterClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); + * $securityCenterClient->deleteBigQueryExport($formattedName); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $name Required. The name of the BigQuery export to delete. Its format is + * organizations/{organization}/bigQueryExports/{export_id}, + * folders/{folder}/bigQueryExports/{export_id}, or + * projects/{project}/bigQueryExports/{export_id} + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @throws ApiException if the remote call fails + */ + public function deleteBigQueryExport($name, array $optionalArgs = []) + { + $request = new DeleteBigQueryExportRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('DeleteBigQueryExport', GPBEmpty::class, $optionalArgs, $request)->wait(); + } + + /** + * Deletes an existing mute config. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedName = $securityCenterClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); + * $securityCenterClient->deleteMuteConfig($formattedName); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $name Required. Name of the mute config to delete. Its format is + * organizations/{organization}/muteConfigs/{config_id}, + * folders/{folder}/muteConfigs/{config_id}, or + * projects/{project}/muteConfigs/{config_id} + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @throws ApiException if the remote call fails + */ + public function deleteMuteConfig($name, array $optionalArgs = []) + { + $request = new DeleteMuteConfigRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('DeleteMuteConfig', GPBEmpty::class, $optionalArgs, $request)->wait(); + } + + /** + * Deletes a notification config. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedName = $securityCenterClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); + * $securityCenterClient->deleteNotificationConfig($formattedName); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $name Required. Name of the notification config to delete. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]", + * "folders/[folder_id]/notificationConfigs/[config_id]", + * or "projects/[project_id]/notificationConfigs/[config_id]". + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @throws ApiException if the remote call fails + */ + public function deleteNotificationConfig($name, array $optionalArgs = []) + { + $request = new DeleteNotificationConfigRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('DeleteNotificationConfig', GPBEmpty::class, $optionalArgs, $request)->wait(); + } + + /** + * Deletes the specified SecurityHealthAnalyticsCustomModule and all of its + * descendants in the CRM hierarchy. This method is only supported for + * resident custom modules. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedName = $securityCenterClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); + * $securityCenterClient->deleteSecurityHealthAnalyticsCustomModule($formattedName); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $name Required. Name of the custom module to delete. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", + * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @throws ApiException if the remote call fails + */ + public function deleteSecurityHealthAnalyticsCustomModule($name, array $optionalArgs = []) + { + $request = new DeleteSecurityHealthAnalyticsCustomModuleRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('DeleteSecurityHealthAnalyticsCustomModule', GPBEmpty::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets a BigQuery export. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedName = $securityCenterClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); + * $response = $securityCenterClient->getBigQueryExport($formattedName); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $name Required. Name of the BigQuery export to retrieve. Its format is + * organizations/{organization}/bigQueryExports/{export_id}, + * folders/{folder}/bigQueryExports/{export_id}, or + * projects/{project}/bigQueryExports/{export_id} + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\BigQueryExport + * + * @throws ApiException if the remote call fails + */ + public function getBigQueryExport($name, array $optionalArgs = []) + { + $request = new GetBigQueryExportRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetBigQueryExport', BigQueryExport::class, $optionalArgs, $request)->wait(); + } + + /** + * Retrieves an EffectiveSecurityHealthAnalyticsCustomModule. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedName = $securityCenterClient->effectiveSecurityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[EFFECTIVE_CUSTOM_MODULE]'); + * $response = $securityCenterClient->getEffectiveSecurityHealthAnalyticsCustomModule($formattedName); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $name Required. Name of the effective custom module to get. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\EffectiveSecurityHealthAnalyticsCustomModule + * + * @throws ApiException if the remote call fails + */ + public function getEffectiveSecurityHealthAnalyticsCustomModule($name, array $optionalArgs = []) + { + $request = new GetEffectiveSecurityHealthAnalyticsCustomModuleRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetEffectiveSecurityHealthAnalyticsCustomModule', EffectiveSecurityHealthAnalyticsCustomModule::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets the access control policy on the specified Source. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $resource = 'resource'; + * $response = $securityCenterClient->getIamPolicy($resource); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $resource REQUIRED: The resource for which the policy is being requested. + * See the operation documentation for the appropriate value for this field. + * @param array $optionalArgs { + * Optional. + * + * @type GetPolicyOptions $options + * OPTIONAL: A `GetPolicyOptions` object for specifying options to + * `GetIamPolicy`. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\Iam\V1\Policy + * + * @throws ApiException if the remote call fails + */ + public function getIamPolicy($resource, array $optionalArgs = []) + { + $request = new GetIamPolicyRequest(); + $requestParamHeaders = []; + $request->setResource($resource); + $requestParamHeaders['resource'] = $resource; + if (isset($optionalArgs['options'])) { + $request->setOptions($optionalArgs['options']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetIamPolicy', Policy::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets a mute config. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedName = $securityCenterClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); + * $response = $securityCenterClient->getMuteConfig($formattedName); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $name Required. Name of the mute config to retrieve. Its format is + * organizations/{organization}/muteConfigs/{config_id}, + * folders/{folder}/muteConfigs/{config_id}, or + * projects/{project}/muteConfigs/{config_id} + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\MuteConfig + * + * @throws ApiException if the remote call fails + */ + public function getMuteConfig($name, array $optionalArgs = []) + { + $request = new GetMuteConfigRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetMuteConfig', MuteConfig::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets a notification config. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedName = $securityCenterClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); + * $response = $securityCenterClient->getNotificationConfig($formattedName); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $name Required. Name of the notification config to get. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]", + * "folders/[folder_id]/notificationConfigs/[config_id]", + * or "projects/[project_id]/notificationConfigs/[config_id]". + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\NotificationConfig + * + * @throws ApiException if the remote call fails + */ + public function getNotificationConfig($name, array $optionalArgs = []) + { + $request = new GetNotificationConfigRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetNotificationConfig', NotificationConfig::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets the settings for an organization. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedName = $securityCenterClient->organizationSettingsName('[ORGANIZATION]'); + * $response = $securityCenterClient->getOrganizationSettings($formattedName); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $name Required. Name of the organization to get organization settings for. Its + * format is "organizations/[organization_id]/organizationSettings". + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\OrganizationSettings + * + * @throws ApiException if the remote call fails + */ + public function getOrganizationSettings($name, array $optionalArgs = []) + { + $request = new GetOrganizationSettingsRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetOrganizationSettings', OrganizationSettings::class, $optionalArgs, $request)->wait(); + } + + /** + * Retrieves a SecurityHealthAnalyticsCustomModule. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedName = $securityCenterClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); + * $response = $securityCenterClient->getSecurityHealthAnalyticsCustomModule($formattedName); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $name Required. Name of the custom module to get. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", + * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", + * or + * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule + * + * @throws ApiException if the remote call fails + */ + public function getSecurityHealthAnalyticsCustomModule($name, array $optionalArgs = []) + { + $request = new GetSecurityHealthAnalyticsCustomModuleRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetSecurityHealthAnalyticsCustomModule', SecurityHealthAnalyticsCustomModule::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets a source. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedName = $securityCenterClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + * $response = $securityCenterClient->getSource($formattedName); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $name Required. Relative resource name of the source. Its format is + * "organizations/[organization_id]/source/[source_id]". + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\Source + * + * @throws ApiException if the remote call fails + */ + public function getSource($name, array $optionalArgs = []) + { + $request = new GetSourceRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetSource', Source::class, $optionalArgs, $request)->wait(); + } + + /** + * Filters an organization's assets and groups them by their specified + * properties. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); + * $groupBy = 'group_by'; + * // Iterate over pages of elements + * $pagedResponse = $securityCenterClient->groupAssets($formattedParent, $groupBy); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $securityCenterClient->groupAssets($formattedParent, $groupBy); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. The name of the parent to group the assets by. Its format is + * "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * @param string $groupBy Required. Expression that defines what assets fields to use for grouping. + * The string value should follow SQL syntax: comma separated list of fields. + * For example: + * "security_center_properties.resource_project,security_center_properties.project". + * + * The following fields are supported when compare_duration is not set: + * + * * security_center_properties.resource_project + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_type + * * security_center_properties.resource_parent + * * security_center_properties.resource_parent_display_name + * + * The following fields are supported when compare_duration is set: + * + * * security_center_properties.resource_type + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_parent_display_name + * @param array $optionalArgs { + * Optional. + * + * @type string $filter + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * + * The supported operators are: + * + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * + * The supported value types are: + * + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * The following field and operator combinations are supported: + * + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * + * For example, `resource_properties.size = 100` is a valid filter string. + * + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * @type Duration $compareDuration + * When compare_duration is set, the GroupResult's "state_change" property is + * updated to indicate whether the asset was added, removed, or remained + * present during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * + * The state change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * + * Possible "state_change" values when compare_duration is specified: + * + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at reference_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at reference_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and reference_time. + * + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * @type Timestamp $readTime + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + * + * @deprecated This method will be removed in the next major version update. + */ + public function groupAssets($parent, $groupBy, array $optionalArgs = []) + { + $request = new GroupAssetsRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setGroupBy($groupBy); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['filter'])) { + $request->setFilter($optionalArgs['filter']); + } + + if (isset($optionalArgs['compareDuration'])) { + $request->setCompareDuration($optionalArgs['compareDuration']); + } + + if (isset($optionalArgs['readTime'])) { + $request->setReadTime($optionalArgs['readTime']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('GroupAssets', $optionalArgs, GroupAssetsResponse::class, $request); + } + + /** + * Filters an organization or source's findings and groups them by their + * specified properties. + * + * To group across all sources provide a `-` as the source id. + * Example: /v1/organizations/{organization_id}/sources/-/findings, + * /v1/folders/{folder_id}/sources/-/findings, + * /v1/projects/{project_id}/sources/-/findings + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + * $groupBy = 'group_by'; + * // Iterate over pages of elements + * $pagedResponse = $securityCenterClient->groupFindings($formattedParent, $groupBy); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $securityCenterClient->groupFindings($formattedParent, $groupBy); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Name of the source to groupBy. Its format is + * "organizations/[organization_id]/sources/[source_id]", + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]. To groupBy across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, + * or projects/{project_id}/sources/- + * @param string $groupBy Required. Expression that defines what assets fields to use for grouping + * (including `state_change`). The string value should follow SQL syntax: + * comma separated list of fields. For example: "parent,resource_name". + * + * The following fields are supported: + * + * * resource_name + * * category + * * state + * * parent + * * severity + * + * The following fields are supported when compare_duration is set: + * + * * state_change + * @param array $optionalArgs { + * Optional. + * + * @type string $filter + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * + * The supported operators are: + * + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * + * The supported value types are: + * + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * The following field and operator combinations are supported: + * + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * + * * severity: `=`, `:` + * * workflow_state: `=`, `:` + * * security_marks.marks: `=`, `:` + * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * + * For example, `source_properties.size = 100` is a valid filter string. + * + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * + * * resource: + * * resource.name: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.type: `=`, `:` + * @type Timestamp $readTime + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * @type Duration $compareDuration + * When compare_duration is set, the GroupResult's "state_change" attribute is + * updated to indicate whether the finding had its state changed, the + * finding's state remained unchanged, or if the finding was added during the + * compare_duration period of time that precedes the read_time. This is the + * time between (read_time - compare_duration) and read_time. + * + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * + * Possible "state_change" values when compare_duration is specified: + * + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present + * at read_time. + * + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + */ + public function groupFindings($parent, $groupBy, array $optionalArgs = []) + { + $request = new GroupFindingsRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setGroupBy($groupBy); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['filter'])) { + $request->setFilter($optionalArgs['filter']); + } + + if (isset($optionalArgs['readTime'])) { + $request->setReadTime($optionalArgs['readTime']); + } + + if (isset($optionalArgs['compareDuration'])) { + $request->setCompareDuration($optionalArgs['compareDuration']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('GroupFindings', $optionalArgs, GroupFindingsResponse::class, $request); + } + + /** + * Lists an organization's assets. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); + * // Iterate over pages of elements + * $pagedResponse = $securityCenterClient->listAssets($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $securityCenterClient->listAssets($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. The name of the parent resource that contains the assets. The + * value that you can specify on parent depends on the method in which you + * specify parent. You can specify one of the following values: + * "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * @param array $optionalArgs { + * Optional. + * + * @type string $filter + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * + * The supported operators are: + * + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * + * The supported value types are: + * + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * The following are the allowed field and operator combinations: + * + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * + * For example, `resource_properties.size = 100` is a valid filter string. + * + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * @type string $orderBy + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,resource_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,resource_properties.a_property" and " + * name desc , resource_properties.a_property " are equivalent. + * + * The following fields are supported: + * name + * update_time + * resource_properties + * security_marks.marks + * security_center_properties.resource_name + * security_center_properties.resource_display_name + * security_center_properties.resource_parent + * security_center_properties.resource_parent_display_name + * security_center_properties.resource_project + * security_center_properties.resource_project_display_name + * security_center_properties.resource_type + * @type Timestamp $readTime + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * @type Duration $compareDuration + * When compare_duration is set, the ListAssetsResult's "state_change" + * attribute is updated to indicate whether the asset was added, removed, or + * remained present during the compare_duration period of time that precedes + * the read_time. This is the time between (read_time - compare_duration) and + * read_time. + * + * The state_change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * + * Possible "state_change" values when compare_duration is specified: + * + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at read_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at read_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and read_time. + * + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * @type FieldMask $fieldMask + * A field mask to specify the ListAssetsResult fields to be listed in the + * response. + * An empty field mask will list all fields. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + * + * @deprecated This method will be removed in the next major version update. + */ + public function listAssets($parent, array $optionalArgs = []) + { + $request = new ListAssetsRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['filter'])) { + $request->setFilter($optionalArgs['filter']); + } + + if (isset($optionalArgs['orderBy'])) { + $request->setOrderBy($optionalArgs['orderBy']); + } + + if (isset($optionalArgs['readTime'])) { + $request->setReadTime($optionalArgs['readTime']); + } + + if (isset($optionalArgs['compareDuration'])) { + $request->setCompareDuration($optionalArgs['compareDuration']); + } + + if (isset($optionalArgs['fieldMask'])) { + $request->setFieldMask($optionalArgs['fieldMask']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListAssets', $optionalArgs, ListAssetsResponse::class, $request); + } + + /** + * Lists BigQuery exports. Note that when requesting BigQuery exports at a + * given level all exports under that level are also returned e.g. if + * requesting BigQuery exports under a folder, then all BigQuery exports + * immediately under the folder plus the ones created under the projects + * within the folder are returned. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); + * // Iterate over pages of elements + * $pagedResponse = $securityCenterClient->listBigQueryExports($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $securityCenterClient->listBigQueryExports($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. The parent, which owns the collection of BigQuery exports. Its + * format is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]". + * @param array $optionalArgs { + * Optional. + * + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + */ + public function listBigQueryExports($parent, array $optionalArgs = []) + { + $request = new ListBigQueryExportsRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListBigQueryExports', $optionalArgs, ListBigQueryExportsResponse::class, $request); + } + + /** + * Returns a list of all resident SecurityHealthAnalyticsCustomModules under + * the given CRM parent and all of the parent’s CRM descendants. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + * // Iterate over pages of elements + * $pagedResponse = $securityCenterClient->listDescendantSecurityHealthAnalyticsCustomModules($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $securityCenterClient->listDescendantSecurityHealthAnalyticsCustomModules($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Name of parent to list descendant custom modules. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * @param array $optionalArgs { + * Optional. + * + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + */ + public function listDescendantSecurityHealthAnalyticsCustomModules($parent, array $optionalArgs = []) + { + $request = new ListDescendantSecurityHealthAnalyticsCustomModulesRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListDescendantSecurityHealthAnalyticsCustomModules', $optionalArgs, ListDescendantSecurityHealthAnalyticsCustomModulesResponse::class, $request); + } + + /** + * Returns a list of all EffectiveSecurityHealthAnalyticsCustomModules for the + * given parent. This includes resident modules defined at the scope of the + * parent, and inherited modules, inherited from CRM ancestors. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + * // Iterate over pages of elements + * $pagedResponse = $securityCenterClient->listEffectiveSecurityHealthAnalyticsCustomModules($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $securityCenterClient->listEffectiveSecurityHealthAnalyticsCustomModules($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Name of parent to list effective custom modules. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * @param array $optionalArgs { + * Optional. + * + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + */ + public function listEffectiveSecurityHealthAnalyticsCustomModules($parent, array $optionalArgs = []) + { + $request = new ListEffectiveSecurityHealthAnalyticsCustomModulesRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListEffectiveSecurityHealthAnalyticsCustomModules', $optionalArgs, ListEffectiveSecurityHealthAnalyticsCustomModulesResponse::class, $request); + } + + /** + * Lists an organization or source's findings. + * + * To list across all sources provide a `-` as the source id. + * Example: /v1/organizations/{organization_id}/sources/-/findings + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + * // Iterate over pages of elements + * $pagedResponse = $securityCenterClient->listFindings($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $securityCenterClient->listFindings($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Name of the source the findings belong to. Its format is + * "organizations/[organization_id]/sources/[source_id], + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]". To list across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or + * projects/{projects_id}/sources/- + * @param array $optionalArgs { + * Optional. + * + * @type string $filter + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * + * The supported operators are: + * + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * + * The supported value types are: + * + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * The following field and operator combinations are supported: + * + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * + * * severity: `=`, `:` + * * workflow_state: `=`, `:` + * * security_marks.marks: `=`, `:` + * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * + * For example, `source_properties.size = 100` is a valid filter string. + * + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * + * * resource: + * * resource.name: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.type: `=`, `:` + * * resource.folders.resource_folder: `=`, `:` + * * resource.display_name: `=`, `:` + * @type string $orderBy + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,source_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,source_properties.a_property" and " + * name desc , source_properties.a_property " are equivalent. + * + * The following fields are supported: + * name + * parent + * state + * category + * resource_name + * event_time + * source_properties + * security_marks.marks + * @type Timestamp $readTime + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * @type Duration $compareDuration + * When compare_duration is set, the ListFindingsResult's "state_change" + * attribute is updated to indicate whether the finding had its state changed, + * the finding's state remained unchanged, or if the finding was added in any + * state during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * + * Possible "state_change" values when compare_duration is specified: + * + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present at + * read_time. + * @type FieldMask $fieldMask + * A field mask to specify the Finding fields to be listed in the response. + * An empty field mask will list all fields. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + */ + public function listFindings($parent, array $optionalArgs = []) + { + $request = new ListFindingsRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['filter'])) { + $request->setFilter($optionalArgs['filter']); + } + + if (isset($optionalArgs['orderBy'])) { + $request->setOrderBy($optionalArgs['orderBy']); + } + + if (isset($optionalArgs['readTime'])) { + $request->setReadTime($optionalArgs['readTime']); + } + + if (isset($optionalArgs['compareDuration'])) { + $request->setCompareDuration($optionalArgs['compareDuration']); + } + + if (isset($optionalArgs['fieldMask'])) { + $request->setFieldMask($optionalArgs['fieldMask']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListFindings', $optionalArgs, ListFindingsResponse::class, $request); + } + + /** + * Lists mute configs. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); + * // Iterate over pages of elements + * $pagedResponse = $securityCenterClient->listMuteConfigs($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $securityCenterClient->listMuteConfigs($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. The parent, which owns the collection of mute configs. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]". + * @param array $optionalArgs { + * Optional. + * + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + */ + public function listMuteConfigs($parent, array $optionalArgs = []) + { + $request = new ListMuteConfigsRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListMuteConfigs', $optionalArgs, ListMuteConfigsResponse::class, $request); + } + + /** + * Lists notification configs. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); + * // Iterate over pages of elements + * $pagedResponse = $securityCenterClient->listNotificationConfigs($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $securityCenterClient->listNotificationConfigs($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. The name of the parent in which to list the notification + * configurations. Its format is "organizations/[organization_id]", + * "folders/[folder_id]", or "projects/[project_id]". + * @param array $optionalArgs { + * Optional. + * + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + */ + public function listNotificationConfigs($parent, array $optionalArgs = []) + { + $request = new ListNotificationConfigsRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListNotificationConfigs', $optionalArgs, ListNotificationConfigsResponse::class, $request); + } + + /** + * Returns a list of all SecurityHealthAnalyticsCustomModules for the given + * parent. This includes resident modules defined at the scope of the parent, + * and inherited modules, inherited from CRM ancestors. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + * // Iterate over pages of elements + * $pagedResponse = $securityCenterClient->listSecurityHealthAnalyticsCustomModules($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $securityCenterClient->listSecurityHealthAnalyticsCustomModules($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Name of parent to list custom modules. Its format is + * "organizations/{organization}/securityHealthAnalyticsSettings", + * "folders/{folder}/securityHealthAnalyticsSettings", or + * "projects/{project}/securityHealthAnalyticsSettings" + * @param array $optionalArgs { + * Optional. + * + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + */ + public function listSecurityHealthAnalyticsCustomModules($parent, array $optionalArgs = []) + { + $request = new ListSecurityHealthAnalyticsCustomModulesRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListSecurityHealthAnalyticsCustomModules', $optionalArgs, ListSecurityHealthAnalyticsCustomModulesResponse::class, $request); + } + + /** + * Lists all sources belonging to an organization. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); + * // Iterate over pages of elements + * $pagedResponse = $securityCenterClient->listSources($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $securityCenterClient->listSources($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Resource name of the parent of sources to list. Its format should + * be "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * @param array $optionalArgs { + * Optional. + * + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + */ + public function listSources($parent, array $optionalArgs = []) + { + $request = new ListSourcesRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListSources', $optionalArgs, ListSourcesResponse::class, $request); + } + + /** + * Runs asset discovery. The discovery is tracked with a long-running + * operation. + * + * This API can only be called with limited frequency for an organization. If + * it is called too frequently the caller will receive a TOO_MANY_REQUESTS + * error. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->organizationName('[ORGANIZATION]'); + * $operationResponse = $securityCenterClient->runAssetDiscovery($formattedParent); + * $operationResponse->pollUntilComplete(); + * if ($operationResponse->operationSucceeded()) { + * $result = $operationResponse->getResult(); + * // doSomethingWith($result) + * } else { + * $error = $operationResponse->getError(); + * // handleError($error) + * } + * // Alternatively: + * // start the operation, keep the operation name, and resume later + * $operationResponse = $securityCenterClient->runAssetDiscovery($formattedParent); + * $operationName = $operationResponse->getName(); + * // ... do other work + * $newOperationResponse = $securityCenterClient->resumeOperation($operationName, 'runAssetDiscovery'); + * while (!$newOperationResponse->isDone()) { + * // ... do other work + * $newOperationResponse->reload(); + * } + * if ($newOperationResponse->operationSucceeded()) { + * $result = $newOperationResponse->getResult(); + * // doSomethingWith($result) + * } else { + * $error = $newOperationResponse->getError(); + * // handleError($error) + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Name of the organization to run asset discovery for. Its format + * is "organizations/[organization_id]". + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\OperationResponse + * + * @throws ApiException if the remote call fails + * + * @deprecated This method will be removed in the next major version update. + */ + public function runAssetDiscovery($parent, array $optionalArgs = []) + { + $request = new RunAssetDiscoveryRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startOperationsCall('RunAssetDiscovery', $optionalArgs, $request, $this->getOperationsClient())->wait(); + } + + /** + * Updates the state of a finding. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedName = $securityCenterClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + * $state = State::STATE_UNSPECIFIED; + * $startTime = new Timestamp(); + * $response = $securityCenterClient->setFindingState($formattedName, $state, $startTime); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $name Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", + * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". + * @param int $state Required. The desired State of the finding. + * For allowed values, use constants defined on {@see \Google\Cloud\SecurityCenter\V1\Finding\State} + * @param Timestamp $startTime Required. The time at which the updated state takes effect. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\Finding + * + * @throws ApiException if the remote call fails + */ + public function setFindingState($name, $state, $startTime, array $optionalArgs = []) + { + $request = new SetFindingStateRequest(); + $requestParamHeaders = []; + $request->setName($name); + $request->setState($state); + $request->setStartTime($startTime); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('SetFindingState', Finding::class, $optionalArgs, $request)->wait(); + } + + /** + * Sets the access control policy on the specified Source. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $resource = 'resource'; + * $policy = new Policy(); + * $response = $securityCenterClient->setIamPolicy($resource, $policy); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $resource REQUIRED: The resource for which the policy is being specified. + * See the operation documentation for the appropriate value for this field. + * @param Policy $policy REQUIRED: The complete policy to be applied to the `resource`. The size of + * the policy is limited to a few 10s of KB. An empty policy is a + * valid policy but certain Cloud Platform services (such as Projects) + * might reject them. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only + * the fields in the mask will be modified. If no mask is provided, the + * following default mask is used: + * + * `paths: "bindings, etag"` + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\Iam\V1\Policy + * + * @throws ApiException if the remote call fails + */ + public function setIamPolicy($resource, $policy, array $optionalArgs = []) + { + $request = new SetIamPolicyRequest(); + $requestParamHeaders = []; + $request->setResource($resource); + $request->setPolicy($policy); + $requestParamHeaders['resource'] = $resource; + if (isset($optionalArgs['updateMask'])) { + $request->setUpdateMask($optionalArgs['updateMask']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('SetIamPolicy', Policy::class, $optionalArgs, $request)->wait(); + } + + /** + * Updates the mute state of a finding. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedName = $securityCenterClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + * $mute = Mute::MUTE_UNSPECIFIED; + * $response = $securityCenterClient->setMute($formattedName, $mute); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $name Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", + * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". + * @param int $mute Required. The desired state of the Mute. + * For allowed values, use constants defined on {@see \Google\Cloud\SecurityCenter\V1\Finding\Mute} + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\Finding + * + * @throws ApiException if the remote call fails + */ + public function setMute($name, $mute, array $optionalArgs = []) + { + $request = new SetMuteRequest(); + $requestParamHeaders = []; + $request->setName($name); + $request->setMute($mute); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('SetMute', Finding::class, $optionalArgs, $request)->wait(); + } + + /** + * Simulates a given SecurityHealthAnalyticsCustomModule and Resource. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $parent = 'parent'; + * $customConfig = new CustomConfig(); + * $resource = new SimulatedResource(); + * $response = $securityCenterClient->simulateSecurityHealthAnalyticsCustomModule($parent, $customConfig, $resource); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. The relative resource name of the organization, project, or + * folder. For more information about relative resource names, see [Relative + * Resource + * Name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * Example: `organizations/{organization_id}` + * @param CustomConfig $customConfig Required. The custom configuration that you need to test. + * @param SimulatedResource $resource Required. Resource data to simulate custom module against. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleResponse + * + * @throws ApiException if the remote call fails + */ + public function simulateSecurityHealthAnalyticsCustomModule($parent, $customConfig, $resource, array $optionalArgs = []) + { + $request = new SimulateSecurityHealthAnalyticsCustomModuleRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setCustomConfig($customConfig); + $request->setResource($resource); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('SimulateSecurityHealthAnalyticsCustomModule', SimulateSecurityHealthAnalyticsCustomModuleResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * Returns the permissions that a caller has on the specified source. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $resource = 'resource'; + * $permissions = []; + * $response = $securityCenterClient->testIamPermissions($resource, $permissions); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $resource REQUIRED: The resource for which the policy detail is being requested. + * See the operation documentation for the appropriate value for this field. + * @param string[] $permissions The set of permissions to check for the `resource`. Permissions with + * wildcards (such as '*' or 'storage.*') are not allowed. For more + * information see + * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\Iam\V1\TestIamPermissionsResponse + * + * @throws ApiException if the remote call fails + */ + public function testIamPermissions($resource, $permissions, array $optionalArgs = []) + { + $request = new TestIamPermissionsRequest(); + $requestParamHeaders = []; + $request->setResource($resource); + $request->setPermissions($permissions); + $requestParamHeaders['resource'] = $resource; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('TestIamPermissions', TestIamPermissionsResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * Updates a BigQuery export. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $bigQueryExport = new BigQueryExport(); + * $response = $securityCenterClient->updateBigQueryExport($bigQueryExport); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param BigQueryExport $bigQueryExport Required. The BigQuery export being updated. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\BigQueryExport + * + * @throws ApiException if the remote call fails + */ + public function updateBigQueryExport($bigQueryExport, array $optionalArgs = []) + { + $request = new UpdateBigQueryExportRequest(); + $requestParamHeaders = []; + $request->setBigQueryExport($bigQueryExport); + $requestParamHeaders['big_query_export.name'] = $bigQueryExport->getName(); + if (isset($optionalArgs['updateMask'])) { + $request->setUpdateMask($optionalArgs['updateMask']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('UpdateBigQueryExport', BigQueryExport::class, $optionalArgs, $request)->wait(); + } + + /** + * Updates external system. This is for a given finding. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $externalSystem = new ExternalSystem(); + * $response = $securityCenterClient->updateExternalSystem($externalSystem); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param ExternalSystem $externalSystem Required. The external system resource to update. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * The FieldMask to use when updating the external system resource. + * + * If empty all mutable fields will be updated. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\ExternalSystem + * + * @throws ApiException if the remote call fails + */ + public function updateExternalSystem($externalSystem, array $optionalArgs = []) + { + $request = new UpdateExternalSystemRequest(); + $requestParamHeaders = []; + $request->setExternalSystem($externalSystem); + $requestParamHeaders['external_system.name'] = $externalSystem->getName(); + if (isset($optionalArgs['updateMask'])) { + $request->setUpdateMask($optionalArgs['updateMask']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('UpdateExternalSystem', ExternalSystem::class, $optionalArgs, $request)->wait(); + } + + /** + * Creates or updates a finding. The corresponding source must exist for a + * finding creation to succeed. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $finding = new Finding(); + * $response = $securityCenterClient->updateFinding($finding); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param Finding $finding Required. The finding resource to update or create if it does not already + * exist. parent, security_marks, and update_time will be ignored. + * + * In the case of creation, the finding id portion of the name must be + * alphanumeric and less than or equal to 32 characters and greater than 0 + * characters in length. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * The FieldMask to use when updating the finding resource. This field should + * not be specified when creating a finding. + * + * When updating a finding, an empty mask is treated as updating all mutable + * fields and replacing source_properties. Individual source_properties can + * be added/updated by using "source_properties." in the field + * mask. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\Finding + * + * @throws ApiException if the remote call fails + */ + public function updateFinding($finding, array $optionalArgs = []) + { + $request = new UpdateFindingRequest(); + $requestParamHeaders = []; + $request->setFinding($finding); + $requestParamHeaders['finding.name'] = $finding->getName(); + if (isset($optionalArgs['updateMask'])) { + $request->setUpdateMask($optionalArgs['updateMask']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('UpdateFinding', Finding::class, $optionalArgs, $request)->wait(); + } + + /** + * Updates a mute config. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $muteConfig = new MuteConfig(); + * $response = $securityCenterClient->updateMuteConfig($muteConfig); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param MuteConfig $muteConfig Required. The mute config being updated. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\MuteConfig + * + * @throws ApiException if the remote call fails + */ + public function updateMuteConfig($muteConfig, array $optionalArgs = []) + { + $request = new UpdateMuteConfigRequest(); + $requestParamHeaders = []; + $request->setMuteConfig($muteConfig); + $requestParamHeaders['mute_config.name'] = $muteConfig->getName(); + if (isset($optionalArgs['updateMask'])) { + $request->setUpdateMask($optionalArgs['updateMask']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('UpdateMuteConfig', MuteConfig::class, $optionalArgs, $request)->wait(); + } + + /** + * + * Updates a notification config. The following update + * fields are allowed: description, pubsub_topic, streaming_config.filter + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $notificationConfig = new NotificationConfig(); + * $response = $securityCenterClient->updateNotificationConfig($notificationConfig); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param NotificationConfig $notificationConfig Required. The notification config to update. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * The FieldMask to use when updating the notification config. + * + * If empty all mutable fields will be updated. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\NotificationConfig + * + * @throws ApiException if the remote call fails + */ + public function updateNotificationConfig($notificationConfig, array $optionalArgs = []) + { + $request = new UpdateNotificationConfigRequest(); + $requestParamHeaders = []; + $request->setNotificationConfig($notificationConfig); + $requestParamHeaders['notification_config.name'] = $notificationConfig->getName(); + if (isset($optionalArgs['updateMask'])) { + $request->setUpdateMask($optionalArgs['updateMask']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('UpdateNotificationConfig', NotificationConfig::class, $optionalArgs, $request)->wait(); + } + + /** + * Updates an organization's settings. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $organizationSettings = new OrganizationSettings(); + * $response = $securityCenterClient->updateOrganizationSettings($organizationSettings); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param OrganizationSettings $organizationSettings Required. The organization settings resource to update. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * The FieldMask to use when updating the settings resource. + * + * If empty all mutable fields will be updated. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\OrganizationSettings + * + * @throws ApiException if the remote call fails + */ + public function updateOrganizationSettings($organizationSettings, array $optionalArgs = []) + { + $request = new UpdateOrganizationSettingsRequest(); + $requestParamHeaders = []; + $request->setOrganizationSettings($organizationSettings); + $requestParamHeaders['organization_settings.name'] = $organizationSettings->getName(); + if (isset($optionalArgs['updateMask'])) { + $request->setUpdateMask($optionalArgs['updateMask']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('UpdateOrganizationSettings', OrganizationSettings::class, $optionalArgs, $request)->wait(); + } + + /** + * Updates the SecurityHealthAnalyticsCustomModule under the given name based + * on the given update mask. Updating the enablement state is supported on + * both resident and inherited modules (though resident modules cannot have an + * enablement state of "inherited"). Updating the display name and custom + * config of a module is supported on resident modules only. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); + * $response = $securityCenterClient->updateSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param SecurityHealthAnalyticsCustomModule $securityHealthAnalyticsCustomModule Required. The SecurityHealthAnalytics custom module to update. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * The list of fields to update. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule + * + * @throws ApiException if the remote call fails + */ + public function updateSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule, array $optionalArgs = []) + { + $request = new UpdateSecurityHealthAnalyticsCustomModuleRequest(); + $requestParamHeaders = []; + $request->setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); + $requestParamHeaders['security_health_analytics_custom_module.name'] = $securityHealthAnalyticsCustomModule->getName(); + if (isset($optionalArgs['updateMask'])) { + $request->setUpdateMask($optionalArgs['updateMask']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('UpdateSecurityHealthAnalyticsCustomModule', SecurityHealthAnalyticsCustomModule::class, $optionalArgs, $request)->wait(); + } + + /** + * Updates security marks. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $securityMarks = new SecurityMarks(); + * $response = $securityCenterClient->updateSecurityMarks($securityMarks); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param SecurityMarks $securityMarks Required. The security marks resource to update. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * The FieldMask to use when updating the security marks resource. + * + * The field mask must not contain duplicate fields. + * If empty or set to "marks", all marks will be replaced. Individual + * marks can be updated using "marks.". + * @type Timestamp $startTime + * The time at which the updated SecurityMarks take effect. + * If not set uses current server time. Updates will be applied to the + * SecurityMarks that are active immediately preceding this time. Must be + * earlier or equal to the server time. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\SecurityMarks + * + * @throws ApiException if the remote call fails + */ + public function updateSecurityMarks($securityMarks, array $optionalArgs = []) + { + $request = new UpdateSecurityMarksRequest(); + $requestParamHeaders = []; + $request->setSecurityMarks($securityMarks); + $requestParamHeaders['security_marks.name'] = $securityMarks->getName(); + if (isset($optionalArgs['updateMask'])) { + $request->setUpdateMask($optionalArgs['updateMask']); + } + + if (isset($optionalArgs['startTime'])) { + $request->setStartTime($optionalArgs['startTime']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('UpdateSecurityMarks', SecurityMarks::class, $optionalArgs, $request)->wait(); + } + + /** + * Updates a source. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $source = new Source(); + * $response = $securityCenterClient->updateSource($source); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param Source $source Required. The source resource to update. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * The FieldMask to use when updating the source resource. + * + * If empty all mutable fields will be updated. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1\Source + * + * @throws ApiException if the remote call fails + */ + public function updateSource($source, array $optionalArgs = []) + { + $request = new UpdateSourceRequest(); + $requestParamHeaders = []; + $request->setSource($source); + $requestParamHeaders['source.name'] = $source->getName(); + if (isset($optionalArgs['updateMask'])) { + $request->setUpdateMask($optionalArgs['updateMask']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('UpdateSource', Source::class, $optionalArgs, $request)->wait(); + } +} diff --git a/owl-bot-staging/SecurityCenter/v1/src/V1/SecurityCenterClient.php b/owl-bot-staging/SecurityCenter/v1/src/V1/SecurityCenterClient.php new file mode 100644 index 000000000000..983e341e88d3 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/src/V1/SecurityCenterClient.php @@ -0,0 +1,34 @@ + [ + 'google.cloud.securitycenter.v1.SecurityCenter' => [ + 'BulkMuteFindings' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\SecurityCenter\V1\BulkMuteFindingsResponse', + 'metadataReturnType' => '\Google\Protobuf\GPBEmpty', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'RunAssetDiscovery' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\SecurityCenter\V1\RunAssetDiscoveryResponse', + 'metadataReturnType' => '\Google\Protobuf\GPBEmpty', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateBigQueryExport' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\BigQueryExport', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateFinding' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\Finding', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateMuteConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\MuteConfig', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateNotificationConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\NotificationConfig', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateSecurityHealthAnalyticsCustomModule' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateSource' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\Source', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteBigQueryExport' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteMuteConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteNotificationConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteSecurityHealthAnalyticsCustomModule' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetBigQueryExport' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\BigQueryExport', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetEffectiveSecurityHealthAnalyticsCustomModule' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\EffectiveSecurityHealthAnalyticsCustomModule', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], + ], + 'GetMuteConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\MuteConfig', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetNotificationConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\NotificationConfig', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetOrganizationSettings' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\OrganizationSettings', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetSecurityHealthAnalyticsCustomModule' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetSource' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\Source', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GroupAssets' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getGroupByResults', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\GroupAssetsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'GroupFindings' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getGroupByResults', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\GroupFindingsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListAssets' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getListAssetsResults', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\ListAssetsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListBigQueryExports' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getBigQueryExports', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\ListBigQueryExportsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListDescendantSecurityHealthAnalyticsCustomModules' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getSecurityHealthAnalyticsCustomModules', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\ListDescendantSecurityHealthAnalyticsCustomModulesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListEffectiveSecurityHealthAnalyticsCustomModules' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getEffectiveSecurityHealthAnalyticsCustomModules', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\ListEffectiveSecurityHealthAnalyticsCustomModulesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListFindings' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getListFindingsResults', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\ListFindingsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListMuteConfigs' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getMuteConfigs', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\ListMuteConfigsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListNotificationConfigs' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getNotificationConfigs', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\ListNotificationConfigsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListSecurityHealthAnalyticsCustomModules' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getSecurityHealthAnalyticsCustomModules', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\ListSecurityHealthAnalyticsCustomModulesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListSources' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getSources', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\ListSourcesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'SetFindingState' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\Finding', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'SetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], + ], + 'SetMute' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\Finding', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'SimulateSecurityHealthAnalyticsCustomModule' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'TestIamPermissions' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], + ], + 'UpdateBigQueryExport' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\BigQueryExport', + 'headerParams' => [ + [ + 'keyName' => 'big_query_export.name', + 'fieldAccessors' => [ + 'getBigQueryExport', + 'getName', + ], + ], + ], + ], + 'UpdateExternalSystem' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\ExternalSystem', + 'headerParams' => [ + [ + 'keyName' => 'external_system.name', + 'fieldAccessors' => [ + 'getExternalSystem', + 'getName', + ], + ], + ], + ], + 'UpdateFinding' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\Finding', + 'headerParams' => [ + [ + 'keyName' => 'finding.name', + 'fieldAccessors' => [ + 'getFinding', + 'getName', + ], + ], + ], + ], + 'UpdateMuteConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\MuteConfig', + 'headerParams' => [ + [ + 'keyName' => 'mute_config.name', + 'fieldAccessors' => [ + 'getMuteConfig', + 'getName', + ], + ], + ], + ], + 'UpdateNotificationConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\NotificationConfig', + 'headerParams' => [ + [ + 'keyName' => 'notification_config.name', + 'fieldAccessors' => [ + 'getNotificationConfig', + 'getName', + ], + ], + ], + ], + 'UpdateOrganizationSettings' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\OrganizationSettings', + 'headerParams' => [ + [ + 'keyName' => 'organization_settings.name', + 'fieldAccessors' => [ + 'getOrganizationSettings', + 'getName', + ], + ], + ], + ], + 'UpdateSecurityHealthAnalyticsCustomModule' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule', + 'headerParams' => [ + [ + 'keyName' => 'security_health_analytics_custom_module.name', + 'fieldAccessors' => [ + 'getSecurityHealthAnalyticsCustomModule', + 'getName', + ], + ], + ], + ], + 'UpdateSecurityMarks' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\SecurityMarks', + 'headerParams' => [ + [ + 'keyName' => 'security_marks.name', + 'fieldAccessors' => [ + 'getSecurityMarks', + 'getName', + ], + ], + ], + ], + 'UpdateSource' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V1\Source', + 'headerParams' => [ + [ + 'keyName' => 'source.name', + 'fieldAccessors' => [ + 'getSource', + 'getName', + ], + ], + ], + ], + 'templateMap' => [ + 'bigQueryExport' => 'organizations/{organization}/bigQueryExports/{export}', + 'dlpJob' => 'projects/{project}/dlpJobs/{dlp_job}', + 'effectiveSecurityHealthAnalyticsCustomModule' => 'organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module}', + 'externalSystem' => 'organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}', + 'finding' => 'organizations/{organization}/sources/{source}/findings/{finding}', + 'folder' => 'folders/{folder}', + 'folderAssetSecurityMarks' => 'folders/{folder}/assets/{asset}/securityMarks', + 'folderConstraintName' => 'folders/{folder}/policies/{constraint_name}', + 'folderCustomModule' => 'folders/{folder}/securityHealthAnalyticsSettings/customModules/{custom_module}', + 'folderEffectiveCustomModule' => 'folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module}', + 'folderExport' => 'folders/{folder}/bigQueryExports/{export}', + 'folderMuteConfig' => 'folders/{folder}/muteConfigs/{mute_config}', + 'folderNotificationConfig' => 'folders/{folder}/notificationConfigs/{notification_config}', + 'folderSecurityHealthAnalyticsSettings' => 'folders/{folder}/securityHealthAnalyticsSettings', + 'folderSource' => 'folders/{folder}/sources/{source}', + 'folderSourceFinding' => 'folders/{folder}/sources/{source}/findings/{finding}', + 'folderSourceFindingExternalsystem' => 'folders/{folder}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}', + 'folderSourceFindingSecurityMarks' => 'folders/{folder}/sources/{source}/findings/{finding}/securityMarks', + 'muteConfig' => 'organizations/{organization}/muteConfigs/{mute_config}', + 'notificationConfig' => 'organizations/{organization}/notificationConfigs/{notification_config}', + 'organization' => 'organizations/{organization}', + 'organizationAssetSecurityMarks' => 'organizations/{organization}/assets/{asset}/securityMarks', + 'organizationConstraintName' => 'organizations/{organization}/policies/{constraint_name}', + 'organizationCustomModule' => 'organizations/{organization}/securityHealthAnalyticsSettings/customModules/{custom_module}', + 'organizationEffectiveCustomModule' => 'organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module}', + 'organizationExport' => 'organizations/{organization}/bigQueryExports/{export}', + 'organizationMuteConfig' => 'organizations/{organization}/muteConfigs/{mute_config}', + 'organizationNotificationConfig' => 'organizations/{organization}/notificationConfigs/{notification_config}', + 'organizationSecurityHealthAnalyticsSettings' => 'organizations/{organization}/securityHealthAnalyticsSettings', + 'organizationSettings' => 'organizations/{organization}/organizationSettings', + 'organizationSource' => 'organizations/{organization}/sources/{source}', + 'organizationSourceFinding' => 'organizations/{organization}/sources/{source}/findings/{finding}', + 'organizationSourceFindingExternalsystem' => 'organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}', + 'organizationSourceFindingSecurityMarks' => 'organizations/{organization}/sources/{source}/findings/{finding}/securityMarks', + 'policy' => 'organizations/{organization}/policies/{constraint_name}', + 'project' => 'projects/{project}', + 'projectAssetSecurityMarks' => 'projects/{project}/assets/{asset}/securityMarks', + 'projectConstraintName' => 'projects/{project}/policies/{constraint_name}', + 'projectCustomModule' => 'projects/{project}/securityHealthAnalyticsSettings/customModules/{custom_module}', + 'projectDlpJob' => 'projects/{project}/dlpJobs/{dlp_job}', + 'projectEffectiveCustomModule' => 'projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module}', + 'projectExport' => 'projects/{project}/bigQueryExports/{export}', + 'projectLocationDlpJob' => 'projects/{project}/locations/{location}/dlpJobs/{dlp_job}', + 'projectLocationTableProfile' => 'projects/{project}/locations/{location}/tableProfiles/{table_profile}', + 'projectMuteConfig' => 'projects/{project}/muteConfigs/{mute_config}', + 'projectNotificationConfig' => 'projects/{project}/notificationConfigs/{notification_config}', + 'projectSecurityHealthAnalyticsSettings' => 'projects/{project}/securityHealthAnalyticsSettings', + 'projectSource' => 'projects/{project}/sources/{source}', + 'projectSourceFinding' => 'projects/{project}/sources/{source}/findings/{finding}', + 'projectSourceFindingExternalsystem' => 'projects/{project}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}', + 'projectSourceFindingSecurityMarks' => 'projects/{project}/sources/{source}/findings/{finding}/securityMarks', + 'projectTableProfile' => 'projects/{project}/tableProfiles/{table_profile}', + 'securityHealthAnalyticsCustomModule' => 'organizations/{organization}/securityHealthAnalyticsSettings/customModules/{custom_module}', + 'securityHealthAnalyticsSettings' => 'organizations/{organization}/securityHealthAnalyticsSettings', + 'securityMarks' => 'organizations/{organization}/assets/{asset}/securityMarks', + 'source' => 'organizations/{organization}/sources/{source}', + 'tableDataProfile' => 'projects/{project}/tableProfiles/{table_profile}', + 'topic' => 'projects/{project}/topics/{topic}', + ], + ], + ], +]; diff --git a/owl-bot-staging/SecurityCenter/v1/src/V1/resources/security_center_rest_client_config.php b/owl-bot-staging/SecurityCenter/v1/src/V1/resources/security_center_rest_client_config.php new file mode 100644 index 000000000000..4968eb9f6970 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/src/V1/resources/security_center_rest_client_config.php @@ -0,0 +1,1033 @@ + [ + 'google.cloud.securitycenter.v1.SecurityCenter' => [ + 'BulkMuteFindings' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=organizations/*}/findings:bulkMute', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=folders/*}/findings:bulkMute', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*}/findings:bulkMute', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'CreateBigQueryExport' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=organizations/*}/bigQueryExports', + 'body' => 'big_query_export', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=folders/*}/bigQueryExports', + 'body' => 'big_query_export', + 'queryParams' => [ + 'big_query_export_id', + ], + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*}/bigQueryExports', + 'body' => 'big_query_export', + 'queryParams' => [ + 'big_query_export_id', + ], + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'big_query_export_id', + ], + ], + 'CreateFinding' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=organizations/*/sources/*}/findings', + 'body' => 'finding', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'finding_id', + ], + ], + 'CreateMuteConfig' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=organizations/*}/muteConfigs', + 'body' => 'mute_config', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=folders/*}/muteConfigs', + 'body' => 'mute_config', + 'queryParams' => [ + 'mute_config_id', + ], + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*}/muteConfigs', + 'body' => 'mute_config', + 'queryParams' => [ + 'mute_config_id', + ], + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'mute_config_id', + ], + ], + 'CreateNotificationConfig' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=organizations/*}/notificationConfigs', + 'body' => 'notification_config', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=folders/*}/notificationConfigs', + 'body' => 'notification_config', + 'queryParams' => [ + 'config_id', + ], + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*}/notificationConfigs', + 'body' => 'notification_config', + 'queryParams' => [ + 'config_id', + ], + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'config_id', + ], + ], + 'CreateSecurityHealthAnalyticsCustomModule' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/customModules', + 'body' => 'security_health_analytics_custom_module', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=folders/*/securityHealthAnalyticsSettings}/customModules', + 'body' => 'security_health_analytics_custom_module', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/securityHealthAnalyticsSettings}/customModules', + 'body' => 'security_health_analytics_custom_module', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'CreateSource' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=organizations/*}/sources', + 'body' => 'source', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteBigQueryExport' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=organizations/*/bigQueryExports/*}', + 'additionalBindings' => [ + [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=folders/*/bigQueryExports/*}', + ], + [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/bigQueryExports/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteMuteConfig' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=organizations/*/muteConfigs/*}', + 'additionalBindings' => [ + [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=folders/*/muteConfigs/*}', + ], + [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/muteConfigs/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteNotificationConfig' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=organizations/*/notificationConfigs/*}', + 'additionalBindings' => [ + [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=folders/*/notificationConfigs/*}', + ], + [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/notificationConfigs/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteSecurityHealthAnalyticsCustomModule' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=organizations/*/securityHealthAnalyticsSettings/customModules/*}', + 'additionalBindings' => [ + [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=folders/*/securityHealthAnalyticsSettings/customModules/*}', + ], + [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/securityHealthAnalyticsSettings/customModules/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetBigQueryExport' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=organizations/*/bigQueryExports/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=folders/*/bigQueryExports/*}', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/bigQueryExports/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetEffectiveSecurityHealthAnalyticsCustomModule' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=organizations/*/securityHealthAnalyticsSettings/effectiveCustomModules/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=folders/*/securityHealthAnalyticsSettings/effectiveCustomModules/*}', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/securityHealthAnalyticsSettings/effectiveCustomModules/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetIamPolicy' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=organizations/*/sources/*}:getIamPolicy', + 'body' => '*', + 'placeholders' => [ + 'resource' => [ + 'getters' => [ + 'getResource', + ], + ], + ], + ], + 'GetMuteConfig' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=organizations/*/muteConfigs/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=folders/*/muteConfigs/*}', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/muteConfigs/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetNotificationConfig' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=organizations/*/notificationConfigs/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=folders/*/notificationConfigs/*}', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/notificationConfigs/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetOrganizationSettings' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=organizations/*/organizationSettings}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetSecurityHealthAnalyticsCustomModule' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=organizations/*/securityHealthAnalyticsSettings/customModules/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=folders/*/securityHealthAnalyticsSettings/customModules/*}', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/securityHealthAnalyticsSettings/customModules/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetSource' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=organizations/*/sources/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GroupAssets' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=organizations/*}/assets:group', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=folders/*}/assets:group', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*}/assets:group', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'GroupFindings' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=organizations/*/sources/*}/findings:group', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=folders/*/sources/*}/findings:group', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/sources/*}/findings:group', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListAssets' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=organizations/*}/assets', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=folders/*}/assets', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*}/assets', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListBigQueryExports' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=organizations/*}/bigQueryExports', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=folders/*}/bigQueryExports', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*}/bigQueryExports', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListDescendantSecurityHealthAnalyticsCustomModules' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/customModules:listDescendant', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=folders/*/securityHealthAnalyticsSettings}/customModules:listDescendant', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/securityHealthAnalyticsSettings}/customModules:listDescendant', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListEffectiveSecurityHealthAnalyticsCustomModules' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/effectiveCustomModules', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=folders/*/securityHealthAnalyticsSettings}/effectiveCustomModules', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/securityHealthAnalyticsSettings}/effectiveCustomModules', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListFindings' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=organizations/*/sources/*}/findings', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=folders/*/sources/*}/findings', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/sources/*}/findings', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListMuteConfigs' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=organizations/*}/muteConfigs', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=folders/*}/muteConfigs', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*}/muteConfigs', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListNotificationConfigs' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=organizations/*}/notificationConfigs', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=folders/*}/notificationConfigs', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*}/notificationConfigs', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListSecurityHealthAnalyticsCustomModules' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/customModules', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=folders/*/securityHealthAnalyticsSettings}/customModules', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/securityHealthAnalyticsSettings}/customModules', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListSources' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=organizations/*}/sources', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=folders/*}/sources', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*}/sources', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'RunAssetDiscovery' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=organizations/*}/assets:runDiscovery', + 'body' => '*', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'SetFindingState' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{name=organizations/*/sources/*/findings/*}:setState', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{name=folders/*/sources/*/findings/*}:setState', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{name=projects/*/sources/*/findings/*}:setState', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'SetIamPolicy' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=organizations/*/sources/*}:setIamPolicy', + 'body' => '*', + 'placeholders' => [ + 'resource' => [ + 'getters' => [ + 'getResource', + ], + ], + ], + ], + 'SetMute' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{name=organizations/*/sources/*/findings/*}:setMute', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{name=folders/*/sources/*/findings/*}:setMute', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{name=projects/*/sources/*/findings/*}:setMute', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'SimulateSecurityHealthAnalyticsCustomModule' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/customModules:simulate', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=folders/*/securityHealthAnalyticsSettings}/customModules:simulate', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/securityHealthAnalyticsSettings}/customModules:simulate', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'TestIamPermissions' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=organizations/*/sources/*}:testIamPermissions', + 'body' => '*', + 'placeholders' => [ + 'resource' => [ + 'getters' => [ + 'getResource', + ], + ], + ], + ], + 'UpdateBigQueryExport' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{big_query_export.name=organizations/*/bigQueryExports/*}', + 'body' => 'big_query_export', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{big_query_export.name=folders/*/bigQueryExports/*}', + 'body' => 'big_query_export', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{big_query_export.name=projects/*/bigQueryExports/*}', + 'body' => 'big_query_export', + ], + ], + 'placeholders' => [ + 'big_query_export.name' => [ + 'getters' => [ + 'getBigQueryExport', + 'getName', + ], + ], + ], + ], + 'UpdateExternalSystem' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{external_system.name=organizations/*/sources/*/findings/*/externalSystems/*}', + 'body' => 'external_system', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{external_system.name=folders/*/sources/*/findings/*/externalSystems/*}', + 'body' => 'external_system', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{external_system.name=projects/*/sources/*/findings/*/externalSystems/*}', + 'body' => 'external_system', + ], + ], + 'placeholders' => [ + 'external_system.name' => [ + 'getters' => [ + 'getExternalSystem', + 'getName', + ], + ], + ], + ], + 'UpdateFinding' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{finding.name=organizations/*/sources/*/findings/*}', + 'body' => 'finding', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{finding.name=folders/*/sources/*/findings/*}', + 'body' => 'finding', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{finding.name=projects/*/sources/*/findings/*}', + 'body' => 'finding', + ], + ], + 'placeholders' => [ + 'finding.name' => [ + 'getters' => [ + 'getFinding', + 'getName', + ], + ], + ], + ], + 'UpdateMuteConfig' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{mute_config.name=organizations/*/muteConfigs/*}', + 'body' => 'mute_config', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{mute_config.name=folders/*/muteConfigs/*}', + 'body' => 'mute_config', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{mute_config.name=projects/*/muteConfigs/*}', + 'body' => 'mute_config', + ], + ], + 'placeholders' => [ + 'mute_config.name' => [ + 'getters' => [ + 'getMuteConfig', + 'getName', + ], + ], + ], + ], + 'UpdateNotificationConfig' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{notification_config.name=organizations/*/notificationConfigs/*}', + 'body' => 'notification_config', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{notification_config.name=folders/*/notificationConfigs/*}', + 'body' => 'notification_config', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{notification_config.name=projects/*/notificationConfigs/*}', + 'body' => 'notification_config', + ], + ], + 'placeholders' => [ + 'notification_config.name' => [ + 'getters' => [ + 'getNotificationConfig', + 'getName', + ], + ], + ], + ], + 'UpdateOrganizationSettings' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{organization_settings.name=organizations/*/organizationSettings}', + 'body' => 'organization_settings', + 'placeholders' => [ + 'organization_settings.name' => [ + 'getters' => [ + 'getOrganizationSettings', + 'getName', + ], + ], + ], + ], + 'UpdateSecurityHealthAnalyticsCustomModule' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{security_health_analytics_custom_module.name=organizations/*/securityHealthAnalyticsSettings/customModules/*}', + 'body' => 'security_health_analytics_custom_module', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{security_health_analytics_custom_module.name=folders/*/securityHealthAnalyticsSettings/customModules/*}', + 'body' => 'security_health_analytics_custom_module', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{security_health_analytics_custom_module.name=projects/*/securityHealthAnalyticsSettings/customModules/*}', + 'body' => 'security_health_analytics_custom_module', + ], + ], + 'placeholders' => [ + 'security_health_analytics_custom_module.name' => [ + 'getters' => [ + 'getSecurityHealthAnalyticsCustomModule', + 'getName', + ], + ], + ], + ], + 'UpdateSecurityMarks' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{security_marks.name=organizations/*/assets/*/securityMarks}', + 'body' => 'security_marks', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{security_marks.name=folders/*/assets/*/securityMarks}', + 'body' => 'security_marks', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{security_marks.name=projects/*/assets/*/securityMarks}', + 'body' => 'security_marks', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{security_marks.name=organizations/*/sources/*/findings/*/securityMarks}', + 'body' => 'security_marks', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{security_marks.name=folders/*/sources/*/findings/*/securityMarks}', + 'body' => 'security_marks', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{security_marks.name=projects/*/sources/*/findings/*/securityMarks}', + 'body' => 'security_marks', + ], + ], + 'placeholders' => [ + 'security_marks.name' => [ + 'getters' => [ + 'getSecurityMarks', + 'getName', + ], + ], + ], + ], + 'UpdateSource' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{source.name=organizations/*/sources/*}', + 'body' => 'source', + 'placeholders' => [ + 'source.name' => [ + 'getters' => [ + 'getSource', + 'getName', + ], + ], + ], + ], + ], + 'google.longrunning.Operations' => [ + 'CancelOperation' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{name=organizations/*/operations/*}:cancel', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteOperation' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=organizations/*/operations/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetOperation' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=organizations/*/operations/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'ListOperations' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=organizations/*/operations}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + ], + ], + 'numericEnums' => true, +]; diff --git a/owl-bot-staging/SecurityCenter/v1/tests/Unit/V1/Client/SecurityCenterClientTest.php b/owl-bot-staging/SecurityCenter/v1/tests/Unit/V1/Client/SecurityCenterClientTest.php new file mode 100644 index 000000000000..c64e942c99f8 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/tests/Unit/V1/Client/SecurityCenterClientTest.php @@ -0,0 +1,3616 @@ +getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); + } + + /** @return SecurityCenterClient */ + private function createClient(array $options = []) + { + $options += [ + 'credentials' => $this->createCredentials(), + ]; + return new SecurityCenterClient($options); + } + + /** @test */ + public function bulkMuteFindingsTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/bulkMuteFindingsTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new BulkMuteFindingsResponse(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/bulkMuteFindingsTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $parent = 'parent-995424086'; + $request = (new BulkMuteFindingsRequest()) + ->setParent($parent); + $response = $gapicClient->bulkMuteFindings($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $apiRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($apiRequests)); + $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); + $this->assertSame(0, count($operationsRequestsEmpty)); + $actualApiFuncCall = $apiRequests[0]->getFuncCall(); + $actualApiRequestObject = $apiRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/BulkMuteFindings', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($parent, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/bulkMuteFindingsTest'); + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + $this->assertTrue($response->isDone()); + $this->assertEquals($expectedResponse, $response->getResult()); + $apiRequestsEmpty = $transport->popReceivedCalls(); + $this->assertSame(0, count($apiRequestsEmpty)); + $operationsRequests = $operationsTransport->popReceivedCalls(); + $this->assertSame(1, count($operationsRequests)); + $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); + $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); + $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); + $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function bulkMuteFindingsExceptionTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/bulkMuteFindingsTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $operationsTransport->addResponse(null, $status); + // Mock request + $parent = 'parent-995424086'; + $request = (new BulkMuteFindingsRequest()) + ->setParent($parent); + $response = $gapicClient->bulkMuteFindings($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/bulkMuteFindingsTest'); + try { + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + // If the pollUntilComplete() method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stubs are exhausted + $transport->popReceivedCalls(); + $operationsTransport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function createBigQueryExportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $description = 'description-1724546052'; + $filter = 'filter-1274492040'; + $dataset = 'dataset1443214456'; + $mostRecentEditor = 'mostRecentEditor-657770475'; + $principal = 'principal-1812041682'; + $expectedResponse = new BigQueryExport(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setFilter($filter); + $expectedResponse->setDataset($dataset); + $expectedResponse->setMostRecentEditor($mostRecentEditor); + $expectedResponse->setPrincipal($principal); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $bigQueryExport = new BigQueryExport(); + $bigQueryExportId = 'bigQueryExportId269737360'; + $request = (new CreateBigQueryExportRequest()) + ->setParent($formattedParent) + ->setBigQueryExport($bigQueryExport) + ->setBigQueryExportId($bigQueryExportId); + $response = $gapicClient->createBigQueryExport($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateBigQueryExport', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getBigQueryExport(); + $this->assertProtobufEquals($bigQueryExport, $actualValue); + $actualValue = $actualRequestObject->getBigQueryExportId(); + $this->assertProtobufEquals($bigQueryExportId, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createBigQueryExportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $bigQueryExport = new BigQueryExport(); + $bigQueryExportId = 'bigQueryExportId269737360'; + $request = (new CreateBigQueryExportRequest()) + ->setParent($formattedParent) + ->setBigQueryExport($bigQueryExport) + ->setBigQueryExportId($bigQueryExportId); + try { + $gapicClient->createBigQueryExport($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createFindingTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $parent2 = 'parent21175163357'; + $resourceName = 'resourceName979421212'; + $category = 'category50511102'; + $externalUri = 'externalUri-1385596168'; + $canonicalName = 'canonicalName1385400054'; + $muteInitiator = 'muteInitiator7603081'; + $parentDisplayName = 'parentDisplayName934119773'; + $description = 'description-1724546052'; + $nextSteps = 'nextSteps-921338149'; + $moduleName = 'moduleName-1195003778'; + $expectedResponse = new Finding(); + $expectedResponse->setName($name); + $expectedResponse->setParent($parent2); + $expectedResponse->setResourceName($resourceName); + $expectedResponse->setCategory($category); + $expectedResponse->setExternalUri($externalUri); + $expectedResponse->setCanonicalName($canonicalName); + $expectedResponse->setMuteInitiator($muteInitiator); + $expectedResponse->setParentDisplayName($parentDisplayName); + $expectedResponse->setDescription($description); + $expectedResponse->setNextSteps($nextSteps); + $expectedResponse->setModuleName($moduleName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $findingId = 'findingId728776081'; + $finding = new Finding(); + $request = (new CreateFindingRequest()) + ->setParent($formattedParent) + ->setFindingId($findingId) + ->setFinding($finding); + $response = $gapicClient->createFinding($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateFinding', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getFindingId(); + $this->assertProtobufEquals($findingId, $actualValue); + $actualValue = $actualRequestObject->getFinding(); + $this->assertProtobufEquals($finding, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createFindingExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $findingId = 'findingId728776081'; + $finding = new Finding(); + $request = (new CreateFindingRequest()) + ->setParent($formattedParent) + ->setFindingId($findingId) + ->setFinding($finding); + try { + $gapicClient->createFinding($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createMuteConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $filter = 'filter-1274492040'; + $mostRecentEditor = 'mostRecentEditor-657770475'; + $expectedResponse = new MuteConfig(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setFilter($filter); + $expectedResponse->setMostRecentEditor($mostRecentEditor); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $muteConfig = new MuteConfig(); + $muteConfigFilter = 'muteConfigFilter-1921414637'; + $muteConfig->setFilter($muteConfigFilter); + $muteConfigId = 'muteConfigId-547860334'; + $request = (new CreateMuteConfigRequest()) + ->setParent($formattedParent) + ->setMuteConfig($muteConfig) + ->setMuteConfigId($muteConfigId); + $response = $gapicClient->createMuteConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateMuteConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getMuteConfig(); + $this->assertProtobufEquals($muteConfig, $actualValue); + $actualValue = $actualRequestObject->getMuteConfigId(); + $this->assertProtobufEquals($muteConfigId, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createMuteConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $muteConfig = new MuteConfig(); + $muteConfigFilter = 'muteConfigFilter-1921414637'; + $muteConfig->setFilter($muteConfigFilter); + $muteConfigId = 'muteConfigId-547860334'; + $request = (new CreateMuteConfigRequest()) + ->setParent($formattedParent) + ->setMuteConfig($muteConfig) + ->setMuteConfigId($muteConfigId); + try { + $gapicClient->createMuteConfig($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createNotificationConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $description = 'description-1724546052'; + $pubsubTopic = 'pubsubTopic-338126829'; + $serviceAccount = 'serviceAccount-1948028253'; + $expectedResponse = new NotificationConfig(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setPubsubTopic($pubsubTopic); + $expectedResponse->setServiceAccount($serviceAccount); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $configId = 'configId-804450504'; + $notificationConfig = new NotificationConfig(); + $request = (new CreateNotificationConfigRequest()) + ->setParent($formattedParent) + ->setConfigId($configId) + ->setNotificationConfig($notificationConfig); + $response = $gapicClient->createNotificationConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateNotificationConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getConfigId(); + $this->assertProtobufEquals($configId, $actualValue); + $actualValue = $actualRequestObject->getNotificationConfig(); + $this->assertProtobufEquals($notificationConfig, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createNotificationConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $configId = 'configId-804450504'; + $notificationConfig = new NotificationConfig(); + $request = (new CreateNotificationConfigRequest()) + ->setParent($formattedParent) + ->setConfigId($configId) + ->setNotificationConfig($notificationConfig); + try { + $gapicClient->createNotificationConfig($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createSecurityHealthAnalyticsCustomModuleTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $lastEditor = 'lastEditor1620154166'; + $ancestorModule = 'ancestorModule-521996712'; + $expectedResponse = new SecurityHealthAnalyticsCustomModule(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setLastEditor($lastEditor); + $expectedResponse->setAncestorModule($ancestorModule); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); + $request = (new CreateSecurityHealthAnalyticsCustomModuleRequest()) + ->setParent($formattedParent) + ->setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); + $response = $gapicClient->createSecurityHealthAnalyticsCustomModule($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateSecurityHealthAnalyticsCustomModule', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getSecurityHealthAnalyticsCustomModule(); + $this->assertProtobufEquals($securityHealthAnalyticsCustomModule, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createSecurityHealthAnalyticsCustomModuleExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); + $request = (new CreateSecurityHealthAnalyticsCustomModuleRequest()) + ->setParent($formattedParent) + ->setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); + try { + $gapicClient->createSecurityHealthAnalyticsCustomModule($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createSourceTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $canonicalName = 'canonicalName1385400054'; + $expectedResponse = new Source(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setCanonicalName($canonicalName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $source = new Source(); + $request = (new CreateSourceRequest()) + ->setParent($formattedParent) + ->setSource($source); + $response = $gapicClient->createSource($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateSource', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getSource(); + $this->assertProtobufEquals($source, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createSourceExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $source = new Source(); + $request = (new CreateSourceRequest()) + ->setParent($formattedParent) + ->setSource($source); + try { + $gapicClient->createSource($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteBigQueryExportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); + $request = (new DeleteBigQueryExportRequest()) + ->setName($formattedName); + $gapicClient->deleteBigQueryExport($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/DeleteBigQueryExport', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteBigQueryExportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); + $request = (new DeleteBigQueryExportRequest()) + ->setName($formattedName); + try { + $gapicClient->deleteBigQueryExport($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteMuteConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); + $request = (new DeleteMuteConfigRequest()) + ->setName($formattedName); + $gapicClient->deleteMuteConfig($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/DeleteMuteConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteMuteConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); + $request = (new DeleteMuteConfigRequest()) + ->setName($formattedName); + try { + $gapicClient->deleteMuteConfig($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteNotificationConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); + $request = (new DeleteNotificationConfigRequest()) + ->setName($formattedName); + $gapicClient->deleteNotificationConfig($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/DeleteNotificationConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteNotificationConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); + $request = (new DeleteNotificationConfigRequest()) + ->setName($formattedName); + try { + $gapicClient->deleteNotificationConfig($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteSecurityHealthAnalyticsCustomModuleTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); + $request = (new DeleteSecurityHealthAnalyticsCustomModuleRequest()) + ->setName($formattedName); + $gapicClient->deleteSecurityHealthAnalyticsCustomModule($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/DeleteSecurityHealthAnalyticsCustomModule', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteSecurityHealthAnalyticsCustomModuleExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); + $request = (new DeleteSecurityHealthAnalyticsCustomModuleRequest()) + ->setName($formattedName); + try { + $gapicClient->deleteSecurityHealthAnalyticsCustomModule($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getBigQueryExportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $description = 'description-1724546052'; + $filter = 'filter-1274492040'; + $dataset = 'dataset1443214456'; + $mostRecentEditor = 'mostRecentEditor-657770475'; + $principal = 'principal-1812041682'; + $expectedResponse = new BigQueryExport(); + $expectedResponse->setName($name2); + $expectedResponse->setDescription($description); + $expectedResponse->setFilter($filter); + $expectedResponse->setDataset($dataset); + $expectedResponse->setMostRecentEditor($mostRecentEditor); + $expectedResponse->setPrincipal($principal); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); + $request = (new GetBigQueryExportRequest()) + ->setName($formattedName); + $response = $gapicClient->getBigQueryExport($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetBigQueryExport', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getBigQueryExportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); + $request = (new GetBigQueryExportRequest()) + ->setName($formattedName); + try { + $gapicClient->getBigQueryExport($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getEffectiveSecurityHealthAnalyticsCustomModuleTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $expectedResponse = new EffectiveSecurityHealthAnalyticsCustomModule(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->effectiveSecurityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[EFFECTIVE_CUSTOM_MODULE]'); + $request = (new GetEffectiveSecurityHealthAnalyticsCustomModuleRequest()) + ->setName($formattedName); + $response = $gapicClient->getEffectiveSecurityHealthAnalyticsCustomModule($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetEffectiveSecurityHealthAnalyticsCustomModule', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getEffectiveSecurityHealthAnalyticsCustomModuleExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->effectiveSecurityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[EFFECTIVE_CUSTOM_MODULE]'); + $request = (new GetEffectiveSecurityHealthAnalyticsCustomModuleRequest()) + ->setName($formattedName); + try { + $gapicClient->getEffectiveSecurityHealthAnalyticsCustomModule($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getIamPolicyTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $version = 351608024; + $etag = '21'; + $expectedResponse = new Policy(); + $expectedResponse->setVersion($version); + $expectedResponse->setEtag($etag); + $transport->addResponse($expectedResponse); + // Mock request + $resource = 'resource-341064690'; + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + $response = $gapicClient->getIamPolicy($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetIamPolicy', $actualFuncCall); + $actualValue = $actualRequestObject->getResource(); + $this->assertProtobufEquals($resource, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getIamPolicyExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $resource = 'resource-341064690'; + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + try { + $gapicClient->getIamPolicy($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getMuteConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $filter = 'filter-1274492040'; + $mostRecentEditor = 'mostRecentEditor-657770475'; + $expectedResponse = new MuteConfig(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setFilter($filter); + $expectedResponse->setMostRecentEditor($mostRecentEditor); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); + $request = (new GetMuteConfigRequest()) + ->setName($formattedName); + $response = $gapicClient->getMuteConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetMuteConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getMuteConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); + $request = (new GetMuteConfigRequest()) + ->setName($formattedName); + try { + $gapicClient->getMuteConfig($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getNotificationConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $description = 'description-1724546052'; + $pubsubTopic = 'pubsubTopic-338126829'; + $serviceAccount = 'serviceAccount-1948028253'; + $expectedResponse = new NotificationConfig(); + $expectedResponse->setName($name2); + $expectedResponse->setDescription($description); + $expectedResponse->setPubsubTopic($pubsubTopic); + $expectedResponse->setServiceAccount($serviceAccount); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); + $request = (new GetNotificationConfigRequest()) + ->setName($formattedName); + $response = $gapicClient->getNotificationConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetNotificationConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getNotificationConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); + $request = (new GetNotificationConfigRequest()) + ->setName($formattedName); + try { + $gapicClient->getNotificationConfig($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getOrganizationSettingsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $enableAssetDiscovery = false; + $expectedResponse = new OrganizationSettings(); + $expectedResponse->setName($name2); + $expectedResponse->setEnableAssetDiscovery($enableAssetDiscovery); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->organizationSettingsName('[ORGANIZATION]'); + $request = (new GetOrganizationSettingsRequest()) + ->setName($formattedName); + $response = $gapicClient->getOrganizationSettings($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetOrganizationSettings', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getOrganizationSettingsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->organizationSettingsName('[ORGANIZATION]'); + $request = (new GetOrganizationSettingsRequest()) + ->setName($formattedName); + try { + $gapicClient->getOrganizationSettings($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getSecurityHealthAnalyticsCustomModuleTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $lastEditor = 'lastEditor1620154166'; + $ancestorModule = 'ancestorModule-521996712'; + $expectedResponse = new SecurityHealthAnalyticsCustomModule(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setLastEditor($lastEditor); + $expectedResponse->setAncestorModule($ancestorModule); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); + $request = (new GetSecurityHealthAnalyticsCustomModuleRequest()) + ->setName($formattedName); + $response = $gapicClient->getSecurityHealthAnalyticsCustomModule($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetSecurityHealthAnalyticsCustomModule', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getSecurityHealthAnalyticsCustomModuleExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); + $request = (new GetSecurityHealthAnalyticsCustomModuleRequest()) + ->setName($formattedName); + try { + $gapicClient->getSecurityHealthAnalyticsCustomModule($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getSourceTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $canonicalName = 'canonicalName1385400054'; + $expectedResponse = new Source(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setCanonicalName($canonicalName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $request = (new GetSourceRequest()) + ->setName($formattedName); + $response = $gapicClient->getSource($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetSource', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getSourceExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $request = (new GetSourceRequest()) + ->setName($formattedName); + try { + $gapicClient->getSource($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function groupAssetsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $totalSize = 705419236; + $groupByResultsElement = new GroupResult(); + $groupByResults = [ + $groupByResultsElement, + ]; + $expectedResponse = new GroupAssetsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setTotalSize($totalSize); + $expectedResponse->setGroupByResults($groupByResults); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $groupBy = 'groupBy506361367'; + $request = (new GroupAssetsRequest()) + ->setParent($formattedParent) + ->setGroupBy($groupBy); + $response = $gapicClient->groupAssets($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getGroupByResults()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GroupAssets', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getGroupBy(); + $this->assertProtobufEquals($groupBy, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function groupAssetsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $groupBy = 'groupBy506361367'; + $request = (new GroupAssetsRequest()) + ->setParent($formattedParent) + ->setGroupBy($groupBy); + try { + $gapicClient->groupAssets($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function groupFindingsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $totalSize = 705419236; + $groupByResultsElement = new GroupResult(); + $groupByResults = [ + $groupByResultsElement, + ]; + $expectedResponse = new GroupFindingsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setTotalSize($totalSize); + $expectedResponse->setGroupByResults($groupByResults); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $groupBy = 'groupBy506361367'; + $request = (new GroupFindingsRequest()) + ->setParent($formattedParent) + ->setGroupBy($groupBy); + $response = $gapicClient->groupFindings($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getGroupByResults()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GroupFindings', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getGroupBy(); + $this->assertProtobufEquals($groupBy, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function groupFindingsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $groupBy = 'groupBy506361367'; + $request = (new GroupFindingsRequest()) + ->setParent($formattedParent) + ->setGroupBy($groupBy); + try { + $gapicClient->groupFindings($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listAssetsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $totalSize = 705419236; + $listAssetsResultsElement = new ListAssetsResult(); + $listAssetsResults = [ + $listAssetsResultsElement, + ]; + $expectedResponse = new ListAssetsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setTotalSize($totalSize); + $expectedResponse->setListAssetsResults($listAssetsResults); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $request = (new ListAssetsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listAssets($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getListAssetsResults()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListAssets', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listAssetsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $request = (new ListAssetsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listAssets($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listBigQueryExportsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $bigQueryExportsElement = new BigQueryExport(); + $bigQueryExports = [ + $bigQueryExportsElement, + ]; + $expectedResponse = new ListBigQueryExportsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setBigQueryExports($bigQueryExports); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $request = (new ListBigQueryExportsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listBigQueryExports($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getBigQueryExports()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListBigQueryExports', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listBigQueryExportsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $request = (new ListBigQueryExportsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listBigQueryExports($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listDescendantSecurityHealthAnalyticsCustomModulesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $securityHealthAnalyticsCustomModulesElement = new SecurityHealthAnalyticsCustomModule(); + $securityHealthAnalyticsCustomModules = [ + $securityHealthAnalyticsCustomModulesElement, + ]; + $expectedResponse = new ListDescendantSecurityHealthAnalyticsCustomModulesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setSecurityHealthAnalyticsCustomModules($securityHealthAnalyticsCustomModules); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + $request = (new ListDescendantSecurityHealthAnalyticsCustomModulesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listDescendantSecurityHealthAnalyticsCustomModules($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getSecurityHealthAnalyticsCustomModules()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListDescendantSecurityHealthAnalyticsCustomModules', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listDescendantSecurityHealthAnalyticsCustomModulesExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + $request = (new ListDescendantSecurityHealthAnalyticsCustomModulesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listDescendantSecurityHealthAnalyticsCustomModules($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listEffectiveSecurityHealthAnalyticsCustomModulesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $effectiveSecurityHealthAnalyticsCustomModulesElement = new EffectiveSecurityHealthAnalyticsCustomModule(); + $effectiveSecurityHealthAnalyticsCustomModules = [ + $effectiveSecurityHealthAnalyticsCustomModulesElement, + ]; + $expectedResponse = new ListEffectiveSecurityHealthAnalyticsCustomModulesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setEffectiveSecurityHealthAnalyticsCustomModules($effectiveSecurityHealthAnalyticsCustomModules); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + $request = (new ListEffectiveSecurityHealthAnalyticsCustomModulesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listEffectiveSecurityHealthAnalyticsCustomModules($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getEffectiveSecurityHealthAnalyticsCustomModules()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListEffectiveSecurityHealthAnalyticsCustomModules', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listEffectiveSecurityHealthAnalyticsCustomModulesExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + $request = (new ListEffectiveSecurityHealthAnalyticsCustomModulesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listEffectiveSecurityHealthAnalyticsCustomModules($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listFindingsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $totalSize = 705419236; + $listFindingsResultsElement = new ListFindingsResult(); + $listFindingsResults = [ + $listFindingsResultsElement, + ]; + $expectedResponse = new ListFindingsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setTotalSize($totalSize); + $expectedResponse->setListFindingsResults($listFindingsResults); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $request = (new ListFindingsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listFindings($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getListFindingsResults()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListFindings', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listFindingsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $request = (new ListFindingsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listFindings($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listMuteConfigsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $muteConfigsElement = new MuteConfig(); + $muteConfigs = [ + $muteConfigsElement, + ]; + $expectedResponse = new ListMuteConfigsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setMuteConfigs($muteConfigs); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $request = (new ListMuteConfigsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listMuteConfigs($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getMuteConfigs()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListMuteConfigs', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listMuteConfigsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $request = (new ListMuteConfigsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listMuteConfigs($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listNotificationConfigsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $notificationConfigsElement = new NotificationConfig(); + $notificationConfigs = [ + $notificationConfigsElement, + ]; + $expectedResponse = new ListNotificationConfigsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setNotificationConfigs($notificationConfigs); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $request = (new ListNotificationConfigsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listNotificationConfigs($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getNotificationConfigs()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListNotificationConfigs', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listNotificationConfigsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $request = (new ListNotificationConfigsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listNotificationConfigs($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listSecurityHealthAnalyticsCustomModulesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $securityHealthAnalyticsCustomModulesElement = new SecurityHealthAnalyticsCustomModule(); + $securityHealthAnalyticsCustomModules = [ + $securityHealthAnalyticsCustomModulesElement, + ]; + $expectedResponse = new ListSecurityHealthAnalyticsCustomModulesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setSecurityHealthAnalyticsCustomModules($securityHealthAnalyticsCustomModules); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + $request = (new ListSecurityHealthAnalyticsCustomModulesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listSecurityHealthAnalyticsCustomModules($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getSecurityHealthAnalyticsCustomModules()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListSecurityHealthAnalyticsCustomModules', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listSecurityHealthAnalyticsCustomModulesExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + $request = (new ListSecurityHealthAnalyticsCustomModulesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listSecurityHealthAnalyticsCustomModules($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listSourcesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $sourcesElement = new Source(); + $sources = [ + $sourcesElement, + ]; + $expectedResponse = new ListSourcesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setSources($sources); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $request = (new ListSourcesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listSources($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getSources()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListSources', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listSourcesExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $request = (new ListSourcesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listSources($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function runAssetDiscoveryTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/runAssetDiscoveryTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new RunAssetDiscoveryResponse(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/runAssetDiscoveryTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $request = (new RunAssetDiscoveryRequest()) + ->setParent($formattedParent); + $response = $gapicClient->runAssetDiscovery($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $apiRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($apiRequests)); + $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); + $this->assertSame(0, count($operationsRequestsEmpty)); + $actualApiFuncCall = $apiRequests[0]->getFuncCall(); + $actualApiRequestObject = $apiRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/RunAssetDiscovery', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/runAssetDiscoveryTest'); + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + $this->assertTrue($response->isDone()); + $this->assertEquals($expectedResponse, $response->getResult()); + $apiRequestsEmpty = $transport->popReceivedCalls(); + $this->assertSame(0, count($apiRequestsEmpty)); + $operationsRequests = $operationsTransport->popReceivedCalls(); + $this->assertSame(1, count($operationsRequests)); + $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); + $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); + $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); + $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function runAssetDiscoveryExceptionTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/runAssetDiscoveryTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $operationsTransport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $request = (new RunAssetDiscoveryRequest()) + ->setParent($formattedParent); + $response = $gapicClient->runAssetDiscovery($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/runAssetDiscoveryTest'); + try { + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + // If the pollUntilComplete() method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stubs are exhausted + $transport->popReceivedCalls(); + $operationsTransport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function setFindingStateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $parent = 'parent-995424086'; + $resourceName = 'resourceName979421212'; + $category = 'category50511102'; + $externalUri = 'externalUri-1385596168'; + $canonicalName = 'canonicalName1385400054'; + $muteInitiator = 'muteInitiator7603081'; + $parentDisplayName = 'parentDisplayName934119773'; + $description = 'description-1724546052'; + $nextSteps = 'nextSteps-921338149'; + $moduleName = 'moduleName-1195003778'; + $expectedResponse = new Finding(); + $expectedResponse->setName($name2); + $expectedResponse->setParent($parent); + $expectedResponse->setResourceName($resourceName); + $expectedResponse->setCategory($category); + $expectedResponse->setExternalUri($externalUri); + $expectedResponse->setCanonicalName($canonicalName); + $expectedResponse->setMuteInitiator($muteInitiator); + $expectedResponse->setParentDisplayName($parentDisplayName); + $expectedResponse->setDescription($description); + $expectedResponse->setNextSteps($nextSteps); + $expectedResponse->setModuleName($moduleName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + $state = State::STATE_UNSPECIFIED; + $startTime = new Timestamp(); + $request = (new SetFindingStateRequest()) + ->setName($formattedName) + ->setState($state) + ->setStartTime($startTime); + $response = $gapicClient->setFindingState($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/SetFindingState', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $actualValue = $actualRequestObject->getState(); + $this->assertProtobufEquals($state, $actualValue); + $actualValue = $actualRequestObject->getStartTime(); + $this->assertProtobufEquals($startTime, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function setFindingStateExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + $state = State::STATE_UNSPECIFIED; + $startTime = new Timestamp(); + $request = (new SetFindingStateRequest()) + ->setName($formattedName) + ->setState($state) + ->setStartTime($startTime); + try { + $gapicClient->setFindingState($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function setIamPolicyTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $version = 351608024; + $etag = '21'; + $expectedResponse = new Policy(); + $expectedResponse->setVersion($version); + $expectedResponse->setEtag($etag); + $transport->addResponse($expectedResponse); + // Mock request + $resource = 'resource-341064690'; + $policy = new Policy(); + $request = (new SetIamPolicyRequest()) + ->setResource($resource) + ->setPolicy($policy); + $response = $gapicClient->setIamPolicy($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/SetIamPolicy', $actualFuncCall); + $actualValue = $actualRequestObject->getResource(); + $this->assertProtobufEquals($resource, $actualValue); + $actualValue = $actualRequestObject->getPolicy(); + $this->assertProtobufEquals($policy, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function setIamPolicyExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $resource = 'resource-341064690'; + $policy = new Policy(); + $request = (new SetIamPolicyRequest()) + ->setResource($resource) + ->setPolicy($policy); + try { + $gapicClient->setIamPolicy($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function setMuteTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $parent = 'parent-995424086'; + $resourceName = 'resourceName979421212'; + $category = 'category50511102'; + $externalUri = 'externalUri-1385596168'; + $canonicalName = 'canonicalName1385400054'; + $muteInitiator = 'muteInitiator7603081'; + $parentDisplayName = 'parentDisplayName934119773'; + $description = 'description-1724546052'; + $nextSteps = 'nextSteps-921338149'; + $moduleName = 'moduleName-1195003778'; + $expectedResponse = new Finding(); + $expectedResponse->setName($name2); + $expectedResponse->setParent($parent); + $expectedResponse->setResourceName($resourceName); + $expectedResponse->setCategory($category); + $expectedResponse->setExternalUri($externalUri); + $expectedResponse->setCanonicalName($canonicalName); + $expectedResponse->setMuteInitiator($muteInitiator); + $expectedResponse->setParentDisplayName($parentDisplayName); + $expectedResponse->setDescription($description); + $expectedResponse->setNextSteps($nextSteps); + $expectedResponse->setModuleName($moduleName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + $mute = Mute::MUTE_UNSPECIFIED; + $request = (new SetMuteRequest()) + ->setName($formattedName) + ->setMute($mute); + $response = $gapicClient->setMute($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/SetMute', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $actualValue = $actualRequestObject->getMute(); + $this->assertProtobufEquals($mute, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function setMuteExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + $mute = Mute::MUTE_UNSPECIFIED; + $request = (new SetMuteRequest()) + ->setName($formattedName) + ->setMute($mute); + try { + $gapicClient->setMute($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function simulateSecurityHealthAnalyticsCustomModuleTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new SimulateSecurityHealthAnalyticsCustomModuleResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $parent = 'parent-995424086'; + $customConfig = new CustomConfig(); + $resource = new SimulatedResource(); + $resourceResourceType = 'resourceResourceType305300374'; + $resource->setResourceType($resourceResourceType); + $request = (new SimulateSecurityHealthAnalyticsCustomModuleRequest()) + ->setParent($parent) + ->setCustomConfig($customConfig) + ->setResource($resource); + $response = $gapicClient->simulateSecurityHealthAnalyticsCustomModule($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/SimulateSecurityHealthAnalyticsCustomModule', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($parent, $actualValue); + $actualValue = $actualRequestObject->getCustomConfig(); + $this->assertProtobufEquals($customConfig, $actualValue); + $actualValue = $actualRequestObject->getResource(); + $this->assertProtobufEquals($resource, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function simulateSecurityHealthAnalyticsCustomModuleExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $parent = 'parent-995424086'; + $customConfig = new CustomConfig(); + $resource = new SimulatedResource(); + $resourceResourceType = 'resourceResourceType305300374'; + $resource->setResourceType($resourceResourceType); + $request = (new SimulateSecurityHealthAnalyticsCustomModuleRequest()) + ->setParent($parent) + ->setCustomConfig($customConfig) + ->setResource($resource); + try { + $gapicClient->simulateSecurityHealthAnalyticsCustomModule($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function testIamPermissionsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new TestIamPermissionsResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $resource = 'resource-341064690'; + $permissions = []; + $request = (new TestIamPermissionsRequest()) + ->setResource($resource) + ->setPermissions($permissions); + $response = $gapicClient->testIamPermissions($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/TestIamPermissions', $actualFuncCall); + $actualValue = $actualRequestObject->getResource(); + $this->assertProtobufEquals($resource, $actualValue); + $actualValue = $actualRequestObject->getPermissions(); + $this->assertProtobufEquals($permissions, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function testIamPermissionsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $resource = 'resource-341064690'; + $permissions = []; + $request = (new TestIamPermissionsRequest()) + ->setResource($resource) + ->setPermissions($permissions); + try { + $gapicClient->testIamPermissions($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateBigQueryExportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $description = 'description-1724546052'; + $filter = 'filter-1274492040'; + $dataset = 'dataset1443214456'; + $mostRecentEditor = 'mostRecentEditor-657770475'; + $principal = 'principal-1812041682'; + $expectedResponse = new BigQueryExport(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setFilter($filter); + $expectedResponse->setDataset($dataset); + $expectedResponse->setMostRecentEditor($mostRecentEditor); + $expectedResponse->setPrincipal($principal); + $transport->addResponse($expectedResponse); + // Mock request + $bigQueryExport = new BigQueryExport(); + $request = (new UpdateBigQueryExportRequest()) + ->setBigQueryExport($bigQueryExport); + $response = $gapicClient->updateBigQueryExport($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateBigQueryExport', $actualFuncCall); + $actualValue = $actualRequestObject->getBigQueryExport(); + $this->assertProtobufEquals($bigQueryExport, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateBigQueryExportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $bigQueryExport = new BigQueryExport(); + $request = (new UpdateBigQueryExportRequest()) + ->setBigQueryExport($bigQueryExport); + try { + $gapicClient->updateBigQueryExport($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateExternalSystemTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $externalUid = 'externalUid-1385596452'; + $status = 'status-892481550'; + $caseUri = 'caseUri21649373'; + $casePriority = 'casePriority715048403'; + $expectedResponse = new ExternalSystem(); + $expectedResponse->setName($name); + $expectedResponse->setExternalUid($externalUid); + $expectedResponse->setStatus($status); + $expectedResponse->setCaseUri($caseUri); + $expectedResponse->setCasePriority($casePriority); + $transport->addResponse($expectedResponse); + // Mock request + $externalSystem = new ExternalSystem(); + $request = (new UpdateExternalSystemRequest()) + ->setExternalSystem($externalSystem); + $response = $gapicClient->updateExternalSystem($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateExternalSystem', $actualFuncCall); + $actualValue = $actualRequestObject->getExternalSystem(); + $this->assertProtobufEquals($externalSystem, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateExternalSystemExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $externalSystem = new ExternalSystem(); + $request = (new UpdateExternalSystemRequest()) + ->setExternalSystem($externalSystem); + try { + $gapicClient->updateExternalSystem($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateFindingTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $parent = 'parent-995424086'; + $resourceName = 'resourceName979421212'; + $category = 'category50511102'; + $externalUri = 'externalUri-1385596168'; + $canonicalName = 'canonicalName1385400054'; + $muteInitiator = 'muteInitiator7603081'; + $parentDisplayName = 'parentDisplayName934119773'; + $description = 'description-1724546052'; + $nextSteps = 'nextSteps-921338149'; + $moduleName = 'moduleName-1195003778'; + $expectedResponse = new Finding(); + $expectedResponse->setName($name); + $expectedResponse->setParent($parent); + $expectedResponse->setResourceName($resourceName); + $expectedResponse->setCategory($category); + $expectedResponse->setExternalUri($externalUri); + $expectedResponse->setCanonicalName($canonicalName); + $expectedResponse->setMuteInitiator($muteInitiator); + $expectedResponse->setParentDisplayName($parentDisplayName); + $expectedResponse->setDescription($description); + $expectedResponse->setNextSteps($nextSteps); + $expectedResponse->setModuleName($moduleName); + $transport->addResponse($expectedResponse); + // Mock request + $finding = new Finding(); + $request = (new UpdateFindingRequest()) + ->setFinding($finding); + $response = $gapicClient->updateFinding($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateFinding', $actualFuncCall); + $actualValue = $actualRequestObject->getFinding(); + $this->assertProtobufEquals($finding, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateFindingExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $finding = new Finding(); + $request = (new UpdateFindingRequest()) + ->setFinding($finding); + try { + $gapicClient->updateFinding($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateMuteConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $filter = 'filter-1274492040'; + $mostRecentEditor = 'mostRecentEditor-657770475'; + $expectedResponse = new MuteConfig(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setFilter($filter); + $expectedResponse->setMostRecentEditor($mostRecentEditor); + $transport->addResponse($expectedResponse); + // Mock request + $muteConfig = new MuteConfig(); + $muteConfigFilter = 'muteConfigFilter-1921414637'; + $muteConfig->setFilter($muteConfigFilter); + $request = (new UpdateMuteConfigRequest()) + ->setMuteConfig($muteConfig); + $response = $gapicClient->updateMuteConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateMuteConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getMuteConfig(); + $this->assertProtobufEquals($muteConfig, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateMuteConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $muteConfig = new MuteConfig(); + $muteConfigFilter = 'muteConfigFilter-1921414637'; + $muteConfig->setFilter($muteConfigFilter); + $request = (new UpdateMuteConfigRequest()) + ->setMuteConfig($muteConfig); + try { + $gapicClient->updateMuteConfig($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateNotificationConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $description = 'description-1724546052'; + $pubsubTopic = 'pubsubTopic-338126829'; + $serviceAccount = 'serviceAccount-1948028253'; + $expectedResponse = new NotificationConfig(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setPubsubTopic($pubsubTopic); + $expectedResponse->setServiceAccount($serviceAccount); + $transport->addResponse($expectedResponse); + // Mock request + $notificationConfig = new NotificationConfig(); + $request = (new UpdateNotificationConfigRequest()) + ->setNotificationConfig($notificationConfig); + $response = $gapicClient->updateNotificationConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateNotificationConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getNotificationConfig(); + $this->assertProtobufEquals($notificationConfig, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateNotificationConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $notificationConfig = new NotificationConfig(); + $request = (new UpdateNotificationConfigRequest()) + ->setNotificationConfig($notificationConfig); + try { + $gapicClient->updateNotificationConfig($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateOrganizationSettingsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $enableAssetDiscovery = false; + $expectedResponse = new OrganizationSettings(); + $expectedResponse->setName($name); + $expectedResponse->setEnableAssetDiscovery($enableAssetDiscovery); + $transport->addResponse($expectedResponse); + // Mock request + $organizationSettings = new OrganizationSettings(); + $request = (new UpdateOrganizationSettingsRequest()) + ->setOrganizationSettings($organizationSettings); + $response = $gapicClient->updateOrganizationSettings($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateOrganizationSettings', $actualFuncCall); + $actualValue = $actualRequestObject->getOrganizationSettings(); + $this->assertProtobufEquals($organizationSettings, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateOrganizationSettingsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $organizationSettings = new OrganizationSettings(); + $request = (new UpdateOrganizationSettingsRequest()) + ->setOrganizationSettings($organizationSettings); + try { + $gapicClient->updateOrganizationSettings($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSecurityHealthAnalyticsCustomModuleTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $lastEditor = 'lastEditor1620154166'; + $ancestorModule = 'ancestorModule-521996712'; + $expectedResponse = new SecurityHealthAnalyticsCustomModule(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setLastEditor($lastEditor); + $expectedResponse->setAncestorModule($ancestorModule); + $transport->addResponse($expectedResponse); + // Mock request + $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); + $request = (new UpdateSecurityHealthAnalyticsCustomModuleRequest()) + ->setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); + $response = $gapicClient->updateSecurityHealthAnalyticsCustomModule($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateSecurityHealthAnalyticsCustomModule', $actualFuncCall); + $actualValue = $actualRequestObject->getSecurityHealthAnalyticsCustomModule(); + $this->assertProtobufEquals($securityHealthAnalyticsCustomModule, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSecurityHealthAnalyticsCustomModuleExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); + $request = (new UpdateSecurityHealthAnalyticsCustomModuleRequest()) + ->setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); + try { + $gapicClient->updateSecurityHealthAnalyticsCustomModule($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSecurityMarksTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $canonicalName = 'canonicalName1385400054'; + $expectedResponse = new SecurityMarks(); + $expectedResponse->setName($name); + $expectedResponse->setCanonicalName($canonicalName); + $transport->addResponse($expectedResponse); + // Mock request + $securityMarks = new SecurityMarks(); + $request = (new UpdateSecurityMarksRequest()) + ->setSecurityMarks($securityMarks); + $response = $gapicClient->updateSecurityMarks($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateSecurityMarks', $actualFuncCall); + $actualValue = $actualRequestObject->getSecurityMarks(); + $this->assertProtobufEquals($securityMarks, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSecurityMarksExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $securityMarks = new SecurityMarks(); + $request = (new UpdateSecurityMarksRequest()) + ->setSecurityMarks($securityMarks); + try { + $gapicClient->updateSecurityMarks($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSourceTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $canonicalName = 'canonicalName1385400054'; + $expectedResponse = new Source(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setCanonicalName($canonicalName); + $transport->addResponse($expectedResponse); + // Mock request + $source = new Source(); + $request = (new UpdateSourceRequest()) + ->setSource($source); + $response = $gapicClient->updateSource($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateSource', $actualFuncCall); + $actualValue = $actualRequestObject->getSource(); + $this->assertProtobufEquals($source, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSourceExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $source = new Source(); + $request = (new UpdateSourceRequest()) + ->setSource($source); + try { + $gapicClient->updateSource($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function bulkMuteFindingsAsyncTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/bulkMuteFindingsTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new BulkMuteFindingsResponse(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/bulkMuteFindingsTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $parent = 'parent-995424086'; + $request = (new BulkMuteFindingsRequest()) + ->setParent($parent); + $response = $gapicClient->bulkMuteFindingsAsync($request)->wait(); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $apiRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($apiRequests)); + $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); + $this->assertSame(0, count($operationsRequestsEmpty)); + $actualApiFuncCall = $apiRequests[0]->getFuncCall(); + $actualApiRequestObject = $apiRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/BulkMuteFindings', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($parent, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/bulkMuteFindingsTest'); + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + $this->assertTrue($response->isDone()); + $this->assertEquals($expectedResponse, $response->getResult()); + $apiRequestsEmpty = $transport->popReceivedCalls(); + $this->assertSame(0, count($apiRequestsEmpty)); + $operationsRequests = $operationsTransport->popReceivedCalls(); + $this->assertSame(1, count($operationsRequests)); + $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); + $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); + $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); + $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } +} diff --git a/owl-bot-staging/SecurityCenter/v1/tests/Unit/V1/SecurityCenterClientTest.php b/owl-bot-staging/SecurityCenter/v1/tests/Unit/V1/SecurityCenterClientTest.php new file mode 100644 index 000000000000..638d1b3fb681 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1/tests/Unit/V1/SecurityCenterClientTest.php @@ -0,0 +1,3289 @@ +getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); + } + + /** @return SecurityCenterClient */ + private function createClient(array $options = []) + { + $options += [ + 'credentials' => $this->createCredentials(), + ]; + return new SecurityCenterClient($options); + } + + /** @test */ + public function bulkMuteFindingsTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/bulkMuteFindingsTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new BulkMuteFindingsResponse(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/bulkMuteFindingsTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $parent = 'parent-995424086'; + $response = $gapicClient->bulkMuteFindings($parent); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $apiRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($apiRequests)); + $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); + $this->assertSame(0, count($operationsRequestsEmpty)); + $actualApiFuncCall = $apiRequests[0]->getFuncCall(); + $actualApiRequestObject = $apiRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/BulkMuteFindings', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($parent, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/bulkMuteFindingsTest'); + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + $this->assertTrue($response->isDone()); + $this->assertEquals($expectedResponse, $response->getResult()); + $apiRequestsEmpty = $transport->popReceivedCalls(); + $this->assertSame(0, count($apiRequestsEmpty)); + $operationsRequests = $operationsTransport->popReceivedCalls(); + $this->assertSame(1, count($operationsRequests)); + $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); + $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); + $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); + $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function bulkMuteFindingsExceptionTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/bulkMuteFindingsTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $operationsTransport->addResponse(null, $status); + // Mock request + $parent = 'parent-995424086'; + $response = $gapicClient->bulkMuteFindings($parent); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/bulkMuteFindingsTest'); + try { + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + // If the pollUntilComplete() method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stubs are exhausted + $transport->popReceivedCalls(); + $operationsTransport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function createBigQueryExportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $description = 'description-1724546052'; + $filter = 'filter-1274492040'; + $dataset = 'dataset1443214456'; + $mostRecentEditor = 'mostRecentEditor-657770475'; + $principal = 'principal-1812041682'; + $expectedResponse = new BigQueryExport(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setFilter($filter); + $expectedResponse->setDataset($dataset); + $expectedResponse->setMostRecentEditor($mostRecentEditor); + $expectedResponse->setPrincipal($principal); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $bigQueryExport = new BigQueryExport(); + $bigQueryExportId = 'bigQueryExportId269737360'; + $response = $gapicClient->createBigQueryExport($formattedParent, $bigQueryExport, $bigQueryExportId); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateBigQueryExport', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getBigQueryExport(); + $this->assertProtobufEquals($bigQueryExport, $actualValue); + $actualValue = $actualRequestObject->getBigQueryExportId(); + $this->assertProtobufEquals($bigQueryExportId, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createBigQueryExportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $bigQueryExport = new BigQueryExport(); + $bigQueryExportId = 'bigQueryExportId269737360'; + try { + $gapicClient->createBigQueryExport($formattedParent, $bigQueryExport, $bigQueryExportId); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createFindingTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $parent2 = 'parent21175163357'; + $resourceName = 'resourceName979421212'; + $category = 'category50511102'; + $externalUri = 'externalUri-1385596168'; + $canonicalName = 'canonicalName1385400054'; + $muteInitiator = 'muteInitiator7603081'; + $parentDisplayName = 'parentDisplayName934119773'; + $description = 'description-1724546052'; + $nextSteps = 'nextSteps-921338149'; + $moduleName = 'moduleName-1195003778'; + $expectedResponse = new Finding(); + $expectedResponse->setName($name); + $expectedResponse->setParent($parent2); + $expectedResponse->setResourceName($resourceName); + $expectedResponse->setCategory($category); + $expectedResponse->setExternalUri($externalUri); + $expectedResponse->setCanonicalName($canonicalName); + $expectedResponse->setMuteInitiator($muteInitiator); + $expectedResponse->setParentDisplayName($parentDisplayName); + $expectedResponse->setDescription($description); + $expectedResponse->setNextSteps($nextSteps); + $expectedResponse->setModuleName($moduleName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $findingId = 'findingId728776081'; + $finding = new Finding(); + $response = $gapicClient->createFinding($formattedParent, $findingId, $finding); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateFinding', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getFindingId(); + $this->assertProtobufEquals($findingId, $actualValue); + $actualValue = $actualRequestObject->getFinding(); + $this->assertProtobufEquals($finding, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createFindingExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $findingId = 'findingId728776081'; + $finding = new Finding(); + try { + $gapicClient->createFinding($formattedParent, $findingId, $finding); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createMuteConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $filter = 'filter-1274492040'; + $mostRecentEditor = 'mostRecentEditor-657770475'; + $expectedResponse = new MuteConfig(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setFilter($filter); + $expectedResponse->setMostRecentEditor($mostRecentEditor); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $muteConfig = new MuteConfig(); + $muteConfigFilter = 'muteConfigFilter-1921414637'; + $muteConfig->setFilter($muteConfigFilter); + $muteConfigId = 'muteConfigId-547860334'; + $response = $gapicClient->createMuteConfig($formattedParent, $muteConfig, $muteConfigId); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateMuteConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getMuteConfig(); + $this->assertProtobufEquals($muteConfig, $actualValue); + $actualValue = $actualRequestObject->getMuteConfigId(); + $this->assertProtobufEquals($muteConfigId, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createMuteConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $muteConfig = new MuteConfig(); + $muteConfigFilter = 'muteConfigFilter-1921414637'; + $muteConfig->setFilter($muteConfigFilter); + $muteConfigId = 'muteConfigId-547860334'; + try { + $gapicClient->createMuteConfig($formattedParent, $muteConfig, $muteConfigId); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createNotificationConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $description = 'description-1724546052'; + $pubsubTopic = 'pubsubTopic-338126829'; + $serviceAccount = 'serviceAccount-1948028253'; + $expectedResponse = new NotificationConfig(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setPubsubTopic($pubsubTopic); + $expectedResponse->setServiceAccount($serviceAccount); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $configId = 'configId-804450504'; + $notificationConfig = new NotificationConfig(); + $response = $gapicClient->createNotificationConfig($formattedParent, $configId, $notificationConfig); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateNotificationConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getConfigId(); + $this->assertProtobufEquals($configId, $actualValue); + $actualValue = $actualRequestObject->getNotificationConfig(); + $this->assertProtobufEquals($notificationConfig, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createNotificationConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $configId = 'configId-804450504'; + $notificationConfig = new NotificationConfig(); + try { + $gapicClient->createNotificationConfig($formattedParent, $configId, $notificationConfig); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createSecurityHealthAnalyticsCustomModuleTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $lastEditor = 'lastEditor1620154166'; + $ancestorModule = 'ancestorModule-521996712'; + $expectedResponse = new SecurityHealthAnalyticsCustomModule(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setLastEditor($lastEditor); + $expectedResponse->setAncestorModule($ancestorModule); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); + $response = $gapicClient->createSecurityHealthAnalyticsCustomModule($formattedParent, $securityHealthAnalyticsCustomModule); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateSecurityHealthAnalyticsCustomModule', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getSecurityHealthAnalyticsCustomModule(); + $this->assertProtobufEquals($securityHealthAnalyticsCustomModule, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createSecurityHealthAnalyticsCustomModuleExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); + try { + $gapicClient->createSecurityHealthAnalyticsCustomModule($formattedParent, $securityHealthAnalyticsCustomModule); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createSourceTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $canonicalName = 'canonicalName1385400054'; + $expectedResponse = new Source(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setCanonicalName($canonicalName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $source = new Source(); + $response = $gapicClient->createSource($formattedParent, $source); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateSource', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getSource(); + $this->assertProtobufEquals($source, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createSourceExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $source = new Source(); + try { + $gapicClient->createSource($formattedParent, $source); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteBigQueryExportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); + $gapicClient->deleteBigQueryExport($formattedName); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/DeleteBigQueryExport', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteBigQueryExportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); + try { + $gapicClient->deleteBigQueryExport($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteMuteConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); + $gapicClient->deleteMuteConfig($formattedName); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/DeleteMuteConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteMuteConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); + try { + $gapicClient->deleteMuteConfig($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteNotificationConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); + $gapicClient->deleteNotificationConfig($formattedName); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/DeleteNotificationConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteNotificationConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); + try { + $gapicClient->deleteNotificationConfig($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteSecurityHealthAnalyticsCustomModuleTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); + $gapicClient->deleteSecurityHealthAnalyticsCustomModule($formattedName); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/DeleteSecurityHealthAnalyticsCustomModule', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteSecurityHealthAnalyticsCustomModuleExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); + try { + $gapicClient->deleteSecurityHealthAnalyticsCustomModule($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getBigQueryExportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $description = 'description-1724546052'; + $filter = 'filter-1274492040'; + $dataset = 'dataset1443214456'; + $mostRecentEditor = 'mostRecentEditor-657770475'; + $principal = 'principal-1812041682'; + $expectedResponse = new BigQueryExport(); + $expectedResponse->setName($name2); + $expectedResponse->setDescription($description); + $expectedResponse->setFilter($filter); + $expectedResponse->setDataset($dataset); + $expectedResponse->setMostRecentEditor($mostRecentEditor); + $expectedResponse->setPrincipal($principal); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); + $response = $gapicClient->getBigQueryExport($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetBigQueryExport', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getBigQueryExportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); + try { + $gapicClient->getBigQueryExport($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getEffectiveSecurityHealthAnalyticsCustomModuleTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $expectedResponse = new EffectiveSecurityHealthAnalyticsCustomModule(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->effectiveSecurityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[EFFECTIVE_CUSTOM_MODULE]'); + $response = $gapicClient->getEffectiveSecurityHealthAnalyticsCustomModule($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetEffectiveSecurityHealthAnalyticsCustomModule', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getEffectiveSecurityHealthAnalyticsCustomModuleExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->effectiveSecurityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[EFFECTIVE_CUSTOM_MODULE]'); + try { + $gapicClient->getEffectiveSecurityHealthAnalyticsCustomModule($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getIamPolicyTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $version = 351608024; + $etag = '21'; + $expectedResponse = new Policy(); + $expectedResponse->setVersion($version); + $expectedResponse->setEtag($etag); + $transport->addResponse($expectedResponse); + // Mock request + $resource = 'resource-341064690'; + $response = $gapicClient->getIamPolicy($resource); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetIamPolicy', $actualFuncCall); + $actualValue = $actualRequestObject->getResource(); + $this->assertProtobufEquals($resource, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getIamPolicyExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $resource = 'resource-341064690'; + try { + $gapicClient->getIamPolicy($resource); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getMuteConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $filter = 'filter-1274492040'; + $mostRecentEditor = 'mostRecentEditor-657770475'; + $expectedResponse = new MuteConfig(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setFilter($filter); + $expectedResponse->setMostRecentEditor($mostRecentEditor); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); + $response = $gapicClient->getMuteConfig($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetMuteConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getMuteConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); + try { + $gapicClient->getMuteConfig($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getNotificationConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $description = 'description-1724546052'; + $pubsubTopic = 'pubsubTopic-338126829'; + $serviceAccount = 'serviceAccount-1948028253'; + $expectedResponse = new NotificationConfig(); + $expectedResponse->setName($name2); + $expectedResponse->setDescription($description); + $expectedResponse->setPubsubTopic($pubsubTopic); + $expectedResponse->setServiceAccount($serviceAccount); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); + $response = $gapicClient->getNotificationConfig($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetNotificationConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getNotificationConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); + try { + $gapicClient->getNotificationConfig($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getOrganizationSettingsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $enableAssetDiscovery = false; + $expectedResponse = new OrganizationSettings(); + $expectedResponse->setName($name2); + $expectedResponse->setEnableAssetDiscovery($enableAssetDiscovery); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->organizationSettingsName('[ORGANIZATION]'); + $response = $gapicClient->getOrganizationSettings($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetOrganizationSettings', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getOrganizationSettingsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->organizationSettingsName('[ORGANIZATION]'); + try { + $gapicClient->getOrganizationSettings($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getSecurityHealthAnalyticsCustomModuleTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $lastEditor = 'lastEditor1620154166'; + $ancestorModule = 'ancestorModule-521996712'; + $expectedResponse = new SecurityHealthAnalyticsCustomModule(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setLastEditor($lastEditor); + $expectedResponse->setAncestorModule($ancestorModule); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); + $response = $gapicClient->getSecurityHealthAnalyticsCustomModule($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetSecurityHealthAnalyticsCustomModule', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getSecurityHealthAnalyticsCustomModuleExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); + try { + $gapicClient->getSecurityHealthAnalyticsCustomModule($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getSourceTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $canonicalName = 'canonicalName1385400054'; + $expectedResponse = new Source(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setCanonicalName($canonicalName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $response = $gapicClient->getSource($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetSource', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getSourceExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + try { + $gapicClient->getSource($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function groupAssetsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $totalSize = 705419236; + $groupByResultsElement = new GroupResult(); + $groupByResults = [ + $groupByResultsElement, + ]; + $expectedResponse = new GroupAssetsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setTotalSize($totalSize); + $expectedResponse->setGroupByResults($groupByResults); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $groupBy = 'groupBy506361367'; + $response = $gapicClient->groupAssets($formattedParent, $groupBy); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getGroupByResults()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GroupAssets', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getGroupBy(); + $this->assertProtobufEquals($groupBy, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function groupAssetsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $groupBy = 'groupBy506361367'; + try { + $gapicClient->groupAssets($formattedParent, $groupBy); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function groupFindingsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $totalSize = 705419236; + $groupByResultsElement = new GroupResult(); + $groupByResults = [ + $groupByResultsElement, + ]; + $expectedResponse = new GroupFindingsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setTotalSize($totalSize); + $expectedResponse->setGroupByResults($groupByResults); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $groupBy = 'groupBy506361367'; + $response = $gapicClient->groupFindings($formattedParent, $groupBy); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getGroupByResults()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GroupFindings', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getGroupBy(); + $this->assertProtobufEquals($groupBy, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function groupFindingsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $groupBy = 'groupBy506361367'; + try { + $gapicClient->groupFindings($formattedParent, $groupBy); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listAssetsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $totalSize = 705419236; + $listAssetsResultsElement = new ListAssetsResult(); + $listAssetsResults = [ + $listAssetsResultsElement, + ]; + $expectedResponse = new ListAssetsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setTotalSize($totalSize); + $expectedResponse->setListAssetsResults($listAssetsResults); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $response = $gapicClient->listAssets($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getListAssetsResults()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListAssets', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listAssetsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + try { + $gapicClient->listAssets($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listBigQueryExportsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $bigQueryExportsElement = new BigQueryExport(); + $bigQueryExports = [ + $bigQueryExportsElement, + ]; + $expectedResponse = new ListBigQueryExportsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setBigQueryExports($bigQueryExports); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $response = $gapicClient->listBigQueryExports($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getBigQueryExports()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListBigQueryExports', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listBigQueryExportsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + try { + $gapicClient->listBigQueryExports($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listDescendantSecurityHealthAnalyticsCustomModulesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $securityHealthAnalyticsCustomModulesElement = new SecurityHealthAnalyticsCustomModule(); + $securityHealthAnalyticsCustomModules = [ + $securityHealthAnalyticsCustomModulesElement, + ]; + $expectedResponse = new ListDescendantSecurityHealthAnalyticsCustomModulesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setSecurityHealthAnalyticsCustomModules($securityHealthAnalyticsCustomModules); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + $response = $gapicClient->listDescendantSecurityHealthAnalyticsCustomModules($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getSecurityHealthAnalyticsCustomModules()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListDescendantSecurityHealthAnalyticsCustomModules', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listDescendantSecurityHealthAnalyticsCustomModulesExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + try { + $gapicClient->listDescendantSecurityHealthAnalyticsCustomModules($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listEffectiveSecurityHealthAnalyticsCustomModulesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $effectiveSecurityHealthAnalyticsCustomModulesElement = new EffectiveSecurityHealthAnalyticsCustomModule(); + $effectiveSecurityHealthAnalyticsCustomModules = [ + $effectiveSecurityHealthAnalyticsCustomModulesElement, + ]; + $expectedResponse = new ListEffectiveSecurityHealthAnalyticsCustomModulesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setEffectiveSecurityHealthAnalyticsCustomModules($effectiveSecurityHealthAnalyticsCustomModules); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + $response = $gapicClient->listEffectiveSecurityHealthAnalyticsCustomModules($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getEffectiveSecurityHealthAnalyticsCustomModules()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListEffectiveSecurityHealthAnalyticsCustomModules', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listEffectiveSecurityHealthAnalyticsCustomModulesExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + try { + $gapicClient->listEffectiveSecurityHealthAnalyticsCustomModules($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listFindingsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $totalSize = 705419236; + $listFindingsResultsElement = new ListFindingsResult(); + $listFindingsResults = [ + $listFindingsResultsElement, + ]; + $expectedResponse = new ListFindingsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setTotalSize($totalSize); + $expectedResponse->setListFindingsResults($listFindingsResults); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $response = $gapicClient->listFindings($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getListFindingsResults()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListFindings', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listFindingsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + try { + $gapicClient->listFindings($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listMuteConfigsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $muteConfigsElement = new MuteConfig(); + $muteConfigs = [ + $muteConfigsElement, + ]; + $expectedResponse = new ListMuteConfigsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setMuteConfigs($muteConfigs); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $response = $gapicClient->listMuteConfigs($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getMuteConfigs()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListMuteConfigs', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listMuteConfigsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + try { + $gapicClient->listMuteConfigs($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listNotificationConfigsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $notificationConfigsElement = new NotificationConfig(); + $notificationConfigs = [ + $notificationConfigsElement, + ]; + $expectedResponse = new ListNotificationConfigsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setNotificationConfigs($notificationConfigs); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $response = $gapicClient->listNotificationConfigs($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getNotificationConfigs()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListNotificationConfigs', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listNotificationConfigsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + try { + $gapicClient->listNotificationConfigs($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listSecurityHealthAnalyticsCustomModulesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $securityHealthAnalyticsCustomModulesElement = new SecurityHealthAnalyticsCustomModule(); + $securityHealthAnalyticsCustomModules = [ + $securityHealthAnalyticsCustomModulesElement, + ]; + $expectedResponse = new ListSecurityHealthAnalyticsCustomModulesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setSecurityHealthAnalyticsCustomModules($securityHealthAnalyticsCustomModules); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + $response = $gapicClient->listSecurityHealthAnalyticsCustomModules($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getSecurityHealthAnalyticsCustomModules()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListSecurityHealthAnalyticsCustomModules', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listSecurityHealthAnalyticsCustomModulesExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); + try { + $gapicClient->listSecurityHealthAnalyticsCustomModules($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listSourcesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $sourcesElement = new Source(); + $sources = [ + $sourcesElement, + ]; + $expectedResponse = new ListSourcesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setSources($sources); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $response = $gapicClient->listSources($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getSources()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListSources', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listSourcesExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + try { + $gapicClient->listSources($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function runAssetDiscoveryTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/runAssetDiscoveryTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new RunAssetDiscoveryResponse(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/runAssetDiscoveryTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $response = $gapicClient->runAssetDiscovery($formattedParent); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $apiRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($apiRequests)); + $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); + $this->assertSame(0, count($operationsRequestsEmpty)); + $actualApiFuncCall = $apiRequests[0]->getFuncCall(); + $actualApiRequestObject = $apiRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/RunAssetDiscovery', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/runAssetDiscoveryTest'); + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + $this->assertTrue($response->isDone()); + $this->assertEquals($expectedResponse, $response->getResult()); + $apiRequestsEmpty = $transport->popReceivedCalls(); + $this->assertSame(0, count($apiRequestsEmpty)); + $operationsRequests = $operationsTransport->popReceivedCalls(); + $this->assertSame(1, count($operationsRequests)); + $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); + $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); + $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); + $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function runAssetDiscoveryExceptionTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/runAssetDiscoveryTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $operationsTransport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $response = $gapicClient->runAssetDiscovery($formattedParent); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/runAssetDiscoveryTest'); + try { + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + // If the pollUntilComplete() method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stubs are exhausted + $transport->popReceivedCalls(); + $operationsTransport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function setFindingStateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $parent = 'parent-995424086'; + $resourceName = 'resourceName979421212'; + $category = 'category50511102'; + $externalUri = 'externalUri-1385596168'; + $canonicalName = 'canonicalName1385400054'; + $muteInitiator = 'muteInitiator7603081'; + $parentDisplayName = 'parentDisplayName934119773'; + $description = 'description-1724546052'; + $nextSteps = 'nextSteps-921338149'; + $moduleName = 'moduleName-1195003778'; + $expectedResponse = new Finding(); + $expectedResponse->setName($name2); + $expectedResponse->setParent($parent); + $expectedResponse->setResourceName($resourceName); + $expectedResponse->setCategory($category); + $expectedResponse->setExternalUri($externalUri); + $expectedResponse->setCanonicalName($canonicalName); + $expectedResponse->setMuteInitiator($muteInitiator); + $expectedResponse->setParentDisplayName($parentDisplayName); + $expectedResponse->setDescription($description); + $expectedResponse->setNextSteps($nextSteps); + $expectedResponse->setModuleName($moduleName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + $state = State::STATE_UNSPECIFIED; + $startTime = new Timestamp(); + $response = $gapicClient->setFindingState($formattedName, $state, $startTime); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/SetFindingState', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $actualValue = $actualRequestObject->getState(); + $this->assertProtobufEquals($state, $actualValue); + $actualValue = $actualRequestObject->getStartTime(); + $this->assertProtobufEquals($startTime, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function setFindingStateExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + $state = State::STATE_UNSPECIFIED; + $startTime = new Timestamp(); + try { + $gapicClient->setFindingState($formattedName, $state, $startTime); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function setIamPolicyTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $version = 351608024; + $etag = '21'; + $expectedResponse = new Policy(); + $expectedResponse->setVersion($version); + $expectedResponse->setEtag($etag); + $transport->addResponse($expectedResponse); + // Mock request + $resource = 'resource-341064690'; + $policy = new Policy(); + $response = $gapicClient->setIamPolicy($resource, $policy); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/SetIamPolicy', $actualFuncCall); + $actualValue = $actualRequestObject->getResource(); + $this->assertProtobufEquals($resource, $actualValue); + $actualValue = $actualRequestObject->getPolicy(); + $this->assertProtobufEquals($policy, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function setIamPolicyExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $resource = 'resource-341064690'; + $policy = new Policy(); + try { + $gapicClient->setIamPolicy($resource, $policy); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function setMuteTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $parent = 'parent-995424086'; + $resourceName = 'resourceName979421212'; + $category = 'category50511102'; + $externalUri = 'externalUri-1385596168'; + $canonicalName = 'canonicalName1385400054'; + $muteInitiator = 'muteInitiator7603081'; + $parentDisplayName = 'parentDisplayName934119773'; + $description = 'description-1724546052'; + $nextSteps = 'nextSteps-921338149'; + $moduleName = 'moduleName-1195003778'; + $expectedResponse = new Finding(); + $expectedResponse->setName($name2); + $expectedResponse->setParent($parent); + $expectedResponse->setResourceName($resourceName); + $expectedResponse->setCategory($category); + $expectedResponse->setExternalUri($externalUri); + $expectedResponse->setCanonicalName($canonicalName); + $expectedResponse->setMuteInitiator($muteInitiator); + $expectedResponse->setParentDisplayName($parentDisplayName); + $expectedResponse->setDescription($description); + $expectedResponse->setNextSteps($nextSteps); + $expectedResponse->setModuleName($moduleName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + $mute = Mute::MUTE_UNSPECIFIED; + $response = $gapicClient->setMute($formattedName, $mute); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/SetMute', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $actualValue = $actualRequestObject->getMute(); + $this->assertProtobufEquals($mute, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function setMuteExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + $mute = Mute::MUTE_UNSPECIFIED; + try { + $gapicClient->setMute($formattedName, $mute); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function simulateSecurityHealthAnalyticsCustomModuleTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new SimulateSecurityHealthAnalyticsCustomModuleResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $parent = 'parent-995424086'; + $customConfig = new CustomConfig(); + $resource = new SimulatedResource(); + $resourceResourceType = 'resourceResourceType305300374'; + $resource->setResourceType($resourceResourceType); + $response = $gapicClient->simulateSecurityHealthAnalyticsCustomModule($parent, $customConfig, $resource); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/SimulateSecurityHealthAnalyticsCustomModule', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($parent, $actualValue); + $actualValue = $actualRequestObject->getCustomConfig(); + $this->assertProtobufEquals($customConfig, $actualValue); + $actualValue = $actualRequestObject->getResource(); + $this->assertProtobufEquals($resource, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function simulateSecurityHealthAnalyticsCustomModuleExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $parent = 'parent-995424086'; + $customConfig = new CustomConfig(); + $resource = new SimulatedResource(); + $resourceResourceType = 'resourceResourceType305300374'; + $resource->setResourceType($resourceResourceType); + try { + $gapicClient->simulateSecurityHealthAnalyticsCustomModule($parent, $customConfig, $resource); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function testIamPermissionsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new TestIamPermissionsResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $resource = 'resource-341064690'; + $permissions = []; + $response = $gapicClient->testIamPermissions($resource, $permissions); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/TestIamPermissions', $actualFuncCall); + $actualValue = $actualRequestObject->getResource(); + $this->assertProtobufEquals($resource, $actualValue); + $actualValue = $actualRequestObject->getPermissions(); + $this->assertProtobufEquals($permissions, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function testIamPermissionsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $resource = 'resource-341064690'; + $permissions = []; + try { + $gapicClient->testIamPermissions($resource, $permissions); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateBigQueryExportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $description = 'description-1724546052'; + $filter = 'filter-1274492040'; + $dataset = 'dataset1443214456'; + $mostRecentEditor = 'mostRecentEditor-657770475'; + $principal = 'principal-1812041682'; + $expectedResponse = new BigQueryExport(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setFilter($filter); + $expectedResponse->setDataset($dataset); + $expectedResponse->setMostRecentEditor($mostRecentEditor); + $expectedResponse->setPrincipal($principal); + $transport->addResponse($expectedResponse); + // Mock request + $bigQueryExport = new BigQueryExport(); + $response = $gapicClient->updateBigQueryExport($bigQueryExport); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateBigQueryExport', $actualFuncCall); + $actualValue = $actualRequestObject->getBigQueryExport(); + $this->assertProtobufEquals($bigQueryExport, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateBigQueryExportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $bigQueryExport = new BigQueryExport(); + try { + $gapicClient->updateBigQueryExport($bigQueryExport); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateExternalSystemTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $externalUid = 'externalUid-1385596452'; + $status = 'status-892481550'; + $caseUri = 'caseUri21649373'; + $casePriority = 'casePriority715048403'; + $expectedResponse = new ExternalSystem(); + $expectedResponse->setName($name); + $expectedResponse->setExternalUid($externalUid); + $expectedResponse->setStatus($status); + $expectedResponse->setCaseUri($caseUri); + $expectedResponse->setCasePriority($casePriority); + $transport->addResponse($expectedResponse); + // Mock request + $externalSystem = new ExternalSystem(); + $response = $gapicClient->updateExternalSystem($externalSystem); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateExternalSystem', $actualFuncCall); + $actualValue = $actualRequestObject->getExternalSystem(); + $this->assertProtobufEquals($externalSystem, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateExternalSystemExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $externalSystem = new ExternalSystem(); + try { + $gapicClient->updateExternalSystem($externalSystem); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateFindingTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $parent = 'parent-995424086'; + $resourceName = 'resourceName979421212'; + $category = 'category50511102'; + $externalUri = 'externalUri-1385596168'; + $canonicalName = 'canonicalName1385400054'; + $muteInitiator = 'muteInitiator7603081'; + $parentDisplayName = 'parentDisplayName934119773'; + $description = 'description-1724546052'; + $nextSteps = 'nextSteps-921338149'; + $moduleName = 'moduleName-1195003778'; + $expectedResponse = new Finding(); + $expectedResponse->setName($name); + $expectedResponse->setParent($parent); + $expectedResponse->setResourceName($resourceName); + $expectedResponse->setCategory($category); + $expectedResponse->setExternalUri($externalUri); + $expectedResponse->setCanonicalName($canonicalName); + $expectedResponse->setMuteInitiator($muteInitiator); + $expectedResponse->setParentDisplayName($parentDisplayName); + $expectedResponse->setDescription($description); + $expectedResponse->setNextSteps($nextSteps); + $expectedResponse->setModuleName($moduleName); + $transport->addResponse($expectedResponse); + // Mock request + $finding = new Finding(); + $response = $gapicClient->updateFinding($finding); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateFinding', $actualFuncCall); + $actualValue = $actualRequestObject->getFinding(); + $this->assertProtobufEquals($finding, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateFindingExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $finding = new Finding(); + try { + $gapicClient->updateFinding($finding); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateMuteConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $filter = 'filter-1274492040'; + $mostRecentEditor = 'mostRecentEditor-657770475'; + $expectedResponse = new MuteConfig(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setFilter($filter); + $expectedResponse->setMostRecentEditor($mostRecentEditor); + $transport->addResponse($expectedResponse); + // Mock request + $muteConfig = new MuteConfig(); + $muteConfigFilter = 'muteConfigFilter-1921414637'; + $muteConfig->setFilter($muteConfigFilter); + $response = $gapicClient->updateMuteConfig($muteConfig); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateMuteConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getMuteConfig(); + $this->assertProtobufEquals($muteConfig, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateMuteConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $muteConfig = new MuteConfig(); + $muteConfigFilter = 'muteConfigFilter-1921414637'; + $muteConfig->setFilter($muteConfigFilter); + try { + $gapicClient->updateMuteConfig($muteConfig); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateNotificationConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $description = 'description-1724546052'; + $pubsubTopic = 'pubsubTopic-338126829'; + $serviceAccount = 'serviceAccount-1948028253'; + $expectedResponse = new NotificationConfig(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setPubsubTopic($pubsubTopic); + $expectedResponse->setServiceAccount($serviceAccount); + $transport->addResponse($expectedResponse); + // Mock request + $notificationConfig = new NotificationConfig(); + $response = $gapicClient->updateNotificationConfig($notificationConfig); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateNotificationConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getNotificationConfig(); + $this->assertProtobufEquals($notificationConfig, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateNotificationConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $notificationConfig = new NotificationConfig(); + try { + $gapicClient->updateNotificationConfig($notificationConfig); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateOrganizationSettingsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $enableAssetDiscovery = false; + $expectedResponse = new OrganizationSettings(); + $expectedResponse->setName($name); + $expectedResponse->setEnableAssetDiscovery($enableAssetDiscovery); + $transport->addResponse($expectedResponse); + // Mock request + $organizationSettings = new OrganizationSettings(); + $response = $gapicClient->updateOrganizationSettings($organizationSettings); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateOrganizationSettings', $actualFuncCall); + $actualValue = $actualRequestObject->getOrganizationSettings(); + $this->assertProtobufEquals($organizationSettings, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateOrganizationSettingsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $organizationSettings = new OrganizationSettings(); + try { + $gapicClient->updateOrganizationSettings($organizationSettings); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSecurityHealthAnalyticsCustomModuleTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $lastEditor = 'lastEditor1620154166'; + $ancestorModule = 'ancestorModule-521996712'; + $expectedResponse = new SecurityHealthAnalyticsCustomModule(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setLastEditor($lastEditor); + $expectedResponse->setAncestorModule($ancestorModule); + $transport->addResponse($expectedResponse); + // Mock request + $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); + $response = $gapicClient->updateSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateSecurityHealthAnalyticsCustomModule', $actualFuncCall); + $actualValue = $actualRequestObject->getSecurityHealthAnalyticsCustomModule(); + $this->assertProtobufEquals($securityHealthAnalyticsCustomModule, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSecurityHealthAnalyticsCustomModuleExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); + try { + $gapicClient->updateSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSecurityMarksTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $canonicalName = 'canonicalName1385400054'; + $expectedResponse = new SecurityMarks(); + $expectedResponse->setName($name); + $expectedResponse->setCanonicalName($canonicalName); + $transport->addResponse($expectedResponse); + // Mock request + $securityMarks = new SecurityMarks(); + $response = $gapicClient->updateSecurityMarks($securityMarks); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateSecurityMarks', $actualFuncCall); + $actualValue = $actualRequestObject->getSecurityMarks(); + $this->assertProtobufEquals($securityMarks, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSecurityMarksExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $securityMarks = new SecurityMarks(); + try { + $gapicClient->updateSecurityMarks($securityMarks); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSourceTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $canonicalName = 'canonicalName1385400054'; + $expectedResponse = new Source(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setCanonicalName($canonicalName); + $transport->addResponse($expectedResponse); + // Mock request + $source = new Source(); + $response = $gapicClient->updateSource($source); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateSource', $actualFuncCall); + $actualValue = $actualRequestObject->getSource(); + $this->assertProtobufEquals($source, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSourceExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $source = new Source(); + try { + $gapicClient->updateSource($source); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } +} diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Asset.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Asset.php new file mode 100644 index 000000000000..35ef1334b2d1 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Asset.php @@ -0,0 +1,60 @@ +internalAddGeneratedFile( + ' +Þ +1google/cloud/securitycenter/v1p1beta1/asset.proto%google.cloud.securitycenter.v1p1beta12google/cloud/securitycenter/v1p1beta1/folder.proto:google/cloud/securitycenter/v1p1beta1/security_marks.protogoogle/protobuf/struct.protogoogle/protobuf/timestamp.proto"Ì +Asset +name ( i +security_center_properties ( 2E.google.cloud.securitycenter.v1p1beta1.Asset.SecurityCenterPropertiesa +resource_properties ( 2D.google.cloud.securitycenter.v1p1beta1.Asset.ResourcePropertiesEntryL +security_marks ( 24.google.cloud.securitycenter.v1p1beta1.SecurityMarks/ + create_time ( 2.google.protobuf.Timestamp/ + update_time + ( 2.google.protobuf.TimestampJ + +iam_policy ( 26.google.cloud.securitycenter.v1p1beta1.Asset.IamPolicy +canonical_name ( À +SecurityCenterProperties + resource_name (  + resource_type (  +resource_parent (  +resource_project (  +resource_owners (  +resource_display_name ( $ +resource_parent_display_name ( % +resource_project_display_name ( > +folders + ( 2-.google.cloud.securitycenter.v1p1beta1.Folder + IamPolicy + policy_blob ( Q +ResourcePropertiesEntry +key ( % +value ( 2.google.protobuf.Value:8:šêA– +#securitycenter.googleapis.com/Asset+organizations/{organization}/assets/{asset}folders/{folder}/assets/{asset}!projects/{project}/assets/{asset}Bû +)com.google.cloud.securitycenter.v1p1beta1PZQcloud.google.com/go/securitycenter/apiv1p1beta1/securitycenterpb;securitycenterpbª%Google.Cloud.SecurityCenter.V1P1Beta1Ê%Google\\Cloud\\SecurityCenter\\V1p1beta1ê(Google::Cloud::SecurityCenter::V1p1beta1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Finding.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Finding.php new file mode 100644 index 0000000000000000000000000000000000000000..9aaff640672f2da297801204a73510a198a84f79 GIT binary patch literal 2387 zcmbVO-EP}96rSz;ICN{cLQ`nLfN@!aI>08uX|WZ`vdw>S4K%S+yBRhJFl3o_xGIuB z(ZSrpFSJM53k=vUw(GvaZgxmYN}Oh?SKnA9&-d~0JLmB5oA1K25PgnY#3#(*WQ2z^ z%+Cl8S-=A~@bGXt9utP$;5?)rVFt#H4nFSmakJ6xe+JMfm@=1GcoGB?kC?6(Oh;x! z+$p1c<`SP1W?odn%8+oUVvealqW;8?{0RBZIf+8YCAihC9f8Hj;f~#sRCZlZ*}VlS z`?S)n)CAQ&LaygT5k6Fu=ncZ~3#UVmx;Wwvhrfq38c?5d>Ui`uobCXR9WNq)eb;t8 z^<7Q_9}7UocS(5{D^6kiFbqJA1DrV56#{`cc3Yg#cRag6BA3yS2doRGmNg+fl~v4? zcjIjZ9UbGc^3k&1aq<9jHYHbg$Cwd5W&XbOTM*3CFZ%}Rsv)%xDe*=%a^_snfLYe% zsV+(W3;Ke@QC%8!d#utR9y#n)w7f5=$UP9m>E`*M; zpTt;MbC9xTB-M;pKfS)n6Umgp_FwC0J+3kB4q6c83#goeM8c1CC(;MGtyMnOjK|g0W}l=y%*3%`3QCpH?n>gtc!bJC-k?c zN=hZauEnOwmN9DccWeflzT;HamMVR)eFa)5}7cCy$6XG=^;@??ls?iBTC3Lk?bBu{18JFWAIGEY_6f@O z5_ffUzt=o%zG(MT_Voqm^gv*0WMp@E$>LdwEpKY3nHWyz@h8#riYz zw)%Sp?Ie*`eJ%DL$~7{eL7GXGd>^oh-&`HeO_iQ7tv=>SPlTDVYGrfn z$vE&vgo!Enu^j3vknv~Ya)8BOOW|t&WY8}7p9JIfl;~!DI#Cu$8N7ZRMN*gV2P19zza@5d{5nWGi?X!geGor2-e${+(y}C{ oWi66gR%$w2llk}fQF`5fp*rxDhAnO|>fX?-rKM`Ab2LZjU*9$s%K!iX literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Folder.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Folder.php new file mode 100644 index 000000000000..2bb7fd7317b4 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Folder.php @@ -0,0 +1,30 @@ +internalAddGeneratedFile( + ' +· +2google/cloud/securitycenter/v1p1beta1/folder.proto%google.cloud.securitycenter.v1p1beta1"G +Folder +resource_folder ( $ +resource_folder_display_name ( Bˆ +)com.google.cloud.securitycenter.v1p1beta1B FolderProtoPZQcloud.google.com/go/securitycenter/apiv1p1beta1/securitycenterpb;securitycenterpbª%Google.Cloud.SecurityCenter.V1P1Beta1Ê%Google\\Cloud\\SecurityCenter\\V1p1beta1ê(Google::Cloud::SecurityCenter::V1p1Beta1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/NotificationConfig.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/NotificationConfig.php new file mode 100644 index 0000000000000000000000000000000000000000..2807cc138addda2f984d3ab834e2d3279eb040a7 GIT binary patch literal 1738 zcmbtU-EPw`6kfYAm^Zd5NT>{uys>GW1PL98i;OY)PcP^SD?^}2Rq8sOQ5HvzQ>mMB z$;UT5`BcBo8N7&(* zX}z4AYh!NaG>39x5oB^gofe{wMY^i21%P9oV$U@ZhSf<p_}+%&2Z)+mOs#?ct8 zahz-93L)$s0LV5y57tNEixM5211KKXZ`%YxkBiC(ZW6CW9KwldlQS{&KD12R!vbbH z*YX_{b_>G|hYrHo9T;JTxtlH(B<;gNpN)_=!I@DD2X{={C}9sV;&RFwB30MBm?vz9 zk?c-fHiRP<%tk%x`c#wqkTV~TR)>&b?lWgk_8kHQ$(L~ni+PtA6@u+f0iT#XLYb}) zry7D>we>xY5Bt(xl8Ps#&cZ&o!Pi^h;6F8^Y()U76rDOQIyDj9 z+P%1r=@N~_GeoM}_&x`eY0)T4U@nwnCIwU31?3J{?8K)igpf(g;70&(PsqE)`!3GR zirDgQQN30}>U2f59AY&El=1>B3AK8DyTz$XP-ZSHSAf6s55fItA+93E@lmW<7#%%S4F!4$s_>TW5deXB7-qJK5Tm>HW@c?2 ztV{%zWiW3MTik|-&5h?^VL0p>xLZCh*PE^8r$)K;p?=gT7i*PTxwJZ?EP|VrTD?@O zS65SdaFIU)PbZEzVmsksnpUMkS=V&PnKT?vJ0JZG#@r|xL8Le%9uhMZ6js1(8SlrD z!jClA5!_#oyGH8syGWx0eTY-*(n*^XgCwGzSaaKZ*jcs|ol?uuW z@gN*{6b`%q7rdWM+9CzWDe{hgGxPU<=EW;@qR=B4Gr=@5EQH_;%n1XfrIA!75M)ur zG*CHLJYm`e7){`4atv=q2geWW)l_DhG7Pblal$;B$Sm|yMl;RL8D+vS?Va{iFJOlB zJRuE_I3L_Nm6Dxmt&($(7ayAFH8hw zP8UjM9=oNam1zKVq0?MBtD1k1w=PKHk621IS4Qfo4aGQSrqMe;ak^F79LFPY${I1g zROA4R&e(Ex0L@IMMZc&!2P~R@{$I=J?{g7y5o3Jb>N)uzc<)(dk1K(NbWdLLN~qm1 zY;@VTW^jlGGlTp9Ya1-5R zr*>qAzgnnkM}EEg)7GbVrJQxia_+_Q;u0W=H~L=qrh@+JOQ_)M#`d_Fe7Bfh($ literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/OrganizationSettings.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/OrganizationSettings.php new file mode 100644 index 0000000000000000000000000000000000000000..4eba6944f9471ad3f772bc5b91757c87b25bb60a GIT binary patch literal 1581 zcmb_c-A>yu7+nh*n_;NR5JFrakAW!Cma6P7j7_C2RV8S<6(%-CixS5TMj?)D2MJKG z_ZYjM_9S~0UST)0oi?_hJgiZcvjMg>JQ zgkI9?VFnSsh)IZ<31O`bTkT_5uQiWf$fKMl3}Fiflm;O#p^zqiiDQ&7BCZgQ1ZJhn za$NSXaLXmi0yiSpt{^mWI2M9L0XH=p0FirvdF&z#8=d_lneV&8wHq4Pt}0-=I|gij zDtF5J3V0U)6uO+l_6R|DfDdi}luw*^AwiG}$&TO#;SPz2AZ|#mW#N0U=Y||hp!>PK zBtl9tR0rA-!o_WvVyfJYn94@&!J*QQ>YePH-BiU#ZfMsqM~uXRvW`r(tN@FwfX=D}S3RGz5S3wi7Owi1Ayi3z9ec4NX#X*H#3eKpE-8@*!Qn;qaxBfKHm36q)VgL@f4p$Lor{ANkFOHZW5gm^n1Cs&+;*Gq7L7 zJbU1DnboD4w)DDziQeXmDWqj-Ov@SvwX7`Fd#tVX%~p12U!?{z;x~Ww8l9QiLLc-2 F_yd*r7~TK? literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Resource.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Resource.php new file mode 100644 index 000000000000..ff0c76c38b4c --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Resource.php @@ -0,0 +1,36 @@ +internalAddGeneratedFile( + ' +â +4google/cloud/securitycenter/v1p1beta1/resource.proto%google.cloud.securitycenter.v1p1beta12google/cloud/securitycenter/v1p1beta1/folder.proto"¹ +Resource +name (  +project (  +project_display_name (  +parent (  +parent_display_name ( C +folders ( 2-.google.cloud.securitycenter.v1p1beta1.FolderBàABŠ +)com.google.cloud.securitycenter.v1p1beta1B ResourceProtoPZQcloud.google.com/go/securitycenter/apiv1p1beta1/securitycenterpb;securitycenterpbª%Google.Cloud.SecurityCenter.V1P1Beta1Ê%Google\\Cloud\\SecurityCenter\\V1p1beta1ê(Google::Cloud::SecurityCenter::V1p1beta1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/RunAssetDiscoveryResponse.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/RunAssetDiscoveryResponse.php new file mode 100644 index 0000000000000000000000000000000000000000..25ba78f13571ae848ed9c5e3b62900f9d25b06aa GIT binary patch literal 1287 zcmb`H(T>tU6ov&|qhs8xB%AEsjq7fI+UdYfQaa6ay2)yI zAs@vjF<$rr-Z<0J?y@V!3%P+Q=X~d!f6m|6Z=>@FJcB(F67CA(L+=uba{?pI1j8(V zUNWB(4l!FsG$34u&=|qtXaY^6KY1!sW0r7C5L_^}2uKYFEb(hG!3n405|dC6Uc0DA zb&m+QUgJqPbK{tZnNMTPE(pJzaS}%?jESBW1t4^n@`;NH>{;!BO!HmgI=z(dbQIsQ zH~7xSx>av0eggm;NIo1VVM~=U@+#wX5%2{-`H2!Qpcux&74qwt#xojHLEV6UmLfFa z+znzPX}4qNNr(kyAyf&Y5EHEmGp33?j+hj!3G;R>rK8l)=_?^ZH*gFRV@@N%xFtgo zS`bmFubybtby*{{+>y0(D!_D$l_Ke=XcWS&|=}9p>b8mF2zbxw1zCu#;u&gD3W+ zH8E$?p>3I+ez$KLdv_|2!NbmIV7)gd@>r_u0$@)qb8MT2JeSpZVvYy>q0BV)?zVrG zKvkMDulIL(tkS0sSwucKThinternalAddGeneratedFile( + ' +È +:google/cloud/securitycenter/v1p1beta1/security_marks.proto%google.cloud.securitycenter.v1p1beta1"Ü + SecurityMarks +name ( N +marks ( 2?.google.cloud.securitycenter.v1p1beta1.SecurityMarks.MarksEntry +canonical_name ( , + +MarksEntry +key (  +value ( :8:¦êA¢ ++securitycenter.googleapis.com/SecurityMarks9organizations/{organization}/assets/{asset}/securityMarksNorganizations/{organization}/sources/{source}/findings/{finding}/securityMarks-folders/{folder}/assets/{asset}/securityMarks/projects/{project}/assets/{asset}/securityMarksBfolders/{folder}/sources/{source}/findings/{finding}/securityMarksDprojects/{project}/sources/{source}/findings/{finding}/securityMarksBû +)com.google.cloud.securitycenter.v1p1beta1PZQcloud.google.com/go/securitycenter/apiv1p1beta1/securitycenterpb;securitycenterpbª%Google.Cloud.SecurityCenter.V1P1Beta1Ê%Google\\Cloud\\SecurityCenter\\V1p1beta1ê(Google::Cloud::SecurityCenter::V1p1beta1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/SecuritycenterService.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/SecuritycenterService.php new file mode 100644 index 0000000000000000000000000000000000000000..a32e77ed09b41f6d57ec66f5badec3bf9d3aa8da GIT binary patch literal 15636 zcmdrTTWlOxwX=?s_&N{w+HPF;k?k~ToYdK^H-#qSJT!iX#*P~&DVUYEw zGn?X87KloGAdrgsK|er%K$QUT5<)@(@sa?kKOiU)G9Oe>35id{2ecq@?rZkW&g|}t z>wG{yVtejA&wJi;=lrGmtvY%%J8#;iYxrg*ySAD2Z<*P;>-bLDsb$w1)vD=c%g#pK zs+n#so1M9uUAlTbJ3Djv`Xd19ISsdLYT0$iS+AM-a?NQ}@}604xR$?JHf`T@^LHld z6Kke#OtdVNJkz~nmCYO_hmdV-m|oo|o7ws0sYL*&7`{=QrTgVtHbU zV4g&%Tr)f`8{V+O2%wix7XH;6Yc;E!^?bvJAIB`OWZ9N)88z!g5dA{7YScUvFh%!P z8+O^Z96L(@uG(dD>|~bVBzuq59Z=PUtYCGSXb&`3yiCNmjaqTW^vbSP_Z@c`wrbkC z=?6L|PsUDivILz~&5ki1H7&yAg{<#3OqqH%>zaPUwI?ax1i@DDTQRjFi%X7gRjo3p z$gvkq&okCdO>2tXq_P9t*BZ9&d8R*Od1dF0>26+w^LA`61qHos6?NNo$Qc4;a@Gjo zbj<>bOb0V(nYGH4dCRzCIc_>okdArBZt0IIFF6mLU8Xo^*%ixP-#vUztzxE7Q5W`P zL!5T(sLR0TO4ddesN3Ki~ zZZ4e4b3rN}T}Va>OrivN+4M^l5%fzgkNPa{k3PsT8FedfG($UIJtD1^Y5e93N2P@- z3DTuC9;Nw)`=t#)k~$Dyn&3-R#+Ir?Dpx4u9OO(gkSYtR9H@{Gh(=Bhb14}Nq`)9g zm&!Cgas+xZ1dbF0p%PX zS%sZr+=ByoIVjchE7aEU5rnuomaNK1hGOUe40s0Z;|n7_@U*{>;~2U)eU7s?MX;!E zDd;HUI-07501GVwoTUO3&=b`2gja4DHk6res~B>c#`mE9SJxB{2!Ttc~` z0x%K3qM$)0B2($^i#3JzGEboA(_c89kYmOV8`jL1*g#2 zjH2k&Dtd6<^rH*AP3L*^Fwl_=K-6i1(n3fgjoQ_dsL)xWIE3mF8UR}11J**=Q@Ne` zat7gf*J;#gx$X&uCtF{Ag#EDH41L?X6lh=q8yP<6*RaoscN4ZBkS3qn3cr zpaIgVL&zwJ05`ISdiedqu0#;Zi8>3PMtu-_DkTz?MtbS)(a7$gRKXabI(TczcW#^Z z$UYKP@V%&yKJ%cH9@!6%dextR>x8txIz4;^4G7LjA<(G#9#~}$1fhZ;+PU(`QLNV} zXqa~r;ra`mct3&;+vZ38k|Y2LfPF+LA9~7KiAq3J)~kLpgN7(A9`%Bgd~Z=X;ZcT8 zg`Ht1$>L6)on?oUPk59+Q_ygWBL3$N6U?z+Hk_Ma#V#ome9IIDIF;T2bISpeS=)Cv z@j=vEb{dedi81z!UPgyocl4v4+vX;V#P~Ssy<^lGCXfF22@V1;y-8NJ%vnYKtb!iC zVtFyaH!#fI%eG<5pru3D$%)(as;@!`(3U4|BhR8CJ6fv>o$owDLwOT%X3D6#i7;V` zMf5;9ZM+sItEIXsgapD~)kcFM(p(1@(LR>th1luRe0x#9nL+mwf_E|1450mv3xk~? z)r5oYT?$P(QoE9-j#Sw+%fvNQCFP2){}VLYKMtm>$t17r|w zmddvbdz}TTLxr0OafEoGW8R29aw`P=G{vr7K>gC6;Bb3yEZta{of)_X_n}^WW(Iy$ za6j62ZFceMP52{2_UO~sFW;OU=uy9uVZL{Fv-SU#H+*9+8X~9ER2lb&4K!RM{!nGp zj8>0WN?`%5xTy_D5AU{D{Av&L_!g3vnk_JCty8zaxE|{ptGlZi**~z2_KSv@x3|yk zGBqfw>EwVk6Fs9pR?vR&1RszaB0Pi+K!x(WS@uh`tz-qlgJ?)Rg<)U4W^A%mR$>pL zem2Ws4@utW!w;ZA{xAeVD%U;?S+hzfW8Mg&9YWHqIY*(?#r6ROqR8}uzBErm%0bk3 zV@dp(X$G4fIoRw`-&D|j(1mhCqM@qU+sWFGBTr|K}%x@Gl%9-I;3Fvz|p}l9&A>p%ZsLj=u z)F)SDq&s5~L+P8wi3|TcgANJ0)AYs#{-uHr$a71qB|LT+i0foD-MOewZ|etHOdn_2 zf0{oQ32A`|I3Vowv}dHjP68ex(|qZFP?b*NDULMuCu zWa?|mwtkFjC>YO=$MpN#`Y7KPvq-hIq(0SMTU&Vw753__~!~5X*U*6th#mx zgzBOL8~OrTo!i!FML;DxcPbbd8q(r$sI#)AoyDPu6KiR5%oQ(HwlI`KeIO>w zt@x?rf-wjoO3GZJ$;_X|p%f9zeA5*1>lr@LWwRWd)K=&eSj>NDl{=a=JBC16tE_%e zp}zE*qCO!zQ@aF5hcTYEPF~)C1Fh!OQ!!w??IAg#72t{3M9TXvnnPP4@Sij2AmyB= zP!A_HxDb>$;`2#ugNP_dLLW&dKKU(*|DXG-(0Z77bVLLfG!kg|ltEa$_qw{5c5f zgc{2#UgDrG!3g1!2K5jq7wDB1d-=E$&Q0w^;_0cKj|5f{G&-we__2Rp?1TV?iGf z=}F{8q02Ts$%mjC5PiouyVgf_rH6|Fv87XM0y+vx&(iH?`tbd4rF6+0G(- zug1R<{##~@q0}^rQ`5poH7(e>e9yA7winLDcg~y$K8PA;U&%@z)sl+bD#v_KOLwxb KTDQ;^LjMIoMP`ox literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Source.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Source.php new file mode 100644 index 000000000000..0132c372a211 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Source.php @@ -0,0 +1,34 @@ +internalAddGeneratedFile( + ' +á +2google/cloud/securitycenter/v1p1beta1/source.proto%google.cloud.securitycenter.v1p1beta1"ý +Source +name (  + display_name (  + description (  +canonical_name ( :¡êA +$securitycenter.googleapis.com/Source-organizations/{organization}/sources/{source}!folders/{folder}/sources/{source}#projects/{project}/sources/{source}Bû +)com.google.cloud.securitycenter.v1p1beta1PZQcloud.google.com/go/securitycenter/apiv1p1beta1/securitycenterpb;securitycenterpbª%Google.Cloud.SecurityCenter.V1P1Beta1Ê%Google\\Cloud\\SecurityCenter\\V1p1beta1ê(Google::Cloud::SecurityCenter::V1p1beta1bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset.php new file mode 100644 index 000000000000..0f552c3e99a7 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset.php @@ -0,0 +1,412 @@ +google.cloud.securitycenter.v1p1beta1.Asset + */ +class Asset extends \Google\Protobuf\Internal\Message +{ + /** + * The relative resource name of this asset. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/assets/{asset_id}". + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Security Command Center managed properties. These properties are managed by + * Security Command Center and cannot be modified by the user. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Asset.SecurityCenterProperties security_center_properties = 2; + */ + protected $security_center_properties = null; + /** + * Resource managed properties. These properties are managed and defined by + * the Google Cloud resource and cannot be modified by the user. + * + * Generated from protobuf field map resource_properties = 7; + */ + private $resource_properties; + /** + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.SecurityMarks security_marks = 8; + */ + protected $security_marks = null; + /** + * The time at which the asset was created in Security Command Center. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 9; + */ + protected $create_time = null; + /** + * The time at which the asset was last updated or added in Cloud SCC. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 10; + */ + protected $update_time = null; + /** + * Cloud IAM Policy information associated with the Google Cloud resource + * described by the Security Command Center asset. This information is managed + * and defined by the Google Cloud resource and cannot be modified by the + * user. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Asset.IamPolicy iam_policy = 11; + */ + protected $iam_policy = null; + /** + * The canonical name of the resource. It's either + * "organizations/{organization_id}/assets/{asset_id}", + * "folders/{folder_id}/assets/{asset_id}" or + * "projects/{project_number}/assets/{asset_id}", depending on the closest CRM + * ancestor of the resource. + * + * Generated from protobuf field string canonical_name = 13; + */ + protected $canonical_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The relative resource name of this asset. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/assets/{asset_id}". + * @type \Google\Cloud\SecurityCenter\V1p1beta1\Asset\SecurityCenterProperties $security_center_properties + * Security Command Center managed properties. These properties are managed by + * Security Command Center and cannot be modified by the user. + * @type array|\Google\Protobuf\Internal\MapField $resource_properties + * Resource managed properties. These properties are managed and defined by + * the Google Cloud resource and cannot be modified by the user. + * @type \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks $security_marks + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + * @type \Google\Protobuf\Timestamp $create_time + * The time at which the asset was created in Security Command Center. + * @type \Google\Protobuf\Timestamp $update_time + * The time at which the asset was last updated or added in Cloud SCC. + * @type \Google\Cloud\SecurityCenter\V1p1beta1\Asset\IamPolicy $iam_policy + * Cloud IAM Policy information associated with the Google Cloud resource + * described by the Security Command Center asset. This information is managed + * and defined by the Google Cloud resource and cannot be modified by the + * user. + * @type string $canonical_name + * The canonical name of the resource. It's either + * "organizations/{organization_id}/assets/{asset_id}", + * "folders/{folder_id}/assets/{asset_id}" or + * "projects/{project_number}/assets/{asset_id}", depending on the closest CRM + * ancestor of the resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\Asset::initOnce(); + parent::__construct($data); + } + + /** + * The relative resource name of this asset. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/assets/{asset_id}". + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The relative resource name of this asset. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/assets/{asset_id}". + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Security Command Center managed properties. These properties are managed by + * Security Command Center and cannot be modified by the user. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Asset.SecurityCenterProperties security_center_properties = 2; + * @return \Google\Cloud\SecurityCenter\V1p1beta1\Asset\SecurityCenterProperties|null + */ + public function getSecurityCenterProperties() + { + return $this->security_center_properties; + } + + public function hasSecurityCenterProperties() + { + return isset($this->security_center_properties); + } + + public function clearSecurityCenterProperties() + { + unset($this->security_center_properties); + } + + /** + * Security Command Center managed properties. These properties are managed by + * Security Command Center and cannot be modified by the user. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Asset.SecurityCenterProperties security_center_properties = 2; + * @param \Google\Cloud\SecurityCenter\V1p1beta1\Asset\SecurityCenterProperties $var + * @return $this + */ + public function setSecurityCenterProperties($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Asset\SecurityCenterProperties::class); + $this->security_center_properties = $var; + + return $this; + } + + /** + * Resource managed properties. These properties are managed and defined by + * the Google Cloud resource and cannot be modified by the user. + * + * Generated from protobuf field map resource_properties = 7; + * @return \Google\Protobuf\Internal\MapField + */ + public function getResourceProperties() + { + return $this->resource_properties; + } + + /** + * Resource managed properties. These properties are managed and defined by + * the Google Cloud resource and cannot be modified by the user. + * + * Generated from protobuf field map resource_properties = 7; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setResourceProperties($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Value::class); + $this->resource_properties = $arr; + + return $this; + } + + /** + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.SecurityMarks security_marks = 8; + * @return \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks|null + */ + public function getSecurityMarks() + { + return $this->security_marks; + } + + public function hasSecurityMarks() + { + return isset($this->security_marks); + } + + public function clearSecurityMarks() + { + unset($this->security_marks); + } + + /** + * User specified security marks. These marks are entirely managed by the user + * and come from the SecurityMarks resource that belongs to the asset. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.SecurityMarks security_marks = 8; + * @param \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks $var + * @return $this + */ + public function setSecurityMarks($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks::class); + $this->security_marks = $var; + + return $this; + } + + /** + * The time at which the asset was created in Security Command Center. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 9; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCreateTime() + { + return $this->create_time; + } + + public function hasCreateTime() + { + return isset($this->create_time); + } + + public function clearCreateTime() + { + unset($this->create_time); + } + + /** + * The time at which the asset was created in Security Command Center. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 9; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->create_time = $var; + + return $this; + } + + /** + * The time at which the asset was last updated or added in Cloud SCC. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 10; + * @return \Google\Protobuf\Timestamp|null + */ + public function getUpdateTime() + { + return $this->update_time; + } + + public function hasUpdateTime() + { + return isset($this->update_time); + } + + public function clearUpdateTime() + { + unset($this->update_time); + } + + /** + * The time at which the asset was last updated or added in Cloud SCC. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 10; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->update_time = $var; + + return $this; + } + + /** + * Cloud IAM Policy information associated with the Google Cloud resource + * described by the Security Command Center asset. This information is managed + * and defined by the Google Cloud resource and cannot be modified by the + * user. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Asset.IamPolicy iam_policy = 11; + * @return \Google\Cloud\SecurityCenter\V1p1beta1\Asset\IamPolicy|null + */ + public function getIamPolicy() + { + return $this->iam_policy; + } + + public function hasIamPolicy() + { + return isset($this->iam_policy); + } + + public function clearIamPolicy() + { + unset($this->iam_policy); + } + + /** + * Cloud IAM Policy information associated with the Google Cloud resource + * described by the Security Command Center asset. This information is managed + * and defined by the Google Cloud resource and cannot be modified by the + * user. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Asset.IamPolicy iam_policy = 11; + * @param \Google\Cloud\SecurityCenter\V1p1beta1\Asset\IamPolicy $var + * @return $this + */ + public function setIamPolicy($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Asset\IamPolicy::class); + $this->iam_policy = $var; + + return $this; + } + + /** + * The canonical name of the resource. It's either + * "organizations/{organization_id}/assets/{asset_id}", + * "folders/{folder_id}/assets/{asset_id}" or + * "projects/{project_number}/assets/{asset_id}", depending on the closest CRM + * ancestor of the resource. + * + * Generated from protobuf field string canonical_name = 13; + * @return string + */ + public function getCanonicalName() + { + return $this->canonical_name; + } + + /** + * The canonical name of the resource. It's either + * "organizations/{organization_id}/assets/{asset_id}", + * "folders/{folder_id}/assets/{asset_id}" or + * "projects/{project_number}/assets/{asset_id}", depending on the closest CRM + * ancestor of the resource. + * + * Generated from protobuf field string canonical_name = 13; + * @param string $var + * @return $this + */ + public function setCanonicalName($var) + { + GPBUtil::checkString($var, True); + $this->canonical_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset/IamPolicy.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset/IamPolicy.php new file mode 100644 index 000000000000..c39f062ad72f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset/IamPolicy.php @@ -0,0 +1,81 @@ +google.cloud.securitycenter.v1p1beta1.Asset.IamPolicy + */ +class IamPolicy extends \Google\Protobuf\Internal\Message +{ + /** + * The JSON representation of the Policy associated with the asset. + * See https://cloud.google.com/iam/docs/reference/rest/v1/Policy for + * format details. + * + * Generated from protobuf field string policy_blob = 1; + */ + protected $policy_blob = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $policy_blob + * The JSON representation of the Policy associated with the asset. + * See https://cloud.google.com/iam/docs/reference/rest/v1/Policy for + * format details. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\Asset::initOnce(); + parent::__construct($data); + } + + /** + * The JSON representation of the Policy associated with the asset. + * See https://cloud.google.com/iam/docs/reference/rest/v1/Policy for + * format details. + * + * Generated from protobuf field string policy_blob = 1; + * @return string + */ + public function getPolicyBlob() + { + return $this->policy_blob; + } + + /** + * The JSON representation of the Policy associated with the asset. + * See https://cloud.google.com/iam/docs/reference/rest/v1/Policy for + * format details. + * + * Generated from protobuf field string policy_blob = 1; + * @param string $var + * @return $this + */ + public function setPolicyBlob($var) + { + GPBUtil::checkString($var, True); + $this->policy_blob = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(IamPolicy::class, \Google\Cloud\SecurityCenter\V1p1beta1\Asset_IamPolicy::class); + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset/SecurityCenterProperties.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset/SecurityCenterProperties.php new file mode 100644 index 000000000000..45ece235170d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset/SecurityCenterProperties.php @@ -0,0 +1,379 @@ +google.cloud.securitycenter.v1p1beta1.Asset.SecurityCenterProperties + */ +class SecurityCenterProperties extends \Google\Protobuf\Internal\Message +{ + /** + * The full resource name of the Google Cloud resource this asset + * represents. This field is immutable after create time. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_name = 1; + */ + protected $resource_name = ''; + /** + * The type of the Google Cloud resource. Examples include: APPLICATION, + * PROJECT, and ORGANIZATION. This is a case insensitive field defined by + * Security Command Center and/or the producer of the resource and is + * immutable after create time. + * + * Generated from protobuf field string resource_type = 2; + */ + protected $resource_type = ''; + /** + * The full resource name of the immediate parent of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_parent = 3; + */ + protected $resource_parent = ''; + /** + * The full resource name of the project the resource belongs to. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_project = 4; + */ + protected $resource_project = ''; + /** + * Owners of the Google Cloud resource. + * + * Generated from protobuf field repeated string resource_owners = 5; + */ + private $resource_owners; + /** + * The user defined display name for this resource. + * + * Generated from protobuf field string resource_display_name = 6; + */ + protected $resource_display_name = ''; + /** + * The user defined display name for the parent of this resource. + * + * Generated from protobuf field string resource_parent_display_name = 7; + */ + protected $resource_parent_display_name = ''; + /** + * The user defined display name for the project of this resource. + * + * Generated from protobuf field string resource_project_display_name = 8; + */ + protected $resource_project_display_name = ''; + /** + * Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is the + * folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Folder folders = 10; + */ + private $folders; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $resource_name + * The full resource name of the Google Cloud resource this asset + * represents. This field is immutable after create time. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * @type string $resource_type + * The type of the Google Cloud resource. Examples include: APPLICATION, + * PROJECT, and ORGANIZATION. This is a case insensitive field defined by + * Security Command Center and/or the producer of the resource and is + * immutable after create time. + * @type string $resource_parent + * The full resource name of the immediate parent of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * @type string $resource_project + * The full resource name of the project the resource belongs to. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * @type array|\Google\Protobuf\Internal\RepeatedField $resource_owners + * Owners of the Google Cloud resource. + * @type string $resource_display_name + * The user defined display name for this resource. + * @type string $resource_parent_display_name + * The user defined display name for the parent of this resource. + * @type string $resource_project_display_name + * The user defined display name for the project of this resource. + * @type array<\Google\Cloud\SecurityCenter\V1p1beta1\Folder>|\Google\Protobuf\Internal\RepeatedField $folders + * Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is the + * folder directly under the Organization. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\Asset::initOnce(); + parent::__construct($data); + } + + /** + * The full resource name of the Google Cloud resource this asset + * represents. This field is immutable after create time. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_name = 1; + * @return string + */ + public function getResourceName() + { + return $this->resource_name; + } + + /** + * The full resource name of the Google Cloud resource this asset + * represents. This field is immutable after create time. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_name = 1; + * @param string $var + * @return $this + */ + public function setResourceName($var) + { + GPBUtil::checkString($var, True); + $this->resource_name = $var; + + return $this; + } + + /** + * The type of the Google Cloud resource. Examples include: APPLICATION, + * PROJECT, and ORGANIZATION. This is a case insensitive field defined by + * Security Command Center and/or the producer of the resource and is + * immutable after create time. + * + * Generated from protobuf field string resource_type = 2; + * @return string + */ + public function getResourceType() + { + return $this->resource_type; + } + + /** + * The type of the Google Cloud resource. Examples include: APPLICATION, + * PROJECT, and ORGANIZATION. This is a case insensitive field defined by + * Security Command Center and/or the producer of the resource and is + * immutable after create time. + * + * Generated from protobuf field string resource_type = 2; + * @param string $var + * @return $this + */ + public function setResourceType($var) + { + GPBUtil::checkString($var, True); + $this->resource_type = $var; + + return $this; + } + + /** + * The full resource name of the immediate parent of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_parent = 3; + * @return string + */ + public function getResourceParent() + { + return $this->resource_parent; + } + + /** + * The full resource name of the immediate parent of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_parent = 3; + * @param string $var + * @return $this + */ + public function setResourceParent($var) + { + GPBUtil::checkString($var, True); + $this->resource_parent = $var; + + return $this; + } + + /** + * The full resource name of the project the resource belongs to. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_project = 4; + * @return string + */ + public function getResourceProject() + { + return $this->resource_project; + } + + /** + * The full resource name of the project the resource belongs to. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_project = 4; + * @param string $var + * @return $this + */ + public function setResourceProject($var) + { + GPBUtil::checkString($var, True); + $this->resource_project = $var; + + return $this; + } + + /** + * Owners of the Google Cloud resource. + * + * Generated from protobuf field repeated string resource_owners = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getResourceOwners() + { + return $this->resource_owners; + } + + /** + * Owners of the Google Cloud resource. + * + * Generated from protobuf field repeated string resource_owners = 5; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setResourceOwners($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->resource_owners = $arr; + + return $this; + } + + /** + * The user defined display name for this resource. + * + * Generated from protobuf field string resource_display_name = 6; + * @return string + */ + public function getResourceDisplayName() + { + return $this->resource_display_name; + } + + /** + * The user defined display name for this resource. + * + * Generated from protobuf field string resource_display_name = 6; + * @param string $var + * @return $this + */ + public function setResourceDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->resource_display_name = $var; + + return $this; + } + + /** + * The user defined display name for the parent of this resource. + * + * Generated from protobuf field string resource_parent_display_name = 7; + * @return string + */ + public function getResourceParentDisplayName() + { + return $this->resource_parent_display_name; + } + + /** + * The user defined display name for the parent of this resource. + * + * Generated from protobuf field string resource_parent_display_name = 7; + * @param string $var + * @return $this + */ + public function setResourceParentDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->resource_parent_display_name = $var; + + return $this; + } + + /** + * The user defined display name for the project of this resource. + * + * Generated from protobuf field string resource_project_display_name = 8; + * @return string + */ + public function getResourceProjectDisplayName() + { + return $this->resource_project_display_name; + } + + /** + * The user defined display name for the project of this resource. + * + * Generated from protobuf field string resource_project_display_name = 8; + * @param string $var + * @return $this + */ + public function setResourceProjectDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->resource_project_display_name = $var; + + return $this; + } + + /** + * Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is the + * folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Folder folders = 10; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFolders() + { + return $this->folders; + } + + /** + * Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is the + * folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Folder folders = 10; + * @param array<\Google\Cloud\SecurityCenter\V1p1beta1\Folder>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFolders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1p1beta1\Folder::class); + $this->folders = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SecurityCenterProperties::class, \Google\Cloud\SecurityCenter\V1p1beta1\Asset_SecurityCenterProperties::class); + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateFindingRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateFindingRequest.php new file mode 100644 index 000000000000..8e7c48078d6b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateFindingRequest.php @@ -0,0 +1,153 @@ +google.cloud.securitycenter.v1p1beta1.CreateFindingRequest + */ +class CreateFindingRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. Unique identifier provided by the client within the parent scope. + * + * Generated from protobuf field string finding_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $finding_id = ''; + /** + * Required. The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $finding = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". + * @type string $finding_id + * Required. Unique identifier provided by the client within the parent scope. + * @type \Google\Cloud\SecurityCenter\V1p1beta1\Finding $finding + * Required. The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. Unique identifier provided by the client within the parent scope. + * + * Generated from protobuf field string finding_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getFindingId() + { + return $this->finding_id; + } + + /** + * Required. Unique identifier provided by the client within the parent scope. + * + * Generated from protobuf field string finding_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setFindingId($var) + { + GPBUtil::checkString($var, True); + $this->finding_id = $var; + + return $this; + } + + /** + * Required. The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1p1beta1\Finding|null + */ + public function getFinding() + { + return $this->finding; + } + + public function hasFinding() + { + return isset($this->finding); + } + + public function clearFinding() + { + unset($this->finding); + } + + /** + * Required. The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1p1beta1\Finding $var + * @return $this + */ + public function setFinding($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Finding::class); + $this->finding = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateNotificationConfigRequest.php new file mode 100644 index 000000000000..350e616be37a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateNotificationConfigRequest.php @@ -0,0 +1,161 @@ +google.cloud.securitycenter.v1p1beta1.CreateNotificationConfigRequest + */ +class CreateNotificationConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the new notification config's parent. Its format is + * "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must be between 1 and 128 characters, and contains alphanumeric + * characters, underscores or hyphens only. + * + * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $config_id = ''; + /** + * Required. The notification config being created. The name and the service account + * will be ignored as they are both output only fields on this resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig notification_config = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $notification_config = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Resource name of the new notification config's parent. Its format is + * "organizations/[organization_id]". + * @type string $config_id + * Required. Unique identifier provided by the client within the parent scope. + * It must be between 1 and 128 characters, and contains alphanumeric + * characters, underscores or hyphens only. + * @type \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig $notification_config + * Required. The notification config being created. The name and the service account + * will be ignored as they are both output only fields on this resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the new notification config's parent. Its format is + * "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Resource name of the new notification config's parent. Its format is + * "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must be between 1 and 128 characters, and contains alphanumeric + * characters, underscores or hyphens only. + * + * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getConfigId() + { + return $this->config_id; + } + + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must be between 1 and 128 characters, and contains alphanumeric + * characters, underscores or hyphens only. + * + * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setConfigId($var) + { + GPBUtil::checkString($var, True); + $this->config_id = $var; + + return $this; + } + + /** + * Required. The notification config being created. The name and the service account + * will be ignored as they are both output only fields on this resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig notification_config = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig|null + */ + public function getNotificationConfig() + { + return $this->notification_config; + } + + public function hasNotificationConfig() + { + return isset($this->notification_config); + } + + public function clearNotificationConfig() + { + unset($this->notification_config); + } + + /** + * Required. The notification config being created. The name and the service account + * will be ignored as they are both output only fields on this resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig notification_config = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig $var + * @return $this + */ + public function setNotificationConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig::class); + $this->notification_config = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateSourceRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateSourceRequest.php new file mode 100644 index 000000000000..b9856ab4564a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateSourceRequest.php @@ -0,0 +1,119 @@ +google.cloud.securitycenter.v1p1beta1.CreateSourceRequest + */ +class CreateSourceRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Source source = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $source = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + * @type \Google\Cloud\SecurityCenter\V1p1beta1\Source $source + * Required. The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Source source = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1p1beta1\Source|null + */ + public function getSource() + { + return $this->source; + } + + public function hasSource() + { + return isset($this->source); + } + + public function clearSource() + { + unset($this->source); + } + + /** + * Required. The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Source source = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1p1beta1\Source $var + * @return $this + */ + public function setSource($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Source::class); + $this->source = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/DeleteNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/DeleteNotificationConfigRequest.php new file mode 100644 index 000000000000..677c4d41b9bf --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/DeleteNotificationConfigRequest.php @@ -0,0 +1,71 @@ +google.cloud.securitycenter.v1p1beta1.DeleteNotificationConfigRequest + */ +class DeleteNotificationConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the notification config to delete. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the notification config to delete. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the notification config to delete. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the notification config to delete. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding.php new file mode 100644 index 000000000000..572c4c7113fd --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding.php @@ -0,0 +1,603 @@ +google.cloud.securitycenter.v1p1beta1.Finding + */ +class Finding extends \Google\Protobuf\Internal\Message +{ + /** + * The relative resource name of this finding. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}" + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The relative resource name of the source the finding belongs to. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * This field is immutable after creation time. + * For example: + * "organizations/{organization_id}/sources/{source_id}" + * + * Generated from protobuf field string parent = 2; + */ + protected $parent = ''; + /** + * For findings on Google Cloud resources, the full resource + * name of the Google Cloud resource this finding is for. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * When the finding is for a non-Google Cloud resource, the resourceName can + * be a customer or partner defined string. This field is immutable after + * creation time. + * + * Generated from protobuf field string resource_name = 3; + */ + protected $resource_name = ''; + /** + * The state of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding.State state = 4; + */ + protected $state = 0; + /** + * The additional taxonomy group within findings from a given source. + * This field is immutable after creation time. + * Example: "XSS_FLASH_INJECTION" + * + * Generated from protobuf field string category = 5; + */ + protected $category = ''; + /** + * The URI that, if available, points to a web page outside of Security + * Command Center where additional information about the finding can be found. + * This field is guaranteed to be either empty or a well formed URL. + * + * Generated from protobuf field string external_uri = 6; + */ + protected $external_uri = ''; + /** + * Source specific properties. These properties are managed by the source + * that writes the finding. The key names in the source_properties map must be + * between 1 and 255 characters, and must start with a letter and contain + * alphanumeric characters or underscores only. + * + * Generated from protobuf field map source_properties = 7; + */ + private $source_properties; + /** + * Output only. User specified security marks. These marks are entirely + * managed by the user and come from the SecurityMarks resource that belongs + * to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.SecurityMarks security_marks = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $security_marks = null; + /** + * The time at which the event took place, or when an update to the finding + * occurred. For example, if the finding represents an open firewall it would + * capture the time the detector believes the firewall became open. The + * accuracy is determined by the detector. If the finding were to be resolved + * afterward, this time would reflect when the finding was resolved. Must not + * be set to a value greater than the current timestamp. + * + * Generated from protobuf field .google.protobuf.Timestamp event_time = 9; + */ + protected $event_time = null; + /** + * The time at which the finding was created in Security Command Center. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 10; + */ + protected $create_time = null; + /** + * The severity of the finding. This field is managed by the source that + * writes the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding.Severity severity = 13; + */ + protected $severity = 0; + /** + * The canonical name of the finding. It's either + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}" or + * "projects/{project_number}/sources/{source_id}/findings/{finding_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * + * Generated from protobuf field string canonical_name = 14; + */ + protected $canonical_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The relative resource name of this finding. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}" + * @type string $parent + * The relative resource name of the source the finding belongs to. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * This field is immutable after creation time. + * For example: + * "organizations/{organization_id}/sources/{source_id}" + * @type string $resource_name + * For findings on Google Cloud resources, the full resource + * name of the Google Cloud resource this finding is for. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * When the finding is for a non-Google Cloud resource, the resourceName can + * be a customer or partner defined string. This field is immutable after + * creation time. + * @type int $state + * The state of the finding. + * @type string $category + * The additional taxonomy group within findings from a given source. + * This field is immutable after creation time. + * Example: "XSS_FLASH_INJECTION" + * @type string $external_uri + * The URI that, if available, points to a web page outside of Security + * Command Center where additional information about the finding can be found. + * This field is guaranteed to be either empty or a well formed URL. + * @type array|\Google\Protobuf\Internal\MapField $source_properties + * Source specific properties. These properties are managed by the source + * that writes the finding. The key names in the source_properties map must be + * between 1 and 255 characters, and must start with a letter and contain + * alphanumeric characters or underscores only. + * @type \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks $security_marks + * Output only. User specified security marks. These marks are entirely + * managed by the user and come from the SecurityMarks resource that belongs + * to the finding. + * @type \Google\Protobuf\Timestamp $event_time + * The time at which the event took place, or when an update to the finding + * occurred. For example, if the finding represents an open firewall it would + * capture the time the detector believes the firewall became open. The + * accuracy is determined by the detector. If the finding were to be resolved + * afterward, this time would reflect when the finding was resolved. Must not + * be set to a value greater than the current timestamp. + * @type \Google\Protobuf\Timestamp $create_time + * The time at which the finding was created in Security Command Center. + * @type int $severity + * The severity of the finding. This field is managed by the source that + * writes the finding. + * @type string $canonical_name + * The canonical name of the finding. It's either + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}" or + * "projects/{project_number}/sources/{source_id}/findings/{finding_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\Finding::initOnce(); + parent::__construct($data); + } + + /** + * The relative resource name of this finding. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}" + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The relative resource name of this finding. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}" + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The relative resource name of the source the finding belongs to. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * This field is immutable after creation time. + * For example: + * "organizations/{organization_id}/sources/{source_id}" + * + * Generated from protobuf field string parent = 2; + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * The relative resource name of the source the finding belongs to. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * This field is immutable after creation time. + * For example: + * "organizations/{organization_id}/sources/{source_id}" + * + * Generated from protobuf field string parent = 2; + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * For findings on Google Cloud resources, the full resource + * name of the Google Cloud resource this finding is for. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * When the finding is for a non-Google Cloud resource, the resourceName can + * be a customer or partner defined string. This field is immutable after + * creation time. + * + * Generated from protobuf field string resource_name = 3; + * @return string + */ + public function getResourceName() + { + return $this->resource_name; + } + + /** + * For findings on Google Cloud resources, the full resource + * name of the Google Cloud resource this finding is for. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * When the finding is for a non-Google Cloud resource, the resourceName can + * be a customer or partner defined string. This field is immutable after + * creation time. + * + * Generated from protobuf field string resource_name = 3; + * @param string $var + * @return $this + */ + public function setResourceName($var) + { + GPBUtil::checkString($var, True); + $this->resource_name = $var; + + return $this; + } + + /** + * The state of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding.State state = 4; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * The state of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding.State state = 4; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1p1beta1\Finding\State::class); + $this->state = $var; + + return $this; + } + + /** + * The additional taxonomy group within findings from a given source. + * This field is immutable after creation time. + * Example: "XSS_FLASH_INJECTION" + * + * Generated from protobuf field string category = 5; + * @return string + */ + public function getCategory() + { + return $this->category; + } + + /** + * The additional taxonomy group within findings from a given source. + * This field is immutable after creation time. + * Example: "XSS_FLASH_INJECTION" + * + * Generated from protobuf field string category = 5; + * @param string $var + * @return $this + */ + public function setCategory($var) + { + GPBUtil::checkString($var, True); + $this->category = $var; + + return $this; + } + + /** + * The URI that, if available, points to a web page outside of Security + * Command Center where additional information about the finding can be found. + * This field is guaranteed to be either empty or a well formed URL. + * + * Generated from protobuf field string external_uri = 6; + * @return string + */ + public function getExternalUri() + { + return $this->external_uri; + } + + /** + * The URI that, if available, points to a web page outside of Security + * Command Center where additional information about the finding can be found. + * This field is guaranteed to be either empty or a well formed URL. + * + * Generated from protobuf field string external_uri = 6; + * @param string $var + * @return $this + */ + public function setExternalUri($var) + { + GPBUtil::checkString($var, True); + $this->external_uri = $var; + + return $this; + } + + /** + * Source specific properties. These properties are managed by the source + * that writes the finding. The key names in the source_properties map must be + * between 1 and 255 characters, and must start with a letter and contain + * alphanumeric characters or underscores only. + * + * Generated from protobuf field map source_properties = 7; + * @return \Google\Protobuf\Internal\MapField + */ + public function getSourceProperties() + { + return $this->source_properties; + } + + /** + * Source specific properties. These properties are managed by the source + * that writes the finding. The key names in the source_properties map must be + * between 1 and 255 characters, and must start with a letter and contain + * alphanumeric characters or underscores only. + * + * Generated from protobuf field map source_properties = 7; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setSourceProperties($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Value::class); + $this->source_properties = $arr; + + return $this; + } + + /** + * Output only. User specified security marks. These marks are entirely + * managed by the user and come from the SecurityMarks resource that belongs + * to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.SecurityMarks security_marks = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks|null + */ + public function getSecurityMarks() + { + return $this->security_marks; + } + + public function hasSecurityMarks() + { + return isset($this->security_marks); + } + + public function clearSecurityMarks() + { + unset($this->security_marks); + } + + /** + * Output only. User specified security marks. These marks are entirely + * managed by the user and come from the SecurityMarks resource that belongs + * to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.SecurityMarks security_marks = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks $var + * @return $this + */ + public function setSecurityMarks($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks::class); + $this->security_marks = $var; + + return $this; + } + + /** + * The time at which the event took place, or when an update to the finding + * occurred. For example, if the finding represents an open firewall it would + * capture the time the detector believes the firewall became open. The + * accuracy is determined by the detector. If the finding were to be resolved + * afterward, this time would reflect when the finding was resolved. Must not + * be set to a value greater than the current timestamp. + * + * Generated from protobuf field .google.protobuf.Timestamp event_time = 9; + * @return \Google\Protobuf\Timestamp|null + */ + public function getEventTime() + { + return $this->event_time; + } + + public function hasEventTime() + { + return isset($this->event_time); + } + + public function clearEventTime() + { + unset($this->event_time); + } + + /** + * The time at which the event took place, or when an update to the finding + * occurred. For example, if the finding represents an open firewall it would + * capture the time the detector believes the firewall became open. The + * accuracy is determined by the detector. If the finding were to be resolved + * afterward, this time would reflect when the finding was resolved. Must not + * be set to a value greater than the current timestamp. + * + * Generated from protobuf field .google.protobuf.Timestamp event_time = 9; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setEventTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->event_time = $var; + + return $this; + } + + /** + * The time at which the finding was created in Security Command Center. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 10; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCreateTime() + { + return $this->create_time; + } + + public function hasCreateTime() + { + return isset($this->create_time); + } + + public function clearCreateTime() + { + unset($this->create_time); + } + + /** + * The time at which the finding was created in Security Command Center. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 10; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->create_time = $var; + + return $this; + } + + /** + * The severity of the finding. This field is managed by the source that + * writes the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding.Severity severity = 13; + * @return int + */ + public function getSeverity() + { + return $this->severity; + } + + /** + * The severity of the finding. This field is managed by the source that + * writes the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding.Severity severity = 13; + * @param int $var + * @return $this + */ + public function setSeverity($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1p1beta1\Finding\Severity::class); + $this->severity = $var; + + return $this; + } + + /** + * The canonical name of the finding. It's either + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}" or + * "projects/{project_number}/sources/{source_id}/findings/{finding_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * + * Generated from protobuf field string canonical_name = 14; + * @return string + */ + public function getCanonicalName() + { + return $this->canonical_name; + } + + /** + * The canonical name of the finding. It's either + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}" or + * "projects/{project_number}/sources/{source_id}/findings/{finding_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * + * Generated from protobuf field string canonical_name = 14; + * @param string $var + * @return $this + */ + public function setCanonicalName($var) + { + GPBUtil::checkString($var, True); + $this->canonical_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding/Severity.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding/Severity.php new file mode 100644 index 000000000000..7b66c33d8bd0 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding/Severity.php @@ -0,0 +1,79 @@ +google.cloud.securitycenter.v1p1beta1.Finding.Severity + */ +class Severity +{ + /** + * No severity specified. The default value. + * + * Generated from protobuf enum SEVERITY_UNSPECIFIED = 0; + */ + const SEVERITY_UNSPECIFIED = 0; + /** + * Critical severity. + * + * Generated from protobuf enum CRITICAL = 1; + */ + const CRITICAL = 1; + /** + * High severity. + * + * Generated from protobuf enum HIGH = 2; + */ + const HIGH = 2; + /** + * Medium severity. + * + * Generated from protobuf enum MEDIUM = 3; + */ + const MEDIUM = 3; + /** + * Low severity. + * + * Generated from protobuf enum LOW = 4; + */ + const LOW = 4; + + private static $valueToName = [ + self::SEVERITY_UNSPECIFIED => 'SEVERITY_UNSPECIFIED', + self::CRITICAL => 'CRITICAL', + self::HIGH => 'HIGH', + self::MEDIUM => 'MEDIUM', + self::LOW => 'LOW', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Severity::class, \Google\Cloud\SecurityCenter\V1p1beta1\Finding_Severity::class); + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding/State.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding/State.php new file mode 100644 index 000000000000..188e804f89de --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding/State.php @@ -0,0 +1,65 @@ +google.cloud.securitycenter.v1p1beta1.Finding.State + */ +class State +{ + /** + * Unspecified state. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The finding requires attention and has not been addressed yet. + * + * Generated from protobuf enum ACTIVE = 1; + */ + const ACTIVE = 1; + /** + * The finding has been fixed, triaged as a non-issue or otherwise addressed + * and is no longer active. + * + * Generated from protobuf enum INACTIVE = 2; + */ + const INACTIVE = 2; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::ACTIVE => 'ACTIVE', + self::INACTIVE => 'INACTIVE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(State::class, \Google\Cloud\SecurityCenter\V1p1beta1\Finding_State::class); + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Folder.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Folder.php new file mode 100644 index 000000000000..1be85831acc6 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Folder.php @@ -0,0 +1,106 @@ +google.cloud.securitycenter.v1p1beta1.Folder + */ +class Folder extends \Google\Protobuf\Internal\Message +{ + /** + * Full resource name of this folder. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_folder = 1; + */ + protected $resource_folder = ''; + /** + * The user defined display name for this folder. + * + * Generated from protobuf field string resource_folder_display_name = 2; + */ + protected $resource_folder_display_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $resource_folder + * Full resource name of this folder. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * @type string $resource_folder_display_name + * The user defined display name for this folder. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\Folder::initOnce(); + parent::__construct($data); + } + + /** + * Full resource name of this folder. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_folder = 1; + * @return string + */ + public function getResourceFolder() + { + return $this->resource_folder; + } + + /** + * Full resource name of this folder. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_folder = 1; + * @param string $var + * @return $this + */ + public function setResourceFolder($var) + { + GPBUtil::checkString($var, True); + $this->resource_folder = $var; + + return $this; + } + + /** + * The user defined display name for this folder. + * + * Generated from protobuf field string resource_folder_display_name = 2; + * @return string + */ + public function getResourceFolderDisplayName() + { + return $this->resource_folder_display_name; + } + + /** + * The user defined display name for this folder. + * + * Generated from protobuf field string resource_folder_display_name = 2; + * @param string $var + * @return $this + */ + public function setResourceFolderDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->resource_folder_display_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetNotificationConfigRequest.php new file mode 100644 index 000000000000..b612d7b962c2 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetNotificationConfigRequest.php @@ -0,0 +1,71 @@ +google.cloud.securitycenter.v1p1beta1.GetNotificationConfigRequest + */ +class GetNotificationConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the notification config to get. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the notification config to get. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the notification config to get. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the notification config to get. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetOrganizationSettingsRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetOrganizationSettingsRequest.php new file mode 100644 index 000000000000..1f0cdc6d247d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetOrganizationSettingsRequest.php @@ -0,0 +1,71 @@ +google.cloud.securitycenter.v1p1beta1.GetOrganizationSettingsRequest + */ +class GetOrganizationSettingsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the organization to get organization settings for. Its format is + * "organizations/[organization_id]/organizationSettings". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the organization to get organization settings for. Its format is + * "organizations/[organization_id]/organizationSettings". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the organization to get organization settings for. Its format is + * "organizations/[organization_id]/organizationSettings". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the organization to get organization settings for. Its format is + * "organizations/[organization_id]/organizationSettings". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetSourceRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetSourceRequest.php new file mode 100644 index 000000000000..4372471b4525 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetSourceRequest.php @@ -0,0 +1,71 @@ +google.cloud.securitycenter.v1p1beta1.GetSourceRequest + */ +class GetSourceRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Relative resource name of the source. Its format is + * "organizations/[organization_id]/source/[source_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Relative resource name of the source. Its format is + * "organizations/[organization_id]/source/[source_id]". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Relative resource name of the source. Its format is + * "organizations/[organization_id]/source/[source_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Relative resource name of the source. Its format is + * "organizations/[organization_id]/source/[source_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupAssetsRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupAssetsRequest.php new file mode 100644 index 000000000000..22d91ed7c020 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupAssetsRequest.php @@ -0,0 +1,643 @@ +google.cloud.securitycenter.v1p1beta1.GroupAssetsRequest + */ +class GroupAssetsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the organization to groupBy. Its format is + * "organizations/[organization_id], folders/[folder_id], or + * projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_name_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * For example, `resource_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * + * Generated from protobuf field string filter = 2; + */ + protected $filter = ''; + /** + * Required. Expression that defines what assets fields to use for grouping. The string + * value should follow SQL syntax: comma separated list of fields. For + * example: + * "security_center_properties.resource_project,security_center_properties.project". + * The following fields are supported when compare_duration is not set: + * * security_center_properties.resource_project + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_type + * * security_center_properties.resource_parent + * * security_center_properties.resource_parent_display_name + * The following fields are supported when compare_duration is set: + * * security_center_properties.resource_type + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_parent_display_name + * + * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $group_by = ''; + /** + * When compare_duration is set, the GroupResult's "state_change" property is + * updated to indicate whether the asset was added, removed, or remained + * present during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * Possible "state_change" values when compare_duration is specified: + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at reference_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at reference_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and reference_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 4; + */ + protected $compare_duration = null; + /** + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 5; + */ + protected $read_time = null; + /** + * The value returned by the last `GroupAssetsResponse`; indicates + * that this is a continuation of a prior `GroupAssets` call, and that the + * system should return the next page of data. + * + * Generated from protobuf field string page_token = 7; + */ + protected $page_token = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 8; + */ + protected $page_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Name of the organization to groupBy. Its format is + * "organizations/[organization_id], folders/[folder_id], or + * projects/[project_id]". + * @type string $filter + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_name_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * For example, `resource_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * @type string $group_by + * Required. Expression that defines what assets fields to use for grouping. The string + * value should follow SQL syntax: comma separated list of fields. For + * example: + * "security_center_properties.resource_project,security_center_properties.project". + * The following fields are supported when compare_duration is not set: + * * security_center_properties.resource_project + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_type + * * security_center_properties.resource_parent + * * security_center_properties.resource_parent_display_name + * The following fields are supported when compare_duration is set: + * * security_center_properties.resource_type + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_parent_display_name + * @type \Google\Protobuf\Duration $compare_duration + * When compare_duration is set, the GroupResult's "state_change" property is + * updated to indicate whether the asset was added, removed, or remained + * present during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * Possible "state_change" values when compare_duration is specified: + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at reference_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at reference_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and reference_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * @type \Google\Protobuf\Timestamp $read_time + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * @type string $page_token + * The value returned by the last `GroupAssetsResponse`; indicates + * that this is a continuation of a prior `GroupAssets` call, and that the + * system should return the next page of data. + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the organization to groupBy. Its format is + * "organizations/[organization_id], folders/[folder_id], or + * projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Name of the organization to groupBy. Its format is + * "organizations/[organization_id], folders/[folder_id], or + * projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_name_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * For example, `resource_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * + * Generated from protobuf field string filter = 2; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_name_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * For example, `resource_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * + * Generated from protobuf field string filter = 2; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * Required. Expression that defines what assets fields to use for grouping. The string + * value should follow SQL syntax: comma separated list of fields. For + * example: + * "security_center_properties.resource_project,security_center_properties.project". + * The following fields are supported when compare_duration is not set: + * * security_center_properties.resource_project + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_type + * * security_center_properties.resource_parent + * * security_center_properties.resource_parent_display_name + * The following fields are supported when compare_duration is set: + * * security_center_properties.resource_type + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_parent_display_name + * + * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getGroupBy() + { + return $this->group_by; + } + + /** + * Required. Expression that defines what assets fields to use for grouping. The string + * value should follow SQL syntax: comma separated list of fields. For + * example: + * "security_center_properties.resource_project,security_center_properties.project". + * The following fields are supported when compare_duration is not set: + * * security_center_properties.resource_project + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_type + * * security_center_properties.resource_parent + * * security_center_properties.resource_parent_display_name + * The following fields are supported when compare_duration is set: + * * security_center_properties.resource_type + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_parent_display_name + * + * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setGroupBy($var) + { + GPBUtil::checkString($var, True); + $this->group_by = $var; + + return $this; + } + + /** + * When compare_duration is set, the GroupResult's "state_change" property is + * updated to indicate whether the asset was added, removed, or remained + * present during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * Possible "state_change" values when compare_duration is specified: + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at reference_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at reference_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and reference_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 4; + * @return \Google\Protobuf\Duration|null + */ + public function getCompareDuration() + { + return $this->compare_duration; + } + + public function hasCompareDuration() + { + return isset($this->compare_duration); + } + + public function clearCompareDuration() + { + unset($this->compare_duration); + } + + /** + * When compare_duration is set, the GroupResult's "state_change" property is + * updated to indicate whether the asset was added, removed, or remained + * present during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * Possible "state_change" values when compare_duration is specified: + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at reference_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at reference_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and reference_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 4; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setCompareDuration($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->compare_duration = $var; + + return $this; + } + + /** + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 5; + * @return \Google\Protobuf\Timestamp|null + */ + public function getReadTime() + { + return $this->read_time; + } + + public function hasReadTime() + { + return isset($this->read_time); + } + + public function clearReadTime() + { + unset($this->read_time); + } + + /** + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 5; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setReadTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->read_time = $var; + + return $this; + } + + /** + * The value returned by the last `GroupAssetsResponse`; indicates + * that this is a continuation of a prior `GroupAssets` call, and that the + * system should return the next page of data. + * + * Generated from protobuf field string page_token = 7; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last `GroupAssetsResponse`; indicates + * that this is a continuation of a prior `GroupAssets` call, and that the + * system should return the next page of data. + * + * Generated from protobuf field string page_token = 7; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 8; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 8; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupAssetsResponse.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupAssetsResponse.php new file mode 100644 index 000000000000..e617f28d43a0 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupAssetsResponse.php @@ -0,0 +1,191 @@ +google.cloud.securitycenter.v1p1beta1.GroupAssetsResponse + */ +class GroupAssetsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.GroupResult group_by_results = 1; + */ + private $group_by_results; + /** + * Time used for executing the groupBy request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + */ + protected $read_time = null; + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + */ + protected $next_page_token = ''; + /** + * The total number of results matching the query. + * + * Generated from protobuf field int32 total_size = 4; + */ + protected $total_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1p1beta1\GroupResult>|\Google\Protobuf\Internal\RepeatedField $group_by_results + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * @type \Google\Protobuf\Timestamp $read_time + * Time used for executing the groupBy request. + * @type string $next_page_token + * Token to retrieve the next page of results, or empty if there are no more + * results. + * @type int $total_size + * The total number of results matching the query. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.GroupResult group_by_results = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getGroupByResults() + { + return $this->group_by_results; + } + + /** + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.GroupResult group_by_results = 1; + * @param array<\Google\Cloud\SecurityCenter\V1p1beta1\GroupResult>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setGroupByResults($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1p1beta1\GroupResult::class); + $this->group_by_results = $arr; + + return $this; + } + + /** + * Time used for executing the groupBy request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + * @return \Google\Protobuf\Timestamp|null + */ + public function getReadTime() + { + return $this->read_time; + } + + public function hasReadTime() + { + return isset($this->read_time); + } + + public function clearReadTime() + { + unset($this->read_time); + } + + /** + * Time used for executing the groupBy request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setReadTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->read_time = $var; + + return $this; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + + /** + * The total number of results matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @return int + */ + public function getTotalSize() + { + return $this->total_size; + } + + /** + * The total number of results matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @param int $var + * @return $this + */ + public function setTotalSize($var) + { + GPBUtil::checkInt32($var); + $this->total_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupFindingsRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupFindingsRequest.php new file mode 100644 index 000000000000..1d1532312f30 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupFindingsRequest.php @@ -0,0 +1,627 @@ +google.cloud.securitycenter.v1p1beta1.GroupFindingsRequest + */ +class GroupFindingsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the source to groupBy. Its format is + * "organizations/[organization_id]/sources/[source_id]", + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]. To groupBy across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, + * or projects/{project_id}/sources/- + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * * severity: `=`, `:` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * security_marks.marks: `=`, `:` + * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * For example, `source_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * + * Generated from protobuf field string filter = 2; + */ + protected $filter = ''; + /** + * Required. Expression that defines what assets fields to use for grouping (including + * `state_change`). The string value should follow SQL syntax: comma separated + * list of fields. For example: "parent,resource_name". + * The following fields are supported: + * * resource_name + * * category + * * state + * * parent + * * severity + * The following fields are supported when compare_duration is set: + * * state_change + * + * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $group_by = ''; + /** + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; + */ + protected $read_time = null; + /** + * When compare_duration is set, the GroupResult's "state_change" attribute is + * updated to indicate whether the finding had its state changed, the + * finding's state remained unchanged, or if the finding was added during the + * compare_duration period of time that precedes the read_time. This is the + * time between (read_time - compare_duration) and read_time. + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * Possible "state_change" values when compare_duration is specified: + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present + * at read_time. + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; + */ + protected $compare_duration = null; + /** + * The value returned by the last `GroupFindingsResponse`; indicates + * that this is a continuation of a prior `GroupFindings` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 7; + */ + protected $page_token = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 8; + */ + protected $page_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Name of the source to groupBy. Its format is + * "organizations/[organization_id]/sources/[source_id]", + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]. To groupBy across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, + * or projects/{project_id}/sources/- + * @type string $filter + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * * severity: `=`, `:` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * security_marks.marks: `=`, `:` + * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * For example, `source_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * @type string $group_by + * Required. Expression that defines what assets fields to use for grouping (including + * `state_change`). The string value should follow SQL syntax: comma separated + * list of fields. For example: "parent,resource_name". + * The following fields are supported: + * * resource_name + * * category + * * state + * * parent + * * severity + * The following fields are supported when compare_duration is set: + * * state_change + * @type \Google\Protobuf\Timestamp $read_time + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * @type \Google\Protobuf\Duration $compare_duration + * When compare_duration is set, the GroupResult's "state_change" attribute is + * updated to indicate whether the finding had its state changed, the + * finding's state remained unchanged, or if the finding was added during the + * compare_duration period of time that precedes the read_time. This is the + * time between (read_time - compare_duration) and read_time. + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * Possible "state_change" values when compare_duration is specified: + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present + * at read_time. + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * @type string $page_token + * The value returned by the last `GroupFindingsResponse`; indicates + * that this is a continuation of a prior `GroupFindings` call, and + * that the system should return the next page of data. + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the source to groupBy. Its format is + * "organizations/[organization_id]/sources/[source_id]", + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]. To groupBy across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, + * or projects/{project_id}/sources/- + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Name of the source to groupBy. Its format is + * "organizations/[organization_id]/sources/[source_id]", + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]. To groupBy across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, + * or projects/{project_id}/sources/- + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * * severity: `=`, `:` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * security_marks.marks: `=`, `:` + * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * For example, `source_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * + * Generated from protobuf field string filter = 2; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * * severity: `=`, `:` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * security_marks.marks: `=`, `:` + * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * For example, `source_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * + * Generated from protobuf field string filter = 2; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * Required. Expression that defines what assets fields to use for grouping (including + * `state_change`). The string value should follow SQL syntax: comma separated + * list of fields. For example: "parent,resource_name". + * The following fields are supported: + * * resource_name + * * category + * * state + * * parent + * * severity + * The following fields are supported when compare_duration is set: + * * state_change + * + * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getGroupBy() + { + return $this->group_by; + } + + /** + * Required. Expression that defines what assets fields to use for grouping (including + * `state_change`). The string value should follow SQL syntax: comma separated + * list of fields. For example: "parent,resource_name". + * The following fields are supported: + * * resource_name + * * category + * * state + * * parent + * * severity + * The following fields are supported when compare_duration is set: + * * state_change + * + * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setGroupBy($var) + { + GPBUtil::checkString($var, True); + $this->group_by = $var; + + return $this; + } + + /** + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; + * @return \Google\Protobuf\Timestamp|null + */ + public function getReadTime() + { + return $this->read_time; + } + + public function hasReadTime() + { + return isset($this->read_time); + } + + public function clearReadTime() + { + unset($this->read_time); + } + + /** + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setReadTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->read_time = $var; + + return $this; + } + + /** + * When compare_duration is set, the GroupResult's "state_change" attribute is + * updated to indicate whether the finding had its state changed, the + * finding's state remained unchanged, or if the finding was added during the + * compare_duration period of time that precedes the read_time. This is the + * time between (read_time - compare_duration) and read_time. + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * Possible "state_change" values when compare_duration is specified: + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present + * at read_time. + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; + * @return \Google\Protobuf\Duration|null + */ + public function getCompareDuration() + { + return $this->compare_duration; + } + + public function hasCompareDuration() + { + return isset($this->compare_duration); + } + + public function clearCompareDuration() + { + unset($this->compare_duration); + } + + /** + * When compare_duration is set, the GroupResult's "state_change" attribute is + * updated to indicate whether the finding had its state changed, the + * finding's state remained unchanged, or if the finding was added during the + * compare_duration period of time that precedes the read_time. This is the + * time between (read_time - compare_duration) and read_time. + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * Possible "state_change" values when compare_duration is specified: + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present + * at read_time. + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setCompareDuration($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->compare_duration = $var; + + return $this; + } + + /** + * The value returned by the last `GroupFindingsResponse`; indicates + * that this is a continuation of a prior `GroupFindings` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 7; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last `GroupFindingsResponse`; indicates + * that this is a continuation of a prior `GroupFindings` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 7; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 8; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 8; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupFindingsResponse.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupFindingsResponse.php new file mode 100644 index 000000000000..08e112996742 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupFindingsResponse.php @@ -0,0 +1,191 @@ +google.cloud.securitycenter.v1p1beta1.GroupFindingsResponse + */ +class GroupFindingsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.GroupResult group_by_results = 1; + */ + private $group_by_results; + /** + * Time used for executing the groupBy request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + */ + protected $read_time = null; + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + */ + protected $next_page_token = ''; + /** + * The total number of results matching the query. + * + * Generated from protobuf field int32 total_size = 4; + */ + protected $total_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1p1beta1\GroupResult>|\Google\Protobuf\Internal\RepeatedField $group_by_results + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * @type \Google\Protobuf\Timestamp $read_time + * Time used for executing the groupBy request. + * @type string $next_page_token + * Token to retrieve the next page of results, or empty if there are no more + * results. + * @type int $total_size + * The total number of results matching the query. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.GroupResult group_by_results = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getGroupByResults() + { + return $this->group_by_results; + } + + /** + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.GroupResult group_by_results = 1; + * @param array<\Google\Cloud\SecurityCenter\V1p1beta1\GroupResult>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setGroupByResults($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1p1beta1\GroupResult::class); + $this->group_by_results = $arr; + + return $this; + } + + /** + * Time used for executing the groupBy request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + * @return \Google\Protobuf\Timestamp|null + */ + public function getReadTime() + { + return $this->read_time; + } + + public function hasReadTime() + { + return isset($this->read_time); + } + + public function clearReadTime() + { + unset($this->read_time); + } + + /** + * Time used for executing the groupBy request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setReadTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->read_time = $var; + + return $this; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + + /** + * The total number of results matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @return int + */ + public function getTotalSize() + { + return $this->total_size; + } + + /** + * The total number of results matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @param int $var + * @return $this + */ + public function setTotalSize($var) + { + GPBUtil::checkInt32($var); + $this->total_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupResult.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupResult.php new file mode 100644 index 000000000000..5abaf409e1ce --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupResult.php @@ -0,0 +1,101 @@ +google.cloud.securitycenter.v1p1beta1.GroupResult + */ +class GroupResult extends \Google\Protobuf\Internal\Message +{ + /** + * Properties matching the groupBy fields in the request. + * + * Generated from protobuf field map properties = 1; + */ + private $properties; + /** + * Total count of resources for the given properties. + * + * Generated from protobuf field int64 count = 2; + */ + protected $count = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\MapField $properties + * Properties matching the groupBy fields in the request. + * @type int|string $count + * Total count of resources for the given properties. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Properties matching the groupBy fields in the request. + * + * Generated from protobuf field map properties = 1; + * @return \Google\Protobuf\Internal\MapField + */ + public function getProperties() + { + return $this->properties; + } + + /** + * Properties matching the groupBy fields in the request. + * + * Generated from protobuf field map properties = 1; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setProperties($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Value::class); + $this->properties = $arr; + + return $this; + } + + /** + * Total count of resources for the given properties. + * + * Generated from protobuf field int64 count = 2; + * @return int|string + */ + public function getCount() + { + return $this->count; + } + + /** + * Total count of resources for the given properties. + * + * Generated from protobuf field int64 count = 2; + * @param int|string $var + * @return $this + */ + public function setCount($var) + { + GPBUtil::checkInt64($var); + $this->count = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsRequest.php new file mode 100644 index 000000000000..a0a4531e7d95 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsRequest.php @@ -0,0 +1,711 @@ +google.cloud.securitycenter.v1p1beta1.ListAssetsRequest + */ +class ListAssetsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the organization assets should belong to. Its format is + * "organizations/[organization_id], folders/[folder_id], or + * projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following are the allowed field and operator combinations: + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * For example, `resource_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * + * Generated from protobuf field string filter = 2; + */ + protected $filter = ''; + /** + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,resource_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,resource_properties.a_property" and " + * name desc , resource_properties.a_property " are equivalent. + * The following fields are supported: + * name + * update_time + * resource_properties + * security_marks.marks + * security_center_properties.resource_name + * security_center_properties.resource_display_name + * security_center_properties.resource_parent + * security_center_properties.resource_parent_display_name + * security_center_properties.resource_project + * security_center_properties.resource_project_display_name + * security_center_properties.resource_type + * + * Generated from protobuf field string order_by = 3; + */ + protected $order_by = ''; + /** + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; + */ + protected $read_time = null; + /** + * When compare_duration is set, the ListAssetsResult's "state_change" + * attribute is updated to indicate whether the asset was added, removed, or + * remained present during the compare_duration period of time that precedes + * the read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state_change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * Possible "state_change" values when compare_duration is specified: + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at read_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at read_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; + */ + protected $compare_duration = null; + /** + * A field mask to specify the ListAssetsResult fields to be listed in the + * response. + * An empty field mask will list all fields. + * + * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; + */ + protected $field_mask = null; + /** + * The value returned by the last `ListAssetsResponse`; indicates + * that this is a continuation of a prior `ListAssets` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 8; + */ + protected $page_token = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 9; + */ + protected $page_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Name of the organization assets should belong to. Its format is + * "organizations/[organization_id], folders/[folder_id], or + * projects/[project_id]". + * @type string $filter + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following are the allowed field and operator combinations: + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * For example, `resource_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * @type string $order_by + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,resource_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,resource_properties.a_property" and " + * name desc , resource_properties.a_property " are equivalent. + * The following fields are supported: + * name + * update_time + * resource_properties + * security_marks.marks + * security_center_properties.resource_name + * security_center_properties.resource_display_name + * security_center_properties.resource_parent + * security_center_properties.resource_parent_display_name + * security_center_properties.resource_project + * security_center_properties.resource_project_display_name + * security_center_properties.resource_type + * @type \Google\Protobuf\Timestamp $read_time + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * @type \Google\Protobuf\Duration $compare_duration + * When compare_duration is set, the ListAssetsResult's "state_change" + * attribute is updated to indicate whether the asset was added, removed, or + * remained present during the compare_duration period of time that precedes + * the read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state_change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * Possible "state_change" values when compare_duration is specified: + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at read_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at read_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * @type \Google\Protobuf\FieldMask $field_mask + * A field mask to specify the ListAssetsResult fields to be listed in the + * response. + * An empty field mask will list all fields. + * @type string $page_token + * The value returned by the last `ListAssetsResponse`; indicates + * that this is a continuation of a prior `ListAssets` call, and + * that the system should return the next page of data. + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the organization assets should belong to. Its format is + * "organizations/[organization_id], folders/[folder_id], or + * projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Name of the organization assets should belong to. Its format is + * "organizations/[organization_id], folders/[folder_id], or + * projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following are the allowed field and operator combinations: + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * For example, `resource_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * + * Generated from protobuf field string filter = 2; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following are the allowed field and operator combinations: + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * For example, `resource_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * + * Generated from protobuf field string filter = 2; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,resource_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,resource_properties.a_property" and " + * name desc , resource_properties.a_property " are equivalent. + * The following fields are supported: + * name + * update_time + * resource_properties + * security_marks.marks + * security_center_properties.resource_name + * security_center_properties.resource_display_name + * security_center_properties.resource_parent + * security_center_properties.resource_parent_display_name + * security_center_properties.resource_project + * security_center_properties.resource_project_display_name + * security_center_properties.resource_type + * + * Generated from protobuf field string order_by = 3; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,resource_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,resource_properties.a_property" and " + * name desc , resource_properties.a_property " are equivalent. + * The following fields are supported: + * name + * update_time + * resource_properties + * security_marks.marks + * security_center_properties.resource_name + * security_center_properties.resource_display_name + * security_center_properties.resource_parent + * security_center_properties.resource_parent_display_name + * security_center_properties.resource_project + * security_center_properties.resource_project_display_name + * security_center_properties.resource_type + * + * Generated from protobuf field string order_by = 3; + * @param string $var + * @return $this + */ + public function setOrderBy($var) + { + GPBUtil::checkString($var, True); + $this->order_by = $var; + + return $this; + } + + /** + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; + * @return \Google\Protobuf\Timestamp|null + */ + public function getReadTime() + { + return $this->read_time; + } + + public function hasReadTime() + { + return isset($this->read_time); + } + + public function clearReadTime() + { + unset($this->read_time); + } + + /** + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setReadTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->read_time = $var; + + return $this; + } + + /** + * When compare_duration is set, the ListAssetsResult's "state_change" + * attribute is updated to indicate whether the asset was added, removed, or + * remained present during the compare_duration period of time that precedes + * the read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state_change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * Possible "state_change" values when compare_duration is specified: + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at read_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at read_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; + * @return \Google\Protobuf\Duration|null + */ + public function getCompareDuration() + { + return $this->compare_duration; + } + + public function hasCompareDuration() + { + return isset($this->compare_duration); + } + + public function clearCompareDuration() + { + unset($this->compare_duration); + } + + /** + * When compare_duration is set, the ListAssetsResult's "state_change" + * attribute is updated to indicate whether the asset was added, removed, or + * remained present during the compare_duration period of time that precedes + * the read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state_change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * Possible "state_change" values when compare_duration is specified: + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at read_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at read_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setCompareDuration($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->compare_duration = $var; + + return $this; + } + + /** + * A field mask to specify the ListAssetsResult fields to be listed in the + * response. + * An empty field mask will list all fields. + * + * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; + * @return \Google\Protobuf\FieldMask|null + */ + public function getFieldMask() + { + return $this->field_mask; + } + + public function hasFieldMask() + { + return isset($this->field_mask); + } + + public function clearFieldMask() + { + unset($this->field_mask); + } + + /** + * A field mask to specify the ListAssetsResult fields to be listed in the + * response. + * An empty field mask will list all fields. + * + * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setFieldMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->field_mask = $var; + + return $this; + } + + /** + * The value returned by the last `ListAssetsResponse`; indicates + * that this is a continuation of a prior `ListAssets` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 8; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last `ListAssetsResponse`; indicates + * that this is a continuation of a prior `ListAssets` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 8; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 9; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 9; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse.php new file mode 100644 index 000000000000..c1c510821ecf --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse.php @@ -0,0 +1,183 @@ +google.cloud.securitycenter.v1p1beta1.ListAssetsResponse + */ +class ListAssetsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Assets matching the list request. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.ListAssetsResponse.ListAssetsResult list_assets_results = 1; + */ + private $list_assets_results; + /** + * Time used for executing the list request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + */ + protected $read_time = null; + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + */ + protected $next_page_token = ''; + /** + * The total number of assets matching the query. + * + * Generated from protobuf field int32 total_size = 4; + */ + protected $total_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1p1beta1\ListAssetsResponse\ListAssetsResult>|\Google\Protobuf\Internal\RepeatedField $list_assets_results + * Assets matching the list request. + * @type \Google\Protobuf\Timestamp $read_time + * Time used for executing the list request. + * @type string $next_page_token + * Token to retrieve the next page of results, or empty if there are no more + * results. + * @type int $total_size + * The total number of assets matching the query. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Assets matching the list request. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.ListAssetsResponse.ListAssetsResult list_assets_results = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getListAssetsResults() + { + return $this->list_assets_results; + } + + /** + * Assets matching the list request. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.ListAssetsResponse.ListAssetsResult list_assets_results = 1; + * @param array<\Google\Cloud\SecurityCenter\V1p1beta1\ListAssetsResponse\ListAssetsResult>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setListAssetsResults($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1p1beta1\ListAssetsResponse\ListAssetsResult::class); + $this->list_assets_results = $arr; + + return $this; + } + + /** + * Time used for executing the list request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + * @return \Google\Protobuf\Timestamp|null + */ + public function getReadTime() + { + return $this->read_time; + } + + public function hasReadTime() + { + return isset($this->read_time); + } + + public function clearReadTime() + { + unset($this->read_time); + } + + /** + * Time used for executing the list request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setReadTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->read_time = $var; + + return $this; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + + /** + * The total number of assets matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @return int + */ + public function getTotalSize() + { + return $this->total_size; + } + + /** + * The total number of assets matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @param int $var + * @return $this + */ + public function setTotalSize($var) + { + GPBUtil::checkInt32($var); + $this->total_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse/ListAssetsResult.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse/ListAssetsResult.php new file mode 100644 index 000000000000..4e9003862dd2 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse/ListAssetsResult.php @@ -0,0 +1,114 @@ +google.cloud.securitycenter.v1p1beta1.ListAssetsResponse.ListAssetsResult + */ +class ListAssetsResult extends \Google\Protobuf\Internal\Message +{ + /** + * Asset matching the search request. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Asset asset = 1; + */ + protected $asset = null; + /** + * State change of the asset between the points in time. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.ListAssetsResponse.ListAssetsResult.StateChange state_change = 2; + */ + protected $state_change = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1p1beta1\Asset $asset + * Asset matching the search request. + * @type int $state_change + * State change of the asset between the points in time. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Asset matching the search request. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Asset asset = 1; + * @return \Google\Cloud\SecurityCenter\V1p1beta1\Asset|null + */ + public function getAsset() + { + return $this->asset; + } + + public function hasAsset() + { + return isset($this->asset); + } + + public function clearAsset() + { + unset($this->asset); + } + + /** + * Asset matching the search request. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Asset asset = 1; + * @param \Google\Cloud\SecurityCenter\V1p1beta1\Asset $var + * @return $this + */ + public function setAsset($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Asset::class); + $this->asset = $var; + + return $this; + } + + /** + * State change of the asset between the points in time. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.ListAssetsResponse.ListAssetsResult.StateChange state_change = 2; + * @return int + */ + public function getStateChange() + { + return $this->state_change; + } + + /** + * State change of the asset between the points in time. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.ListAssetsResponse.ListAssetsResult.StateChange state_change = 2; + * @param int $var + * @return $this + */ + public function setStateChange($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1p1beta1\ListAssetsResponse\ListAssetsResult\StateChange::class); + $this->state_change = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ListAssetsResult::class, \Google\Cloud\SecurityCenter\V1p1beta1\ListAssetsResponse_ListAssetsResult::class); + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse/ListAssetsResult/StateChange.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse/ListAssetsResult/StateChange.php new file mode 100644 index 000000000000..2ef0a7011948 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse/ListAssetsResult/StateChange.php @@ -0,0 +1,75 @@ +google.cloud.securitycenter.v1p1beta1.ListAssetsResponse.ListAssetsResult.StateChange + */ +class StateChange +{ + /** + * State change is unused, this is the canonical default for this enum. + * + * Generated from protobuf enum UNUSED = 0; + */ + const UNUSED = 0; + /** + * Asset was added between the points in time. + * + * Generated from protobuf enum ADDED = 1; + */ + const ADDED = 1; + /** + * Asset was removed between the points in time. + * + * Generated from protobuf enum REMOVED = 2; + */ + const REMOVED = 2; + /** + * Asset was present at both point(s) in time. + * + * Generated from protobuf enum ACTIVE = 3; + */ + const ACTIVE = 3; + + private static $valueToName = [ + self::UNUSED => 'UNUSED', + self::ADDED => 'ADDED', + self::REMOVED => 'REMOVED', + self::ACTIVE => 'ACTIVE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(StateChange::class, \Google\Cloud\SecurityCenter\V1p1beta1\ListAssetsResponse_ListAssetsResult_StateChange::class); + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsRequest.php new file mode 100644 index 000000000000..a16083dde217 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsRequest.php @@ -0,0 +1,695 @@ +google.cloud.securitycenter.v1p1beta1.ListFindingsRequest + */ +class ListFindingsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the source the findings belong to. Its format is + * "organizations/[organization_id]/sources/[source_id], + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]". To list across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or + * projects/{projects_id}/sources/- + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * * severity: `=`, `:` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * security_marks.marks: `=`, `:` + * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * For example, `source_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * + * Generated from protobuf field string filter = 2; + */ + protected $filter = ''; + /** + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,source_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,source_properties.a_property" and " + * name desc , source_properties.a_property " are equivalent. + * The following fields are supported: + * name + * parent + * state + * category + * resource_name + * event_time + * source_properties + * security_marks.marks + * + * Generated from protobuf field string order_by = 3; + */ + protected $order_by = ''; + /** + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; + */ + protected $read_time = null; + /** + * When compare_duration is set, the ListFindingsResult's "state_change" + * attribute is updated to indicate whether the finding had its state changed, + * the finding's state remained unchanged, or if the finding was added in any + * state during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * Possible "state_change" values when compare_duration is specified: + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present at + * read_time. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; + */ + protected $compare_duration = null; + /** + * A field mask to specify the Finding fields to be listed in the response. + * An empty field mask will list all fields. + * + * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; + */ + protected $field_mask = null; + /** + * The value returned by the last `ListFindingsResponse`; indicates + * that this is a continuation of a prior `ListFindings` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 8; + */ + protected $page_token = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 9; + */ + protected $page_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Name of the source the findings belong to. Its format is + * "organizations/[organization_id]/sources/[source_id], + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]". To list across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or + * projects/{projects_id}/sources/- + * @type string $filter + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * * severity: `=`, `:` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * security_marks.marks: `=`, `:` + * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * For example, `source_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * @type string $order_by + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,source_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,source_properties.a_property" and " + * name desc , source_properties.a_property " are equivalent. + * The following fields are supported: + * name + * parent + * state + * category + * resource_name + * event_time + * source_properties + * security_marks.marks + * @type \Google\Protobuf\Timestamp $read_time + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * @type \Google\Protobuf\Duration $compare_duration + * When compare_duration is set, the ListFindingsResult's "state_change" + * attribute is updated to indicate whether the finding had its state changed, + * the finding's state remained unchanged, or if the finding was added in any + * state during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * Possible "state_change" values when compare_duration is specified: + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present at + * read_time. + * @type \Google\Protobuf\FieldMask $field_mask + * A field mask to specify the Finding fields to be listed in the response. + * An empty field mask will list all fields. + * @type string $page_token + * The value returned by the last `ListFindingsResponse`; indicates + * that this is a continuation of a prior `ListFindings` call, and + * that the system should return the next page of data. + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the source the findings belong to. Its format is + * "organizations/[organization_id]/sources/[source_id], + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]". To list across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or + * projects/{projects_id}/sources/- + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Name of the source the findings belong to. Its format is + * "organizations/[organization_id]/sources/[source_id], + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]". To list across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or + * projects/{projects_id}/sources/- + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * * severity: `=`, `:` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * security_marks.marks: `=`, `:` + * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * For example, `source_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * + * Generated from protobuf field string filter = 2; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * * severity: `=`, `:` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * security_marks.marks: `=`, `:` + * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * For example, `source_properties.size = 100` is a valid filter string. + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * + * Generated from protobuf field string filter = 2; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,source_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,source_properties.a_property" and " + * name desc , source_properties.a_property " are equivalent. + * The following fields are supported: + * name + * parent + * state + * category + * resource_name + * event_time + * source_properties + * security_marks.marks + * + * Generated from protobuf field string order_by = 3; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,source_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,source_properties.a_property" and " + * name desc , source_properties.a_property " are equivalent. + * The following fields are supported: + * name + * parent + * state + * category + * resource_name + * event_time + * source_properties + * security_marks.marks + * + * Generated from protobuf field string order_by = 3; + * @param string $var + * @return $this + */ + public function setOrderBy($var) + { + GPBUtil::checkString($var, True); + $this->order_by = $var; + + return $this; + } + + /** + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; + * @return \Google\Protobuf\Timestamp|null + */ + public function getReadTime() + { + return $this->read_time; + } + + public function hasReadTime() + { + return isset($this->read_time); + } + + public function clearReadTime() + { + unset($this->read_time); + } + + /** + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setReadTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->read_time = $var; + + return $this; + } + + /** + * When compare_duration is set, the ListFindingsResult's "state_change" + * attribute is updated to indicate whether the finding had its state changed, + * the finding's state remained unchanged, or if the finding was added in any + * state during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * Possible "state_change" values when compare_duration is specified: + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present at + * read_time. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; + * @return \Google\Protobuf\Duration|null + */ + public function getCompareDuration() + { + return $this->compare_duration; + } + + public function hasCompareDuration() + { + return isset($this->compare_duration); + } + + public function clearCompareDuration() + { + unset($this->compare_duration); + } + + /** + * When compare_duration is set, the ListFindingsResult's "state_change" + * attribute is updated to indicate whether the finding had its state changed, + * the finding's state remained unchanged, or if the finding was added in any + * state during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * Possible "state_change" values when compare_duration is specified: + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present at + * read_time. + * + * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setCompareDuration($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->compare_duration = $var; + + return $this; + } + + /** + * A field mask to specify the Finding fields to be listed in the response. + * An empty field mask will list all fields. + * + * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; + * @return \Google\Protobuf\FieldMask|null + */ + public function getFieldMask() + { + return $this->field_mask; + } + + public function hasFieldMask() + { + return isset($this->field_mask); + } + + public function clearFieldMask() + { + unset($this->field_mask); + } + + /** + * A field mask to specify the Finding fields to be listed in the response. + * An empty field mask will list all fields. + * + * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setFieldMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->field_mask = $var; + + return $this; + } + + /** + * The value returned by the last `ListFindingsResponse`; indicates + * that this is a continuation of a prior `ListFindings` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 8; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last `ListFindingsResponse`; indicates + * that this is a continuation of a prior `ListFindings` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 8; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 9; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 9; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse.php new file mode 100644 index 000000000000..d9166aab0298 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse.php @@ -0,0 +1,183 @@ +google.cloud.securitycenter.v1p1beta1.ListFindingsResponse + */ +class ListFindingsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Findings matching the list request. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult list_findings_results = 1; + */ + private $list_findings_results; + /** + * Time used for executing the list request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + */ + protected $read_time = null; + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + */ + protected $next_page_token = ''; + /** + * The total number of findings matching the query. + * + * Generated from protobuf field int32 total_size = 4; + */ + protected $total_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse\ListFindingsResult>|\Google\Protobuf\Internal\RepeatedField $list_findings_results + * Findings matching the list request. + * @type \Google\Protobuf\Timestamp $read_time + * Time used for executing the list request. + * @type string $next_page_token + * Token to retrieve the next page of results, or empty if there are no more + * results. + * @type int $total_size + * The total number of findings matching the query. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Findings matching the list request. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult list_findings_results = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getListFindingsResults() + { + return $this->list_findings_results; + } + + /** + * Findings matching the list request. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult list_findings_results = 1; + * @param array<\Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse\ListFindingsResult>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setListFindingsResults($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse\ListFindingsResult::class); + $this->list_findings_results = $arr; + + return $this; + } + + /** + * Time used for executing the list request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + * @return \Google\Protobuf\Timestamp|null + */ + public function getReadTime() + { + return $this->read_time; + } + + public function hasReadTime() + { + return isset($this->read_time); + } + + public function clearReadTime() + { + unset($this->read_time); + } + + /** + * Time used for executing the list request. + * + * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setReadTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->read_time = $var; + + return $this; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + + /** + * The total number of findings matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @return int + */ + public function getTotalSize() + { + return $this->total_size; + } + + /** + * The total number of findings matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @param int $var + * @return $this + */ + public function setTotalSize($var) + { + GPBUtil::checkInt32($var); + $this->total_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult.php new file mode 100644 index 000000000000..af44be50fcb1 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult.php @@ -0,0 +1,158 @@ +google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult + */ +class ListFindingsResult extends \Google\Protobuf\Internal\Message +{ + /** + * Finding matching the search request. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 1; + */ + protected $finding = null; + /** + * State change of the finding between the points in time. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult.StateChange state_change = 2; + */ + protected $state_change = 0; + /** + * Output only. Resource that is associated with this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult.Resource resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $resource = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1p1beta1\Finding $finding + * Finding matching the search request. + * @type int $state_change + * State change of the finding between the points in time. + * @type \Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse\ListFindingsResult\Resource $resource + * Output only. Resource that is associated with this finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Finding matching the search request. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 1; + * @return \Google\Cloud\SecurityCenter\V1p1beta1\Finding|null + */ + public function getFinding() + { + return $this->finding; + } + + public function hasFinding() + { + return isset($this->finding); + } + + public function clearFinding() + { + unset($this->finding); + } + + /** + * Finding matching the search request. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 1; + * @param \Google\Cloud\SecurityCenter\V1p1beta1\Finding $var + * @return $this + */ + public function setFinding($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Finding::class); + $this->finding = $var; + + return $this; + } + + /** + * State change of the finding between the points in time. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult.StateChange state_change = 2; + * @return int + */ + public function getStateChange() + { + return $this->state_change; + } + + /** + * State change of the finding between the points in time. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult.StateChange state_change = 2; + * @param int $var + * @return $this + */ + public function setStateChange($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse\ListFindingsResult\StateChange::class); + $this->state_change = $var; + + return $this; + } + + /** + * Output only. Resource that is associated with this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult.Resource resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse\ListFindingsResult\Resource|null + */ + public function getResource() + { + return $this->resource; + } + + public function hasResource() + { + return isset($this->resource); + } + + public function clearResource() + { + unset($this->resource); + } + + /** + * Output only. Resource that is associated with this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult.Resource resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse\ListFindingsResult\Resource $var + * @return $this + */ + public function setResource($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse\ListFindingsResult\Resource::class); + $this->resource = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ListFindingsResult::class, \Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse_ListFindingsResult::class); + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult/Resource.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult/Resource.php new file mode 100644 index 000000000000..64280eb4f994 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult/Resource.php @@ -0,0 +1,253 @@ +google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult.Resource + */ +class Resource extends \Google\Protobuf\Internal\Message +{ + /** + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The full resource name of project that the resource belongs to. + * + * Generated from protobuf field string project_name = 2; + */ + protected $project_name = ''; + /** + * The human readable name of project that the resource belongs to. + * + * Generated from protobuf field string project_display_name = 3; + */ + protected $project_display_name = ''; + /** + * The full resource name of resource's parent. + * + * Generated from protobuf field string parent_name = 4; + */ + protected $parent_name = ''; + /** + * The human readable name of resource's parent. + * + * Generated from protobuf field string parent_display_name = 5; + */ + protected $parent_display_name = ''; + /** + * Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is + * the folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Folder folders = 10; + */ + private $folders; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * @type string $project_name + * The full resource name of project that the resource belongs to. + * @type string $project_display_name + * The human readable name of project that the resource belongs to. + * @type string $parent_name + * The full resource name of resource's parent. + * @type string $parent_display_name + * The human readable name of resource's parent. + * @type array<\Google\Cloud\SecurityCenter\V1p1beta1\Folder>|\Google\Protobuf\Internal\RepeatedField $folders + * Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is + * the folder directly under the Organization. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The full resource name of project that the resource belongs to. + * + * Generated from protobuf field string project_name = 2; + * @return string + */ + public function getProjectName() + { + return $this->project_name; + } + + /** + * The full resource name of project that the resource belongs to. + * + * Generated from protobuf field string project_name = 2; + * @param string $var + * @return $this + */ + public function setProjectName($var) + { + GPBUtil::checkString($var, True); + $this->project_name = $var; + + return $this; + } + + /** + * The human readable name of project that the resource belongs to. + * + * Generated from protobuf field string project_display_name = 3; + * @return string + */ + public function getProjectDisplayName() + { + return $this->project_display_name; + } + + /** + * The human readable name of project that the resource belongs to. + * + * Generated from protobuf field string project_display_name = 3; + * @param string $var + * @return $this + */ + public function setProjectDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->project_display_name = $var; + + return $this; + } + + /** + * The full resource name of resource's parent. + * + * Generated from protobuf field string parent_name = 4; + * @return string + */ + public function getParentName() + { + return $this->parent_name; + } + + /** + * The full resource name of resource's parent. + * + * Generated from protobuf field string parent_name = 4; + * @param string $var + * @return $this + */ + public function setParentName($var) + { + GPBUtil::checkString($var, True); + $this->parent_name = $var; + + return $this; + } + + /** + * The human readable name of resource's parent. + * + * Generated from protobuf field string parent_display_name = 5; + * @return string + */ + public function getParentDisplayName() + { + return $this->parent_display_name; + } + + /** + * The human readable name of resource's parent. + * + * Generated from protobuf field string parent_display_name = 5; + * @param string $var + * @return $this + */ + public function setParentDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->parent_display_name = $var; + + return $this; + } + + /** + * Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is + * the folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Folder folders = 10; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFolders() + { + return $this->folders; + } + + /** + * Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is + * the folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Folder folders = 10; + * @param array<\Google\Cloud\SecurityCenter\V1p1beta1\Folder>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFolders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1p1beta1\Folder::class); + $this->folders = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Resource::class, \Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse_ListFindingsResult_Resource::class); + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult/StateChange.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult/StateChange.php new file mode 100644 index 000000000000..4f8ad2507ab2 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult/StateChange.php @@ -0,0 +1,87 @@ +google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult.StateChange + */ +class StateChange +{ + /** + * State change is unused, this is the canonical default for this enum. + * + * Generated from protobuf enum UNUSED = 0; + */ + const UNUSED = 0; + /** + * The finding has changed state in some way between the points in time + * and existed at both points. + * + * Generated from protobuf enum CHANGED = 1; + */ + const CHANGED = 1; + /** + * The finding has not changed state between the points in time and + * existed at both points. + * + * Generated from protobuf enum UNCHANGED = 2; + */ + const UNCHANGED = 2; + /** + * The finding was created between the points in time. + * + * Generated from protobuf enum ADDED = 3; + */ + const ADDED = 3; + /** + * The finding at timestamp does not match the filter specified, but it + * did at timestamp - compare_duration. + * + * Generated from protobuf enum REMOVED = 4; + */ + const REMOVED = 4; + + private static $valueToName = [ + self::UNUSED => 'UNUSED', + self::CHANGED => 'CHANGED', + self::UNCHANGED => 'UNCHANGED', + self::ADDED => 'ADDED', + self::REMOVED => 'REMOVED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(StateChange::class, \Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse_ListFindingsResult_StateChange::class); + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListNotificationConfigsRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListNotificationConfigsRequest.php new file mode 100644 index 000000000000..de399ce20dfe --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListNotificationConfigsRequest.php @@ -0,0 +1,151 @@ +google.cloud.securitycenter.v1p1beta1.ListNotificationConfigsRequest + */ +class ListNotificationConfigsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the organization to list notification configs. + * Its format is "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The value returned by the last `ListNotificationConfigsResponse`; indicates + * that this is a continuation of a prior `ListNotificationConfigs` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 2; + */ + protected $page_token = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 3; + */ + protected $page_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Name of the organization to list notification configs. + * Its format is "organizations/[organization_id]". + * @type string $page_token + * The value returned by the last `ListNotificationConfigsResponse`; indicates + * that this is a continuation of a prior `ListNotificationConfigs` call, and + * that the system should return the next page of data. + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the organization to list notification configs. + * Its format is "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Name of the organization to list notification configs. + * Its format is "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The value returned by the last `ListNotificationConfigsResponse`; indicates + * that this is a continuation of a prior `ListNotificationConfigs` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 2; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last `ListNotificationConfigsResponse`; indicates + * that this is a continuation of a prior `ListNotificationConfigs` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 2; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 3; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 3; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListNotificationConfigsResponse.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListNotificationConfigsResponse.php new file mode 100644 index 000000000000..89c6439423d1 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListNotificationConfigsResponse.php @@ -0,0 +1,105 @@ +google.cloud.securitycenter.v1p1beta1.ListNotificationConfigsResponse + */ +class ListNotificationConfigsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Notification configs belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.NotificationConfig notification_configs = 1; + */ + private $notification_configs; + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig>|\Google\Protobuf\Internal\RepeatedField $notification_configs + * Notification configs belonging to the requested parent. + * @type string $next_page_token + * Token to retrieve the next page of results, or empty if there are no more + * results. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Notification configs belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.NotificationConfig notification_configs = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getNotificationConfigs() + { + return $this->notification_configs; + } + + /** + * Notification configs belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.NotificationConfig notification_configs = 1; + * @param array<\Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setNotificationConfigs($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig::class); + $this->notification_configs = $arr; + + return $this; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListSourcesRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListSourcesRequest.php new file mode 100644 index 000000000000..9a7274d12191 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListSourcesRequest.php @@ -0,0 +1,155 @@ +google.cloud.securitycenter.v1p1beta1.ListSourcesRequest + */ +class ListSourcesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the parent of sources to list. Its format should be + * "organizations/[organization_id], folders/[folder_id], or + * projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The value returned by the last `ListSourcesResponse`; indicates + * that this is a continuation of a prior `ListSources` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 2; + */ + protected $page_token = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 7; + */ + protected $page_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Resource name of the parent of sources to list. Its format should be + * "organizations/[organization_id], folders/[folder_id], or + * projects/[project_id]". + * @type string $page_token + * The value returned by the last `ListSourcesResponse`; indicates + * that this is a continuation of a prior `ListSources` call, and + * that the system should return the next page of data. + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the parent of sources to list. Its format should be + * "organizations/[organization_id], folders/[folder_id], or + * projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Resource name of the parent of sources to list. Its format should be + * "organizations/[organization_id], folders/[folder_id], or + * projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The value returned by the last `ListSourcesResponse`; indicates + * that this is a continuation of a prior `ListSources` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 2; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last `ListSourcesResponse`; indicates + * that this is a continuation of a prior `ListSources` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 2; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 7; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 7; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListSourcesResponse.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListSourcesResponse.php new file mode 100644 index 000000000000..da561e81ec42 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListSourcesResponse.php @@ -0,0 +1,105 @@ +google.cloud.securitycenter.v1p1beta1.ListSourcesResponse + */ +class ListSourcesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Sources belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Source sources = 1; + */ + private $sources; + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V1p1beta1\Source>|\Google\Protobuf\Internal\RepeatedField $sources + * Sources belonging to the requested parent. + * @type string $next_page_token + * Token to retrieve the next page of results, or empty if there are no more + * results. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Sources belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Source sources = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSources() + { + return $this->sources; + } + + /** + * Sources belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Source sources = 1; + * @param array<\Google\Cloud\SecurityCenter\V1p1beta1\Source>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSources($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1p1beta1\Source::class); + $this->sources = $arr; + + return $this; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig.php new file mode 100644 index 000000000000..4c365622d5b1 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig.php @@ -0,0 +1,268 @@ +google.cloud.securitycenter.v1p1beta1.NotificationConfig + */ +class NotificationConfig extends \Google\Protobuf\Internal\Message +{ + /** + * The relative resource name of this notification config. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/notificationConfigs/notify_public_bucket". + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The description of the notification config (max of 1024 characters). + * + * Generated from protobuf field string description = 2; + */ + protected $description = ''; + /** + * The type of events the config is for, e.g. FINDING. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig.EventType event_type = 3; + */ + protected $event_type = 0; + /** + * The Pub/Sub topic to send notifications to. Its format is + * "projects/[project_id]/topics/[topic]". + * + * Generated from protobuf field string pubsub_topic = 4 [(.google.api.resource_reference) = { + */ + protected $pubsub_topic = ''; + /** + * Output only. The service account that needs "pubsub.topics.publish" + * permission to publish to the Pub/Sub topic. + * + * Generated from protobuf field string service_account = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $service_account = ''; + protected $notify_config; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The relative resource name of this notification config. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/notificationConfigs/notify_public_bucket". + * @type string $description + * The description of the notification config (max of 1024 characters). + * @type int $event_type + * The type of events the config is for, e.g. FINDING. + * @type string $pubsub_topic + * The Pub/Sub topic to send notifications to. Its format is + * "projects/[project_id]/topics/[topic]". + * @type string $service_account + * Output only. The service account that needs "pubsub.topics.publish" + * permission to publish to the Pub/Sub topic. + * @type \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig\StreamingConfig $streaming_config + * The config for triggering streaming-based notifications. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\NotificationConfig::initOnce(); + parent::__construct($data); + } + + /** + * The relative resource name of this notification config. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/notificationConfigs/notify_public_bucket". + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The relative resource name of this notification config. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/notificationConfigs/notify_public_bucket". + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The description of the notification config (max of 1024 characters). + * + * Generated from protobuf field string description = 2; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * The description of the notification config (max of 1024 characters). + * + * Generated from protobuf field string description = 2; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * The type of events the config is for, e.g. FINDING. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig.EventType event_type = 3; + * @return int + */ + public function getEventType() + { + return $this->event_type; + } + + /** + * The type of events the config is for, e.g. FINDING. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig.EventType event_type = 3; + * @param int $var + * @return $this + */ + public function setEventType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig\EventType::class); + $this->event_type = $var; + + return $this; + } + + /** + * The Pub/Sub topic to send notifications to. Its format is + * "projects/[project_id]/topics/[topic]". + * + * Generated from protobuf field string pubsub_topic = 4 [(.google.api.resource_reference) = { + * @return string + */ + public function getPubsubTopic() + { + return $this->pubsub_topic; + } + + /** + * The Pub/Sub topic to send notifications to. Its format is + * "projects/[project_id]/topics/[topic]". + * + * Generated from protobuf field string pubsub_topic = 4 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setPubsubTopic($var) + { + GPBUtil::checkString($var, True); + $this->pubsub_topic = $var; + + return $this; + } + + /** + * Output only. The service account that needs "pubsub.topics.publish" + * permission to publish to the Pub/Sub topic. + * + * Generated from protobuf field string service_account = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getServiceAccount() + { + return $this->service_account; + } + + /** + * Output only. The service account that needs "pubsub.topics.publish" + * permission to publish to the Pub/Sub topic. + * + * Generated from protobuf field string service_account = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setServiceAccount($var) + { + GPBUtil::checkString($var, True); + $this->service_account = $var; + + return $this; + } + + /** + * The config for triggering streaming-based notifications. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig.StreamingConfig streaming_config = 6; + * @return \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig\StreamingConfig|null + */ + public function getStreamingConfig() + { + return $this->readOneof(6); + } + + public function hasStreamingConfig() + { + return $this->hasOneof(6); + } + + /** + * The config for triggering streaming-based notifications. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig.StreamingConfig streaming_config = 6; + * @param \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig\StreamingConfig $var + * @return $this + */ + public function setStreamingConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig\StreamingConfig::class); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * @return string + */ + public function getNotifyConfig() + { + return $this->whichOneof("notify_config"); + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig/EventType.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig/EventType.php new file mode 100644 index 000000000000..0b27a01f5961 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig/EventType.php @@ -0,0 +1,57 @@ +google.cloud.securitycenter.v1p1beta1.NotificationConfig.EventType + */ +class EventType +{ + /** + * Unspecified event type. + * + * Generated from protobuf enum EVENT_TYPE_UNSPECIFIED = 0; + */ + const EVENT_TYPE_UNSPECIFIED = 0; + /** + * Events for findings. + * + * Generated from protobuf enum FINDING = 1; + */ + const FINDING = 1; + + private static $valueToName = [ + self::EVENT_TYPE_UNSPECIFIED => 'EVENT_TYPE_UNSPECIFIED', + self::FINDING => 'FINDING', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(EventType::class, \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig_EventType::class); + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig/StreamingConfig.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig/StreamingConfig.php new file mode 100644 index 000000000000..448267a7d500 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig/StreamingConfig.php @@ -0,0 +1,131 @@ +google.cloud.securitycenter.v1p1beta1.NotificationConfig.StreamingConfig + */ +class StreamingConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Expression that defines the filter to apply across create/update events + * of assets or findings as specified by the event type. The expression is a + * list of zero or more restrictions combined via logical operators `AND` + * and `OR`. Parentheses are supported, and `OR` has higher precedence than + * `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 1; + */ + protected $filter = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $filter + * Expression that defines the filter to apply across create/update events + * of assets or findings as specified by the event type. The expression is a + * list of zero or more restrictions combined via logical operators `AND` + * and `OR`. Parentheses are supported, and `OR` has higher precedence than + * `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\NotificationConfig::initOnce(); + parent::__construct($data); + } + + /** + * Expression that defines the filter to apply across create/update events + * of assets or findings as specified by the event type. The expression is a + * list of zero or more restrictions combined via logical operators `AND` + * and `OR`. Parentheses are supported, and `OR` has higher precedence than + * `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 1; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Expression that defines the filter to apply across create/update events + * of assets or findings as specified by the event type. The expression is a + * list of zero or more restrictions combined via logical operators `AND` + * and `OR`. Parentheses are supported, and `OR` has higher precedence than + * `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 1; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(StreamingConfig::class, \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig_StreamingConfig::class); + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationMessage.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationMessage.php new file mode 100644 index 000000000000..b5483ae0f269 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationMessage.php @@ -0,0 +1,156 @@ +google.cloud.securitycenter.v1p1beta1.NotificationMessage + */ +class NotificationMessage extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the notification config that generated current notification. + * + * Generated from protobuf field string notification_config_name = 1; + */ + protected $notification_config_name = ''; + /** + * The Cloud resource tied to the notification. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Resource resource = 3; + */ + protected $resource = null; + protected $event; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $notification_config_name + * Name of the notification config that generated current notification. + * @type \Google\Cloud\SecurityCenter\V1p1beta1\Finding $finding + * If it's a Finding based notification config, this field will be + * populated. + * @type \Google\Cloud\SecurityCenter\V1p1beta1\Resource $resource + * The Cloud resource tied to the notification. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\NotificationMessage::initOnce(); + parent::__construct($data); + } + + /** + * Name of the notification config that generated current notification. + * + * Generated from protobuf field string notification_config_name = 1; + * @return string + */ + public function getNotificationConfigName() + { + return $this->notification_config_name; + } + + /** + * Name of the notification config that generated current notification. + * + * Generated from protobuf field string notification_config_name = 1; + * @param string $var + * @return $this + */ + public function setNotificationConfigName($var) + { + GPBUtil::checkString($var, True); + $this->notification_config_name = $var; + + return $this; + } + + /** + * If it's a Finding based notification config, this field will be + * populated. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 2; + * @return \Google\Cloud\SecurityCenter\V1p1beta1\Finding|null + */ + public function getFinding() + { + return $this->readOneof(2); + } + + public function hasFinding() + { + return $this->hasOneof(2); + } + + /** + * If it's a Finding based notification config, this field will be + * populated. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 2; + * @param \Google\Cloud\SecurityCenter\V1p1beta1\Finding $var + * @return $this + */ + public function setFinding($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Finding::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * The Cloud resource tied to the notification. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Resource resource = 3; + * @return \Google\Cloud\SecurityCenter\V1p1beta1\Resource|null + */ + public function getResource() + { + return $this->resource; + } + + public function hasResource() + { + return isset($this->resource); + } + + public function clearResource() + { + unset($this->resource); + } + + /** + * The Cloud resource tied to the notification. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Resource resource = 3; + * @param \Google\Cloud\SecurityCenter\V1p1beta1\Resource $var + * @return $this + */ + public function setResource($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Resource::class); + $this->resource = $var; + + return $this; + } + + /** + * @return string + */ + public function getEvent() + { + return $this->whichOneof("event"); + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings.php new file mode 100644 index 000000000000..ad4b7cd0210c --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings.php @@ -0,0 +1,170 @@ +google.cloud.securitycenter.v1p1beta1.OrganizationSettings + */ +class OrganizationSettings extends \Google\Protobuf\Internal\Message +{ + /** + * The relative resource name of the settings. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/organizationSettings". + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * A flag that indicates if Asset Discovery should be enabled. If the flag is + * set to `true`, then discovery of assets will occur. If it is set to `false, + * all historical assets will remain, but discovery of future assets will not + * occur. + * + * Generated from protobuf field bool enable_asset_discovery = 2; + */ + protected $enable_asset_discovery = false; + /** + * The configuration used for Asset Discovery runs. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.OrganizationSettings.AssetDiscoveryConfig asset_discovery_config = 3; + */ + protected $asset_discovery_config = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The relative resource name of the settings. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/organizationSettings". + * @type bool $enable_asset_discovery + * A flag that indicates if Asset Discovery should be enabled. If the flag is + * set to `true`, then discovery of assets will occur. If it is set to `false, + * all historical assets will remain, but discovery of future assets will not + * occur. + * @type \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings\AssetDiscoveryConfig $asset_discovery_config + * The configuration used for Asset Discovery runs. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\OrganizationSettings::initOnce(); + parent::__construct($data); + } + + /** + * The relative resource name of the settings. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/organizationSettings". + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The relative resource name of the settings. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/organizationSettings". + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * A flag that indicates if Asset Discovery should be enabled. If the flag is + * set to `true`, then discovery of assets will occur. If it is set to `false, + * all historical assets will remain, but discovery of future assets will not + * occur. + * + * Generated from protobuf field bool enable_asset_discovery = 2; + * @return bool + */ + public function getEnableAssetDiscovery() + { + return $this->enable_asset_discovery; + } + + /** + * A flag that indicates if Asset Discovery should be enabled. If the flag is + * set to `true`, then discovery of assets will occur. If it is set to `false, + * all historical assets will remain, but discovery of future assets will not + * occur. + * + * Generated from protobuf field bool enable_asset_discovery = 2; + * @param bool $var + * @return $this + */ + public function setEnableAssetDiscovery($var) + { + GPBUtil::checkBool($var); + $this->enable_asset_discovery = $var; + + return $this; + } + + /** + * The configuration used for Asset Discovery runs. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.OrganizationSettings.AssetDiscoveryConfig asset_discovery_config = 3; + * @return \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings\AssetDiscoveryConfig|null + */ + public function getAssetDiscoveryConfig() + { + return $this->asset_discovery_config; + } + + public function hasAssetDiscoveryConfig() + { + return isset($this->asset_discovery_config); + } + + public function clearAssetDiscoveryConfig() + { + unset($this->asset_discovery_config); + } + + /** + * The configuration used for Asset Discovery runs. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.OrganizationSettings.AssetDiscoveryConfig asset_discovery_config = 3; + * @param \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings\AssetDiscoveryConfig $var + * @return $this + */ + public function setAssetDiscoveryConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings\AssetDiscoveryConfig::class); + $this->asset_discovery_config = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings/AssetDiscoveryConfig.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings/AssetDiscoveryConfig.php new file mode 100644 index 000000000000..c6eb1dfedea0 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings/AssetDiscoveryConfig.php @@ -0,0 +1,142 @@ +google.cloud.securitycenter.v1p1beta1.OrganizationSettings.AssetDiscoveryConfig + */ +class AssetDiscoveryConfig extends \Google\Protobuf\Internal\Message +{ + /** + * The project ids to use for filtering asset discovery. + * + * Generated from protobuf field repeated string project_ids = 1; + */ + private $project_ids; + /** + * The mode to use for filtering asset discovery. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.OrganizationSettings.AssetDiscoveryConfig.InclusionMode inclusion_mode = 2; + */ + protected $inclusion_mode = 0; + /** + * The folder ids to use for filtering asset discovery. + * It consists of only digits, e.g., 756619654966. + * + * Generated from protobuf field repeated string folder_ids = 3; + */ + private $folder_ids; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\RepeatedField $project_ids + * The project ids to use for filtering asset discovery. + * @type int $inclusion_mode + * The mode to use for filtering asset discovery. + * @type array|\Google\Protobuf\Internal\RepeatedField $folder_ids + * The folder ids to use for filtering asset discovery. + * It consists of only digits, e.g., 756619654966. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\OrganizationSettings::initOnce(); + parent::__construct($data); + } + + /** + * The project ids to use for filtering asset discovery. + * + * Generated from protobuf field repeated string project_ids = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getProjectIds() + { + return $this->project_ids; + } + + /** + * The project ids to use for filtering asset discovery. + * + * Generated from protobuf field repeated string project_ids = 1; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setProjectIds($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->project_ids = $arr; + + return $this; + } + + /** + * The mode to use for filtering asset discovery. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.OrganizationSettings.AssetDiscoveryConfig.InclusionMode inclusion_mode = 2; + * @return int + */ + public function getInclusionMode() + { + return $this->inclusion_mode; + } + + /** + * The mode to use for filtering asset discovery. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.OrganizationSettings.AssetDiscoveryConfig.InclusionMode inclusion_mode = 2; + * @param int $var + * @return $this + */ + public function setInclusionMode($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings\AssetDiscoveryConfig\InclusionMode::class); + $this->inclusion_mode = $var; + + return $this; + } + + /** + * The folder ids to use for filtering asset discovery. + * It consists of only digits, e.g., 756619654966. + * + * Generated from protobuf field repeated string folder_ids = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFolderIds() + { + return $this->folder_ids; + } + + /** + * The folder ids to use for filtering asset discovery. + * It consists of only digits, e.g., 756619654966. + * + * Generated from protobuf field repeated string folder_ids = 3; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFolderIds($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->folder_ids = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AssetDiscoveryConfig::class, \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings_AssetDiscoveryConfig::class); + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings/AssetDiscoveryConfig/InclusionMode.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings/AssetDiscoveryConfig/InclusionMode.php new file mode 100644 index 000000000000..2e218d0692dc --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings/AssetDiscoveryConfig/InclusionMode.php @@ -0,0 +1,74 @@ +google.cloud.securitycenter.v1p1beta1.OrganizationSettings.AssetDiscoveryConfig.InclusionMode + */ +class InclusionMode +{ + /** + * Unspecified. Setting the mode with this value will disable + * inclusion/exclusion filtering for Asset Discovery. + * + * Generated from protobuf enum INCLUSION_MODE_UNSPECIFIED = 0; + */ + const INCLUSION_MODE_UNSPECIFIED = 0; + /** + * Asset Discovery will capture only the resources within the projects + * specified. All other resources will be ignored. + * + * Generated from protobuf enum INCLUDE_ONLY = 1; + */ + const INCLUDE_ONLY = 1; + /** + * Asset Discovery will ignore all resources under the projects specified. + * All other resources will be retrieved. + * + * Generated from protobuf enum EXCLUDE = 2; + */ + const EXCLUDE = 2; + + private static $valueToName = [ + self::INCLUSION_MODE_UNSPECIFIED => 'INCLUSION_MODE_UNSPECIFIED', + self::INCLUDE_ONLY => 'INCLUDE_ONLY', + self::EXCLUDE => 'EXCLUDE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(InclusionMode::class, \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings_AssetDiscoveryConfig_InclusionMode::class); + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Resource.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Resource.php new file mode 100644 index 000000000000..1ac6538b8c8d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Resource.php @@ -0,0 +1,249 @@ +google.cloud.securitycenter.v1p1beta1.Resource + */ +class Resource extends \Google\Protobuf\Internal\Message +{ + /** + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The full resource name of project that the resource belongs to. + * + * Generated from protobuf field string project = 2; + */ + protected $project = ''; + /** + * The human readable name of project that the resource belongs to. + * + * Generated from protobuf field string project_display_name = 3; + */ + protected $project_display_name = ''; + /** + * The full resource name of resource's parent. + * + * Generated from protobuf field string parent = 4; + */ + protected $parent = ''; + /** + * The human readable name of resource's parent. + * + * Generated from protobuf field string parent_display_name = 5; + */ + protected $parent_display_name = ''; + /** + * Output only. Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is the + * folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Folder folders = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $folders; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * @type string $project + * The full resource name of project that the resource belongs to. + * @type string $project_display_name + * The human readable name of project that the resource belongs to. + * @type string $parent + * The full resource name of resource's parent. + * @type string $parent_display_name + * The human readable name of resource's parent. + * @type array<\Google\Cloud\SecurityCenter\V1p1beta1\Folder>|\Google\Protobuf\Internal\RepeatedField $folders + * Output only. Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is the + * folder directly under the Organization. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\Resource::initOnce(); + parent::__construct($data); + } + + /** + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The full resource name of project that the resource belongs to. + * + * Generated from protobuf field string project = 2; + * @return string + */ + public function getProject() + { + return $this->project; + } + + /** + * The full resource name of project that the resource belongs to. + * + * Generated from protobuf field string project = 2; + * @param string $var + * @return $this + */ + public function setProject($var) + { + GPBUtil::checkString($var, True); + $this->project = $var; + + return $this; + } + + /** + * The human readable name of project that the resource belongs to. + * + * Generated from protobuf field string project_display_name = 3; + * @return string + */ + public function getProjectDisplayName() + { + return $this->project_display_name; + } + + /** + * The human readable name of project that the resource belongs to. + * + * Generated from protobuf field string project_display_name = 3; + * @param string $var + * @return $this + */ + public function setProjectDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->project_display_name = $var; + + return $this; + } + + /** + * The full resource name of resource's parent. + * + * Generated from protobuf field string parent = 4; + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * The full resource name of resource's parent. + * + * Generated from protobuf field string parent = 4; + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The human readable name of resource's parent. + * + * Generated from protobuf field string parent_display_name = 5; + * @return string + */ + public function getParentDisplayName() + { + return $this->parent_display_name; + } + + /** + * The human readable name of resource's parent. + * + * Generated from protobuf field string parent_display_name = 5; + * @param string $var + * @return $this + */ + public function setParentDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->parent_display_name = $var; + + return $this; + } + + /** + * Output only. Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is the + * folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Folder folders = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFolders() + { + return $this->folders; + } + + /** + * Output only. Contains a Folder message for each folder in the assets ancestry. + * The first folder is the deepest nested folder, and the last folder is the + * folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Folder folders = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param array<\Google\Cloud\SecurityCenter\V1p1beta1\Folder>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFolders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1p1beta1\Folder::class); + $this->folders = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryRequest.php new file mode 100644 index 000000000000..7cf38c3e5319 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryRequest.php @@ -0,0 +1,71 @@ +google.cloud.securitycenter.v1p1beta1.RunAssetDiscoveryRequest + */ +class RunAssetDiscoveryRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the organization to run asset discovery for. Its format is + * "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Name of the organization to run asset discovery for. Its format is + * "organizations/[organization_id]". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the organization to run asset discovery for. Its format is + * "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Name of the organization to run asset discovery for. Its format is + * "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryResponse.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryResponse.php new file mode 100644 index 000000000000..3e04eb554e2a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryResponse.php @@ -0,0 +1,111 @@ +google.cloud.securitycenter.v1p1beta1.RunAssetDiscoveryResponse + */ +class RunAssetDiscoveryResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The state of an asset discovery run. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.RunAssetDiscoveryResponse.State state = 1; + */ + protected $state = 0; + /** + * The duration between asset discovery run start and end + * + * Generated from protobuf field .google.protobuf.Duration duration = 2; + */ + protected $duration = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $state + * The state of an asset discovery run. + * @type \Google\Protobuf\Duration $duration + * The duration between asset discovery run start and end + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\RunAssetDiscoveryResponse::initOnce(); + parent::__construct($data); + } + + /** + * The state of an asset discovery run. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.RunAssetDiscoveryResponse.State state = 1; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * The state of an asset discovery run. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.RunAssetDiscoveryResponse.State state = 1; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1p1beta1\RunAssetDiscoveryResponse\State::class); + $this->state = $var; + + return $this; + } + + /** + * The duration between asset discovery run start and end + * + * Generated from protobuf field .google.protobuf.Duration duration = 2; + * @return \Google\Protobuf\Duration|null + */ + public function getDuration() + { + return $this->duration; + } + + public function hasDuration() + { + return isset($this->duration); + } + + public function clearDuration() + { + unset($this->duration); + } + + /** + * The duration between asset discovery run start and end + * + * Generated from protobuf field .google.protobuf.Duration duration = 2; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setDuration($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->duration = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryResponse/State.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryResponse/State.php new file mode 100644 index 000000000000..ca26f2bcbecd --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryResponse/State.php @@ -0,0 +1,72 @@ +google.cloud.securitycenter.v1p1beta1.RunAssetDiscoveryResponse.State + */ +class State +{ + /** + * Asset discovery run state was unspecified. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * Asset discovery run completed successfully. + * + * Generated from protobuf enum COMPLETED = 1; + */ + const COMPLETED = 1; + /** + * Asset discovery run was cancelled with tasks still pending, as another + * run for the same organization was started with a higher priority. + * + * Generated from protobuf enum SUPERSEDED = 2; + */ + const SUPERSEDED = 2; + /** + * Asset discovery run was killed and terminated. + * + * Generated from protobuf enum TERMINATED = 3; + */ + const TERMINATED = 3; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::COMPLETED => 'COMPLETED', + self::SUPERSEDED => 'SUPERSEDED', + self::TERMINATED => 'TERMINATED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(State::class, \Google\Cloud\SecurityCenter\V1p1beta1\RunAssetDiscoveryResponse_State::class); + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/SecurityMarks.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/SecurityMarks.php new file mode 100644 index 000000000000..764bcfd68bb2 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/SecurityMarks.php @@ -0,0 +1,206 @@ +google.cloud.securitycenter.v1p1beta1.SecurityMarks + */ +class SecurityMarks extends \Google\Protobuf\Internal\Message +{ + /** + * The relative resource name of the SecurityMarks. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Examples: + * "organizations/{organization_id}/assets/{asset_id}/securityMarks" + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks". + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Mutable user specified security marks belonging to the parent resource. + * Constraints are as follows: + * * Keys and values are treated as case insensitive + * * Keys must be between 1 - 256 characters (inclusive) + * * Keys must be letters, numbers, underscores, or dashes + * * Values have leading and trailing whitespace trimmed, remaining + * characters must be between 1 - 4096 characters (inclusive) + * + * Generated from protobuf field map marks = 2; + */ + private $marks; + /** + * The canonical name of the marks. + * Examples: + * "organizations/{organization_id}/assets/{asset_id}/securityMarks" + * "folders/{folder_id}/assets/{asset_id}/securityMarks" + * "projects/{project_number}/assets/{asset_id}/securityMarks" + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks" + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks" + * "projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks" + * + * Generated from protobuf field string canonical_name = 3; + */ + protected $canonical_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The relative resource name of the SecurityMarks. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Examples: + * "organizations/{organization_id}/assets/{asset_id}/securityMarks" + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks". + * @type array|\Google\Protobuf\Internal\MapField $marks + * Mutable user specified security marks belonging to the parent resource. + * Constraints are as follows: + * * Keys and values are treated as case insensitive + * * Keys must be between 1 - 256 characters (inclusive) + * * Keys must be letters, numbers, underscores, or dashes + * * Values have leading and trailing whitespace trimmed, remaining + * characters must be between 1 - 4096 characters (inclusive) + * @type string $canonical_name + * The canonical name of the marks. + * Examples: + * "organizations/{organization_id}/assets/{asset_id}/securityMarks" + * "folders/{folder_id}/assets/{asset_id}/securityMarks" + * "projects/{project_number}/assets/{asset_id}/securityMarks" + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks" + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks" + * "projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks" + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecurityMarks::initOnce(); + parent::__construct($data); + } + + /** + * The relative resource name of the SecurityMarks. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Examples: + * "organizations/{organization_id}/assets/{asset_id}/securityMarks" + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks". + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The relative resource name of the SecurityMarks. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Examples: + * "organizations/{organization_id}/assets/{asset_id}/securityMarks" + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks". + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Mutable user specified security marks belonging to the parent resource. + * Constraints are as follows: + * * Keys and values are treated as case insensitive + * * Keys must be between 1 - 256 characters (inclusive) + * * Keys must be letters, numbers, underscores, or dashes + * * Values have leading and trailing whitespace trimmed, remaining + * characters must be between 1 - 4096 characters (inclusive) + * + * Generated from protobuf field map marks = 2; + * @return \Google\Protobuf\Internal\MapField + */ + public function getMarks() + { + return $this->marks; + } + + /** + * Mutable user specified security marks belonging to the parent resource. + * Constraints are as follows: + * * Keys and values are treated as case insensitive + * * Keys must be between 1 - 256 characters (inclusive) + * * Keys must be letters, numbers, underscores, or dashes + * * Values have leading and trailing whitespace trimmed, remaining + * characters must be between 1 - 4096 characters (inclusive) + * + * Generated from protobuf field map marks = 2; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setMarks($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); + $this->marks = $arr; + + return $this; + } + + /** + * The canonical name of the marks. + * Examples: + * "organizations/{organization_id}/assets/{asset_id}/securityMarks" + * "folders/{folder_id}/assets/{asset_id}/securityMarks" + * "projects/{project_number}/assets/{asset_id}/securityMarks" + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks" + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks" + * "projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks" + * + * Generated from protobuf field string canonical_name = 3; + * @return string + */ + public function getCanonicalName() + { + return $this->canonical_name; + } + + /** + * The canonical name of the marks. + * Examples: + * "organizations/{organization_id}/assets/{asset_id}/securityMarks" + * "folders/{folder_id}/assets/{asset_id}/securityMarks" + * "projects/{project_number}/assets/{asset_id}/securityMarks" + * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks" + * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks" + * "projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks" + * + * Generated from protobuf field string canonical_name = 3; + * @param string $var + * @return $this + */ + public function setCanonicalName($var) + { + GPBUtil::checkString($var, True); + $this->canonical_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/SetFindingStateRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/SetFindingStateRequest.php new file mode 100644 index 000000000000..b4da815ef956 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/SetFindingStateRequest.php @@ -0,0 +1,157 @@ +google.cloud.securitycenter.v1p1beta1.SetFindingStateRequest + */ +class SetFindingStateRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The relative resource name of the finding. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}/finding/{finding_id}". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Required. The desired State of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding.State state = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $state = 0; + /** + * Required. The time at which the updated state takes effect. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $start_time = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The relative resource name of the finding. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}/finding/{finding_id}". + * @type int $state + * Required. The desired State of the finding. + * @type \Google\Protobuf\Timestamp $start_time + * Required. The time at which the updated state takes effect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The relative resource name of the finding. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}/finding/{finding_id}". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The relative resource name of the finding. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}/finding/{finding_id}". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Required. The desired State of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding.State state = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Required. The desired State of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding.State state = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1p1beta1\Finding\State::class); + $this->state = $var; + + return $this; + } + + /** + * Required. The time at which the updated state takes effect. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getStartTime() + { + return $this->start_time; + } + + public function hasStartTime() + { + return isset($this->start_time); + } + + public function clearStartTime() + { + unset($this->start_time); + } + + /** + * Required. The time at which the updated state takes effect. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setStartTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->start_time = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Source.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Source.php new file mode 100644 index 000000000000..494d5ccd87d0 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Source.php @@ -0,0 +1,243 @@ +google.cloud.securitycenter.v1p1beta1.Source + */ +class Source extends \Google\Protobuf\Internal\Message +{ + /** + * The relative resource name of this source. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}" + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The source's display name. + * A source's display name must be unique amongst its siblings, for example, + * two sources with the same parent can't share the same display name. + * The display name must have a length between 1 and 64 characters + * (inclusive). + * + * Generated from protobuf field string display_name = 2; + */ + protected $display_name = ''; + /** + * The description of the source (max of 1024 characters). + * Example: + * "Web Security Scanner is a web security scanner for common + * vulnerabilities in App Engine applications. It can automatically + * scan and detect four common vulnerabilities, including cross-site-scripting + * (XSS), Flash injection, mixed content (HTTP in HTTPS), and + * outdated/insecure libraries." + * + * Generated from protobuf field string description = 3; + */ + protected $description = ''; + /** + * The canonical name of the finding. It's either + * "organizations/{organization_id}/sources/{source_id}", + * "folders/{folder_id}/sources/{source_id}" or + * "projects/{project_number}/sources/{source_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * + * Generated from protobuf field string canonical_name = 14; + */ + protected $canonical_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The relative resource name of this source. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}" + * @type string $display_name + * The source's display name. + * A source's display name must be unique amongst its siblings, for example, + * two sources with the same parent can't share the same display name. + * The display name must have a length between 1 and 64 characters + * (inclusive). + * @type string $description + * The description of the source (max of 1024 characters). + * Example: + * "Web Security Scanner is a web security scanner for common + * vulnerabilities in App Engine applications. It can automatically + * scan and detect four common vulnerabilities, including cross-site-scripting + * (XSS), Flash injection, mixed content (HTTP in HTTPS), and + * outdated/insecure libraries." + * @type string $canonical_name + * The canonical name of the finding. It's either + * "organizations/{organization_id}/sources/{source_id}", + * "folders/{folder_id}/sources/{source_id}" or + * "projects/{project_number}/sources/{source_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\Source::initOnce(); + parent::__construct($data); + } + + /** + * The relative resource name of this source. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}" + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The relative resource name of this source. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}" + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The source's display name. + * A source's display name must be unique amongst its siblings, for example, + * two sources with the same parent can't share the same display name. + * The display name must have a length between 1 and 64 characters + * (inclusive). + * + * Generated from protobuf field string display_name = 2; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * The source's display name. + * A source's display name must be unique amongst its siblings, for example, + * two sources with the same parent can't share the same display name. + * The display name must have a length between 1 and 64 characters + * (inclusive). + * + * Generated from protobuf field string display_name = 2; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * The description of the source (max of 1024 characters). + * Example: + * "Web Security Scanner is a web security scanner for common + * vulnerabilities in App Engine applications. It can automatically + * scan and detect four common vulnerabilities, including cross-site-scripting + * (XSS), Flash injection, mixed content (HTTP in HTTPS), and + * outdated/insecure libraries." + * + * Generated from protobuf field string description = 3; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * The description of the source (max of 1024 characters). + * Example: + * "Web Security Scanner is a web security scanner for common + * vulnerabilities in App Engine applications. It can automatically + * scan and detect four common vulnerabilities, including cross-site-scripting + * (XSS), Flash injection, mixed content (HTTP in HTTPS), and + * outdated/insecure libraries." + * + * Generated from protobuf field string description = 3; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * The canonical name of the finding. It's either + * "organizations/{organization_id}/sources/{source_id}", + * "folders/{folder_id}/sources/{source_id}" or + * "projects/{project_number}/sources/{source_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * + * Generated from protobuf field string canonical_name = 14; + * @return string + */ + public function getCanonicalName() + { + return $this->canonical_name; + } + + /** + * The canonical name of the finding. It's either + * "organizations/{organization_id}/sources/{source_id}", + * "folders/{folder_id}/sources/{source_id}" or + * "projects/{project_number}/sources/{source_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * + * Generated from protobuf field string canonical_name = 14; + * @param string $var + * @return $this + */ + public function setCanonicalName($var) + { + GPBUtil::checkString($var, True); + $this->canonical_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateFindingRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateFindingRequest.php new file mode 100644 index 000000000000..f56a1a74b304 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateFindingRequest.php @@ -0,0 +1,157 @@ +google.cloud.securitycenter.v1p1beta1.UpdateFindingRequest + */ +class UpdateFindingRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The finding resource to update or create if it does not already exist. + * parent, security_marks, and update_time will be ignored. + * In the case of creation, the finding id portion of the name must be + * alphanumeric and less than or equal to 32 characters and greater than 0 + * characters in length. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $finding = null; + /** + * The FieldMask to use when updating the finding resource. This field should + * not be specified when creating a finding. + * When updating a finding, an empty mask is treated as updating all mutable + * fields and replacing source_properties. Individual source_properties can + * be added/updated by using "source_properties." in the field + * mask. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1p1beta1\Finding $finding + * Required. The finding resource to update or create if it does not already exist. + * parent, security_marks, and update_time will be ignored. + * In the case of creation, the finding id portion of the name must be + * alphanumeric and less than or equal to 32 characters and greater than 0 + * characters in length. + * @type \Google\Protobuf\FieldMask $update_mask + * The FieldMask to use when updating the finding resource. This field should + * not be specified when creating a finding. + * When updating a finding, an empty mask is treated as updating all mutable + * fields and replacing source_properties. Individual source_properties can + * be added/updated by using "source_properties." in the field + * mask. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The finding resource to update or create if it does not already exist. + * parent, security_marks, and update_time will be ignored. + * In the case of creation, the finding id portion of the name must be + * alphanumeric and less than or equal to 32 characters and greater than 0 + * characters in length. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1p1beta1\Finding|null + */ + public function getFinding() + { + return $this->finding; + } + + public function hasFinding() + { + return isset($this->finding); + } + + public function clearFinding() + { + unset($this->finding); + } + + /** + * Required. The finding resource to update or create if it does not already exist. + * parent, security_marks, and update_time will be ignored. + * In the case of creation, the finding id portion of the name must be + * alphanumeric and less than or equal to 32 characters and greater than 0 + * characters in length. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1p1beta1\Finding $var + * @return $this + */ + public function setFinding($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Finding::class); + $this->finding = $var; + + return $this; + } + + /** + * The FieldMask to use when updating the finding resource. This field should + * not be specified when creating a finding. + * When updating a finding, an empty mask is treated as updating all mutable + * fields and replacing source_properties. Individual source_properties can + * be added/updated by using "source_properties." in the field + * mask. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The FieldMask to use when updating the finding resource. This field should + * not be specified when creating a finding. + * When updating a finding, an empty mask is treated as updating all mutable + * fields and replacing source_properties. Individual source_properties can + * be added/updated by using "source_properties." in the field + * mask. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateNotificationConfigRequest.php new file mode 100644 index 000000000000..bbd8b7c55d97 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateNotificationConfigRequest.php @@ -0,0 +1,125 @@ +google.cloud.securitycenter.v1p1beta1.UpdateNotificationConfigRequest + */ +class UpdateNotificationConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The notification config to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig notification_config = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $notification_config = null; + /** + * The FieldMask to use when updating the notification config. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig $notification_config + * Required. The notification config to update. + * @type \Google\Protobuf\FieldMask $update_mask + * The FieldMask to use when updating the notification config. + * If empty all mutable fields will be updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The notification config to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig notification_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig|null + */ + public function getNotificationConfig() + { + return $this->notification_config; + } + + public function hasNotificationConfig() + { + return isset($this->notification_config); + } + + public function clearNotificationConfig() + { + unset($this->notification_config); + } + + /** + * Required. The notification config to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig notification_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig $var + * @return $this + */ + public function setNotificationConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig::class); + $this->notification_config = $var; + + return $this; + } + + /** + * The FieldMask to use when updating the notification config. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The FieldMask to use when updating the notification config. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateOrganizationSettingsRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateOrganizationSettingsRequest.php new file mode 100644 index 000000000000..ab2d90e1566d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateOrganizationSettingsRequest.php @@ -0,0 +1,125 @@ +google.cloud.securitycenter.v1p1beta1.UpdateOrganizationSettingsRequest + */ +class UpdateOrganizationSettingsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The organization settings resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.OrganizationSettings organization_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $organization_settings = null; + /** + * The FieldMask to use when updating the settings resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings $organization_settings + * Required. The organization settings resource to update. + * @type \Google\Protobuf\FieldMask $update_mask + * The FieldMask to use when updating the settings resource. + * If empty all mutable fields will be updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The organization settings resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.OrganizationSettings organization_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings|null + */ + public function getOrganizationSettings() + { + return $this->organization_settings; + } + + public function hasOrganizationSettings() + { + return isset($this->organization_settings); + } + + public function clearOrganizationSettings() + { + unset($this->organization_settings); + } + + /** + * Required. The organization settings resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.OrganizationSettings organization_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings $var + * @return $this + */ + public function setOrganizationSettings($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings::class); + $this->organization_settings = $var; + + return $this; + } + + /** + * The FieldMask to use when updating the settings resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The FieldMask to use when updating the settings resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateSecurityMarksRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateSecurityMarksRequest.php new file mode 100644 index 000000000000..eb9d37881735 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateSecurityMarksRequest.php @@ -0,0 +1,185 @@ +google.cloud.securitycenter.v1p1beta1.UpdateSecurityMarksRequest + */ +class UpdateSecurityMarksRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The security marks resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.SecurityMarks security_marks = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $security_marks = null; + /** + * The FieldMask to use when updating the security marks resource. + * The field mask must not contain duplicate fields. + * If empty or set to "marks", all marks will be replaced. Individual + * marks can be updated using "marks.". + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + /** + * The time at which the updated SecurityMarks take effect. + * If not set uses current server time. Updates will be applied to the + * SecurityMarks that are active immediately preceding this time. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 3; + */ + protected $start_time = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks $security_marks + * Required. The security marks resource to update. + * @type \Google\Protobuf\FieldMask $update_mask + * The FieldMask to use when updating the security marks resource. + * The field mask must not contain duplicate fields. + * If empty or set to "marks", all marks will be replaced. Individual + * marks can be updated using "marks.". + * @type \Google\Protobuf\Timestamp $start_time + * The time at which the updated SecurityMarks take effect. + * If not set uses current server time. Updates will be applied to the + * SecurityMarks that are active immediately preceding this time. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The security marks resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.SecurityMarks security_marks = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks|null + */ + public function getSecurityMarks() + { + return $this->security_marks; + } + + public function hasSecurityMarks() + { + return isset($this->security_marks); + } + + public function clearSecurityMarks() + { + unset($this->security_marks); + } + + /** + * Required. The security marks resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.SecurityMarks security_marks = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks $var + * @return $this + */ + public function setSecurityMarks($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks::class); + $this->security_marks = $var; + + return $this; + } + + /** + * The FieldMask to use when updating the security marks resource. + * The field mask must not contain duplicate fields. + * If empty or set to "marks", all marks will be replaced. Individual + * marks can be updated using "marks.". + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The FieldMask to use when updating the security marks resource. + * The field mask must not contain duplicate fields. + * If empty or set to "marks", all marks will be replaced. Individual + * marks can be updated using "marks.". + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + + /** + * The time at which the updated SecurityMarks take effect. + * If not set uses current server time. Updates will be applied to the + * SecurityMarks that are active immediately preceding this time. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 3; + * @return \Google\Protobuf\Timestamp|null + */ + public function getStartTime() + { + return $this->start_time; + } + + public function hasStartTime() + { + return isset($this->start_time); + } + + public function clearStartTime() + { + unset($this->start_time); + } + + /** + * The time at which the updated SecurityMarks take effect. + * If not set uses current server time. Updates will be applied to the + * SecurityMarks that are active immediately preceding this time. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 3; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setStartTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->start_time = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateSourceRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateSourceRequest.php new file mode 100644 index 000000000000..ba5092d0370b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateSourceRequest.php @@ -0,0 +1,125 @@ +google.cloud.securitycenter.v1p1beta1.UpdateSourceRequest + */ +class UpdateSourceRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The source resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Source source = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $source = null; + /** + * The FieldMask to use when updating the source resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V1p1beta1\Source $source + * Required. The source resource to update. + * @type \Google\Protobuf\FieldMask $update_mask + * The FieldMask to use when updating the source resource. + * If empty all mutable fields will be updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The source resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Source source = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V1p1beta1\Source|null + */ + public function getSource() + { + return $this->source; + } + + public function hasSource() + { + return isset($this->source); + } + + public function clearSource() + { + unset($this->source); + } + + /** + * Required. The source resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Source source = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V1p1beta1\Source $var + * @return $this + */ + public function setSource($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Source::class); + $this->source = $var; + + return $this; + } + + /** + * The FieldMask to use when updating the source resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The FieldMask to use when updating the source resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_finding.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_finding.php new file mode 100644 index 000000000000..a630224198be --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_finding.php @@ -0,0 +1,73 @@ +createFinding($formattedParent, $findingId, $finding); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); + $findingId = '[FINDING_ID]'; + + create_finding_sample($formattedParent, $findingId); +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_CreateFinding_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_notification_config.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_notification_config.php new file mode 100644 index 000000000000..8cc391c040f6 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_notification_config.php @@ -0,0 +1,78 @@ +createNotificationConfig( + $formattedParent, + $configId, + $notificationConfig + ); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::organizationName('[ORGANIZATION]'); + $configId = '[CONFIG_ID]'; + + create_notification_config_sample($formattedParent, $configId); +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_CreateNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_source.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_source.php new file mode 100644 index 000000000000..f7961bb5f7ff --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_source.php @@ -0,0 +1,70 @@ +createSource($formattedParent, $source); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::organizationName('[ORGANIZATION]'); + + create_source_sample($formattedParent); +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_CreateSource_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/delete_notification_config.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/delete_notification_config.php new file mode 100644 index 000000000000..04f15670b27b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/delete_notification_config.php @@ -0,0 +1,68 @@ +deleteNotificationConfig($formattedName); + printf('Call completed successfully.' . PHP_EOL); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::notificationConfigName( + '[ORGANIZATION]', + '[NOTIFICATION_CONFIG]' + ); + + delete_notification_config_sample($formattedName); +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_DeleteNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_iam_policy.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_iam_policy.php new file mode 100644 index 000000000000..fd3f11c4c3d7 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_iam_policy.php @@ -0,0 +1,66 @@ +getIamPolicy($resource); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $resource = '[RESOURCE]'; + + get_iam_policy_sample($resource); +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_GetIamPolicy_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_notification_config.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_notification_config.php new file mode 100644 index 000000000000..48e88d1dbf90 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_notification_config.php @@ -0,0 +1,70 @@ +getNotificationConfig($formattedName); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::notificationConfigName( + '[ORGANIZATION]', + '[NOTIFICATION_CONFIG]' + ); + + get_notification_config_sample($formattedName); +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_GetNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_organization_settings.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_organization_settings.php new file mode 100644 index 000000000000..a37f09e90885 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_organization_settings.php @@ -0,0 +1,67 @@ +getOrganizationSettings($formattedName); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::organizationSettingsName('[ORGANIZATION]'); + + get_organization_settings_sample($formattedName); +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_GetOrganizationSettings_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_source.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_source.php new file mode 100644 index 000000000000..8e03ab838dc8 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_source.php @@ -0,0 +1,67 @@ +getSource($formattedName); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); + + get_source_sample($formattedName); +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_GetSource_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/group_assets.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/group_assets.php new file mode 100644 index 000000000000..9f4a21636d33 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/group_assets.php @@ -0,0 +1,93 @@ +groupAssets($formattedParent, $groupBy); + + /** @var GroupResult $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); + $groupBy = '[GROUP_BY]'; + + group_assets_sample($formattedParent, $groupBy); +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_GroupAssets_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/group_findings.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/group_findings.php new file mode 100644 index 000000000000..80364d57cfe8 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/group_findings.php @@ -0,0 +1,99 @@ +groupFindings($formattedParent, $groupBy); + + /** @var GroupResult $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); + $groupBy = '[GROUP_BY]'; + + group_findings_sample($formattedParent, $groupBy); +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_GroupFindings_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_assets.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_assets.php new file mode 100644 index 000000000000..0d21434ba3f9 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_assets.php @@ -0,0 +1,73 @@ +listAssets($formattedParent); + + /** @var ListAssetsResult $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); + + list_assets_sample($formattedParent); +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_ListAssets_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_findings.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_findings.php new file mode 100644 index 000000000000..fd5e808557cc --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_findings.php @@ -0,0 +1,80 @@ +listFindings($formattedParent); + + /** @var ListFindingsResult $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); + + list_findings_sample($formattedParent); +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_ListFindings_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_notification_configs.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_notification_configs.php new file mode 100644 index 000000000000..5c80f8598b5d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_notification_configs.php @@ -0,0 +1,72 @@ +listNotificationConfigs($formattedParent); + + /** @var NotificationConfig $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::organizationName('[ORGANIZATION]'); + + list_notification_configs_sample($formattedParent); +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_ListNotificationConfigs_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_sources.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_sources.php new file mode 100644 index 000000000000..e6becafb315b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_sources.php @@ -0,0 +1,73 @@ +listSources($formattedParent); + + /** @var Source $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); + + list_sources_sample($formattedParent); +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_ListSources_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/run_asset_discovery.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/run_asset_discovery.php new file mode 100644 index 000000000000..b2f56f56a4cb --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/run_asset_discovery.php @@ -0,0 +1,84 @@ +runAssetDiscovery($formattedParent); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var RunAssetDiscoveryResponse $result */ + $result = $response->getResult(); + printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString()); + } else { + /** @var Status $error */ + $error = $response->getError(); + printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::organizationName('[ORGANIZATION]'); + + run_asset_discovery_sample($formattedParent); +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_RunAssetDiscovery_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/set_finding_state.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/set_finding_state.php new file mode 100644 index 000000000000..0da483cc5b5b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/set_finding_state.php @@ -0,0 +1,76 @@ +setFindingState($formattedName, $state, $startTime); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + $state = State::STATE_UNSPECIFIED; + + set_finding_state_sample($formattedName, $state); +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_SetFindingState_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/set_iam_policy.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/set_iam_policy.php new file mode 100644 index 000000000000..b43b7e167485 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/set_iam_policy.php @@ -0,0 +1,69 @@ +setIamPolicy($resource, $policy); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $resource = '[RESOURCE]'; + + set_iam_policy_sample($resource); +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_SetIamPolicy_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/test_iam_permissions.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/test_iam_permissions.php new file mode 100644 index 000000000000..e9fe6046692a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/test_iam_permissions.php @@ -0,0 +1,74 @@ +testIamPermissions($resource, $permissions); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $resource = '[RESOURCE]'; + $permissionsElement = '[PERMISSIONS]'; + + test_iam_permissions_sample($resource, $permissionsElement); +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_TestIamPermissions_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_finding.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_finding.php new file mode 100644 index 000000000000..e5b6e36b45e6 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_finding.php @@ -0,0 +1,57 @@ +updateFinding($finding); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_UpdateFinding_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_notification_config.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_notification_config.php new file mode 100644 index 000000000000..c16382ce5c3c --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_notification_config.php @@ -0,0 +1,57 @@ +updateNotificationConfig($notificationConfig); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_UpdateNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_organization_settings.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_organization_settings.php new file mode 100644 index 000000000000..81879ab5ed8a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_organization_settings.php @@ -0,0 +1,56 @@ +updateOrganizationSettings($organizationSettings); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_UpdateOrganizationSettings_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_security_marks.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_security_marks.php new file mode 100644 index 000000000000..2cbacdf6f4f0 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_security_marks.php @@ -0,0 +1,56 @@ +updateSecurityMarks($securityMarks); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_UpdateSecurityMarks_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_source.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_source.php new file mode 100644 index 000000000000..cb1c762db9e6 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_source.php @@ -0,0 +1,56 @@ +updateSource($source); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END securitycenter_v1p1beta1_generated_SecurityCenter_UpdateSource_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/Gapic/SecurityCenterGapicClient.php b/owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/Gapic/SecurityCenterGapicClient.php new file mode 100644 index 000000000000..7e40c1b4f76f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/Gapic/SecurityCenterGapicClient.php @@ -0,0 +1,2807 @@ +sourceName('[ORGANIZATION]', '[SOURCE]'); + * $findingId = 'finding_id'; + * $finding = new Finding(); + * $response = $securityCenterClient->createFinding($formattedParent, $findingId, $finding); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * Many parameters require resource names to be formatted in a particular way. To + * assist with these names, this class includes a format method for each type of + * name, and additionally a parseName method to extract the individual identifiers + * contained within formatted names that are returned by the API. + * + * @experimental + * + * @deprecated This class will be removed in the next major version update. + */ +class SecurityCenterGapicClient +{ + use GapicClientTrait; + + /** The name of the service. */ + const SERVICE_NAME = 'google.cloud.securitycenter.v1p1beta1.SecurityCenter'; + + /** + * The default address of the service. + * + * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. + */ + const SERVICE_ADDRESS = 'securitycenter.googleapis.com'; + + /** The address template of the service. */ + private const SERVICE_ADDRESS_TEMPLATE = 'securitycenter.UNIVERSE_DOMAIN'; + + /** The default port of the service. */ + const DEFAULT_SERVICE_PORT = 443; + + /** The name of the code generator, to be included in the agent header. */ + const CODEGEN_NAME = 'gapic'; + + /** The default scopes required by the service. */ + public static $serviceScopes = [ + 'https://www.googleapis.com/auth/cloud-platform', + ]; + + private static $findingNameTemplate; + + private static $folderNameTemplate; + + private static $folderAssetSecurityMarksNameTemplate; + + private static $folderSourceNameTemplate; + + private static $folderSourceFindingNameTemplate; + + private static $folderSourceFindingSecurityMarksNameTemplate; + + private static $notificationConfigNameTemplate; + + private static $organizationNameTemplate; + + private static $organizationAssetSecurityMarksNameTemplate; + + private static $organizationSettingsNameTemplate; + + private static $organizationSourceNameTemplate; + + private static $organizationSourceFindingNameTemplate; + + private static $organizationSourceFindingSecurityMarksNameTemplate; + + private static $projectNameTemplate; + + private static $projectAssetSecurityMarksNameTemplate; + + private static $projectSourceNameTemplate; + + private static $projectSourceFindingNameTemplate; + + private static $projectSourceFindingSecurityMarksNameTemplate; + + private static $securityMarksNameTemplate; + + private static $sourceNameTemplate; + + private static $topicNameTemplate; + + private static $pathTemplateMap; + + private $operationsClient; + + private static function getClientDefaults() + { + return [ + 'serviceName' => self::SERVICE_NAME, + 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, + 'clientConfig' => __DIR__ . '/../resources/security_center_client_config.json', + 'descriptorsConfigPath' => __DIR__ . '/../resources/security_center_descriptor_config.php', + 'gcpApiConfigPath' => __DIR__ . '/../resources/security_center_grpc_config.json', + 'credentialsConfig' => [ + 'defaultScopes' => self::$serviceScopes, + ], + 'transportConfig' => [ + 'rest' => [ + 'restClientConfigPath' => __DIR__ . '/../resources/security_center_rest_client_config.php', + ], + ], + ]; + } + + private static function getFindingNameTemplate() + { + if (self::$findingNameTemplate == null) { + self::$findingNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}/findings/{finding}'); + } + + return self::$findingNameTemplate; + } + + private static function getFolderNameTemplate() + { + if (self::$folderNameTemplate == null) { + self::$folderNameTemplate = new PathTemplate('folders/{folder}'); + } + + return self::$folderNameTemplate; + } + + private static function getFolderAssetSecurityMarksNameTemplate() + { + if (self::$folderAssetSecurityMarksNameTemplate == null) { + self::$folderAssetSecurityMarksNameTemplate = new PathTemplate('folders/{folder}/assets/{asset}/securityMarks'); + } + + return self::$folderAssetSecurityMarksNameTemplate; + } + + private static function getFolderSourceNameTemplate() + { + if (self::$folderSourceNameTemplate == null) { + self::$folderSourceNameTemplate = new PathTemplate('folders/{folder}/sources/{source}'); + } + + return self::$folderSourceNameTemplate; + } + + private static function getFolderSourceFindingNameTemplate() + { + if (self::$folderSourceFindingNameTemplate == null) { + self::$folderSourceFindingNameTemplate = new PathTemplate('folders/{folder}/sources/{source}/findings/{finding}'); + } + + return self::$folderSourceFindingNameTemplate; + } + + private static function getFolderSourceFindingSecurityMarksNameTemplate() + { + if (self::$folderSourceFindingSecurityMarksNameTemplate == null) { + self::$folderSourceFindingSecurityMarksNameTemplate = new PathTemplate('folders/{folder}/sources/{source}/findings/{finding}/securityMarks'); + } + + return self::$folderSourceFindingSecurityMarksNameTemplate; + } + + private static function getNotificationConfigNameTemplate() + { + if (self::$notificationConfigNameTemplate == null) { + self::$notificationConfigNameTemplate = new PathTemplate('organizations/{organization}/notificationConfigs/{notification_config}'); + } + + return self::$notificationConfigNameTemplate; + } + + private static function getOrganizationNameTemplate() + { + if (self::$organizationNameTemplate == null) { + self::$organizationNameTemplate = new PathTemplate('organizations/{organization}'); + } + + return self::$organizationNameTemplate; + } + + private static function getOrganizationAssetSecurityMarksNameTemplate() + { + if (self::$organizationAssetSecurityMarksNameTemplate == null) { + self::$organizationAssetSecurityMarksNameTemplate = new PathTemplate('organizations/{organization}/assets/{asset}/securityMarks'); + } + + return self::$organizationAssetSecurityMarksNameTemplate; + } + + private static function getOrganizationSettingsNameTemplate() + { + if (self::$organizationSettingsNameTemplate == null) { + self::$organizationSettingsNameTemplate = new PathTemplate('organizations/{organization}/organizationSettings'); + } + + return self::$organizationSettingsNameTemplate; + } + + private static function getOrganizationSourceNameTemplate() + { + if (self::$organizationSourceNameTemplate == null) { + self::$organizationSourceNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}'); + } + + return self::$organizationSourceNameTemplate; + } + + private static function getOrganizationSourceFindingNameTemplate() + { + if (self::$organizationSourceFindingNameTemplate == null) { + self::$organizationSourceFindingNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}/findings/{finding}'); + } + + return self::$organizationSourceFindingNameTemplate; + } + + private static function getOrganizationSourceFindingSecurityMarksNameTemplate() + { + if (self::$organizationSourceFindingSecurityMarksNameTemplate == null) { + self::$organizationSourceFindingSecurityMarksNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}/findings/{finding}/securityMarks'); + } + + return self::$organizationSourceFindingSecurityMarksNameTemplate; + } + + private static function getProjectNameTemplate() + { + if (self::$projectNameTemplate == null) { + self::$projectNameTemplate = new PathTemplate('projects/{project}'); + } + + return self::$projectNameTemplate; + } + + private static function getProjectAssetSecurityMarksNameTemplate() + { + if (self::$projectAssetSecurityMarksNameTemplate == null) { + self::$projectAssetSecurityMarksNameTemplate = new PathTemplate('projects/{project}/assets/{asset}/securityMarks'); + } + + return self::$projectAssetSecurityMarksNameTemplate; + } + + private static function getProjectSourceNameTemplate() + { + if (self::$projectSourceNameTemplate == null) { + self::$projectSourceNameTemplate = new PathTemplate('projects/{project}/sources/{source}'); + } + + return self::$projectSourceNameTemplate; + } + + private static function getProjectSourceFindingNameTemplate() + { + if (self::$projectSourceFindingNameTemplate == null) { + self::$projectSourceFindingNameTemplate = new PathTemplate('projects/{project}/sources/{source}/findings/{finding}'); + } + + return self::$projectSourceFindingNameTemplate; + } + + private static function getProjectSourceFindingSecurityMarksNameTemplate() + { + if (self::$projectSourceFindingSecurityMarksNameTemplate == null) { + self::$projectSourceFindingSecurityMarksNameTemplate = new PathTemplate('projects/{project}/sources/{source}/findings/{finding}/securityMarks'); + } + + return self::$projectSourceFindingSecurityMarksNameTemplate; + } + + private static function getSecurityMarksNameTemplate() + { + if (self::$securityMarksNameTemplate == null) { + self::$securityMarksNameTemplate = new PathTemplate('organizations/{organization}/assets/{asset}/securityMarks'); + } + + return self::$securityMarksNameTemplate; + } + + private static function getSourceNameTemplate() + { + if (self::$sourceNameTemplate == null) { + self::$sourceNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}'); + } + + return self::$sourceNameTemplate; + } + + private static function getTopicNameTemplate() + { + if (self::$topicNameTemplate == null) { + self::$topicNameTemplate = new PathTemplate('projects/{project}/topics/{topic}'); + } + + return self::$topicNameTemplate; + } + + private static function getPathTemplateMap() + { + if (self::$pathTemplateMap == null) { + self::$pathTemplateMap = [ + 'finding' => self::getFindingNameTemplate(), + 'folder' => self::getFolderNameTemplate(), + 'folderAssetSecurityMarks' => self::getFolderAssetSecurityMarksNameTemplate(), + 'folderSource' => self::getFolderSourceNameTemplate(), + 'folderSourceFinding' => self::getFolderSourceFindingNameTemplate(), + 'folderSourceFindingSecurityMarks' => self::getFolderSourceFindingSecurityMarksNameTemplate(), + 'notificationConfig' => self::getNotificationConfigNameTemplate(), + 'organization' => self::getOrganizationNameTemplate(), + 'organizationAssetSecurityMarks' => self::getOrganizationAssetSecurityMarksNameTemplate(), + 'organizationSettings' => self::getOrganizationSettingsNameTemplate(), + 'organizationSource' => self::getOrganizationSourceNameTemplate(), + 'organizationSourceFinding' => self::getOrganizationSourceFindingNameTemplate(), + 'organizationSourceFindingSecurityMarks' => self::getOrganizationSourceFindingSecurityMarksNameTemplate(), + 'project' => self::getProjectNameTemplate(), + 'projectAssetSecurityMarks' => self::getProjectAssetSecurityMarksNameTemplate(), + 'projectSource' => self::getProjectSourceNameTemplate(), + 'projectSourceFinding' => self::getProjectSourceFindingNameTemplate(), + 'projectSourceFindingSecurityMarks' => self::getProjectSourceFindingSecurityMarksNameTemplate(), + 'securityMarks' => self::getSecurityMarksNameTemplate(), + 'source' => self::getSourceNameTemplate(), + 'topic' => self::getTopicNameTemplate(), + ]; + } + + return self::$pathTemplateMap; + } + + /** + * Formats a string containing the fully-qualified path to represent a finding + * resource. + * + * @param string $organization + * @param string $source + * @param string $finding + * + * @return string The formatted finding resource. + * + * @experimental + */ + public static function findingName($organization, $source, $finding) + { + return self::getFindingNameTemplate()->render([ + 'organization' => $organization, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a folder + * resource. + * + * @param string $folder + * + * @return string The formatted folder resource. + * + * @experimental + */ + public static function folderName($folder) + { + return self::getFolderNameTemplate()->render([ + 'folder' => $folder, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_asset_securityMarks resource. + * + * @param string $folder + * @param string $asset + * + * @return string The formatted folder_asset_securityMarks resource. + * + * @experimental + */ + public static function folderAssetSecurityMarksName($folder, $asset) + { + return self::getFolderAssetSecurityMarksNameTemplate()->render([ + 'folder' => $folder, + 'asset' => $asset, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_source resource. + * + * @param string $folder + * @param string $source + * + * @return string The formatted folder_source resource. + * + * @experimental + */ + public static function folderSourceName($folder, $source) + { + return self::getFolderSourceNameTemplate()->render([ + 'folder' => $folder, + 'source' => $source, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_source_finding resource. + * + * @param string $folder + * @param string $source + * @param string $finding + * + * @return string The formatted folder_source_finding resource. + * + * @experimental + */ + public static function folderSourceFindingName($folder, $source, $finding) + { + return self::getFolderSourceFindingNameTemplate()->render([ + 'folder' => $folder, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_source_finding_securityMarks resource. + * + * @param string $folder + * @param string $source + * @param string $finding + * + * @return string The formatted folder_source_finding_securityMarks resource. + * + * @experimental + */ + public static function folderSourceFindingSecurityMarksName($folder, $source, $finding) + { + return self::getFolderSourceFindingSecurityMarksNameTemplate()->render([ + 'folder' => $folder, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * notification_config resource. + * + * @param string $organization + * @param string $notificationConfig + * + * @return string The formatted notification_config resource. + * + * @experimental + */ + public static function notificationConfigName($organization, $notificationConfig) + { + return self::getNotificationConfigNameTemplate()->render([ + 'organization' => $organization, + 'notification_config' => $notificationConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a organization + * resource. + * + * @param string $organization + * + * @return string The formatted organization resource. + * + * @experimental + */ + public static function organizationName($organization) + { + return self::getOrganizationNameTemplate()->render([ + 'organization' => $organization, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_asset_securityMarks resource. + * + * @param string $organization + * @param string $asset + * + * @return string The formatted organization_asset_securityMarks resource. + * + * @experimental + */ + public static function organizationAssetSecurityMarksName($organization, $asset) + { + return self::getOrganizationAssetSecurityMarksNameTemplate()->render([ + 'organization' => $organization, + 'asset' => $asset, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_settings resource. + * + * @param string $organization + * + * @return string The formatted organization_settings resource. + * + * @experimental + */ + public static function organizationSettingsName($organization) + { + return self::getOrganizationSettingsNameTemplate()->render([ + 'organization' => $organization, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_source resource. + * + * @param string $organization + * @param string $source + * + * @return string The formatted organization_source resource. + * + * @experimental + */ + public static function organizationSourceName($organization, $source) + { + return self::getOrganizationSourceNameTemplate()->render([ + 'organization' => $organization, + 'source' => $source, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_source_finding resource. + * + * @param string $organization + * @param string $source + * @param string $finding + * + * @return string The formatted organization_source_finding resource. + * + * @experimental + */ + public static function organizationSourceFindingName($organization, $source, $finding) + { + return self::getOrganizationSourceFindingNameTemplate()->render([ + 'organization' => $organization, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_source_finding_securityMarks resource. + * + * @param string $organization + * @param string $source + * @param string $finding + * + * @return string The formatted organization_source_finding_securityMarks resource. + * + * @experimental + */ + public static function organizationSourceFindingSecurityMarksName($organization, $source, $finding) + { + return self::getOrganizationSourceFindingSecurityMarksNameTemplate()->render([ + 'organization' => $organization, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a project + * resource. + * + * @param string $project + * + * @return string The formatted project resource. + * + * @experimental + */ + public static function projectName($project) + { + return self::getProjectNameTemplate()->render([ + 'project' => $project, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_asset_securityMarks resource. + * + * @param string $project + * @param string $asset + * + * @return string The formatted project_asset_securityMarks resource. + * + * @experimental + */ + public static function projectAssetSecurityMarksName($project, $asset) + { + return self::getProjectAssetSecurityMarksNameTemplate()->render([ + 'project' => $project, + 'asset' => $asset, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_source resource. + * + * @param string $project + * @param string $source + * + * @return string The formatted project_source resource. + * + * @experimental + */ + public static function projectSourceName($project, $source) + { + return self::getProjectSourceNameTemplate()->render([ + 'project' => $project, + 'source' => $source, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_source_finding resource. + * + * @param string $project + * @param string $source + * @param string $finding + * + * @return string The formatted project_source_finding resource. + * + * @experimental + */ + public static function projectSourceFindingName($project, $source, $finding) + { + return self::getProjectSourceFindingNameTemplate()->render([ + 'project' => $project, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_source_finding_securityMarks resource. + * + * @param string $project + * @param string $source + * @param string $finding + * + * @return string The formatted project_source_finding_securityMarks resource. + * + * @experimental + */ + public static function projectSourceFindingSecurityMarksName($project, $source, $finding) + { + return self::getProjectSourceFindingSecurityMarksNameTemplate()->render([ + 'project' => $project, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * security_marks resource. + * + * @param string $organization + * @param string $asset + * + * @return string The formatted security_marks resource. + * + * @experimental + */ + public static function securityMarksName($organization, $asset) + { + return self::getSecurityMarksNameTemplate()->render([ + 'organization' => $organization, + 'asset' => $asset, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a source + * resource. + * + * @param string $organization + * @param string $source + * + * @return string The formatted source resource. + * + * @experimental + */ + public static function sourceName($organization, $source) + { + return self::getSourceNameTemplate()->render([ + 'organization' => $organization, + 'source' => $source, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a topic + * resource. + * + * @param string $project + * @param string $topic + * + * @return string The formatted topic resource. + * + * @experimental + */ + public static function topicName($project, $topic) + { + return self::getTopicNameTemplate()->render([ + 'project' => $project, + 'topic' => $topic, + ]); + } + + /** + * Parses a formatted name string and returns an associative array of the components in the name. + * The following name formats are supported: + * Template: Pattern + * - finding: organizations/{organization}/sources/{source}/findings/{finding} + * - folder: folders/{folder} + * - folderAssetSecurityMarks: folders/{folder}/assets/{asset}/securityMarks + * - folderSource: folders/{folder}/sources/{source} + * - folderSourceFinding: folders/{folder}/sources/{source}/findings/{finding} + * - folderSourceFindingSecurityMarks: folders/{folder}/sources/{source}/findings/{finding}/securityMarks + * - notificationConfig: organizations/{organization}/notificationConfigs/{notification_config} + * - organization: organizations/{organization} + * - organizationAssetSecurityMarks: organizations/{organization}/assets/{asset}/securityMarks + * - organizationSettings: organizations/{organization}/organizationSettings + * - organizationSource: organizations/{organization}/sources/{source} + * - organizationSourceFinding: organizations/{organization}/sources/{source}/findings/{finding} + * - organizationSourceFindingSecurityMarks: organizations/{organization}/sources/{source}/findings/{finding}/securityMarks + * - project: projects/{project} + * - projectAssetSecurityMarks: projects/{project}/assets/{asset}/securityMarks + * - projectSource: projects/{project}/sources/{source} + * - projectSourceFinding: projects/{project}/sources/{source}/findings/{finding} + * - projectSourceFindingSecurityMarks: projects/{project}/sources/{source}/findings/{finding}/securityMarks + * - securityMarks: organizations/{organization}/assets/{asset}/securityMarks + * - source: organizations/{organization}/sources/{source} + * - topic: projects/{project}/topics/{topic} + * + * The optional $template argument can be supplied to specify a particular pattern, + * and must match one of the templates listed above. If no $template argument is + * provided, or if the $template argument does not match one of the templates + * listed, then parseName will check each of the supported templates, and return + * the first match. + * + * @param string $formattedName The formatted name string + * @param string $template Optional name of template to match + * + * @return array An associative array from name component IDs to component values. + * + * @throws ValidationException If $formattedName could not be matched. + * + * @experimental + */ + public static function parseName($formattedName, $template = null) + { + $templateMap = self::getPathTemplateMap(); + if ($template) { + if (!isset($templateMap[$template])) { + throw new ValidationException("Template name $template does not exist"); + } + + return $templateMap[$template]->match($formattedName); + } + + foreach ($templateMap as $templateName => $pathTemplate) { + try { + return $pathTemplate->match($formattedName); + } catch (ValidationException $ex) { + // Swallow the exception to continue trying other path templates + } + } + + throw new ValidationException("Input did not match any known format. Input: $formattedName"); + } + + /** + * Return an OperationsClient object with the same endpoint as $this. + * + * @return OperationsClient + * + * @experimental + */ + public function getOperationsClient() + { + return $this->operationsClient; + } + + /** + * Resume an existing long running operation that was previously started by a long + * running API method. If $methodName is not provided, or does not match a long + * running API method, then the operation can still be resumed, but the + * OperationResponse object will not deserialize the final response. + * + * @param string $operationName The name of the long running operation + * @param string $methodName The name of the method used to start the operation + * + * @return OperationResponse + * + * @experimental + */ + public function resumeOperation($operationName, $methodName = null) + { + $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; + $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); + $operation->reload(); + return $operation; + } + + /** + * Constructor. + * + * @param array $options { + * Optional. Options for configuring the service API wrapper. + * + * @type string $apiEndpoint + * The address of the API remote host. May optionally include the port, formatted + * as ":". Default 'securitycenter.googleapis.com:443'. + * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials + * The credentials to be used by the client to authorize API calls. This option + * accepts either a path to a credentials file, or a decoded credentials file as a + * PHP array. + * *Advanced usage*: In addition, this option can also accept a pre-constructed + * {@see \Google\Auth\FetchAuthTokenInterface} object or + * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these + * objects are provided, any settings in $credentialsConfig will be ignored. + * @type array $credentialsConfig + * Options used to configure credentials, including auth token caching, for the + * client. For a full list of supporting configuration options, see + * {@see \Google\ApiCore\CredentialsWrapper::build()} . + * @type bool $disableRetries + * Determines whether or not retries defined by the client configuration should be + * disabled. Defaults to `false`. + * @type string|array $clientConfig + * Client method configuration, including retry settings. This option can be either + * a path to a JSON file, or a PHP array containing the decoded JSON data. By + * default this settings points to the default client config file, which is + * provided in the resources folder. + * @type string|TransportInterface $transport + * The transport used for executing network requests. May be either the string + * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. + * *Advanced usage*: Additionally, it is possible to pass in an already + * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note + * that when this object is provided, any settings in $transportConfig, and any + * $apiEndpoint setting, will be ignored. + * @type array $transportConfig + * Configuration options that will be used to construct the transport. Options for + * each supported transport type should be passed in a key for that transport. For + * example: + * $transportConfig = [ + * 'grpc' => [...], + * 'rest' => [...], + * ]; + * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and + * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the + * supported options. + * @type callable $clientCertSource + * A callable which returns the client cert as a string. This can be used to + * provide a certificate and private key to the transport layer for mTLS. + * } + * + * @throws ValidationException + * + * @experimental + */ + public function __construct(array $options = []) + { + $clientOptions = $this->buildClientOptions($options); + $this->setClientOptions($clientOptions); + $this->operationsClient = $this->createOperationsClient($clientOptions); + } + + /** + * Creates a finding. The corresponding source must exist for finding + * creation to succeed. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + * $findingId = 'finding_id'; + * $finding = new Finding(); + * $response = $securityCenterClient->createFinding($formattedParent, $findingId, $finding); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Resource name of the new finding's parent. Its format should be + * "organizations/[organization_id]/sources/[source_id]". + * @param string $findingId Required. Unique identifier provided by the client within the parent scope. + * @param Finding $finding Required. The Finding being created. The name and security_marks will be ignored as + * they are both output only fields on this resource. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1p1beta1\Finding + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function createFinding($parent, $findingId, $finding, array $optionalArgs = []) + { + $request = new CreateFindingRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setFindingId($findingId); + $request->setFinding($finding); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CreateFinding', Finding::class, $optionalArgs, $request)->wait(); + } + + /** + * Creates a notification config. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->organizationName('[ORGANIZATION]'); + * $configId = 'config_id'; + * $notificationConfig = new NotificationConfig(); + * $response = $securityCenterClient->createNotificationConfig($formattedParent, $configId, $notificationConfig); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Resource name of the new notification config's parent. Its format is + * "organizations/[organization_id]". + * @param string $configId Required. Unique identifier provided by the client within the parent scope. + * It must be between 1 and 128 characters, and contains alphanumeric + * characters, underscores or hyphens only. + * @param NotificationConfig $notificationConfig Required. The notification config being created. The name and the service account + * will be ignored as they are both output only fields on this resource. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function createNotificationConfig($parent, $configId, $notificationConfig, array $optionalArgs = []) + { + $request = new CreateNotificationConfigRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setConfigId($configId); + $request->setNotificationConfig($notificationConfig); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CreateNotificationConfig', NotificationConfig::class, $optionalArgs, $request)->wait(); + } + + /** + * Creates a source. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->organizationName('[ORGANIZATION]'); + * $source = new Source(); + * $response = $securityCenterClient->createSource($formattedParent, $source); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + * @param Source $source Required. The Source being created, only the display_name and description will be + * used. All other fields will be ignored. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1p1beta1\Source + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function createSource($parent, $source, array $optionalArgs = []) + { + $request = new CreateSourceRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setSource($source); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('CreateSource', Source::class, $optionalArgs, $request)->wait(); + } + + /** + * Deletes a notification config. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedName = $securityCenterClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); + * $securityCenterClient->deleteNotificationConfig($formattedName); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $name Required. Name of the notification config to delete. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]". + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function deleteNotificationConfig($name, array $optionalArgs = []) + { + $request = new DeleteNotificationConfigRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('DeleteNotificationConfig', GPBEmpty::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets the access control policy on the specified Source. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $resource = 'resource'; + * $response = $securityCenterClient->getIamPolicy($resource); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $resource REQUIRED: The resource for which the policy is being requested. + * See the operation documentation for the appropriate value for this field. + * @param array $optionalArgs { + * Optional. + * + * @type GetPolicyOptions $options + * OPTIONAL: A `GetPolicyOptions` object for specifying options to + * `GetIamPolicy`. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\Iam\V1\Policy + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function getIamPolicy($resource, array $optionalArgs = []) + { + $request = new GetIamPolicyRequest(); + $requestParamHeaders = []; + $request->setResource($resource); + $requestParamHeaders['resource'] = $resource; + if (isset($optionalArgs['options'])) { + $request->setOptions($optionalArgs['options']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetIamPolicy', Policy::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets a notification config. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedName = $securityCenterClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); + * $response = $securityCenterClient->getNotificationConfig($formattedName); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $name Required. Name of the notification config to get. Its format is + * "organizations/[organization_id]/notificationConfigs/[config_id]". + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function getNotificationConfig($name, array $optionalArgs = []) + { + $request = new GetNotificationConfigRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetNotificationConfig', NotificationConfig::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets the settings for an organization. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedName = $securityCenterClient->organizationSettingsName('[ORGANIZATION]'); + * $response = $securityCenterClient->getOrganizationSettings($formattedName); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $name Required. Name of the organization to get organization settings for. Its format is + * "organizations/[organization_id]/organizationSettings". + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function getOrganizationSettings($name, array $optionalArgs = []) + { + $request = new GetOrganizationSettingsRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetOrganizationSettings', OrganizationSettings::class, $optionalArgs, $request)->wait(); + } + + /** + * Gets a source. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedName = $securityCenterClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + * $response = $securityCenterClient->getSource($formattedName); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $name Required. Relative resource name of the source. Its format is + * "organizations/[organization_id]/source/[source_id]". + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1p1beta1\Source + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function getSource($name, array $optionalArgs = []) + { + $request = new GetSourceRequest(); + $requestParamHeaders = []; + $request->setName($name); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('GetSource', Source::class, $optionalArgs, $request)->wait(); + } + + /** + * Filters an organization's assets and groups them by their specified + * properties. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); + * $groupBy = 'group_by'; + * // Iterate over pages of elements + * $pagedResponse = $securityCenterClient->groupAssets($formattedParent, $groupBy); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $securityCenterClient->groupAssets($formattedParent, $groupBy); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Name of the organization to groupBy. Its format is + * "organizations/[organization_id], folders/[folder_id], or + * projects/[project_id]". + * @param string $groupBy Required. Expression that defines what assets fields to use for grouping. The string + * value should follow SQL syntax: comma separated list of fields. For + * example: + * "security_center_properties.resource_project,security_center_properties.project". + * + * The following fields are supported when compare_duration is not set: + * + * * security_center_properties.resource_project + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_type + * * security_center_properties.resource_parent + * * security_center_properties.resource_parent_display_name + * + * The following fields are supported when compare_duration is set: + * + * * security_center_properties.resource_type + * * security_center_properties.resource_project_display_name + * * security_center_properties.resource_parent_display_name + * @param array $optionalArgs { + * Optional. + * + * @type string $filter + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * + * The supported operators are: + * + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * + * The supported value types are: + * + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * The following field and operator combinations are supported: + * + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_name_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * + * For example, `resource_properties.size = 100` is a valid filter string. + * + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * @type Duration $compareDuration + * When compare_duration is set, the GroupResult's "state_change" property is + * updated to indicate whether the asset was added, removed, or remained + * present during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * + * The state change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * + * Possible "state_change" values when compare_duration is specified: + * + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at reference_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at reference_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and reference_time. + * + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * @type Timestamp $readTime + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function groupAssets($parent, $groupBy, array $optionalArgs = []) + { + $request = new GroupAssetsRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setGroupBy($groupBy); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['filter'])) { + $request->setFilter($optionalArgs['filter']); + } + + if (isset($optionalArgs['compareDuration'])) { + $request->setCompareDuration($optionalArgs['compareDuration']); + } + + if (isset($optionalArgs['readTime'])) { + $request->setReadTime($optionalArgs['readTime']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('GroupAssets', $optionalArgs, GroupAssetsResponse::class, $request); + } + + /** + * Filters an organization or source's findings and groups them by their + * specified properties. + * + * To group across all sources provide a `-` as the source id. + * Example: /v1/organizations/{organization_id}/sources/-/findings, + * /v1/folders/{folder_id}/sources/-/findings, + * /v1/projects/{project_id}/sources/-/findings + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + * $groupBy = 'group_by'; + * // Iterate over pages of elements + * $pagedResponse = $securityCenterClient->groupFindings($formattedParent, $groupBy); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $securityCenterClient->groupFindings($formattedParent, $groupBy); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Name of the source to groupBy. Its format is + * "organizations/[organization_id]/sources/[source_id]", + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]. To groupBy across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, + * or projects/{project_id}/sources/- + * @param string $groupBy Required. Expression that defines what assets fields to use for grouping (including + * `state_change`). The string value should follow SQL syntax: comma separated + * list of fields. For example: "parent,resource_name". + * + * The following fields are supported: + * + * * resource_name + * * category + * * state + * * parent + * * severity + * + * The following fields are supported when compare_duration is set: + * + * * state_change + * @param array $optionalArgs { + * Optional. + * + * @type string $filter + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * + * The supported operators are: + * + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * + * The supported value types are: + * + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * The following field and operator combinations are supported: + * + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * * severity: `=`, `:` + * + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * + * * security_marks.marks: `=`, `:` + * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * + * For example, `source_properties.size = 100` is a valid filter string. + * + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * @type Timestamp $readTime + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * @type Duration $compareDuration + * When compare_duration is set, the GroupResult's "state_change" attribute is + * updated to indicate whether the finding had its state changed, the + * finding's state remained unchanged, or if the finding was added during the + * compare_duration period of time that precedes the read_time. This is the + * time between (read_time - compare_duration) and read_time. + * + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * + * Possible "state_change" values when compare_duration is specified: + * + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present + * at read_time. + * + * If this field is set then `state_change` must be a specified field in + * `group_by`. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function groupFindings($parent, $groupBy, array $optionalArgs = []) + { + $request = new GroupFindingsRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $request->setGroupBy($groupBy); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['filter'])) { + $request->setFilter($optionalArgs['filter']); + } + + if (isset($optionalArgs['readTime'])) { + $request->setReadTime($optionalArgs['readTime']); + } + + if (isset($optionalArgs['compareDuration'])) { + $request->setCompareDuration($optionalArgs['compareDuration']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('GroupFindings', $optionalArgs, GroupFindingsResponse::class, $request); + } + + /** + * Lists an organization's assets. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); + * // Iterate over pages of elements + * $pagedResponse = $securityCenterClient->listAssets($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $securityCenterClient->listAssets($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Name of the organization assets should belong to. Its format is + * "organizations/[organization_id], folders/[folder_id], or + * projects/[project_id]". + * @param array $optionalArgs { + * Optional. + * + * @type string $filter + * Expression that defines the filter to apply across assets. + * The expression is a list of zero or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. The fields map to those + * defined in the Asset resource. Examples include: + * + * * name + * * security_center_properties.resource_name + * * resource_properties.a_property + * * security_marks.marks.marka + * + * The supported operators are: + * + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * + * The supported value types are: + * + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * The following are the allowed field and operator combinations: + * + * * name: `=` + * * update_time: `=`, `>`, `<`, `>=`, `<=` + * + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `update_time = "2019-06-10T16:07:18-07:00"` + * `update_time = 1560208038000` + * + * * create_time: `=`, `>`, `<`, `>=`, `<=` + * + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `create_time = "2019-06-10T16:07:18-07:00"` + * `create_time = 1560208038000` + * + * * iam_policy.policy_blob: `=`, `:` + * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * * security_marks.marks: `=`, `:` + * * security_center_properties.resource_name: `=`, `:` + * * security_center_properties.resource_display_name: `=`, `:` + * * security_center_properties.resource_type: `=`, `:` + * * security_center_properties.resource_parent: `=`, `:` + * * security_center_properties.resource_parent_display_name: `=`, `:` + * * security_center_properties.resource_project: `=`, `:` + * * security_center_properties.resource_project_display_name: `=`, `:` + * * security_center_properties.resource_owners: `=`, `:` + * + * For example, `resource_properties.size = 100` is a valid filter string. + * + * Use a partial match on the empty string to filter based on a property + * existing: `resource_properties.my_property : ""` + * + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-resource_properties.my_property : ""` + * @type string $orderBy + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,resource_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,resource_properties.a_property" and " + * name desc , resource_properties.a_property " are equivalent. + * + * The following fields are supported: + * name + * update_time + * resource_properties + * security_marks.marks + * security_center_properties.resource_name + * security_center_properties.resource_display_name + * security_center_properties.resource_parent + * security_center_properties.resource_parent_display_name + * security_center_properties.resource_project + * security_center_properties.resource_project_display_name + * security_center_properties.resource_type + * @type Timestamp $readTime + * Time used as a reference point when filtering assets. The filter is limited + * to assets existing at the supplied time and their values are those at that + * specific time. Absence of this field will default to the API's version of + * NOW. + * @type Duration $compareDuration + * When compare_duration is set, the ListAssetsResult's "state_change" + * attribute is updated to indicate whether the asset was added, removed, or + * remained present during the compare_duration period of time that precedes + * the read_time. This is the time between (read_time - compare_duration) and + * read_time. + * + * The state_change value is derived based on the presence of the asset at the + * two points in time. Intermediate state changes between the two times don't + * affect the result. For example, the results aren't affected if the asset is + * removed and re-created again. + * + * Possible "state_change" values when compare_duration is specified: + * + * * "ADDED": indicates that the asset was not present at the start of + * compare_duration, but present at read_time. + * * "REMOVED": indicates that the asset was present at the start of + * compare_duration, but not present at read_time. + * * "ACTIVE": indicates that the asset was present at both the + * start and the end of the time period defined by + * compare_duration and read_time. + * + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all assets present at + * read_time. + * @type FieldMask $fieldMask + * A field mask to specify the ListAssetsResult fields to be listed in the + * response. + * An empty field mask will list all fields. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function listAssets($parent, array $optionalArgs = []) + { + $request = new ListAssetsRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['filter'])) { + $request->setFilter($optionalArgs['filter']); + } + + if (isset($optionalArgs['orderBy'])) { + $request->setOrderBy($optionalArgs['orderBy']); + } + + if (isset($optionalArgs['readTime'])) { + $request->setReadTime($optionalArgs['readTime']); + } + + if (isset($optionalArgs['compareDuration'])) { + $request->setCompareDuration($optionalArgs['compareDuration']); + } + + if (isset($optionalArgs['fieldMask'])) { + $request->setFieldMask($optionalArgs['fieldMask']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListAssets', $optionalArgs, ListAssetsResponse::class, $request); + } + + /** + * Lists an organization or source's findings. + * + * To list across all sources provide a `-` as the source id. + * Example: /v1p1beta1/organizations/{organization_id}/sources/-/findings + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + * // Iterate over pages of elements + * $pagedResponse = $securityCenterClient->listFindings($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $securityCenterClient->listFindings($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Name of the source the findings belong to. Its format is + * "organizations/[organization_id]/sources/[source_id], + * folders/[folder_id]/sources/[source_id], or + * projects/[project_id]/sources/[source_id]". To list across all sources + * provide a source_id of `-`. For example: + * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or + * projects/{projects_id}/sources/- + * @param array $optionalArgs { + * Optional. + * + * @type string $filter + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * + * * name + * * source_properties.a_property + * * security_marks.marks.marka + * + * The supported operators are: + * + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * + * The supported value types are: + * + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * The following field and operator combinations are supported: + * + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * * severity: `=`, `:` + * + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * + * security_marks.marks: `=`, `:` + * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` + * + * For example, `source_properties.size = 100` is a valid filter string. + * + * Use a partial match on the empty string to filter based on a property + * existing: `source_properties.my_property : ""` + * + * Use a negated partial match on the empty string to filter based on a + * property not existing: `-source_properties.my_property : ""` + * @type string $orderBy + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,resource_properties.a_property". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,source_properties.a_property". Redundant space characters in the + * syntax are insignificant. "name desc,source_properties.a_property" and " + * name desc , source_properties.a_property " are equivalent. + * + * The following fields are supported: + * name + * parent + * state + * category + * resource_name + * event_time + * source_properties + * security_marks.marks + * @type Timestamp $readTime + * Time used as a reference point when filtering findings. The filter is + * limited to findings existing at the supplied time and their values are + * those at that specific time. Absence of this field will default to the + * API's version of NOW. + * @type Duration $compareDuration + * When compare_duration is set, the ListFindingsResult's "state_change" + * attribute is updated to indicate whether the finding had its state changed, + * the finding's state remained unchanged, or if the finding was added in any + * state during the compare_duration period of time that precedes the + * read_time. This is the time between (read_time - compare_duration) and + * read_time. + * + * The state_change value is derived based on the presence and state of the + * finding at the two points in time. Intermediate state changes between the + * two times don't affect the result. For example, the results aren't affected + * if the finding is made inactive and then active again. + * + * Possible "state_change" values when compare_duration is specified: + * + * * "CHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration, but changed its + * state at read_time. + * * "UNCHANGED": indicates that the finding was present and matched the given + * filter at the start of compare_duration and did not change + * state at read_time. + * * "ADDED": indicates that the finding did not match the given filter or + * was not present at the start of compare_duration, but was + * present at read_time. + * * "REMOVED": indicates that the finding was present and matched the + * filter at the start of compare_duration, but did not match + * the filter at read_time. + * + * If compare_duration is not specified, then the only possible state_change + * is "UNUSED", which will be the state_change set for all findings present at + * read_time. + * @type FieldMask $fieldMask + * A field mask to specify the Finding fields to be listed in the response. + * An empty field mask will list all fields. + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function listFindings($parent, array $optionalArgs = []) + { + $request = new ListFindingsRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['filter'])) { + $request->setFilter($optionalArgs['filter']); + } + + if (isset($optionalArgs['orderBy'])) { + $request->setOrderBy($optionalArgs['orderBy']); + } + + if (isset($optionalArgs['readTime'])) { + $request->setReadTime($optionalArgs['readTime']); + } + + if (isset($optionalArgs['compareDuration'])) { + $request->setCompareDuration($optionalArgs['compareDuration']); + } + + if (isset($optionalArgs['fieldMask'])) { + $request->setFieldMask($optionalArgs['fieldMask']); + } + + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListFindings', $optionalArgs, ListFindingsResponse::class, $request); + } + + /** + * Lists notification configs. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->organizationName('[ORGANIZATION]'); + * // Iterate over pages of elements + * $pagedResponse = $securityCenterClient->listNotificationConfigs($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $securityCenterClient->listNotificationConfigs($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Name of the organization to list notification configs. + * Its format is "organizations/[organization_id]". + * @param array $optionalArgs { + * Optional. + * + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function listNotificationConfigs($parent, array $optionalArgs = []) + { + $request = new ListNotificationConfigsRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListNotificationConfigs', $optionalArgs, ListNotificationConfigsResponse::class, $request); + } + + /** + * Lists all sources belonging to an organization. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); + * // Iterate over pages of elements + * $pagedResponse = $securityCenterClient->listSources($formattedParent); + * foreach ($pagedResponse->iteratePages() as $page) { + * foreach ($page as $element) { + * // doSomethingWith($element); + * } + * } + * // Alternatively: + * // Iterate through all elements + * $pagedResponse = $securityCenterClient->listSources($formattedParent); + * foreach ($pagedResponse->iterateAllElements() as $element) { + * // doSomethingWith($element); + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Resource name of the parent of sources to list. Its format should be + * "organizations/[organization_id], folders/[folder_id], or + * projects/[project_id]". + * @param array $optionalArgs { + * Optional. + * + * @type string $pageToken + * A page token is used to specify a page of values to be returned. + * If no page token is specified (the default), the first page + * of values will be returned. Any page token used here must have + * been generated by a previous call to the API. + * @type int $pageSize + * The maximum number of resources contained in the underlying API + * response. The API may return fewer values in a page, even if + * there are additional values to be retrieved. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\PagedListResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function listSources($parent, array $optionalArgs = []) + { + $request = new ListSourcesRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + if (isset($optionalArgs['pageToken'])) { + $request->setPageToken($optionalArgs['pageToken']); + } + + if (isset($optionalArgs['pageSize'])) { + $request->setPageSize($optionalArgs['pageSize']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->getPagedListResponse('ListSources', $optionalArgs, ListSourcesResponse::class, $request); + } + + /** + * Runs asset discovery. The discovery is tracked with a long-running + * operation. + * + * This API can only be called with limited frequency for an organization. If + * it is called too frequently the caller will receive a TOO_MANY_REQUESTS + * error. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedParent = $securityCenterClient->organizationName('[ORGANIZATION]'); + * $operationResponse = $securityCenterClient->runAssetDiscovery($formattedParent); + * $operationResponse->pollUntilComplete(); + * if ($operationResponse->operationSucceeded()) { + * $result = $operationResponse->getResult(); + * // doSomethingWith($result) + * } else { + * $error = $operationResponse->getError(); + * // handleError($error) + * } + * // Alternatively: + * // start the operation, keep the operation name, and resume later + * $operationResponse = $securityCenterClient->runAssetDiscovery($formattedParent); + * $operationName = $operationResponse->getName(); + * // ... do other work + * $newOperationResponse = $securityCenterClient->resumeOperation($operationName, 'runAssetDiscovery'); + * while (!$newOperationResponse->isDone()) { + * // ... do other work + * $newOperationResponse->reload(); + * } + * if ($newOperationResponse->operationSucceeded()) { + * $result = $newOperationResponse->getResult(); + * // doSomethingWith($result) + * } else { + * $error = $newOperationResponse->getError(); + * // handleError($error) + * } + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $parent Required. Name of the organization to run asset discovery for. Its format is + * "organizations/[organization_id]". + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\ApiCore\OperationResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function runAssetDiscovery($parent, array $optionalArgs = []) + { + $request = new RunAssetDiscoveryRequest(); + $requestParamHeaders = []; + $request->setParent($parent); + $requestParamHeaders['parent'] = $parent; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startOperationsCall('RunAssetDiscovery', $optionalArgs, $request, $this->getOperationsClient())->wait(); + } + + /** + * Updates the state of a finding. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $formattedName = $securityCenterClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + * $state = State::STATE_UNSPECIFIED; + * $startTime = new Timestamp(); + * $response = $securityCenterClient->setFindingState($formattedName, $state, $startTime); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $name Required. The relative resource name of the finding. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}/finding/{finding_id}". + * @param int $state Required. The desired State of the finding. + * For allowed values, use constants defined on {@see \Google\Cloud\SecurityCenter\V1p1beta1\Finding\State} + * @param Timestamp $startTime Required. The time at which the updated state takes effect. + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1p1beta1\Finding + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function setFindingState($name, $state, $startTime, array $optionalArgs = []) + { + $request = new SetFindingStateRequest(); + $requestParamHeaders = []; + $request->setName($name); + $request->setState($state); + $request->setStartTime($startTime); + $requestParamHeaders['name'] = $name; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('SetFindingState', Finding::class, $optionalArgs, $request)->wait(); + } + + /** + * Sets the access control policy on the specified Source. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $resource = 'resource'; + * $policy = new Policy(); + * $response = $securityCenterClient->setIamPolicy($resource, $policy); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $resource REQUIRED: The resource for which the policy is being specified. + * See the operation documentation for the appropriate value for this field. + * @param Policy $policy REQUIRED: The complete policy to be applied to the `resource`. The size of + * the policy is limited to a few 10s of KB. An empty policy is a + * valid policy but certain Cloud Platform services (such as Projects) + * might reject them. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only + * the fields in the mask will be modified. If no mask is provided, the + * following default mask is used: + * + * `paths: "bindings, etag"` + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\Iam\V1\Policy + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function setIamPolicy($resource, $policy, array $optionalArgs = []) + { + $request = new SetIamPolicyRequest(); + $requestParamHeaders = []; + $request->setResource($resource); + $request->setPolicy($policy); + $requestParamHeaders['resource'] = $resource; + if (isset($optionalArgs['updateMask'])) { + $request->setUpdateMask($optionalArgs['updateMask']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('SetIamPolicy', Policy::class, $optionalArgs, $request)->wait(); + } + + /** + * Returns the permissions that a caller has on the specified source. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $resource = 'resource'; + * $permissions = []; + * $response = $securityCenterClient->testIamPermissions($resource, $permissions); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param string $resource REQUIRED: The resource for which the policy detail is being requested. + * See the operation documentation for the appropriate value for this field. + * @param string[] $permissions The set of permissions to check for the `resource`. Permissions with + * wildcards (such as '*' or 'storage.*') are not allowed. For more + * information see + * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). + * @param array $optionalArgs { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\Iam\V1\TestIamPermissionsResponse + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function testIamPermissions($resource, $permissions, array $optionalArgs = []) + { + $request = new TestIamPermissionsRequest(); + $requestParamHeaders = []; + $request->setResource($resource); + $request->setPermissions($permissions); + $requestParamHeaders['resource'] = $resource; + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('TestIamPermissions', TestIamPermissionsResponse::class, $optionalArgs, $request)->wait(); + } + + /** + * Creates or updates a finding. The corresponding source must exist for a + * finding creation to succeed. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $finding = new Finding(); + * $response = $securityCenterClient->updateFinding($finding); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param Finding $finding Required. The finding resource to update or create if it does not already exist. + * parent, security_marks, and update_time will be ignored. + * + * In the case of creation, the finding id portion of the name must be + * alphanumeric and less than or equal to 32 characters and greater than 0 + * characters in length. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * The FieldMask to use when updating the finding resource. This field should + * not be specified when creating a finding. + * + * When updating a finding, an empty mask is treated as updating all mutable + * fields and replacing source_properties. Individual source_properties can + * be added/updated by using "source_properties." in the field + * mask. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1p1beta1\Finding + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function updateFinding($finding, array $optionalArgs = []) + { + $request = new UpdateFindingRequest(); + $requestParamHeaders = []; + $request->setFinding($finding); + $requestParamHeaders['finding.name'] = $finding->getName(); + if (isset($optionalArgs['updateMask'])) { + $request->setUpdateMask($optionalArgs['updateMask']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('UpdateFinding', Finding::class, $optionalArgs, $request)->wait(); + } + + /** + * Updates a notification config. The following update + * fields are allowed: description, pubsub_topic, streaming_config.filter + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $notificationConfig = new NotificationConfig(); + * $response = $securityCenterClient->updateNotificationConfig($notificationConfig); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param NotificationConfig $notificationConfig Required. The notification config to update. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * The FieldMask to use when updating the notification config. + * + * If empty all mutable fields will be updated. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function updateNotificationConfig($notificationConfig, array $optionalArgs = []) + { + $request = new UpdateNotificationConfigRequest(); + $requestParamHeaders = []; + $request->setNotificationConfig($notificationConfig); + $requestParamHeaders['notification_config.name'] = $notificationConfig->getName(); + if (isset($optionalArgs['updateMask'])) { + $request->setUpdateMask($optionalArgs['updateMask']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('UpdateNotificationConfig', NotificationConfig::class, $optionalArgs, $request)->wait(); + } + + /** + * Updates an organization's settings. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $organizationSettings = new OrganizationSettings(); + * $response = $securityCenterClient->updateOrganizationSettings($organizationSettings); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param OrganizationSettings $organizationSettings Required. The organization settings resource to update. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * The FieldMask to use when updating the settings resource. + * + * If empty all mutable fields will be updated. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function updateOrganizationSettings($organizationSettings, array $optionalArgs = []) + { + $request = new UpdateOrganizationSettingsRequest(); + $requestParamHeaders = []; + $request->setOrganizationSettings($organizationSettings); + $requestParamHeaders['organization_settings.name'] = $organizationSettings->getName(); + if (isset($optionalArgs['updateMask'])) { + $request->setUpdateMask($optionalArgs['updateMask']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('UpdateOrganizationSettings', OrganizationSettings::class, $optionalArgs, $request)->wait(); + } + + /** + * Updates security marks. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $securityMarks = new SecurityMarks(); + * $response = $securityCenterClient->updateSecurityMarks($securityMarks); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param SecurityMarks $securityMarks Required. The security marks resource to update. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * The FieldMask to use when updating the security marks resource. + * + * The field mask must not contain duplicate fields. + * If empty or set to "marks", all marks will be replaced. Individual + * marks can be updated using "marks.". + * @type Timestamp $startTime + * The time at which the updated SecurityMarks take effect. + * If not set uses current server time. Updates will be applied to the + * SecurityMarks that are active immediately preceding this time. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function updateSecurityMarks($securityMarks, array $optionalArgs = []) + { + $request = new UpdateSecurityMarksRequest(); + $requestParamHeaders = []; + $request->setSecurityMarks($securityMarks); + $requestParamHeaders['security_marks.name'] = $securityMarks->getName(); + if (isset($optionalArgs['updateMask'])) { + $request->setUpdateMask($optionalArgs['updateMask']); + } + + if (isset($optionalArgs['startTime'])) { + $request->setStartTime($optionalArgs['startTime']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('UpdateSecurityMarks', SecurityMarks::class, $optionalArgs, $request)->wait(); + } + + /** + * Updates a source. + * + * Sample code: + * ``` + * $securityCenterClient = new SecurityCenterClient(); + * try { + * $source = new Source(); + * $response = $securityCenterClient->updateSource($source); + * } finally { + * $securityCenterClient->close(); + * } + * ``` + * + * @param Source $source Required. The source resource to update. + * @param array $optionalArgs { + * Optional. + * + * @type FieldMask $updateMask + * The FieldMask to use when updating the source resource. + * + * If empty all mutable fields will be updated. + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return \Google\Cloud\SecurityCenter\V1p1beta1\Source + * + * @throws ApiException if the remote call fails + * + * @experimental + */ + public function updateSource($source, array $optionalArgs = []) + { + $request = new UpdateSourceRequest(); + $requestParamHeaders = []; + $request->setSource($source); + $requestParamHeaders['source.name'] = $source->getName(); + if (isset($optionalArgs['updateMask'])) { + $request->setUpdateMask($optionalArgs['updateMask']); + } + + $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); + $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); + return $this->startCall('UpdateSource', Source::class, $optionalArgs, $request)->wait(); + } +} diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/SecurityCenterClient.php b/owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/SecurityCenterClient.php new file mode 100644 index 000000000000..f3d3c3c31148 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/SecurityCenterClient.php @@ -0,0 +1,36 @@ + [ + 'google.cloud.securitycenter.v1p1beta1.SecurityCenter' => [ + 'RunAssetDiscovery' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\SecurityCenter\V1p1beta1\RunAssetDiscoveryResponse', + 'metadataReturnType' => '\Google\Protobuf\GPBEmpty', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + ], + 'GroupAssets' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getGroupByResults', + ], + ], + 'GroupFindings' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getGroupByResults', + ], + ], + 'ListAssets' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getListAssetsResults', + ], + ], + 'ListFindings' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getListFindingsResults', + ], + ], + 'ListNotificationConfigs' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getNotificationConfigs', + ], + ], + 'ListSources' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getSources', + ], + ], + ], + ], +]; diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/resources/security_center_rest_client_config.php b/owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/resources/security_center_rest_client_config.php new file mode 100644 index 000000000000..13e18b62b348 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/resources/security_center_rest_client_config.php @@ -0,0 +1,460 @@ + [ + 'google.cloud.securitycenter.v1p1beta1.SecurityCenter' => [ + 'CreateFinding' => [ + 'method' => 'post', + 'uriTemplate' => '/v1p1beta1/{parent=organizations/*/sources/*}/findings', + 'body' => 'finding', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'finding_id', + ], + ], + 'CreateNotificationConfig' => [ + 'method' => 'post', + 'uriTemplate' => '/v1p1beta1/{parent=organizations/*}/notificationConfigs', + 'body' => 'notification_config', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'config_id', + ], + ], + 'CreateSource' => [ + 'method' => 'post', + 'uriTemplate' => '/v1p1beta1/{parent=organizations/*}/sources', + 'body' => 'source', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteNotificationConfig' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1p1beta1/{name=organizations/*/notificationConfigs/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetIamPolicy' => [ + 'method' => 'post', + 'uriTemplate' => '/v1p1beta1/{resource=organizations/*/sources/*}:getIamPolicy', + 'body' => '*', + 'placeholders' => [ + 'resource' => [ + 'getters' => [ + 'getResource', + ], + ], + ], + ], + 'GetNotificationConfig' => [ + 'method' => 'get', + 'uriTemplate' => '/v1p1beta1/{name=organizations/*/notificationConfigs/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetOrganizationSettings' => [ + 'method' => 'get', + 'uriTemplate' => '/v1p1beta1/{name=organizations/*/organizationSettings}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetSource' => [ + 'method' => 'get', + 'uriTemplate' => '/v1p1beta1/{name=organizations/*/sources/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GroupAssets' => [ + 'method' => 'post', + 'uriTemplate' => '/v1p1beta1/{parent=organizations/*}/assets:group', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1p1beta1/{parent=folders/*}/assets:group', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v1p1beta1/{parent=projects/*}/assets:group', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'GroupFindings' => [ + 'method' => 'post', + 'uriTemplate' => '/v1p1beta1/{parent=organizations/*/sources/*}/findings:group', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1p1beta1/{parent=folders/*/sources/*}/findings:group', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v1p1beta1/{parent=projects/*/sources/*}/findings:group', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListAssets' => [ + 'method' => 'get', + 'uriTemplate' => '/v1p1beta1/{parent=organizations/*}/assets', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1p1beta1/{parent=folders/*}/assets', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v1p1beta1/{parent=projects/*}/assets', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListFindings' => [ + 'method' => 'get', + 'uriTemplate' => '/v1p1beta1/{parent=organizations/*/sources/*}/findings', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1p1beta1/{parent=folders/*/sources/*}/findings', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v1p1beta1/{parent=projects/*/sources/*}/findings', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListNotificationConfigs' => [ + 'method' => 'get', + 'uriTemplate' => '/v1p1beta1/{parent=organizations/*}/notificationConfigs', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListSources' => [ + 'method' => 'get', + 'uriTemplate' => '/v1p1beta1/{parent=organizations/*}/sources', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1p1beta1/{parent=folders/*}/sources', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v1p1beta1/{parent=projects/*}/sources', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'RunAssetDiscovery' => [ + 'method' => 'post', + 'uriTemplate' => '/v1p1beta1/{parent=organizations/*}/assets:runDiscovery', + 'body' => '*', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'SetFindingState' => [ + 'method' => 'post', + 'uriTemplate' => '/v1p1beta1/{name=organizations/*/sources/*/findings/*}:setState', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1p1beta1/{name=folders/*/sources/*/findings/*}:setState', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v1p1beta1/{name=projects/*/sources/*/findings/*}:setState', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'SetIamPolicy' => [ + 'method' => 'post', + 'uriTemplate' => '/v1p1beta1/{resource=organizations/*/sources/*}:setIamPolicy', + 'body' => '*', + 'placeholders' => [ + 'resource' => [ + 'getters' => [ + 'getResource', + ], + ], + ], + ], + 'TestIamPermissions' => [ + 'method' => 'post', + 'uriTemplate' => '/v1p1beta1/{resource=organizations/*/sources/*}:testIamPermissions', + 'body' => '*', + 'placeholders' => [ + 'resource' => [ + 'getters' => [ + 'getResource', + ], + ], + ], + ], + 'UpdateFinding' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1p1beta1/{finding.name=organizations/*/sources/*/findings/*}', + 'body' => 'finding', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v1p1beta1/{finding.name=folders/*/sources/*/findings/*}', + 'body' => 'finding', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v1p1beta1/{finding.name=projects/*/sources/*/findings/*}', + 'body' => 'finding', + ], + ], + 'placeholders' => [ + 'finding.name' => [ + 'getters' => [ + 'getFinding', + 'getName', + ], + ], + ], + ], + 'UpdateNotificationConfig' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1p1beta1/{notification_config.name=organizations/*/notificationConfigs/*}', + 'body' => 'notification_config', + 'placeholders' => [ + 'notification_config.name' => [ + 'getters' => [ + 'getNotificationConfig', + 'getName', + ], + ], + ], + ], + 'UpdateOrganizationSettings' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1p1beta1/{organization_settings.name=organizations/*/organizationSettings}', + 'body' => 'organization_settings', + 'placeholders' => [ + 'organization_settings.name' => [ + 'getters' => [ + 'getOrganizationSettings', + 'getName', + ], + ], + ], + ], + 'UpdateSecurityMarks' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1p1beta1/{security_marks.name=organizations/*/assets/*/securityMarks}', + 'body' => 'security_marks', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v1p1beta1/{security_marks.name=folders/*/assets/*/securityMarks}', + 'body' => 'security_marks', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v1p1beta1/{security_marks.name=projects/*/assets/*/securityMarks}', + 'body' => 'security_marks', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v1p1beta1/{security_marks.name=organizations/*/sources/*/findings/*/securityMarks}', + 'body' => 'security_marks', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v1p1beta1/{security_marks.name=folders/*/sources/*/findings/*/securityMarks}', + 'body' => 'security_marks', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v1p1beta1/{security_marks.name=projects/*/sources/*/findings/*/securityMarks}', + 'body' => 'security_marks', + ], + ], + 'placeholders' => [ + 'security_marks.name' => [ + 'getters' => [ + 'getSecurityMarks', + 'getName', + ], + ], + ], + ], + 'UpdateSource' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1p1beta1/{source.name=organizations/*/sources/*}', + 'body' => 'source', + 'placeholders' => [ + 'source.name' => [ + 'getters' => [ + 'getSource', + 'getName', + ], + ], + ], + ], + ], + 'google.longrunning.Operations' => [ + 'CancelOperation' => [ + 'method' => 'post', + 'uriTemplate' => '/v1p1beta1/{name=organizations/*/operations/*}:cancel', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteOperation' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1p1beta1/{name=organizations/*/operations/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetOperation' => [ + 'method' => 'get', + 'uriTemplate' => '/v1p1beta1/{name=organizations/*/operations/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'ListOperations' => [ + 'method' => 'get', + 'uriTemplate' => '/v1p1beta1/{name=organizations/*/operations}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + ], + ], + 'numericEnums' => true, +]; diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/tests/Unit/V1p1beta1/SecurityCenterClientTest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/tests/Unit/V1p1beta1/SecurityCenterClientTest.php new file mode 100644 index 000000000000..b5d5a2fef570 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v1p1beta1/tests/Unit/V1p1beta1/SecurityCenterClientTest.php @@ -0,0 +1,1692 @@ +getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); + } + + /** @return SecurityCenterClient */ + private function createClient(array $options = []) + { + $options += [ + 'credentials' => $this->createCredentials(), + ]; + return new SecurityCenterClient($options); + } + + /** @test */ + public function createFindingTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $parent2 = 'parent21175163357'; + $resourceName = 'resourceName979421212'; + $category = 'category50511102'; + $externalUri = 'externalUri-1385596168'; + $canonicalName = 'canonicalName1385400054'; + $expectedResponse = new Finding(); + $expectedResponse->setName($name); + $expectedResponse->setParent($parent2); + $expectedResponse->setResourceName($resourceName); + $expectedResponse->setCategory($category); + $expectedResponse->setExternalUri($externalUri); + $expectedResponse->setCanonicalName($canonicalName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $findingId = 'findingId728776081'; + $finding = new Finding(); + $response = $gapicClient->createFinding($formattedParent, $findingId, $finding); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/CreateFinding', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getFindingId(); + $this->assertProtobufEquals($findingId, $actualValue); + $actualValue = $actualRequestObject->getFinding(); + $this->assertProtobufEquals($finding, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createFindingExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $findingId = 'findingId728776081'; + $finding = new Finding(); + try { + $gapicClient->createFinding($formattedParent, $findingId, $finding); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createNotificationConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $description = 'description-1724546052'; + $pubsubTopic = 'pubsubTopic-338126829'; + $serviceAccount = 'serviceAccount-1948028253'; + $expectedResponse = new NotificationConfig(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setPubsubTopic($pubsubTopic); + $expectedResponse->setServiceAccount($serviceAccount); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $configId = 'configId-804450504'; + $notificationConfig = new NotificationConfig(); + $response = $gapicClient->createNotificationConfig($formattedParent, $configId, $notificationConfig); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/CreateNotificationConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getConfigId(); + $this->assertProtobufEquals($configId, $actualValue); + $actualValue = $actualRequestObject->getNotificationConfig(); + $this->assertProtobufEquals($notificationConfig, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createNotificationConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $configId = 'configId-804450504'; + $notificationConfig = new NotificationConfig(); + try { + $gapicClient->createNotificationConfig($formattedParent, $configId, $notificationConfig); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createSourceTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $canonicalName = 'canonicalName1385400054'; + $expectedResponse = new Source(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setCanonicalName($canonicalName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $source = new Source(); + $response = $gapicClient->createSource($formattedParent, $source); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/CreateSource', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getSource(); + $this->assertProtobufEquals($source, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createSourceExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $source = new Source(); + try { + $gapicClient->createSource($formattedParent, $source); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteNotificationConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); + $gapicClient->deleteNotificationConfig($formattedName); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/DeleteNotificationConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteNotificationConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); + try { + $gapicClient->deleteNotificationConfig($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getIamPolicyTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $version = 351608024; + $etag = '21'; + $expectedResponse = new Policy(); + $expectedResponse->setVersion($version); + $expectedResponse->setEtag($etag); + $transport->addResponse($expectedResponse); + // Mock request + $resource = 'resource-341064690'; + $response = $gapicClient->getIamPolicy($resource); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/GetIamPolicy', $actualFuncCall); + $actualValue = $actualRequestObject->getResource(); + $this->assertProtobufEquals($resource, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getIamPolicyExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $resource = 'resource-341064690'; + try { + $gapicClient->getIamPolicy($resource); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getNotificationConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $description = 'description-1724546052'; + $pubsubTopic = 'pubsubTopic-338126829'; + $serviceAccount = 'serviceAccount-1948028253'; + $expectedResponse = new NotificationConfig(); + $expectedResponse->setName($name2); + $expectedResponse->setDescription($description); + $expectedResponse->setPubsubTopic($pubsubTopic); + $expectedResponse->setServiceAccount($serviceAccount); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); + $response = $gapicClient->getNotificationConfig($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/GetNotificationConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getNotificationConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); + try { + $gapicClient->getNotificationConfig($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getOrganizationSettingsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $enableAssetDiscovery = false; + $expectedResponse = new OrganizationSettings(); + $expectedResponse->setName($name2); + $expectedResponse->setEnableAssetDiscovery($enableAssetDiscovery); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->organizationSettingsName('[ORGANIZATION]'); + $response = $gapicClient->getOrganizationSettings($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/GetOrganizationSettings', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getOrganizationSettingsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->organizationSettingsName('[ORGANIZATION]'); + try { + $gapicClient->getOrganizationSettings($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getSourceTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $canonicalName = 'canonicalName1385400054'; + $expectedResponse = new Source(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setCanonicalName($canonicalName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $response = $gapicClient->getSource($formattedName); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/GetSource', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getSourceExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + try { + $gapicClient->getSource($formattedName); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function groupAssetsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $totalSize = 705419236; + $groupByResultsElement = new GroupResult(); + $groupByResults = [ + $groupByResultsElement, + ]; + $expectedResponse = new GroupAssetsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setTotalSize($totalSize); + $expectedResponse->setGroupByResults($groupByResults); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $groupBy = 'groupBy506361367'; + $response = $gapicClient->groupAssets($formattedParent, $groupBy); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getGroupByResults()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/GroupAssets', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getGroupBy(); + $this->assertProtobufEquals($groupBy, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function groupAssetsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $groupBy = 'groupBy506361367'; + try { + $gapicClient->groupAssets($formattedParent, $groupBy); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function groupFindingsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $totalSize = 705419236; + $groupByResultsElement = new GroupResult(); + $groupByResults = [ + $groupByResultsElement, + ]; + $expectedResponse = new GroupFindingsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setTotalSize($totalSize); + $expectedResponse->setGroupByResults($groupByResults); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $groupBy = 'groupBy506361367'; + $response = $gapicClient->groupFindings($formattedParent, $groupBy); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getGroupByResults()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/GroupFindings', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getGroupBy(); + $this->assertProtobufEquals($groupBy, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function groupFindingsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $groupBy = 'groupBy506361367'; + try { + $gapicClient->groupFindings($formattedParent, $groupBy); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listAssetsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $totalSize = 705419236; + $listAssetsResultsElement = new ListAssetsResult(); + $listAssetsResults = [ + $listAssetsResultsElement, + ]; + $expectedResponse = new ListAssetsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setTotalSize($totalSize); + $expectedResponse->setListAssetsResults($listAssetsResults); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $response = $gapicClient->listAssets($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getListAssetsResults()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/ListAssets', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listAssetsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + try { + $gapicClient->listAssets($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listFindingsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $totalSize = 705419236; + $listFindingsResultsElement = new ListFindingsResult(); + $listFindingsResults = [ + $listFindingsResultsElement, + ]; + $expectedResponse = new ListFindingsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setTotalSize($totalSize); + $expectedResponse->setListFindingsResults($listFindingsResults); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $response = $gapicClient->listFindings($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getListFindingsResults()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/ListFindings', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listFindingsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + try { + $gapicClient->listFindings($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listNotificationConfigsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $notificationConfigsElement = new NotificationConfig(); + $notificationConfigs = [ + $notificationConfigsElement, + ]; + $expectedResponse = new ListNotificationConfigsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setNotificationConfigs($notificationConfigs); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $response = $gapicClient->listNotificationConfigs($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getNotificationConfigs()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/ListNotificationConfigs', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listNotificationConfigsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + try { + $gapicClient->listNotificationConfigs($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listSourcesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $sourcesElement = new Source(); + $sources = [ + $sourcesElement, + ]; + $expectedResponse = new ListSourcesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setSources($sources); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $response = $gapicClient->listSources($formattedParent); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getSources()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/ListSources', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listSourcesExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + try { + $gapicClient->listSources($formattedParent); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function runAssetDiscoveryTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/runAssetDiscoveryTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new RunAssetDiscoveryResponse(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/runAssetDiscoveryTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $response = $gapicClient->runAssetDiscovery($formattedParent); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $apiRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($apiRequests)); + $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); + $this->assertSame(0, count($operationsRequestsEmpty)); + $actualApiFuncCall = $apiRequests[0]->getFuncCall(); + $actualApiRequestObject = $apiRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/RunAssetDiscovery', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/runAssetDiscoveryTest'); + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + $this->assertTrue($response->isDone()); + $this->assertEquals($expectedResponse, $response->getResult()); + $apiRequestsEmpty = $transport->popReceivedCalls(); + $this->assertSame(0, count($apiRequestsEmpty)); + $operationsRequests = $operationsTransport->popReceivedCalls(); + $this->assertSame(1, count($operationsRequests)); + $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); + $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); + $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); + $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function runAssetDiscoveryExceptionTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/runAssetDiscoveryTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $operationsTransport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $response = $gapicClient->runAssetDiscovery($formattedParent); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/runAssetDiscoveryTest'); + try { + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + // If the pollUntilComplete() method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stubs are exhausted + $transport->popReceivedCalls(); + $operationsTransport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function setFindingStateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $parent = 'parent-995424086'; + $resourceName = 'resourceName979421212'; + $category = 'category50511102'; + $externalUri = 'externalUri-1385596168'; + $canonicalName = 'canonicalName1385400054'; + $expectedResponse = new Finding(); + $expectedResponse->setName($name2); + $expectedResponse->setParent($parent); + $expectedResponse->setResourceName($resourceName); + $expectedResponse->setCategory($category); + $expectedResponse->setExternalUri($externalUri); + $expectedResponse->setCanonicalName($canonicalName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + $state = State::STATE_UNSPECIFIED; + $startTime = new Timestamp(); + $response = $gapicClient->setFindingState($formattedName, $state, $startTime); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/SetFindingState', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $actualValue = $actualRequestObject->getState(); + $this->assertProtobufEquals($state, $actualValue); + $actualValue = $actualRequestObject->getStartTime(); + $this->assertProtobufEquals($startTime, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function setFindingStateExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + $state = State::STATE_UNSPECIFIED; + $startTime = new Timestamp(); + try { + $gapicClient->setFindingState($formattedName, $state, $startTime); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function setIamPolicyTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $version = 351608024; + $etag = '21'; + $expectedResponse = new Policy(); + $expectedResponse->setVersion($version); + $expectedResponse->setEtag($etag); + $transport->addResponse($expectedResponse); + // Mock request + $resource = 'resource-341064690'; + $policy = new Policy(); + $response = $gapicClient->setIamPolicy($resource, $policy); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/SetIamPolicy', $actualFuncCall); + $actualValue = $actualRequestObject->getResource(); + $this->assertProtobufEquals($resource, $actualValue); + $actualValue = $actualRequestObject->getPolicy(); + $this->assertProtobufEquals($policy, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function setIamPolicyExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $resource = 'resource-341064690'; + $policy = new Policy(); + try { + $gapicClient->setIamPolicy($resource, $policy); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function testIamPermissionsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new TestIamPermissionsResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $resource = 'resource-341064690'; + $permissions = []; + $response = $gapicClient->testIamPermissions($resource, $permissions); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/TestIamPermissions', $actualFuncCall); + $actualValue = $actualRequestObject->getResource(); + $this->assertProtobufEquals($resource, $actualValue); + $actualValue = $actualRequestObject->getPermissions(); + $this->assertProtobufEquals($permissions, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function testIamPermissionsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $resource = 'resource-341064690'; + $permissions = []; + try { + $gapicClient->testIamPermissions($resource, $permissions); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateFindingTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $parent = 'parent-995424086'; + $resourceName = 'resourceName979421212'; + $category = 'category50511102'; + $externalUri = 'externalUri-1385596168'; + $canonicalName = 'canonicalName1385400054'; + $expectedResponse = new Finding(); + $expectedResponse->setName($name); + $expectedResponse->setParent($parent); + $expectedResponse->setResourceName($resourceName); + $expectedResponse->setCategory($category); + $expectedResponse->setExternalUri($externalUri); + $expectedResponse->setCanonicalName($canonicalName); + $transport->addResponse($expectedResponse); + // Mock request + $finding = new Finding(); + $response = $gapicClient->updateFinding($finding); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/UpdateFinding', $actualFuncCall); + $actualValue = $actualRequestObject->getFinding(); + $this->assertProtobufEquals($finding, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateFindingExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $finding = new Finding(); + try { + $gapicClient->updateFinding($finding); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateNotificationConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $description = 'description-1724546052'; + $pubsubTopic = 'pubsubTopic-338126829'; + $serviceAccount = 'serviceAccount-1948028253'; + $expectedResponse = new NotificationConfig(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setPubsubTopic($pubsubTopic); + $expectedResponse->setServiceAccount($serviceAccount); + $transport->addResponse($expectedResponse); + // Mock request + $notificationConfig = new NotificationConfig(); + $response = $gapicClient->updateNotificationConfig($notificationConfig); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/UpdateNotificationConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getNotificationConfig(); + $this->assertProtobufEquals($notificationConfig, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateNotificationConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $notificationConfig = new NotificationConfig(); + try { + $gapicClient->updateNotificationConfig($notificationConfig); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateOrganizationSettingsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $enableAssetDiscovery = false; + $expectedResponse = new OrganizationSettings(); + $expectedResponse->setName($name); + $expectedResponse->setEnableAssetDiscovery($enableAssetDiscovery); + $transport->addResponse($expectedResponse); + // Mock request + $organizationSettings = new OrganizationSettings(); + $response = $gapicClient->updateOrganizationSettings($organizationSettings); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/UpdateOrganizationSettings', $actualFuncCall); + $actualValue = $actualRequestObject->getOrganizationSettings(); + $this->assertProtobufEquals($organizationSettings, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateOrganizationSettingsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $organizationSettings = new OrganizationSettings(); + try { + $gapicClient->updateOrganizationSettings($organizationSettings); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSecurityMarksTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $canonicalName = 'canonicalName1385400054'; + $expectedResponse = new SecurityMarks(); + $expectedResponse->setName($name); + $expectedResponse->setCanonicalName($canonicalName); + $transport->addResponse($expectedResponse); + // Mock request + $securityMarks = new SecurityMarks(); + $response = $gapicClient->updateSecurityMarks($securityMarks); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/UpdateSecurityMarks', $actualFuncCall); + $actualValue = $actualRequestObject->getSecurityMarks(); + $this->assertProtobufEquals($securityMarks, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSecurityMarksExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $securityMarks = new SecurityMarks(); + try { + $gapicClient->updateSecurityMarks($securityMarks); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSourceTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $canonicalName = 'canonicalName1385400054'; + $expectedResponse = new Source(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setCanonicalName($canonicalName); + $transport->addResponse($expectedResponse); + // Mock request + $source = new Source(); + $response = $gapicClient->updateSource($source); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/UpdateSource', $actualFuncCall); + $actualValue = $actualRequestObject->getSource(); + $this->assertProtobufEquals($source, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSourceExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $source = new Source(); + try { + $gapicClient->updateSource($source); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } +} diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Access.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Access.php new file mode 100644 index 000000000000..a41d008cd1f5 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Access.php @@ -0,0 +1,46 @@ +internalAddGeneratedFile( + ' +Á ++google/cloud/securitycenter/v2/access.protogoogle.cloud.securitycenter.v2"‰ +Access +principal_email (  + caller_ip ( B + caller_ip_geo ( 2+.google.cloud.securitycenter.v2.Geolocation +user_agent_family (  + +user_agent (  + service_name (  + method_name (  +principal_subject (  +service_account_key_name ( e +service_account_delegation_info + ( 2<.google.cloud.securitycenter.v2.ServiceAccountDelegationInfo + user_name ( "R +ServiceAccountDelegationInfo +principal_email (  +principal_subject ( "" + Geolocation + region_code ( Bå +"com.google.cloud.securitycenter.v2B AccessProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Application.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Application.php new file mode 100644 index 000000000000..dddd039a6a28 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Application.php @@ -0,0 +1,30 @@ +internalAddGeneratedFile( + ' +ú +0google/cloud/securitycenter/v2/application.protogoogle.cloud.securitycenter.v2"1 + Application +base_uri (  +full_uri ( Bê +"com.google.cloud.securitycenter.v2BApplicationProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/AttackExposure.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/AttackExposure.php new file mode 100644 index 0000000000000000000000000000000000000000..3c66cf8645d5c829429744fc616c1a15ce227c1d GIT binary patch literal 1462 zcmbVM-EI;=7!{Bj$4KfLmGq)cu}Q(yCBa@TR>NNrQ(F>fFU%&JVRnFt!_H=Q7Okci zK7sGyqxckFoA?gS&a&Im(wN8%%W%H)o$uQ-=hYj3>Vs#nOFSZwBrY7CK{+MR7hH18 z861V-^vB`*84RtEqx6a=uL zIXeqV@D)Jy@xu|L7zPqa^|eg{hk8^}#ON0_-aZ^777#^o9Xk#^EGhS3RB-HJQm(+5 zGs15BT&-gtCgS?hhSYZKUNoYInB67;7Sxwq^cB>yCPb!tjZVsyMcasuj$t|0Xj#`p z?n5a;a=AN%g2+&Kb*(!hI8UGK6{~Cb)IOkuxlJ-fbIOHfT}*XBvZ^#4Y)I9+k!a?x zuGI^9@tQ8iZ@6wc?SZmNIn@`b-2va$z~29O#Mq3hOzkXl*;(eiw()eqsvV_XNL41f zW0RG>=RjfED#m?~4=@*`n1Pvc#;AiQOu0Xh4n_=z>RH*qiFk@x1-Mt+Fc%_{CT6-E zV-q~SVs1x}AY`(bQ?+-Ex2l&iBPrfiKMS?JgzAQQ%w?(OAgXQVel>E&b5PRvhq%s^ zPNvQrv5-W~^c4&o%tKEW^QukW*ah1Oc1Bzp&Tc@jX>K*ht?e$wm0f1KHuyt~%{%Wsh3HmUUVit!d}H+(~c6ZhXftMMC5fidV#eM#h)+9GnC2 E7n{-M&;S4c literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/AttackPath.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/AttackPath.php new file mode 100644 index 0000000000000000000000000000000000000000..f3fa8e4a833b05b10da3868eb04420fe6279a5b7 GIT binary patch literal 2341 zcmcIm&2Jk;6vuWFmFFZlTY?-Ps%fZHx1wuggajJ`a^g)Iptcp8NJXoz#=B!@)Xna) zI~&QZeC3bf#FYc$z>WWep7;}(kNvO{0wM@syz^$}_ul)xulekY@H~X~(J}E!gc)(s zc!t7}b`Xgj^Pe%9o)i_8ZhZtxY1XGW+94|=R zR!p2EqHN|6pOL6_*=}LRu=COmF+0~KIDn5YNE~8^pyR>8Gs3Wo8Mclkj&&$-tl<)l zb=KYka6BBxs3Y+P91dOs;=eE%d(=TO!;Jqups`JT$|&~eEAG}lnqV&`{QC8?lf-uz z4SXan^nHgkA0dS)&OQhOPQyOR3>ye$I4jnPaLvb_)g`eL(U1kvfFCuCDPcLELehMc zsugf_f||-k!?%h+ zzT>*Nu}3_@%^Y4Rdk8;mz=!`fwAwv&Lzl^*FDHY3+1~vF0Ez%=>#!nnpEAB6QyjY z)^Ec`Cb8KpB-{bv)Vr|m(m3?+%$BZJq%?%PJeLE9iqf+u)OV>rjq5AY(&4Rr)KCkb`yt5W|9SjVa^V@ATbz9tnvy}e>Z&ya%&^^F&>bF(Qsu;pMs@Tr5n z%=eVUI@D4!Y==`b4We1fW0oqCzs8T{EFzi8+(DH~16av}u-QJiy<@_i5fA4LfplTb z!(-xQu^Zi9(=vtn*AmwBSv1q`LY0?<>@~bysTek%Ky~p<6)G>uEahfTuC{h;L+{|BoS$tI8~CV;hRa!S5y5- J<{ah#e*zGZ1l|Au literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/BackupDisasterRecovery.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/BackupDisasterRecovery.php new file mode 100644 index 000000000000..40de3eea3460 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/BackupDisasterRecovery.php @@ -0,0 +1,40 @@ +internalAddGeneratedFile( + ' +è +=google/cloud/securitycenter/v2/backup_disaster_recovery.protogoogle.cloud.securitycenter.v2"† +BackupDisasterRecovery +backup_template (  +policies (  +host (  + applications (  + storage_pool (  +policy_options (  +profile (  + appliance (  + backup_type ( 6 +backup_create_time + ( 2.google.protobuf.TimestampBõ +"com.google.cloud.securitycenter.v2BBackupDisasterRecoveryProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/BigqueryExport.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/BigqueryExport.php new file mode 100644 index 000000000000..b3bd3445ab67 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/BigqueryExport.php @@ -0,0 +1,40 @@ +internalAddGeneratedFile( + ' +ª +4google/cloud/securitycenter/v2/bigquery_export.protogoogle.cloud.securitycenter.v2google/api/resource.protogoogle/protobuf/timestamp.proto" +BigQueryExport +name (  + description (  +filter (  +dataset ( 4 + create_time ( 2.google.protobuf.TimestampBàA4 + update_time ( 2.google.protobuf.TimestampBàA +most_recent_editor ( BàA + principal ( BàA:¡êA +,securitycenter.googleapis.com/BigQueryExportJorganizations/{organization}/locations/{location}/bigQueryExports/{export}>folders/{folder}/locations/{location}/bigQueryExports/{export}@projects/{project}/locations/{location}/bigQueryExports/{export}*bigQueryExports2bigQueryExportBí +"com.google.cloud.securitycenter.v2BBigQueryExportProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudArmor.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudArmor.php new file mode 100644 index 000000000000..1efa56cbd883 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudArmor.php @@ -0,0 +1,54 @@ +internalAddGeneratedFile( + ' +Æ +0google/cloud/securitycenter/v2/cloud_armor.protogoogle.cloud.securitycenter.v2"Þ + +CloudArmorG +security_policy ( 2..google.cloud.securitycenter.v2.SecurityPolicy: +requests ( 2(.google.cloud.securitycenter.v2.RequestsO +adaptive_protection ( 22.google.cloud.securitycenter.v2.AdaptiveProtection6 +attack ( 2&.google.cloud.securitycenter.v2.Attack + threat_vector ( + +duration ( 2.google.protobuf.Duration"= +SecurityPolicy +name (  +type (  +preview ("j +Requests +ratio ( +short_term_allowed ( +long_term_allowed ( +long_term_denied ("( +AdaptiveProtection + +confidence ("H +Attack + +volume_pps ( + +volume_bps ( +classification ( Bé +"com.google.cloud.securitycenter.v2BCloudArmorProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudDlpDataProfile.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudDlpDataProfile.php new file mode 100644 index 0000000000000000000000000000000000000000..6e9a8949218ed768e71013944ee93ce9e4a5b91f GIT binary patch literal 1395 zcmbtUU2oGc6s1Lg@FrA+2PPp+-UnJIL5j*-%7)T5E1g6ebzu@yq{wyM&M1p5$C)&y z{tKS@0sItx3a{|Q6E{iQwOgklk(W5mz2_dEdyn6~lcy4G;TDUSBAN|w{{rh%hNTi( zP!ZyOG8{66sW_87WXi<2*~Oi%hn;5I+kn(qB#JT%kAxV7tU^PP3@S0BiQ@W#vPd&k zIj`pX!61~ufM^l`{t)oYtPVmEIb*RTl;M_J|G+d!gZx$o={HhH|7ZcyKd#mgq9KW6 zoc(WxvI#kEj*Bi4hDRp-kW(CMqT#j8HtP#^Qjnkd-?xbuA$A`F_ zbF{1*B=@jZ37fBuv0^$=Q7z-00*q%Xe~Es!w=27tqrsO*Qt>>iqDm6>y>axL*Eazd&0s zS!NDPB#%v)*NR8_A)6Zt;|Q%tqF^KgeIeOe5z?Pj_a|w$u`!o0G2INt1C-782wi;{ z&(Sm2?l~PV@IJXt@Ue5`I*s;0+i8~W86~vZ?X~Pq`^5Iz-A<`ste{73uY2e;yi&3L z^*-7J-goe+uPq^z4WL^%Im{)U>I))_#C0=*KH$ei)n&hSedBv^y_NYd7r>nQuaQ~W zJg)wj2KW<)&McaT_~6l>#f==qvNG0|wFqNb5MzHU{9FHC!)@`IQ5{z=PnUPV^dAC@7H@WDK6sg%a?ZoI`ZtTrtu{tug#H4b CG2A5p literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudDlpInspection.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudDlpInspection.php new file mode 100644 index 000000000000..510aecae86dc --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudDlpInspection.php @@ -0,0 +1,35 @@ +internalAddGeneratedFile( + ' +á +9google/cloud/securitycenter/v2/cloud_dlp_inspection.protogoogle.cloud.securitycenter.v2"ˆ +CloudDlpInspection3 + inspect_job ( BúA +dlp.googleapis.com/DlpJob + info_type (  +info_type_count ( + full_scan (Bð +"com.google.cloud.securitycenter.v2BCloudDlpInspectionProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2êA| +dlp.googleapis.com/DlpJob$projects/{project}/dlpJobs/{dlp_job}9projects/{project}/locations/{location}/dlpJobs/{dlp_job}bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Compliance.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Compliance.php new file mode 100644 index 000000000000..7a3d888c1bc9 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Compliance.php @@ -0,0 +1,32 @@ +internalAddGeneratedFile( + ' +ƒ +/google/cloud/securitycenter/v2/compliance.protogoogle.cloud.securitycenter.v2"< + +Compliance +standard (  +version (  +ids ( Bé +"com.google.cloud.securitycenter.v2BComplianceProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Connection.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Connection.php new file mode 100644 index 0000000000000000000000000000000000000000..8da88c9e1a6041d5232e75785d9589c892575735 GIT binary patch literal 1150 zcmb7D(Qeu>6djay)RVfDO%qR*%PN&hTOy@zVQdYN z`|g&ICg&gyUp7 z#T+6wk4T8Q31PDfuet-+YIX+4vNdK2N7#Wg#%3Y5P{@*r6=RfeBJL2T0(0xuwh*Hf zBS9E7H8%h>nBzDK5Qc59afwAR2}IzxHI45o8o$3q;}7i`04NON7`ho9_yVB(MaeiM z2*x51^6!MiBSMKFK}bH!SJmM(2xBbUA7ZBo)w-Z+=u(8MXE5bd*prCKDb(Rgn5PCK zhvIkC%V-e#O&lXmBEh&Pp^h`dA{(cwRL_>zDmpTS)l{S7JP=ujf+u+Mb_h8Z38yu! zTM;a>lUDZnEm`V#Kbd6LUP!B|8Bn#Ig6{=j{ijEzqqM=)rkdNPnzwf4YaW2L6Qvj6 zV1i>osPur*5sAtinternalAddGeneratedFile( + ' +µ +4google/cloud/securitycenter/v2/contact_details.protogoogle.cloud.securitycenter.v2"K +ContactDetails9 +contacts ( 2\'.google.cloud.securitycenter.v2.Contact" +Contact +email ( Bí +"com.google.cloud.securitycenter.v2BContactDetailsProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Container.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Container.php new file mode 100644 index 000000000000..d82267c96d98 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Container.php @@ -0,0 +1,35 @@ +internalAddGeneratedFile( + ' +‡ +.google/cloud/securitycenter/v2/container.protogoogle.cloud.securitycenter.v2google/protobuf/timestamp.proto"  + Container +name (  +uri (  +image_id ( 5 +labels ( 2%.google.cloud.securitycenter.v2.Label/ + create_time ( 2.google.protobuf.TimestampBè +"com.google.cloud.securitycenter.v2BContainerProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Database.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Database.php new file mode 100644 index 000000000000..388dd983cbe9 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Database.php @@ -0,0 +1,34 @@ +internalAddGeneratedFile( + ' +¶ +-google/cloud/securitycenter/v2/database.protogoogle.cloud.securitycenter.v2"s +Database +name (  + display_name (  + user_name (  +query (  +grantees (  +version ( Bç +"com.google.cloud.securitycenter.v2B DatabaseProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Exfiltration.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Exfiltration.php new file mode 100644 index 000000000000..8b3c62fdd77b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Exfiltration.php @@ -0,0 +1,35 @@ +internalAddGeneratedFile( + ' +® +1google/cloud/securitycenter/v2/exfiltration.protogoogle.cloud.securitycenter.v2"¯ + Exfiltration> +sources ( 2-.google.cloud.securitycenter.v2.ExfilResource> +targets ( 2-.google.cloud.securitycenter.v2.ExfilResource +total_exfiltrated_bytes ("1 + ExfilResource +name (  + +components ( Bë +"com.google.cloud.securitycenter.v2BExfiltrationProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ExternalSystem.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ExternalSystem.php new file mode 100644 index 000000000000..3a7292ea5354 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ExternalSystem.php @@ -0,0 +1,52 @@ +internalAddGeneratedFile( + ' +Æ +4google/cloud/securitycenter/v2/external_system.protogoogle.cloud.securitycenter.v2google/protobuf/timestamp.proto"Ô +ExternalSystem +name (  + assignees (  + external_uid (  +status ( ? +external_system_update_time ( 2.google.protobuf.Timestamp +case_uri (  + case_priority ( , +case_sla ( 2.google.protobuf.Timestamp4 +case_create_time + ( 2.google.protobuf.Timestamp3 +case_close_time ( 2.google.protobuf.TimestampN + ticket_info ( 29.google.cloud.securitycenter.v2.ExternalSystem.TicketInfo + +TicketInfo + +id (  +assignee (  + description (  +uri (  +status ( / + update_time ( 2.google.protobuf.Timestamp:—êA“ +,securitycenter.googleapis.com/ExternalSystemaorganizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}vorganizations/{organization}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem}Ufolders/{folder}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}jfolders/{folder}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem}Wprojects/{project}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}lprojects/{project}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem}Bí +"com.google.cloud.securitycenter.v2BExternalSystemProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/File.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/File.php new file mode 100644 index 000000000000..15ff948c6d2f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/File.php @@ -0,0 +1,38 @@ +internalAddGeneratedFile( + ' +¬ +)google/cloud/securitycenter/v2/file.protogoogle.cloud.securitycenter.v2"ð +File +path (  +size ( +sha256 (  + hashed_size ( +partially_hashed ( +contents ( @ + disk_path ( 2-.google.cloud.securitycenter.v2.File.DiskPath9 +DiskPath +partition_uuid (  + relative_path ( Bã +"com.google.cloud.securitycenter.v2B FileProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Finding.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Finding.php new file mode 100644 index 0000000000000000000000000000000000000000..ce87104095b842c0fc52cec27e0d86325e3ee84f GIT binary patch literal 9093 zcmb_iOLN=E5su!{P?9NFcE;MQ4QuVS zz7dkP+B#Lkk3{u+H*`(cR$INJBjT&3+x0A)_$gH_R@8E(p_YnT<36YcZqGMKR_(ZM z$0ljhc6;q~K+K+Rg{LNQLgJ@SGU+4BX z3lyVSAHrxJX5JuV+C~tlI~)uBj8ypN^;))NszGRk@ZSR~&@IObEyK2cg86K#M}{2` z(7h;o)N{mi=Ud8_$=pH%^i!_ z?L7HtoLH`(&Gu*22f0eMM#MUftaZgAHFKs(f?)K~uf*{@SXNk5*BJv?7#ikr>67OM zJ)c}3FAr!vuV@8E0I^Ubrh7vC)9d3hXXO0u=Pch<4rK3(wpWCm1+jYs+jmR`0;uK$ z9$}kj449BxY|DWCHx4Yv8J}GaL`_(P>}1(vi0Fa~cornu>ra!eY0C)4;IPss2#gSN z|5)}}=@U$^Q~pLAQq4?bGn_07_ZZl2emFzBx8vEJ=bXG4V!NAF@*n~+bKEWI1=u@75XH{s>AgiR(3?>_;$!=Ue>{eWh~TPj06b?5nXKV{vdn_pZCTEkve{wJ zrnInW7xk)!DYZDr8Bm;7dw(aTk*rR)#oeAaFBP&}m z2@|SmnQF|mMplUElu(c@fJr%y8R~6LnuJzLYL{R}LjIXVo_dYaA0hsYM4Sw8oDt_i z1d-7L#$<%nreq+>v4!Zj644IjBziX{B|=TMB`l+>LxSrcrPpM>rNWF~h!M6Vh8;5! zq5GUg2qjry9miBbC}bp~*uV$$mLLQ|M>Z4N?dZ@?@K1%jY}vcCw(AB<2|`5{SdOUR zLR>a&*YD^atJ6Y3mS7WlIrdUcF08u27N%R;&bPU0PU$+DplTgtU6<(B_HC zr_hrvHGZDFS#jY8O?fz4*`OwnD81}ii#7LosMK@lpLC&y%>UL;oWlP znFzhBDqc#Mld4lCKHM!d58H}#T>li$^^sT6Vw^jm1%~IDEg#Sd@2}8Y?-4(=NPrjA zsf|Qtd*rcMqpce2GX|{uh?e6OXJLX7jF^y5sV>@UjLz{Xr4S+~;6R242}?*`LY`YSn+)jxEFNErzo29st-R6&c$J0aTiGn4EiruL4_H)k@ElqkOu_gT zv+0Qpc;HB;yhO8{G2+`y`D>Xn?>;KuLu9%UbqVlq*_0m3l%YW*nn%iQw9I_UTgh-b z#~2J)fWTW2IUF|d9R}NcB*TS0OS8VR2PuQ|qX4fl-EU>8k(a?V%Bu$5%jOt$&I0_! zsB?@|6cyd%36nBk&o)kZn*5SZl&|1TlxT|{H?)WFUFL#3&2asu5x&P(M!E+F8%@d& zXmNna1Xvx-_#4SvApDh;H5=L7;~K4Po*A=BQFt$9(fTV)sB;Or$n(BQ8bL`nw1I~q~H zTiHT0l$r*(`H0Q`flQwsBb6#z?H^S7XAQi;Y{L%)q2sbf{ehDPu9FbF?}?87)%cP7TC#!ss7Z@iS(GG~4C+ zD#{0huR4n2G=qC7bI|195(zR}*VTX!Wx4t_Wy5Zq#u;))lxy*(MrYSZ=jgW<_Zn%u#}vDBgec}7Jp5y{{hX{Bi4!0YQ1z= zs%ecsozn-M0=(7=xjjIbN7L`L-FL}Jin|XV$`AIFQ_38g+N=CAIlW#$(~O9&qU8R; z1ydH#41HS!oCKOXDDyuil_j)rP%f5sv@-lQwf^@Bv^c~>zeIQ7x1v_w)eC#Mdi|V* zU`gX$t(0p3?h0BuJlHFjYPr0&2a^FqsV!Q)P$}sU>HqH>;I;d4Jox8XnxCfNHGepZ?iawDBiky zoAWRJHhFiKT_H)aRG*4!R{;*SaChY}^Up}2DK44Bw@kQ56Rw&3I(eUiWU~wlKe`>89GDge?c2H9RL6T literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Folder.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Folder.php new file mode 100644 index 000000000000..e75b30cc98de --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Folder.php @@ -0,0 +1,30 @@ +internalAddGeneratedFile( + ' +† ++google/cloud/securitycenter/v2/folder.protogoogle.cloud.securitycenter.v2"G +Folder +resource_folder ( $ +resource_folder_display_name ( Bå +"com.google.cloud.securitycenter.v2B FolderProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/GroupMembership.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/GroupMembership.php new file mode 100644 index 0000000000000000000000000000000000000000..f024cffe830972be98eb7bc3b1d6f54571ec0acf GIT binary patch literal 1104 zcmbW0-HOvd6vs^wapyuy5m`i*vvpy+pec0m!qh6;j|~yp1UFk$0wo{Qb|B3RlgUDr zzJt%n=|K}|LeDG&d@V3ae}!oa0I~;#2f?TRM3#d z5MZ!2&7x+C!;BNL3~?ebZ{D<; zGfp!$S>Q#0c{(RdS0^Bp_zRpeKg3`<-60l!WQQ!sPr zuwy`d@kiG{g{#^;ERnh$dN20@ugdNl^bfDyF z`w4n%zPGQPiTlwROs+>)&Y)*qT7!P|P7To0tv%QNVD%q3ZdV@ ChjEtx literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/IamBinding.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/IamBinding.php new file mode 100644 index 0000000000000000000000000000000000000000..c107744af2c6dc7352476ca66f45f5acb1b3bffd GIT binary patch literal 1059 zcmb7D(TdYR6g90>9AqtdkUlMU>%w+HQ;qnNTBU8eCBnAFt$mO{nIzNhK#~cQ$-*lA z8=w3X|3txma58Dr?Jg?jCCPBkx#!+{=FPk0GC@yaL}J3RAOU#SAT9|coC)T$5WH-; zBpiGeB{U@50I(-8p3GoqJF_E6OB&zgtxEEHpS7x zqj5mvm7&BDig85J1p5R=)BZUTIKTqCBcKAh83j+Bh znHN$YQh|kh9n*9{V=5>P>1Wwi7nV3oiKO4fF06T$dYLM>}WL^;p=q;HwUG zjK>}2I~Q1&U&`6@w{+v97X)S5Gr6l)3Cw9H=vNiJ_}?YzhXun>Yc=-QYFwGkuNp$T zRp>ob!)lfd4YbyQ`O^41-`H`Do+9dx(0$HA(x^y*hx!4kMI`bFZ&dUD=4({j;GQ78 zH<&q-@#5q7Vmcf+XU@>B-_swUYR|UonvPKI!|;4EAJ!}V9~x@P2>-)P|MAX_TJu!< z^uFkP+Xjo;D|S2HIH5A(`@>1R&h3M5mBWz=x1qvqY{NZJm&BNx-?spF6aO;*1;mvX s;AiEi5V0(!Vp;n#mNhrMnz~`HPRay4D}r?+hkwkVLKbmbqcuXm0V)|;W&i*H literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Indicator.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Indicator.php new file mode 100644 index 0000000000000000000000000000000000000000..80bfebe13cb9a065901d43360cd5fa54ac8394ad GIT binary patch literal 1746 zcmbtU-A)rh7RYfJ927+oawtqM<*O8Ym4dL`;))x;t$rZg)33vn18< zEZ+MdUibhezJc*6oZW3V{ec)|Z@QiR=A83=XXd}Wi)%~%Ek+iCQUlul7CBk%Ws*J z#9fb!vm@jZ?zz@ppxXzyj@|-gFJ9B3jswGpXb*)^*{IOpwgX=hp!}Od@La02U3qkEzAdv0$MFz-ZUPqAgK0C)Sqo z>QLEjOiIL}i23URzcGT4mtkHUG?t$C(KFu`AT?8B!+M|eZFivcFzaa%eL9XL!Cw1+ zcI70%Jrb~yqN98AM_3zR7i+F(k}AVe_Rtfpv$7aI(1O;4WcWA9KA&3~}zHtdw~Mt1}aoS0NFZmtOE;whUOA zn25XqnMSozJ7}Jtm9^$&y{w(r8ufCqdRQ%&QupKxJevAmKRYd!8;z7CKZdobZ->?6 zaw=9>f<$Cw;ginternalAddGeneratedFile( + ' +¦ +3google/cloud/securitycenter/v2/kernel_rootkit.protogoogle.cloud.securitycenter.v2"× + KernelRootkit +name ( $ +unexpected_code_modification (. +&unexpected_read_only_data_modification (! +unexpected_ftrace_handler (! +unexpected_kprobe_handler ($ +unexpected_kernel_code_pages (& +unexpected_system_call_handler ($ +unexpected_interrupt_handler (( + unexpected_processes_in_runqueue (Bì +"com.google.cloud.securitycenter.v2BKernelRootkitProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Kubernetes.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Kubernetes.php new file mode 100644 index 0000000000000000000000000000000000000000..1b674c4c93b5bdc56cfe02fe2d138a7d6852f6d1 GIT binary patch literal 2621 zcmbtW-HzKt6efSW>FKhKOp!t^s_9bHETWD`K_G8al)r|s+a$`*iXuyq<4m%qUfc56 zix#w8@DAK^jd%zifH#2$;F>ctv9sB2yS2zooXPpVIrE+Gc+Qiryb}*TBpvEd-w5cO z%+5)0LW$?Qfor-pnT3l5^@-`8dX`Onm5^4S^!j7cZgt1^5z5@qH>pOJuDi5p#kAdU zUSZS>eJeOOsS{AYa#pRp3}@7LXh4}NxB(pFlrqmSDd`Lv&uL)Hjlj@5f<|w08hx}u zqaRlf08HCpj2y;v@DmXHc;U>pOu_;qz^?}un_7+)ScYx=h^MNNg<&&_@awUQ&@ltc zbqELa9g~*#iR9$54?GuDsF5hK0T%{E(YyR)j$!L9%1qz#0@oj4sHQDx5X;F|%KNKr zIi0m2WtpRsoH{?qL-=-!R*i7BDnR-?&eS8C<&9j#d z-1}t*VC^I231mHY&Wb6LDc`QD>YH~`*GP5X&XuQ-bKE&)#k7D|62N6t}; zV8t!L^+f`%x*!+|ywZSeclJFs16JG?OrIuT>I-D)*A!%UtpL&vuXCz=OWA=ee-UBX z_^;1lOE@H|z(+T2BDz7T;cF@Cut@m*o1k$|mhM7Ucp%C}WLEkX@_bbkb>pA^>$TEv zDaeXiHz4~G3nrx4t$ub>#+NM5;p!n`S7J)}qBJvH%)KumD$Y2kca%Kl&_8MyQc3}Knn#n-xILVTm2~O%6l_OMdVR5KkmXLtW=UbgCh54y=qy}W zO7=<;qmLxC^e3jedRDp{avmg*bH$+6!{B6m?$I}>+Jk%?^#QzJpNzkrj$aJg*X5mz z+C!9Afn9t!?l#-?X0t!(jSFez7UVj^{$xCx+dIHyv(i+K89!E?6Y}I zd9#D73xA~Vb;R7Gin&LP=ANb)pVZ^(Ur~U*nvCMnNQUS*8~u~MFG(~_uxQ#Qjiwz} fXIoTmbwB?!hk! literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Label.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Label.php new file mode 100644 index 000000000000..966299706ef7 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Label.php @@ -0,0 +1,31 @@ +internalAddGeneratedFile( + ' +á +*google/cloud/securitycenter/v2/label.protogoogle.cloud.securitycenter.v2"$ +Label +name (  +value ( Bä +"com.google.cloud.securitycenter.v2B +LabelProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/LoadBalancer.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/LoadBalancer.php new file mode 100644 index 000000000000..6c2bf9316606 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/LoadBalancer.php @@ -0,0 +1,29 @@ +internalAddGeneratedFile( + ' +è +2google/cloud/securitycenter/v2/load_balancer.protogoogle.cloud.securitycenter.v2" + LoadBalancer +name ( Bë +"com.google.cloud.securitycenter.v2BLoadBalancerProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/LogEntry.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/LogEntry.php new file mode 100644 index 0000000000000000000000000000000000000000..443fbb6d129f86995e5d1fce14b248f0ca90c66d GIT binary patch literal 1183 zcmb7DU2hUW6cub5nMRYYFQgC66q}SLc8S}!K{Qe-)~Jw3crcrgVRqO~vdnB|XPcnm z!N231f5Sgw;;(Q%*lj8DATO}Xx#!+{?l~`Cr`IWX2K$s#i4~3DbOF^hg{c%u5Rt%X zKATYqiI}G>q0)!2H-Mi8BY4@n8Xf7n3O= zBA)06x$rGD036S0mSRF-f7ty<6^^jNVc)WZ7ltMLyv7oagEjyp!C3}Bi1^Zwfo}ln zPnu5?Mqs9}(qG3cn=sB4!wLJUSL(nSPBN;CH?gyv6U79FreMGcZJt8MX|Tts&=PcD zG1kziq7@0R%vu~LVUK1+vQ!B<)KG+Cs!A=*o95}Nt)XKx*mN@@v@v7{Dw)%}-651z z<&wAU+=gIT{tEvgS~=Z_X=xRnrwHAyb<1M6I(x-dJG_aaa^$!A#?7*cX?X&E?g0P) zj_Vydyl>6mubaWY2^tJMDlX^^!BY#HXotj%uUt~Ez)Ev3c(Lldjmfu0(Ojm|I^x}f z?jERVF6Xw!_X^nG0D1eM#&|}hny|>Ws(DYquBp<`Ro%Mg9RN>KXYL6RTw$goQh#Xw zI|DUUXk6d1lO7b4T6=4c_~jM4zbl}j15_ZksM39`_pm$ILk=rn-aBL=rkJ;4aX(r( zWjbB!5~tJl{TDx~hb~%9F~5k`h0df-^*H!d0K!%H%Jex%sN?sidgMqDvXUaSPJ_@m cnC@Bu&QD4gJ$J^wlY^}put;arC0GLR7ovKJ&Hw-a literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/MitreAttack.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/MitreAttack.php new file mode 100644 index 0000000000000000000000000000000000000000..61d429ac69c1ed935f724fabfc0fd7e14a367ecc GIT binary patch literal 3313 zcmbtX>uwvz6|SV%j>fh;9$U72lUK45%V|P2O4AD+Cm8My$+32KHaoktXb>1s)XFAG zku141;1+(N{w~mW=%2nv(1++byGv>%qb<@3uuKonoXhup=gjeUKaAgw$rG!Q43kMW zO^&Uj_g4BgvBr~8I_ixE*3sw&3b?G@JC2s`X|x zdNWA&dV|sIcyF5YW|MyUzLyNsWU}{efA6%PP7>2i({Aq%mCQRK!|rJ^9d~<))d*@{ zl6H@~X}8nJ9Cd7T)Y0c0bz1w+3F!^G)2Zd5L!S8~ePJbwu+qsaDMz=gNs`Vc z!{=Gv=-|WRQvu?5I+5Qi-yg>_@^DzLMVCVgHY_WV*3z zt$@F8f0n=bZRQi!Jw66qjDWc!!|BFK=JJ0@F(T__fAcugjZglcEN_r2?~=(BlH9li z=&f%5b(vf)K)FL$#O+AhCiZn8Y+0AWp}$~^tcAi>zR#uB+_wc?VjJXkD71=0TNp>Q zgsTEi_z_)3Yw62Ka@TO%7FyFw>^fN$hr*5{seHP^Zjh^i2({FaKyR1PTM){YbVWlL zp>6K+%=A-si`;NTUHBT#TU_J)D{P(Iv_s)Qyi$}^jN(XbtCk4cl(5@`f*TP+A|9M& z>0M=OgxJb;1=I%hC$~A-cBx z4+s{`Ibrw6dL-w5Re$753TON<>rh#e!C-^Lk&plyOXk2CI z(e~Lc*{LZN<);nhn*vq&I<&gbkg zc>vUUAQXVtG(r^zA6&p20J))hbC@FCWRLRH$aScc|b#9}iN|e(Fr~yZLP?QN2 z7_~767(YcbY-T+2hy(393gf(YAEB1!>ei78=&#uWa##9IS%Yx84bXT7Cs#HQb{NdJ z#ms8Tm)t(UhWxbLEHG1Wq^SD5ZRkz(nUgh-b=FD0V%uaB!l0B&5-wv#zhL*tow+26 zZ$beRiM#Y0_Kl=qJQZILdf&IAyANwV@)3; zGJplIx#j%wcKj_mEzeJbESS8?Y#`CwADKj|XbWI7yY2`t^|K`T-E=eJrYgSNlBBO%>7KAfx%U^X8>N`7Ji8 zs$mZrn+LomUFd3Pm|vntd_keh;1TnE)YlT$F#ng4fvLglIneM@?hp%!%3GN`9t?QM zZq8u#CeiP*$phB|0X+zlMo09;g`4nfEp&aR&EK;M`6AaAhzGhHp4JQW+9HhdE`#L1 zul=+{wqYOtFY8Z@miDP^Wet{Izs#4o`64zt-Fq{-xU6@_ec0E}?|I{+=NAwDvb@>I zHuXxjsaNKkx}B~3mDc{>=LVf(mtQRNxk(4M`Ja}zawpYl=A~La@1|O9?H^sv{=4wa a)5SLXWxgbrcItn-PiL0->imIxAmm@gTdt=7 literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/MuteConfig.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/MuteConfig.php new file mode 100644 index 0000000000000000000000000000000000000000..6b092319f8dde5cbc38a27d12f36aa49a24a6e3c GIT binary patch literal 1908 zcmb7F-A)rh6t)x_84Qy3rV;}Kl28b4O*JMi0_lIM0*x&snoXMR?zD{A?rdgfNr3bX zyzwQx;8A=EZ{;aGvp?OIKe0ERnLXz_bH4Ma|i2x8&xDHg{ByPOGT zG8=dOUXO5WvVlu&!c~kb2YCOWjjNSLdl_6k=5v#1xX)PMCVA6lzLocg>2oShP2vc` z^CyM;z!#)rGN(uTY5gV+zU~EFBIUljPQM zh$(GXT?RC4T=GVp}D0Y@ATWH7&_10lCffGl|N1Z?6#@ zZ3@*C#=yNfVnE}|9U75Vw5$)C!PiR`4x+MDuj^+yQ;#=H8pPHmUwrm4HklM-)noBI?v4YX_ zy~B33Q$EKAe3pfi|s~vKBZlxFN;6ZD0ii9AvI7k zPlYCwPeLef8SfhoJ%b0&94~)9z8wY)Cu|V#X^?cEq4IIu@S2~^%os3U-UYVNW41*& zz=VstYOabQ6>MrZz4c2j#`vu&XmBd9X7ErP&{Yjw}D91k} zQ+kq=t10_tGxhaDD6dHIvZQ@>bzVTVVPs4S!R>BcJ-C=!tOwIV4W@6J1$(_V>Qb9wrygtUw>I^_GHks= HG(_kxM~sfp literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Notebook.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Notebook.php new file mode 100644 index 000000000000..e2955ed42f67 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Notebook.php @@ -0,0 +1,33 @@ +internalAddGeneratedFile( + ' +» +-google/cloud/securitycenter/v2/notebook.protogoogle.cloud.securitycenter.v2"x +Notebook +name (  +service (  + last_author ( 8 +notebook_update_time ( 2.google.protobuf.TimestampBç +"com.google.cloud.securitycenter.v2B NotebookProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/NotificationConfig.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/NotificationConfig.php new file mode 100644 index 0000000000000000000000000000000000000000..8493156c21bb8b0be2c0431fb1fded35438987c9 GIT binary patch literal 1778 zcmbtUO-~a+7?$!89Z<}2u%ePFl2DB9nwl81h}wcwOr%u^2i@3AXJ^ZpWo9!w+XP5& z{u4hq z2&Y|g7?(7l7)i=m19KM8maT&Tz|aASBZLX8)+_IbL_U(pt7<%NJ;n2O2JpPS(kcKr zL~#ta`*7DaEI0;G{i389QVe6MLSnc?;|66^QWVl7RpuHDP#6;hGwK^845w+r^g)eb zQe1%sGxc4HxN6H9>?T-GJEgkhZKb6$6nYyZ#)3wYi@I`k-4>C({-&1VN)|SSqX8_M z99?%L$u%fNLi(daD2Pl1Th)1|0G-~+JEwi+hfBUhDfTi;^IQf$u7YR(%MxqBytFmH>_L9n?b7`13>ih#5n0xT zV2fWTfi+4KYX(fD%*&6#vEnsr4ov&m+|=mvIcqBuXES}X8(`5w4q zE^HH4MU8E>BhGH>XWa#}F%fNwNdsZb6DIQ$`sw&ddEEL8ZpKm&bU;}vTZR0jx}Gjo zGPsMXv`5RZce+r9{confk}tH19`;hY)iZBs+j|DEQPa*_PWa!*el8eQy@(F-M1dm5qZfDQnE0BxCUv;Y7A literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/NotificationMessage.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/NotificationMessage.php new file mode 100644 index 0000000000000000000000000000000000000000..73c3a92b57a720400ba01eb0097e750523dd3410 GIT binary patch literal 1310 zcmbVM%We}f6eZPo#qK zLwo^imV63Jz5tKs(WDIonAOO-_uO-j&+&^_@kNZDK%WVwh-OomT!Ow}5G$!Al@UzR zAYclpoW(q1$_3~R;B0UXZ+a)^yQVdfsiF)+C}kM27L8;&Z6%DRit9_tgl4KW_gX?~ z9&k!Dmts6)NkT&A+9?PLVh&Mw3XyW%RpnsGB`X5#R{gKy3h(;ty;A{!_ zG{;4s5tuJdClRNRXfu?;K2OG6aLq}?Kbb{45RfQg2IppNkP4a+g{)y9D02=V$INQ? zV`+rxK*?~JX=QZsPqJkNiToZ*sN%7fYG_I^4wV+e*Q5RQ!YY`uXenG{1>42tgygZBrDe8OI}FxdOEF?I5viI zD(=}PP4w*!dj8)|s_*2jt~H^%YC?DJJwDt3t%_B0WA1&ep+{@%RR`2qu``t-;Ndv4 zaiaz`=RqB#?I72;v1JY(dVbUWGdH)mkGHo>^Zk-Yc2G*8e{;C>r6TbYMofffk; E0%O6xegFUf literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/OrgPolicy.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/OrgPolicy.php new file mode 100644 index 000000000000..f07f984864f3 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/OrgPolicy.php @@ -0,0 +1,31 @@ +internalAddGeneratedFile( + ' + +/google/cloud/securitycenter/v2/org_policy.protogoogle.cloud.securitycenter.v2"Ö + OrgPolicy +name ( :ºêA¶ +orgpolicy.googleapis.com/Policy7organizations/{organization}/policies/{constraint_name}+folders/{folder}/policies/{constraint_name}-projects/{project}/policies/{constraint_name}Bè +"com.google.cloud.securitycenter.v2BOrgPolicyProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Process.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Process.php new file mode 100644 index 000000000000..757c7052e2d7 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Process.php @@ -0,0 +1,44 @@ +internalAddGeneratedFile( + ' +é +,google/cloud/securitycenter/v2/process.protogoogle.cloud.securitycenter.v2"õ +Process +name ( 4 +binary ( 2$.google.cloud.securitycenter.v2.File7 + libraries ( 2$.google.cloud.securitycenter.v2.File4 +script ( 2$.google.cloud.securitycenter.v2.File +args (  +arguments_truncated (J + env_variables ( 23.google.cloud.securitycenter.v2.EnvironmentVariable +env_variables_truncated ( +pid ( + +parent_pid + ("0 +EnvironmentVariable +name (  +val ( Bæ +"com.google.cloud.securitycenter.v2B ProcessProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Resource.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Resource.php new file mode 100644 index 0000000000000000000000000000000000000000..bd8db04f5de9caa50cdbea5390cac3f6883121e0 GIT binary patch literal 3212 zcmbtW-*4Mg6kd}4JZaO+?ba-V%FCv;V{0mcK*(Jgj^lWl+BhUm2UU>eI=88jYg_)& z(W1WbfcR5*=9Pbde}Grska$Mom3yxp*GXH#MqXkcpYz@Cob%m#&+`|~u>%iT30cV1 zeAH(T&shH$v5sr|wr-p3VQ_SWTvoSF9K%FznPqD-+msbntTmJeIMlNPS4SK>u3J3*eK>4=qD)ji~Eea+W;5(ViA1f7nugALzUJeU$Je zx^LJPO9Es|M;lMr5R>>ma%^0I9d<~oMT&w8(rb{cEY0lIkf*zbwB`Eet+#|5A`&nD$G>{koNFz><22#D(Wu3-%dS&TJby$7qK{fSAJen~+# zQ616)+{AB??nnK{$dN(4Mh7{VaWoenW04Z>!*cjO>P+M?&pe0OP<0;eZwB}6@uVEX z9ahc!&S!`aZFitq#(6>zrSCJ4O*Dr2V$6$(I9u7Cv`_+~jGyJiLW~M4$%Qpj4e)X3 z71A^Z{(nGgW)~wd63lA4ZU<2nvz1TY5|a<3i|@nIIC+4y(GOc${1EPpeU1nuoZ{V2 z_j&O#01k=pnH&8|KWAWZMA*#NaQj5Fv;jK7>QD!+9XKB5LE2uOm|k*=ltbJYOCnHA z7Z$wWFuY#K@j&QiD=*#wxs!llzJy%7k0@uV>ulxocK{x4P)fM?DXd(ZNV2Bap0&k~ z;WmvNAv!s%1Pl!up%J&29`2>TGO#fGPS25Dn6~Ub8g^=DQrgMja`L5#QHnpNAU|$o z6qqMVsPz6IG;)=RdngHVWf=uuM3FSZ%W1rf^pYz5kcO2c4q-?`d+YG9Eq3H?TM*S2 zue?;7a!pi~uUewoZFX9s(5N@WTK*P3g7T8kQsuV9Hya1M(vX|^6q5rW*1Eh~6WjST zK0>qPz15aqiGq?RCs&?--5Cv=V(!E0xRu|<3pSMeG{GPrc|nl7O(j3W6yYv^&~1zA z9^d38aZhY2s??Udt^6!=7k8R|>vXFfq1|XvVslIZOOD#(?81oo559%P(W`e2io&kk ztr6Dy4V=eV=J()^B+JsSs77wPyi%9jdpP}7SmyWm1G%Zb7OQGUZ0|P&v4iWd3`=_r zp)Gghx}s7d`AqeX6qN9^JV960#kf;ssBEPUUeOCI4zo|T2KM+ItvLoBrAJ30=Wu)6 z@KbtCqJwleew2rUv_Plv@_yylp+hekwc}Ykbm`$?`_J@)5QO7sB{^;shU4}thco!* c^zDz<<6-YvIL0QX-Ww-g>KV?Z7jOaa4|PTO%>V!Z literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ResourceValueConfig.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ResourceValueConfig.php new file mode 100644 index 0000000000000000000000000000000000000000..8b11b3f6e6532c3e03dc7998ff68b2531b6af5e7 GIT binary patch literal 2522 zcmbVO-EJC36fWR6_E1M?-KtwEx#KiaNE9zB?M1b&TVcS2$~M&4w2D?;Ez1C-E<4-Z zStJti0KMo7^bz_Tz3Nl+I+wlcUC+$^1ZHF zgK|LZ(5HN66PFXeJgt;{5(S!5%L$2TGj~Wwnk<8mYfVVtSvJAV&hZ)H*1+PH(Ugcr zO&}WGB}AiFIYh{ItRTP_F>+4;*CZ}_g)n@)u6ZvDPkXa4465>NrxRl77%5$#A;p3G3q3+ed=-McOX>P zM}(&oi#MewaajRJhqx5=sOvYHJi^=$$zpYkeZoWEJ(PV5fO-1MSixV_qs9p(&fu7g zttn-`uD@B;8<5*l6MEOrx@E(RyCbEfQSEX zq1}Ym1^p}UqYdFHHG?yyZKZ)8_)GRvv+({wOh8>OCgtI?wOo(ueB`=HZ zdsLi|0SzZBA>T#6#Uu1dQe%}^@+kK+nZ=d??aGTvI%QkWewERG%f7Dunnj;qGkjzr z@Oq%ZC0R}?EYPd8m_M>y`Vy`o<_6_gi;wg4h*-#gnA9q=jrhKtD?csf-hgtLozzHv z-VOih2T9$i?JO-;*+a#PMz?)+QEQmJ>giR(ygKi88nxC*t5Gk!r);5( z=dI@RLPkMo^9<&PtFuB@xsP(E?H>v`@%MTAyiwRV{wIST0+;`zkIe zB?>WMT6vw_k3e)?qUicEjIQ@8{Y~L&_Qm7$x_TB}{tL6ht#g8mjBfKenj`cdpTS+V literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecurityMarks.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecurityMarks.php new file mode 100644 index 000000000000..c7a94ee486ec --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecurityMarks.php @@ -0,0 +1,37 @@ +internalAddGeneratedFile( + ' +½ +3google/cloud/securitycenter/v2/security_marks.protogoogle.cloud.securitycenter.v2"î + SecurityMarks +name ( G +marks ( 28.google.cloud.securitycenter.v2.SecurityMarks.MarksEntry +canonical_name ( , + +MarksEntry +key (  +value ( :8:¿êA» ++securitycenter.googleapis.com/SecurityMarks9organizations/{organization}/assets/{asset}/securityMarksNorganizations/{organization}/sources/{source}/findings/{finding}/securityMarkscorganizations/{organization}/sources/{source}/locations/{location}/findings/{finding}/securityMarks-folders/{folder}/assets/{asset}/securityMarksBfolders/{folder}/sources/{source}/findings/{finding}/securityMarksWfolders/{folder}/sources/{source}/locations/{location}/findings/{finding}/securityMarks/projects/{project}/assets/{asset}/securityMarksDprojects/{project}/sources/{source}/findings/{finding}/securityMarksYprojects/{project}/sources/{source}/locations/{location}/findings/{finding}/securityMarksBì +"com.google.cloud.securitycenter.v2BSecurityMarksProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecurityPosture.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecurityPosture.php new file mode 100644 index 000000000000..f11372408da3 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecurityPosture.php @@ -0,0 +1,41 @@ +internalAddGeneratedFile( + ' +» +5google/cloud/securitycenter/v2/security_posture.protogoogle.cloud.securitycenter.v2"è +SecurityPosture +name (  + revision_id ( # +posture_deployment_resource (  +posture_deployment (  +changed_policy (  + +policy_set (  +policy ( ` +policy_drift_details ( 2B.google.cloud.securitycenter.v2.SecurityPosture.PolicyDriftDetailsS +PolicyDriftDetails +field (  +expected_value (  +detected_value ( Bî +"com.google.cloud.securitycenter.v2BSecurityPostureProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecuritycenterService.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecuritycenterService.php new file mode 100644 index 0000000000000000000000000000000000000000..b0afb9ba07b805f8868f9c68b4c46e350d21bca8 GIT binary patch literal 28020 zcmd@-TWlQHb={??$E9ArdQp^Zt;TwJMeRzXr&pq+B_&c)^q@sWb{0$)%jJ+-Yq`7K znWaMuEb0U>kj712+YJ&oMcTAMiu9QnY5LI^2nrN|kmjQ)(3U`v)W}csRRjgv^sDzd zbMKuyduNt(f9fB~yZ4-XUiZB2nc0h%TMt{{xy*#qaM~5mna#{BWxR(@rqynG&1$or znd!{UIqgifxzMWBopvshxq3Hq=kEQ?wW~MoA3&gPv(v6Rh0J`jIbV13)q1ltn|GaR zr(N@ws!qdm+WAFW`K0VR?ZsNv$&q~kXjB#)w^gY+nTg5K+m2V6t$3B`34(HZ45OT$ zl2A@RurB~mtyf$(BY!hRF@wh-gZ^uEX6m(S#`P*5`g5@6mTQfgSF6-(uOVhfGIN!> z>mW?wwR4?D)vGld84Pf@QFV?!pP@MM+Jmho63$45(>RIcg=95-12f#H)TggHZna%& zdCm4DT3RT~JDx9P{K?Vh*|r#6Z7y?^(pV^jh#bjy?T#bvp2@TwuhVW^Aar8{%l^Nn zH4-egYSYC=qlu-^Y`BF&z*B%C3UI7mLt0D*GhTD*v!l+#%3`hAP6m3 zS8L42-zvhWri-3esXm&lcn?>PYqU21s~xAkbnVlvW;=ldqiDPKX=+fMa@4sdv_lW$wUkSK5yf9L^{j zr)mqGI+5S%O=OCC_tdOg}g|js8qFkt1J944D+{R;h>nzWBP#rx#4RIEiVDZJ}B{?w=3?W_}u!iQz%wcBYX`BTE{QdScodl&iWB) z90m8Iehk48%jh##!D3z?xk&mLd82)Z9P8J>^bsRFZVP3`4x9qJ zxhf?CbrFAPNY28e-AN7*!K+|E@as(SSrdT) z0?Ok)uvNgK2>f4CU_WIboQHEpt}Be3CydzeM0ZBQ2;pw9iN+{J4fnwgO*mpIu}utz zH=@eFGqbJDww-c~0dhScls^EM7221QIzS z>l0uP-6Ak`j`VxBfKBIG9H3w&_4ecnz#eDqn+fVTaeV8D4JPcLqT$) z-R!hjDDrcQ)dfi<{eZi`#(BI;d1grn(GUXALjI)eH6J;R!3{We!>7O|@|laetb-fT zNB!34Q(%`uB+Iz2f$bbG&Z0YYkLOy)OkRf|L@GltD5h^~pvnrBZ$2?3k-!9csPkDb z6Kd8GYW_L}21MYyh>14NvAvqZcfXKe_Z+If8T7S=*It5KK!3H_L0K_QF8YRUfNkoE z0nqozS)yJL9s>QOj$rO~H{Y5k@Hvut7t-fb)^Df4?prn23mTQazI)6t0!(VksVJAq zQ&KJ!rw8_gNMhQ(0yYbEHJ7b1X%T4BD3<2K)Z+x*F7BRtiU0u`<|&E9{f-sK-Ba+A zQCXi$fgvm|*%$j-T$@x~(h`!@zf(!$ht13aas=v;>hQ-0k6rFulw<_=85 zN9(?}gN@Dhtkd@07tG-*05_L#T}(XJfISpCdE3D<2HXIz6Ez}CuZowgI8!8SW!=DCQW1Vm$C z3s*8}m<|GhXV@e=t}lGS2A>8yB_w6kghGAy!2v9_(Y;`gtRJ6f?6pV?46;q%d-fOu z159%A674xz%nJY!2|>(T2>P$wUm9axfGXNoqUirDKCa<>*q1;=71%?0E~j?%3`ubX zAMbwaP1G}pq=|`S66|b*8_ZlZJ(Tp(B6^3B!%dAuUwV`1%V-U&d`TeD=JFP5K42l~ zsbW(4D4LJaf?A@UpB5s%Xd;RR7_YNtG#OkV^jq^Z;`>`O{?8#_N_y|yFk<|Mdt;L_3QK6lFDN!k<|B|-NB^bX*H7<)&LlXl?r5pbw`Kaiz+un79`=!-*YpBUkn z!Q}`EwBz)J6xfPr!wz(9Xu1s6VGqtoGDbB{5+;CB^m|B&A8(;4ridn(u9Hp^Eu#|U zvVm*|^I)JucB8p0c0*lrSqrrg8GZ6l2^ZfjuuZw9B$aB6M!$@&NAli4Ee$F@CR$FH z(4bG4m-a{r^4ohTB|&)R#3=oEN>G9@-y=zXi~<}bDVzmx(jq$Ol*AswZI7g)`cR2Uc#Fm8v8 zMY0hOjiT0{q*jXC=*{(To83Bp=EpyKC;fKH8o|>bkLi~qP2pa|&1aYM+*V02WqD;` zCb%sxq_U+u){QPW^1MEbix0lH4s2KNe&IQzO!arpL(gzPVZtEi4?9_Z*7u}13C_{` zp~$Oul^j1m*~I|;-X$4>S}C$Q0V3olX)D)7K+E|#I_=^XW*84xs+X-o7a&=xS_H?f zqauR2W*wFNL+SSP@fbT$YRhm~{Q%wf5+w&t6oQPg>5E5qk{5`a1G!dzl)TQ4h1fT~Kmt-kN8Dk{;IoatcJS^uU z0Z&?%s9vA$E+Dq`oCp%o8V&OsIOu*p1&{Hm5_lj06D;sC7xqYY8J_SLA6EE@g2?(1 z8K04;wcqXogVfT(2{ybO?*NA(xvln)eOteeoa;emvzk8Ius=mZyy`Df)7Lysx;bFg2uW*T+NjeGkdnKt`xU0 zeNcBv1fR1GiaaTDU(PenT42L9@DI~qr*2fn9JzH+oQLr3G0DKJ@1W2?MsEnM-$-R? z=*1T#YL+XUjBH+syC?@PozBugOJKE@po2P-rD2so=@qU4gCC&em-2htcd_PBp+cCX z^Ur;vbly#8X{xA|j^Hw}G|pyeo~T{R-4@FIL|2R94rZx?Rivn3Kar)Wva+fR-a}dH zg$aZpX9e-eEDhi4vS`f2SN}x{o}&#vm=}--P@<=nS%w!G;A!P(2=>+m`YeOa=`5}b z+;`JpkeWl-E1Ug!6r{)YEp; zvmO-wG6nWh{x$s@XdKUu1U1R-bxC$!_9StuTG8psam@AQEG^@;K!LGlwe>tg0Kbz4 zPoX)jQK{;H=S|^11j2buT2QI(8m_`!!=BtV?8#k!m;zhye4GE&g}LUDmUDR-bNXNh zt10^K8Q8^jyFOXC7%!cLFVc?;W`|TK40QdF=2vVL`fJ@rvJDewD@sB54z+QPv*ogIq$oaHT01^>ticL ze~^S^EWAg;Pkbn8@e9{w{Is=C1Zo|@AFd-tDI^faLL8AAEa$WujWPhS)QqB=St_A9 zwpl802Vty?0w&HVV7!b1{y)hm{yvSSS#?v%@FF+nsQ!)?jGI?4wV|44z*XiMu;)Aj z_MB(Dl?J*_#wt()i{^_&@9M!`(hs=G^y9r0*n~vFirEt} zq(GN)#^YA9r$kl{Lt4P<;|Lwiz`4kco#V&7t6V+<`@`lfj zlMwNrX}OQC=Gj4n2yPe%0(`wNZWX&!@4R@AY>WDMPRk9upjhd;`xUtXRH$<{X%Wlb>pJkEYg7)c7}hj4s652O~KT*3(uNVs{nA5Fy3l~;FwW-1sR2S z$Mj|&^JKJ76V4W-OprbOjpq{G(oJ|>lw`6=5&}|I2Ehs&tx_SPV8ezFnctuo8%!ZT*TG7yv6k5DUGl-dVrmh?qPP2+n?BXBhrP^Du~x?Bxpt=sDylx|ivi}l{E zGz_!iX%KXy+vdFNY;>#j`@o+t=NVKEF`cIXz*QQ{c}j3ht1F80d^gRi6}?ua>m0v` z)~}V>77CUUuT~hGuNoQq30AGBtD^B9V$}+R2y`JMJ}Db+uq+aD(Ens703O#uMfD<4 z|C0mSYETIdd?fT)A9~oAl|XAG92(Fe&u4|ZpDw%<$NOpkxy2c;!>|+4!ZXYJTg3~% zpJD|}9Bb0FElbKt)JaNzuT*-06)+*Y5rnJ<#Wy*Fm{UzP;hI~_QIK57#zt#20w(3p zDpKY(jb6z5A*a%1R@3N#WFfWLM4wQ~x$qb0u}e(q6s;tnvD_6Fb6FS*Ithlc|C$`L z9JroAX z%P5D*NII!0-{@mAO5KZMzaT?tb-_i2JDzFBW#tX)Dv^%?Jn;Y7NL1(8d=o+CTcc2! z@}f|sVa&P|(4Yg1v-^2A6-9OrEIr2dSFOvz_FBjo`$IHSzZq%R@9Tz|%i@<@_YuwI zd#HiHUDPmr`%>Z_Gg7io3+^%hcOTe*NWke8H1_k^LQZCU6MYAn=q9WJGO$F5{`EdK zOJOiE#X2yd*g&saV}W);$Co#KME9;5D93cx5;|o%GmD^Ll#Sd*+I1K6;CoAFLu+FZ zn@eXy3uxXQ{vZY5ee^yoY!FU+q2{{ywSn*`&#r3p`XjuA8^H51Rxj2-4*aB}OapMlRJ-9-b3tos|Y{q|s#!2a*xm-A#hf;JphqlNVN%TS zchTeLR1xx%IC0e{L&a8~3}*dK|4MP6Bfsb{q`m)GXTL~1kFrp&JiqD|yicA((pTc* zmR3Q1aH-U?KiSJJqT~bD5o^a!*&mDEF|eARIeNu@DH;A%@KUyKMeijTYR}9(vR_WP zLGRqaZ=;I~dOF5w@63F0AuZ?UA%496K8n{nnEixKz#sM5^v;Yeh;RAJ1wKk$y2G4Q zOdNXY3HUDBG>S|3x?8OPech%PUq)yn9V0fKT9GgrEKVTghD~!`Gq{No_|^4bJ2eBG zZLo_;W3Nqx;I@-whT!YSkM3DOoAN33juHXC*=N%U7GaUzitqw9;EUa)G@^djzCzBR z5s4_OZU{$gI${t)7}!xa@EbOrXXyeSmy%01ok<9x5-h13DK~A}tL_FLlNQoG{Ba7s z%455VE%_)VdJH^-q_?rkQ4OY~BbNV;M&_x#hkJeI{#O(vKQYEWQFv49pHKq1U+fP? zouEHY+mpojHH-BpNmRE8B%Cho1bxN6*?ptnaP+#x49h%3viK{ONlGkOeUE#6wGQy2M|zAn6m)--vL}chw9EA>=SxXXP0+Lc$>mbr zo=UodsEuU1!JlpL9}N~CTQ=XUQdRKBdBta)hmt+hZ2jB%mEw^6aCAuS-&@a8NqL=K z;M#PO0}@J?3(C{jrF$%j@n!5S;o4FV{cwzfufYBHz(?SGg=MF4a0WDs%4GRRjJ;mA z=^UnRufR0~yTr$Qi^bFKnB&T1)}|fb?$`o4dy~c|*eTWRB6zW2oA~0m&0@L%bzFHk z?6e!u1(fzA5coaR|70hY^l;3#{^DxxUE|J$O|BFnr8snu&)CO^ccWh$&hIjR+G*&; zC&g#Dh_r8o|A%7kq35;SLO%cMtFN+#nE%T7O2>Ohe_rZ1da;`~*K9A0ez*=;=ymeE zcNQ^oIXW~Y{dg4niKt2Z>io%6=_Uo^&%2|y)6X}3x4?eE3Q-aI5v$hB1(}`J%s11| zPLLn1%8ilVyx{xNHznjA*iZO^Y4)>L{_k4RCDZ7Kt$v<9K#>#*1WTbHqbU^7n&LdL z<=s_z-4$M3aErZ=4xW_zyN|{HT^3rr{$29&&x;>7y_|WRJV)>Eafth>$Mhdjc+q=I z&c|m#zRiMlk#aX5gAwT->v3=`6}r*NKc<&a{%<-g&#Xrd$7`NC;{QU*F#Sy~;U~QC Vg;A}l`S~uglK#xrGFS%Se*s<}D?|VQ literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Simulation.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Simulation.php new file mode 100644 index 000000000000..eb916ed5113f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Simulation.php @@ -0,0 +1,40 @@ +internalAddGeneratedFile( + ' +³ +/google/cloud/securitycenter/v2/simulation.protogoogle.cloud.securitycenter.v2google/api/resource.proto-google/cloud/securitycenter/v2/resource.proto4google/cloud/securitycenter/v2/valued_resource.protogoogle/protobuf/timestamp.proto"Ê + +Simulation +name ( 4 + create_time ( 2.google.protobuf.TimestampBàAd +resource_value_configs_metadata ( 2;.google.cloud.securitycenter.v2.ResourceValueConfigMetadataE +cloud_provider (2-.google.cloud.securitycenter.v2.CloudProvider:ÊêAÆ +(securitycenter.googleapis.com/Simulation5organizations/{organization}/simulations/{simulation}Jorganizations/{organization}/locations/{location}/simulations/{simluation}* simulations2 +simulationBé +"com.google.cloud.securitycenter.v2BSimulationProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Source.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Source.php new file mode 100644 index 000000000000..d08497f18dee --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Source.php @@ -0,0 +1,34 @@ +internalAddGeneratedFile( + ' +½ ++google/cloud/securitycenter/v2/source.protogoogle.cloud.securitycenter.v2"ý +Source +name (  + display_name (  + description (  +canonical_name ( :¡êA +$securitycenter.googleapis.com/Source-organizations/{organization}/sources/{source}!folders/{folder}/sources/{source}#projects/{project}/sources/{source}Bå +"com.google.cloud.securitycenter.v2B SourceProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ToxicCombination.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ToxicCombination.php new file mode 100644 index 000000000000..628745d06027 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ToxicCombination.php @@ -0,0 +1,30 @@ +internalAddGeneratedFile( + ' +Ÿ +6google/cloud/securitycenter/v2/toxic_combination.protogoogle.cloud.securitycenter.v2"K +ToxicCombination +attack_exposure_score ( +related_findings ( Bï +"com.google.cloud.securitycenter.v2BToxicCombinationProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ValuedResource.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ValuedResource.php new file mode 100644 index 0000000000000000000000000000000000000000..936e64c1da32cd998e0a24646556da851a645cfa GIT binary patch literal 1720 zcmbVM;ZD;~6m|m?uP~P)Iwc{ONy1RodINL2s$od z#3UB%c)cESp-IjiY#~>Muv~{n^%Gbr*G|@WC?%e2A{F)t>02moTEy$-DKb45vw?|h zhTQyxlD{x44|R1H1^%)~0Dx_rBkC9?g4M?EA!0_?V1`x|SX#-)(wZ?Wt*sOQFfD^p z*cO<_BS>%sAb%XMV__3gW-$I*$5h8QX4tUsC2wyB_6&<64sp}B=h-I1#D;!A-8NBf z69$;R@47=c9Xl{AuHiGp+0kl#i?(5DWkgLEJB+vu?y9PN#3EjOOKx+N)`!DAmLxj>DFO7DLny8Q%C!? z>VA4g{gS*ceolg|sVN3T8V;s1*NJ?bIO&wQeZ$6={5}$!=C3Ayhk1(6Ju5sK{|rZh z5%$XC#PG%nGL)=Iq#M8%F+ExpzSO%v z6ClgEx@8k~mjqHb#1)#;NPKu7T&8e=Ip=*ct+{+0Tz2D=ayo@+!`I|$Rj92j)K+ee z)V3s)TW%{qLI-W6$B`fhE*e+l>*QJhqN)N#RpT(K+EzMuh2+29h=gS;P`L?F{G%WW L&p^9|U0mtc$t#7UD>IB7#>5|c4AX=_S4LI@);wksQxbUdSx<%6S%EUEf& zLpqt>^a*m;SLj_|qgQ>7PVf2x-E$-v+mHg~1~_N;JG*jBCh6> z4&OfI{nvzdT-&#G+vMB9$q8|J-R?PtN!&co?^O9pwZTg}a$^-;Jv(r9Qsld~-8IR& zZrVX--6MM78vdzHET6dR{la=bFzFF(!^Gu0g9os*9`PJaCw!^4eMo$*qxo8^#E@Dd zMQYVYkXp^cCV*~gp2s(b5#cA`@y7|;rlIqmule}vq2Z~9W%!0>8t*W-E&fC^J%R}5 zZBGJA_YK?PsYBJ$$=YK+#H6+l9UE)0#mBMLXnC+SEt%$LX=ZDOc)DvizU|h~v{>vC ze^6Aqvi3MSmckh){8|`ev3M@XE#7wnGJHDEyTlJ%Ym>!I0p1V(YF$vdL39lR>+5Sh zr&v5o>kNfu_4I`i=Q65p`06Aa|pWkJL|-;Vrpe@;M(rUsBSI;4l>a>uYt-a4jj(6+TL6_JcS%0zaG!F_cVIB5t# zi2S*`aMNyk#O>py8kUN}rv7M{o$NH?&Ttu+c}HAZ?P#aj8M=~d0t|)qDcn-z`hltl z4Y^WMk1F+=B+9$8w3GRSn}$@mdYnn%{Y)LA79JgDlH3eT?8&9QOp3b!Gom6lWKk$* zCUU{%y#tuW=V|hoy)8=7TtX6hq1<%9-@n4}S z$Yo)>Ea9mOFeg;-P`M^FaDRe^QK_m2mFjUNGnre1*)uYvVJejFh+A`zLdj-LGn@Mz zvx+Vs6Krc9Q9a#u!=6lV`!KKhKDLe8CptJEj)4H&NX4lagjnM=@L(M$q#|yk`7~Qy72WCQELMPB?91TkO`1Z$R$*L z%2L~kDF6J5phxJ=z8Rr6w+WM2ScgPZe{w~bI`!cWVMVvC6QhG)S^AChPt~XoDZ$f) zr&mOiS@Uuw$k4>P^urwk(Z0Ag&^|0h62ZRqG1lz=z{>rafEy!xxd*p}Mnez})TSgh zs>)ca+=k`R?TXYmt||xEJ9l7ZbW7OT7euMjz(%?SOQU<`DsA1=d8gXmt9sPdCS=0U zhN!m+_aY#%dRQwp_rV7IJCtiC7Jt>0PX@#K7h|^3W`QqDoJ%!k-j^U z6=`RzDt94!kx`{up`wC9chN2lDTx|-p=+pfxgIQxQ<{gnM|DY2F2qw5im=71@rDRTlsfhF| zz{!U-408+#r8HV+nI^b2K(r9n<;;MEp312(9ZwQB;YKussC2}Q6m|iob%&?}mF0%a z{8Q8bs(Q0X#f8|pPh5{`44olnb3a37d`jS!U@o3C)WMjr0SjKx?in6+R(%`-qgm)q zEC_7=#`!frm=L*Dxa|d9)JuE?sDaaUwGKgf4+CJ4ZU3Es9Ex-d@{xgVn;V(t*f3g4 ze7_%>$HSc6TkqQA?*z>;@Tm~bP~qdjX>X1%{Fc05VsC^zdn4rIs)+2hk#83Mhz(lN zD`N1B2u)h}j`%CN8iEvy45e5cg(()Bh4vIH)W)O1B>W^C&WC3CkIwPTG90$w!+U^# E0oidV*8l(j literal 0 HcmV?d00001 diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Access.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Access.php new file mode 100644 index 000000000000..47690622e2e4 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Access.php @@ -0,0 +1,521 @@ +google.cloud.securitycenter.v2.Access + */ +class Access extends \Google\Protobuf\Internal\Message +{ + /** + * Associated email, such as "foo@google.com". + * The email address of the authenticated user or a service account acting on + * behalf of a third party principal making the request. For third party + * identity callers, the `principal_subject` field is populated instead of + * this field. For privacy reasons, the principal email address is sometimes + * redacted. For more information, see [Caller identities in audit + * logs](https://cloud.google.com/logging/docs/audit#user-id). + * + * Generated from protobuf field string principal_email = 1; + */ + protected $principal_email = ''; + /** + * Caller's IP address, such as "1.1.1.1". + * + * Generated from protobuf field string caller_ip = 2; + */ + protected $caller_ip = ''; + /** + * The caller IP's geolocation, which identifies where the call came from. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Geolocation caller_ip_geo = 3; + */ + protected $caller_ip_geo = null; + /** + * Type of user agent associated with the finding. For example, an operating + * system shell or an embedded or standalone application. + * + * Generated from protobuf field string user_agent_family = 4; + */ + protected $user_agent_family = ''; + /** + * The caller's user agent string associated with the finding. + * + * Generated from protobuf field string user_agent = 5; + */ + protected $user_agent = ''; + /** + * This is the API service that the service account made a call to, e.g. + * "iam.googleapis.com" + * + * Generated from protobuf field string service_name = 6; + */ + protected $service_name = ''; + /** + * The method that the service account called, e.g. "SetIamPolicy". + * + * Generated from protobuf field string method_name = 7; + */ + protected $method_name = ''; + /** + * A string that represents the principal_subject that is associated with the + * identity. Unlike `principal_email`, `principal_subject` supports principals + * that aren't associated with email addresses, such as third party + * principals. For most identities, the format is + * `principal://iam.googleapis.com/{identity pool name}/subject/{subject}`. + * Some GKE identities, such as GKE_WORKLOAD, FREEFORM, and GKE_HUB_WORKLOAD, + * still use the legacy format `serviceAccount:{identity pool + * name}[{subject}]`. + * + * Generated from protobuf field string principal_subject = 8; + */ + protected $principal_subject = ''; + /** + * The name of the service account key that was used to create or exchange + * credentials when authenticating the service account that made the request. + * This is a scheme-less URI full resource name. For example: + * "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}". + * + * Generated from protobuf field string service_account_key_name = 9; + */ + protected $service_account_key_name = ''; + /** + * The identity delegation history of an authenticated service account that + * made the request. The `serviceAccountDelegationInfo[]` object contains + * information about the real authorities that try to access Google Cloud + * resources by delegating on a service account. When multiple authorities are + * present, they are guaranteed to be sorted based on the original ordering of + * the identity delegation events. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ServiceAccountDelegationInfo service_account_delegation_info = 10; + */ + private $service_account_delegation_info; + /** + * A string that represents a username. The username provided depends on the + * type of the finding and is likely not an IAM principal. For example, this + * can be a system username if the finding is related to a virtual machine, or + * it can be an application login username. + * + * Generated from protobuf field string user_name = 11; + */ + protected $user_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $principal_email + * Associated email, such as "foo@google.com". + * The email address of the authenticated user or a service account acting on + * behalf of a third party principal making the request. For third party + * identity callers, the `principal_subject` field is populated instead of + * this field. For privacy reasons, the principal email address is sometimes + * redacted. For more information, see [Caller identities in audit + * logs](https://cloud.google.com/logging/docs/audit#user-id). + * @type string $caller_ip + * Caller's IP address, such as "1.1.1.1". + * @type \Google\Cloud\SecurityCenter\V2\Geolocation $caller_ip_geo + * The caller IP's geolocation, which identifies where the call came from. + * @type string $user_agent_family + * Type of user agent associated with the finding. For example, an operating + * system shell or an embedded or standalone application. + * @type string $user_agent + * The caller's user agent string associated with the finding. + * @type string $service_name + * This is the API service that the service account made a call to, e.g. + * "iam.googleapis.com" + * @type string $method_name + * The method that the service account called, e.g. "SetIamPolicy". + * @type string $principal_subject + * A string that represents the principal_subject that is associated with the + * identity. Unlike `principal_email`, `principal_subject` supports principals + * that aren't associated with email addresses, such as third party + * principals. For most identities, the format is + * `principal://iam.googleapis.com/{identity pool name}/subject/{subject}`. + * Some GKE identities, such as GKE_WORKLOAD, FREEFORM, and GKE_HUB_WORKLOAD, + * still use the legacy format `serviceAccount:{identity pool + * name}[{subject}]`. + * @type string $service_account_key_name + * The name of the service account key that was used to create or exchange + * credentials when authenticating the service account that made the request. + * This is a scheme-less URI full resource name. For example: + * "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}". + * @type array<\Google\Cloud\SecurityCenter\V2\ServiceAccountDelegationInfo>|\Google\Protobuf\Internal\RepeatedField $service_account_delegation_info + * The identity delegation history of an authenticated service account that + * made the request. The `serviceAccountDelegationInfo[]` object contains + * information about the real authorities that try to access Google Cloud + * resources by delegating on a service account. When multiple authorities are + * present, they are guaranteed to be sorted based on the original ordering of + * the identity delegation events. + * @type string $user_name + * A string that represents a username. The username provided depends on the + * type of the finding and is likely not an IAM principal. For example, this + * can be a system username if the finding is related to a virtual machine, or + * it can be an application login username. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Access::initOnce(); + parent::__construct($data); + } + + /** + * Associated email, such as "foo@google.com". + * The email address of the authenticated user or a service account acting on + * behalf of a third party principal making the request. For third party + * identity callers, the `principal_subject` field is populated instead of + * this field. For privacy reasons, the principal email address is sometimes + * redacted. For more information, see [Caller identities in audit + * logs](https://cloud.google.com/logging/docs/audit#user-id). + * + * Generated from protobuf field string principal_email = 1; + * @return string + */ + public function getPrincipalEmail() + { + return $this->principal_email; + } + + /** + * Associated email, such as "foo@google.com". + * The email address of the authenticated user or a service account acting on + * behalf of a third party principal making the request. For third party + * identity callers, the `principal_subject` field is populated instead of + * this field. For privacy reasons, the principal email address is sometimes + * redacted. For more information, see [Caller identities in audit + * logs](https://cloud.google.com/logging/docs/audit#user-id). + * + * Generated from protobuf field string principal_email = 1; + * @param string $var + * @return $this + */ + public function setPrincipalEmail($var) + { + GPBUtil::checkString($var, True); + $this->principal_email = $var; + + return $this; + } + + /** + * Caller's IP address, such as "1.1.1.1". + * + * Generated from protobuf field string caller_ip = 2; + * @return string + */ + public function getCallerIp() + { + return $this->caller_ip; + } + + /** + * Caller's IP address, such as "1.1.1.1". + * + * Generated from protobuf field string caller_ip = 2; + * @param string $var + * @return $this + */ + public function setCallerIp($var) + { + GPBUtil::checkString($var, True); + $this->caller_ip = $var; + + return $this; + } + + /** + * The caller IP's geolocation, which identifies where the call came from. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Geolocation caller_ip_geo = 3; + * @return \Google\Cloud\SecurityCenter\V2\Geolocation|null + */ + public function getCallerIpGeo() + { + return $this->caller_ip_geo; + } + + public function hasCallerIpGeo() + { + return isset($this->caller_ip_geo); + } + + public function clearCallerIpGeo() + { + unset($this->caller_ip_geo); + } + + /** + * The caller IP's geolocation, which identifies where the call came from. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Geolocation caller_ip_geo = 3; + * @param \Google\Cloud\SecurityCenter\V2\Geolocation $var + * @return $this + */ + public function setCallerIpGeo($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Geolocation::class); + $this->caller_ip_geo = $var; + + return $this; + } + + /** + * Type of user agent associated with the finding. For example, an operating + * system shell or an embedded or standalone application. + * + * Generated from protobuf field string user_agent_family = 4; + * @return string + */ + public function getUserAgentFamily() + { + return $this->user_agent_family; + } + + /** + * Type of user agent associated with the finding. For example, an operating + * system shell or an embedded or standalone application. + * + * Generated from protobuf field string user_agent_family = 4; + * @param string $var + * @return $this + */ + public function setUserAgentFamily($var) + { + GPBUtil::checkString($var, True); + $this->user_agent_family = $var; + + return $this; + } + + /** + * The caller's user agent string associated with the finding. + * + * Generated from protobuf field string user_agent = 5; + * @return string + */ + public function getUserAgent() + { + return $this->user_agent; + } + + /** + * The caller's user agent string associated with the finding. + * + * Generated from protobuf field string user_agent = 5; + * @param string $var + * @return $this + */ + public function setUserAgent($var) + { + GPBUtil::checkString($var, True); + $this->user_agent = $var; + + return $this; + } + + /** + * This is the API service that the service account made a call to, e.g. + * "iam.googleapis.com" + * + * Generated from protobuf field string service_name = 6; + * @return string + */ + public function getServiceName() + { + return $this->service_name; + } + + /** + * This is the API service that the service account made a call to, e.g. + * "iam.googleapis.com" + * + * Generated from protobuf field string service_name = 6; + * @param string $var + * @return $this + */ + public function setServiceName($var) + { + GPBUtil::checkString($var, True); + $this->service_name = $var; + + return $this; + } + + /** + * The method that the service account called, e.g. "SetIamPolicy". + * + * Generated from protobuf field string method_name = 7; + * @return string + */ + public function getMethodName() + { + return $this->method_name; + } + + /** + * The method that the service account called, e.g. "SetIamPolicy". + * + * Generated from protobuf field string method_name = 7; + * @param string $var + * @return $this + */ + public function setMethodName($var) + { + GPBUtil::checkString($var, True); + $this->method_name = $var; + + return $this; + } + + /** + * A string that represents the principal_subject that is associated with the + * identity. Unlike `principal_email`, `principal_subject` supports principals + * that aren't associated with email addresses, such as third party + * principals. For most identities, the format is + * `principal://iam.googleapis.com/{identity pool name}/subject/{subject}`. + * Some GKE identities, such as GKE_WORKLOAD, FREEFORM, and GKE_HUB_WORKLOAD, + * still use the legacy format `serviceAccount:{identity pool + * name}[{subject}]`. + * + * Generated from protobuf field string principal_subject = 8; + * @return string + */ + public function getPrincipalSubject() + { + return $this->principal_subject; + } + + /** + * A string that represents the principal_subject that is associated with the + * identity. Unlike `principal_email`, `principal_subject` supports principals + * that aren't associated with email addresses, such as third party + * principals. For most identities, the format is + * `principal://iam.googleapis.com/{identity pool name}/subject/{subject}`. + * Some GKE identities, such as GKE_WORKLOAD, FREEFORM, and GKE_HUB_WORKLOAD, + * still use the legacy format `serviceAccount:{identity pool + * name}[{subject}]`. + * + * Generated from protobuf field string principal_subject = 8; + * @param string $var + * @return $this + */ + public function setPrincipalSubject($var) + { + GPBUtil::checkString($var, True); + $this->principal_subject = $var; + + return $this; + } + + /** + * The name of the service account key that was used to create or exchange + * credentials when authenticating the service account that made the request. + * This is a scheme-less URI full resource name. For example: + * "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}". + * + * Generated from protobuf field string service_account_key_name = 9; + * @return string + */ + public function getServiceAccountKeyName() + { + return $this->service_account_key_name; + } + + /** + * The name of the service account key that was used to create or exchange + * credentials when authenticating the service account that made the request. + * This is a scheme-less URI full resource name. For example: + * "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}". + * + * Generated from protobuf field string service_account_key_name = 9; + * @param string $var + * @return $this + */ + public function setServiceAccountKeyName($var) + { + GPBUtil::checkString($var, True); + $this->service_account_key_name = $var; + + return $this; + } + + /** + * The identity delegation history of an authenticated service account that + * made the request. The `serviceAccountDelegationInfo[]` object contains + * information about the real authorities that try to access Google Cloud + * resources by delegating on a service account. When multiple authorities are + * present, they are guaranteed to be sorted based on the original ordering of + * the identity delegation events. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ServiceAccountDelegationInfo service_account_delegation_info = 10; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getServiceAccountDelegationInfo() + { + return $this->service_account_delegation_info; + } + + /** + * The identity delegation history of an authenticated service account that + * made the request. The `serviceAccountDelegationInfo[]` object contains + * information about the real authorities that try to access Google Cloud + * resources by delegating on a service account. When multiple authorities are + * present, they are guaranteed to be sorted based on the original ordering of + * the identity delegation events. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ServiceAccountDelegationInfo service_account_delegation_info = 10; + * @param array<\Google\Cloud\SecurityCenter\V2\ServiceAccountDelegationInfo>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setServiceAccountDelegationInfo($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ServiceAccountDelegationInfo::class); + $this->service_account_delegation_info = $arr; + + return $this; + } + + /** + * A string that represents a username. The username provided depends on the + * type of the finding and is likely not an IAM principal. For example, this + * can be a system username if the finding is related to a virtual machine, or + * it can be an application login username. + * + * Generated from protobuf field string user_name = 11; + * @return string + */ + public function getUserName() + { + return $this->user_name; + } + + /** + * A string that represents a username. The username provided depends on the + * type of the finding and is likely not an IAM principal. For example, this + * can be a system username if the finding is related to a virtual machine, or + * it can be an application login username. + * + * Generated from protobuf field string user_name = 11; + * @param string $var + * @return $this + */ + public function setUserName($var) + { + GPBUtil::checkString($var, True); + $this->user_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AdaptiveProtection.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AdaptiveProtection.php new file mode 100644 index 000000000000..e9bb98caba93 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AdaptiveProtection.php @@ -0,0 +1,84 @@ +google.cloud.securitycenter.v2.AdaptiveProtection + */ +class AdaptiveProtection extends \Google\Protobuf\Internal\Message +{ + /** + * A score of 0 means that there is low confidence that the detected event is + * an actual attack. A score of 1 means that there is high confidence that the + * detected event is an attack. See the [Adaptive Protection + * documentation](https://cloud.google.com/armor/docs/adaptive-protection-overview#configure-alert-tuning) + * for further explanation. + * + * Generated from protobuf field double confidence = 1; + */ + protected $confidence = 0.0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type float $confidence + * A score of 0 means that there is low confidence that the detected event is + * an actual attack. A score of 1 means that there is high confidence that the + * detected event is an attack. See the [Adaptive Protection + * documentation](https://cloud.google.com/armor/docs/adaptive-protection-overview#configure-alert-tuning) + * for further explanation. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\CloudArmor::initOnce(); + parent::__construct($data); + } + + /** + * A score of 0 means that there is low confidence that the detected event is + * an actual attack. A score of 1 means that there is high confidence that the + * detected event is an attack. See the [Adaptive Protection + * documentation](https://cloud.google.com/armor/docs/adaptive-protection-overview#configure-alert-tuning) + * for further explanation. + * + * Generated from protobuf field double confidence = 1; + * @return float + */ + public function getConfidence() + { + return $this->confidence; + } + + /** + * A score of 0 means that there is low confidence that the detected event is + * an actual attack. A score of 1 means that there is high confidence that the + * detected event is an attack. See the [Adaptive Protection + * documentation](https://cloud.google.com/armor/docs/adaptive-protection-overview#configure-alert-tuning) + * for further explanation. + * + * Generated from protobuf field double confidence = 1; + * @param float $var + * @return $this + */ + public function setConfidence($var) + { + GPBUtil::checkDouble($var); + $this->confidence = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Application.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Application.php new file mode 100644 index 000000000000..6dca97cc5b28 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Application.php @@ -0,0 +1,109 @@ +google.cloud.securitycenter.v2.Application + */ +class Application extends \Google\Protobuf\Internal\Message +{ + /** + * The base URI that identifies the network location of the application in + * which the vulnerability was detected. For example, `http://example.com`. + * + * Generated from protobuf field string base_uri = 1; + */ + protected $base_uri = ''; + /** + * The full URI with payload that could be used to reproduce the + * vulnerability. For example, `http://example.com?p=aMmYgI6H`. + * + * Generated from protobuf field string full_uri = 2; + */ + protected $full_uri = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $base_uri + * The base URI that identifies the network location of the application in + * which the vulnerability was detected. For example, `http://example.com`. + * @type string $full_uri + * The full URI with payload that could be used to reproduce the + * vulnerability. For example, `http://example.com?p=aMmYgI6H`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Application::initOnce(); + parent::__construct($data); + } + + /** + * The base URI that identifies the network location of the application in + * which the vulnerability was detected. For example, `http://example.com`. + * + * Generated from protobuf field string base_uri = 1; + * @return string + */ + public function getBaseUri() + { + return $this->base_uri; + } + + /** + * The base URI that identifies the network location of the application in + * which the vulnerability was detected. For example, `http://example.com`. + * + * Generated from protobuf field string base_uri = 1; + * @param string $var + * @return $this + */ + public function setBaseUri($var) + { + GPBUtil::checkString($var, True); + $this->base_uri = $var; + + return $this; + } + + /** + * The full URI with payload that could be used to reproduce the + * vulnerability. For example, `http://example.com?p=aMmYgI6H`. + * + * Generated from protobuf field string full_uri = 2; + * @return string + */ + public function getFullUri() + { + return $this->full_uri; + } + + /** + * The full URI with payload that could be used to reproduce the + * vulnerability. For example, `http://example.com?p=aMmYgI6H`. + * + * Generated from protobuf field string full_uri = 2; + * @param string $var + * @return $this + */ + public function setFullUri($var) + { + GPBUtil::checkString($var, True); + $this->full_uri = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Attack.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Attack.php new file mode 100644 index 000000000000..a260722cbc65 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Attack.php @@ -0,0 +1,135 @@ +google.cloud.securitycenter.v2.Attack + */ +class Attack extends \Google\Protobuf\Internal\Message +{ + /** + * Total PPS (packets per second) volume of attack. + * + * Generated from protobuf field int32 volume_pps = 1; + */ + protected $volume_pps = 0; + /** + * Total BPS (bytes per second) volume of attack. + * + * Generated from protobuf field int32 volume_bps = 2; + */ + protected $volume_bps = 0; + /** + * Type of attack, for example, 'SYN-flood', 'NTP-udp', or 'CHARGEN-udp'. + * + * Generated from protobuf field string classification = 3; + */ + protected $classification = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $volume_pps + * Total PPS (packets per second) volume of attack. + * @type int $volume_bps + * Total BPS (bytes per second) volume of attack. + * @type string $classification + * Type of attack, for example, 'SYN-flood', 'NTP-udp', or 'CHARGEN-udp'. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\CloudArmor::initOnce(); + parent::__construct($data); + } + + /** + * Total PPS (packets per second) volume of attack. + * + * Generated from protobuf field int32 volume_pps = 1; + * @return int + */ + public function getVolumePps() + { + return $this->volume_pps; + } + + /** + * Total PPS (packets per second) volume of attack. + * + * Generated from protobuf field int32 volume_pps = 1; + * @param int $var + * @return $this + */ + public function setVolumePps($var) + { + GPBUtil::checkInt32($var); + $this->volume_pps = $var; + + return $this; + } + + /** + * Total BPS (bytes per second) volume of attack. + * + * Generated from protobuf field int32 volume_bps = 2; + * @return int + */ + public function getVolumeBps() + { + return $this->volume_bps; + } + + /** + * Total BPS (bytes per second) volume of attack. + * + * Generated from protobuf field int32 volume_bps = 2; + * @param int $var + * @return $this + */ + public function setVolumeBps($var) + { + GPBUtil::checkInt32($var); + $this->volume_bps = $var; + + return $this; + } + + /** + * Type of attack, for example, 'SYN-flood', 'NTP-udp', or 'CHARGEN-udp'. + * + * Generated from protobuf field string classification = 3; + * @return string + */ + public function getClassification() + { + return $this->classification; + } + + /** + * Type of attack, for example, 'SYN-flood', 'NTP-udp', or 'CHARGEN-udp'. + * + * Generated from protobuf field string classification = 3; + * @param string $var + * @return $this + */ + public function setClassification($var) + { + GPBUtil::checkString($var, True); + $this->classification = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackExposure.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackExposure.php new file mode 100644 index 000000000000..1c7ab996ecca --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackExposure.php @@ -0,0 +1,313 @@ +google.cloud.securitycenter.v2.AttackExposure + */ +class AttackExposure extends \Google\Protobuf\Internal\Message +{ + /** + * A number between 0 (inclusive) and infinity that represents how important + * this finding is to remediate. The higher the score, the more important it + * is to remediate. + * + * Generated from protobuf field double score = 1; + */ + protected $score = 0.0; + /** + * The most recent time the attack exposure was updated on this finding. + * + * Generated from protobuf field .google.protobuf.Timestamp latest_calculation_time = 2; + */ + protected $latest_calculation_time = null; + /** + * The resource name of the attack path simulation result that contains the + * details regarding this attack exposure score. + * Example: organizations/123/simulations/456/attackExposureResults/789 + * + * Generated from protobuf field string attack_exposure_result = 3; + */ + protected $attack_exposure_result = ''; + /** + * Output only. What state this AttackExposure is in. This captures whether or + * not an attack exposure has been calculated or not. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AttackExposure.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * The number of high value resources that are exposed as a result of this + * finding. + * + * Generated from protobuf field int32 exposed_high_value_resources_count = 5; + */ + protected $exposed_high_value_resources_count = 0; + /** + * The number of medium value resources that are exposed as a result of this + * finding. + * + * Generated from protobuf field int32 exposed_medium_value_resources_count = 6; + */ + protected $exposed_medium_value_resources_count = 0; + /** + * The number of high value resources that are exposed as a result of this + * finding. + * + * Generated from protobuf field int32 exposed_low_value_resources_count = 7; + */ + protected $exposed_low_value_resources_count = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type float $score + * A number between 0 (inclusive) and infinity that represents how important + * this finding is to remediate. The higher the score, the more important it + * is to remediate. + * @type \Google\Protobuf\Timestamp $latest_calculation_time + * The most recent time the attack exposure was updated on this finding. + * @type string $attack_exposure_result + * The resource name of the attack path simulation result that contains the + * details regarding this attack exposure score. + * Example: organizations/123/simulations/456/attackExposureResults/789 + * @type int $state + * Output only. What state this AttackExposure is in. This captures whether or + * not an attack exposure has been calculated or not. + * @type int $exposed_high_value_resources_count + * The number of high value resources that are exposed as a result of this + * finding. + * @type int $exposed_medium_value_resources_count + * The number of medium value resources that are exposed as a result of this + * finding. + * @type int $exposed_low_value_resources_count + * The number of high value resources that are exposed as a result of this + * finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\AttackExposure::initOnce(); + parent::__construct($data); + } + + /** + * A number between 0 (inclusive) and infinity that represents how important + * this finding is to remediate. The higher the score, the more important it + * is to remediate. + * + * Generated from protobuf field double score = 1; + * @return float + */ + public function getScore() + { + return $this->score; + } + + /** + * A number between 0 (inclusive) and infinity that represents how important + * this finding is to remediate. The higher the score, the more important it + * is to remediate. + * + * Generated from protobuf field double score = 1; + * @param float $var + * @return $this + */ + public function setScore($var) + { + GPBUtil::checkDouble($var); + $this->score = $var; + + return $this; + } + + /** + * The most recent time the attack exposure was updated on this finding. + * + * Generated from protobuf field .google.protobuf.Timestamp latest_calculation_time = 2; + * @return \Google\Protobuf\Timestamp|null + */ + public function getLatestCalculationTime() + { + return $this->latest_calculation_time; + } + + public function hasLatestCalculationTime() + { + return isset($this->latest_calculation_time); + } + + public function clearLatestCalculationTime() + { + unset($this->latest_calculation_time); + } + + /** + * The most recent time the attack exposure was updated on this finding. + * + * Generated from protobuf field .google.protobuf.Timestamp latest_calculation_time = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setLatestCalculationTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->latest_calculation_time = $var; + + return $this; + } + + /** + * The resource name of the attack path simulation result that contains the + * details regarding this attack exposure score. + * Example: organizations/123/simulations/456/attackExposureResults/789 + * + * Generated from protobuf field string attack_exposure_result = 3; + * @return string + */ + public function getAttackExposureResult() + { + return $this->attack_exposure_result; + } + + /** + * The resource name of the attack path simulation result that contains the + * details regarding this attack exposure score. + * Example: organizations/123/simulations/456/attackExposureResults/789 + * + * Generated from protobuf field string attack_exposure_result = 3; + * @param string $var + * @return $this + */ + public function setAttackExposureResult($var) + { + GPBUtil::checkString($var, True); + $this->attack_exposure_result = $var; + + return $this; + } + + /** + * Output only. What state this AttackExposure is in. This captures whether or + * not an attack exposure has been calculated or not. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AttackExposure.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. What state this AttackExposure is in. This captures whether or + * not an attack exposure has been calculated or not. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AttackExposure.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\AttackExposure\State::class); + $this->state = $var; + + return $this; + } + + /** + * The number of high value resources that are exposed as a result of this + * finding. + * + * Generated from protobuf field int32 exposed_high_value_resources_count = 5; + * @return int + */ + public function getExposedHighValueResourcesCount() + { + return $this->exposed_high_value_resources_count; + } + + /** + * The number of high value resources that are exposed as a result of this + * finding. + * + * Generated from protobuf field int32 exposed_high_value_resources_count = 5; + * @param int $var + * @return $this + */ + public function setExposedHighValueResourcesCount($var) + { + GPBUtil::checkInt32($var); + $this->exposed_high_value_resources_count = $var; + + return $this; + } + + /** + * The number of medium value resources that are exposed as a result of this + * finding. + * + * Generated from protobuf field int32 exposed_medium_value_resources_count = 6; + * @return int + */ + public function getExposedMediumValueResourcesCount() + { + return $this->exposed_medium_value_resources_count; + } + + /** + * The number of medium value resources that are exposed as a result of this + * finding. + * + * Generated from protobuf field int32 exposed_medium_value_resources_count = 6; + * @param int $var + * @return $this + */ + public function setExposedMediumValueResourcesCount($var) + { + GPBUtil::checkInt32($var); + $this->exposed_medium_value_resources_count = $var; + + return $this; + } + + /** + * The number of high value resources that are exposed as a result of this + * finding. + * + * Generated from protobuf field int32 exposed_low_value_resources_count = 7; + * @return int + */ + public function getExposedLowValueResourcesCount() + { + return $this->exposed_low_value_resources_count; + } + + /** + * The number of high value resources that are exposed as a result of this + * finding. + * + * Generated from protobuf field int32 exposed_low_value_resources_count = 7; + * @param int $var + * @return $this + */ + public function setExposedLowValueResourcesCount($var) + { + GPBUtil::checkInt32($var); + $this->exposed_low_value_resources_count = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackExposure/State.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackExposure/State.php new file mode 100644 index 000000000000..1b5c43e6e677 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackExposure/State.php @@ -0,0 +1,64 @@ +google.cloud.securitycenter.v2.AttackExposure.State + */ +class State +{ + /** + * The state is not specified. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The attack exposure has been calculated. + * + * Generated from protobuf enum CALCULATED = 1; + */ + const CALCULATED = 1; + /** + * The attack exposure has not been calculated. + * + * Generated from protobuf enum NOT_CALCULATED = 2; + */ + const NOT_CALCULATED = 2; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::CALCULATED => 'CALCULATED', + self::NOT_CALCULATED => 'NOT_CALCULATED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(State::class, \Google\Cloud\SecurityCenter\V2\AttackExposure_State::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath.php new file mode 100644 index 000000000000..bb00ddfd9c43 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath.php @@ -0,0 +1,139 @@ +google.cloud.securitycenter.v2.AttackPath + */ +class AttackPath extends \Google\Protobuf\Internal\Message +{ + /** + * The attack path name, for example, + * `organizations/12/simulations/34/valuedResources/56/attackPaths/78` + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * A list of nodes that exist in this attack path. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathNode path_nodes = 2; + */ + private $path_nodes; + /** + * A list of the edges between nodes in this attack path. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathEdge edges = 3; + */ + private $edges; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The attack path name, for example, + * `organizations/12/simulations/34/valuedResources/56/attackPaths/78` + * @type array<\Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode>|\Google\Protobuf\Internal\RepeatedField $path_nodes + * A list of nodes that exist in this attack path. + * @type array<\Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathEdge>|\Google\Protobuf\Internal\RepeatedField $edges + * A list of the edges between nodes in this attack path. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\AttackPath::initOnce(); + parent::__construct($data); + } + + /** + * The attack path name, for example, + * `organizations/12/simulations/34/valuedResources/56/attackPaths/78` + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The attack path name, for example, + * `organizations/12/simulations/34/valuedResources/56/attackPaths/78` + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * A list of nodes that exist in this attack path. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathNode path_nodes = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPathNodes() + { + return $this->path_nodes; + } + + /** + * A list of nodes that exist in this attack path. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathNode path_nodes = 2; + * @param array<\Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPathNodes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode::class); + $this->path_nodes = $arr; + + return $this; + } + + /** + * A list of the edges between nodes in this attack path. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathEdge edges = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getEdges() + { + return $this->edges; + } + + /** + * A list of the edges between nodes in this attack path. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathEdge edges = 3; + * @param array<\Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathEdge>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setEdges($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathEdge::class); + $this->edges = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathEdge.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathEdge.php new file mode 100644 index 000000000000..e16a8769ae8e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathEdge.php @@ -0,0 +1,105 @@ +google.cloud.securitycenter.v2.AttackPath.AttackPathEdge + */ +class AttackPathEdge extends \Google\Protobuf\Internal\Message +{ + /** + * The attack node uuid of the source node. + * + * Generated from protobuf field string source = 1; + */ + protected $source = ''; + /** + * The attack node uuid of the destination node. + * + * Generated from protobuf field string destination = 2; + */ + protected $destination = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $source + * The attack node uuid of the source node. + * @type string $destination + * The attack node uuid of the destination node. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\AttackPath::initOnce(); + parent::__construct($data); + } + + /** + * The attack node uuid of the source node. + * + * Generated from protobuf field string source = 1; + * @return string + */ + public function getSource() + { + return $this->source; + } + + /** + * The attack node uuid of the source node. + * + * Generated from protobuf field string source = 1; + * @param string $var + * @return $this + */ + public function setSource($var) + { + GPBUtil::checkString($var, True); + $this->source = $var; + + return $this; + } + + /** + * The attack node uuid of the destination node. + * + * Generated from protobuf field string destination = 2; + * @return string + */ + public function getDestination() + { + return $this->destination; + } + + /** + * The attack node uuid of the destination node. + * + * Generated from protobuf field string destination = 2; + * @param string $var + * @return $this + */ + public function setDestination($var) + { + GPBUtil::checkString($var, True); + $this->destination = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AttackPathEdge::class, \Google\Cloud\SecurityCenter\V2\AttackPath_AttackPathEdge::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode.php new file mode 100644 index 000000000000..972723b60ce9 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode.php @@ -0,0 +1,256 @@ +google.cloud.securitycenter.v2.AttackPath.AttackPathNode + */ +class AttackPathNode extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the resource at this point in the attack path. + * The format of the name follows the Cloud Asset Inventory [resource + * name + * format]("https://cloud.google.com/asset-inventory/docs/resource-name-format") + * + * Generated from protobuf field string resource = 1; + */ + protected $resource = ''; + /** + * The [supported resource + * type](https://cloud.google.com/asset-inventory/docs/supported-asset-types") + * + * Generated from protobuf field string resource_type = 2; + */ + protected $resource_type = ''; + /** + * Human-readable name of this resource. + * + * Generated from protobuf field string display_name = 3; + */ + protected $display_name = ''; + /** + * The findings associated with this node in the attack path. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathNode.PathNodeAssociatedFinding associated_findings = 4; + */ + private $associated_findings; + /** + * Unique id of the attack path node. + * + * Generated from protobuf field string uuid = 5; + */ + protected $uuid = ''; + /** + * A list of attack step nodes that exist in this attack path node. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathNode.AttackStepNode attack_steps = 6; + */ + private $attack_steps; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $resource + * The name of the resource at this point in the attack path. + * The format of the name follows the Cloud Asset Inventory [resource + * name + * format]("https://cloud.google.com/asset-inventory/docs/resource-name-format") + * @type string $resource_type + * The [supported resource + * type](https://cloud.google.com/asset-inventory/docs/supported-asset-types") + * @type string $display_name + * Human-readable name of this resource. + * @type array<\Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode\PathNodeAssociatedFinding>|\Google\Protobuf\Internal\RepeatedField $associated_findings + * The findings associated with this node in the attack path. + * @type string $uuid + * Unique id of the attack path node. + * @type array<\Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode\AttackStepNode>|\Google\Protobuf\Internal\RepeatedField $attack_steps + * A list of attack step nodes that exist in this attack path node. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\AttackPath::initOnce(); + parent::__construct($data); + } + + /** + * The name of the resource at this point in the attack path. + * The format of the name follows the Cloud Asset Inventory [resource + * name + * format]("https://cloud.google.com/asset-inventory/docs/resource-name-format") + * + * Generated from protobuf field string resource = 1; + * @return string + */ + public function getResource() + { + return $this->resource; + } + + /** + * The name of the resource at this point in the attack path. + * The format of the name follows the Cloud Asset Inventory [resource + * name + * format]("https://cloud.google.com/asset-inventory/docs/resource-name-format") + * + * Generated from protobuf field string resource = 1; + * @param string $var + * @return $this + */ + public function setResource($var) + { + GPBUtil::checkString($var, True); + $this->resource = $var; + + return $this; + } + + /** + * The [supported resource + * type](https://cloud.google.com/asset-inventory/docs/supported-asset-types") + * + * Generated from protobuf field string resource_type = 2; + * @return string + */ + public function getResourceType() + { + return $this->resource_type; + } + + /** + * The [supported resource + * type](https://cloud.google.com/asset-inventory/docs/supported-asset-types") + * + * Generated from protobuf field string resource_type = 2; + * @param string $var + * @return $this + */ + public function setResourceType($var) + { + GPBUtil::checkString($var, True); + $this->resource_type = $var; + + return $this; + } + + /** + * Human-readable name of this resource. + * + * Generated from protobuf field string display_name = 3; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * Human-readable name of this resource. + * + * Generated from protobuf field string display_name = 3; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * The findings associated with this node in the attack path. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathNode.PathNodeAssociatedFinding associated_findings = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAssociatedFindings() + { + return $this->associated_findings; + } + + /** + * The findings associated with this node in the attack path. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathNode.PathNodeAssociatedFinding associated_findings = 4; + * @param array<\Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode\PathNodeAssociatedFinding>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAssociatedFindings($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode\PathNodeAssociatedFinding::class); + $this->associated_findings = $arr; + + return $this; + } + + /** + * Unique id of the attack path node. + * + * Generated from protobuf field string uuid = 5; + * @return string + */ + public function getUuid() + { + return $this->uuid; + } + + /** + * Unique id of the attack path node. + * + * Generated from protobuf field string uuid = 5; + * @param string $var + * @return $this + */ + public function setUuid($var) + { + GPBUtil::checkString($var, True); + $this->uuid = $var; + + return $this; + } + + /** + * A list of attack step nodes that exist in this attack path node. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathNode.AttackStepNode attack_steps = 6; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAttackSteps() + { + return $this->attack_steps; + } + + /** + * A list of attack step nodes that exist in this attack path node. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathNode.AttackStepNode attack_steps = 6; + * @param array<\Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode\AttackStepNode>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAttackSteps($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode\AttackStepNode::class); + $this->attack_steps = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AttackPathNode::class, \Google\Cloud\SecurityCenter\V2\AttackPath_AttackPathNode::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/AttackStepNode.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/AttackStepNode.php new file mode 100644 index 000000000000..a6ac0b4f49f2 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/AttackStepNode.php @@ -0,0 +1,206 @@ +google.cloud.securitycenter.v2.AttackPath.AttackPathNode.AttackStepNode + */ +class AttackStepNode extends \Google\Protobuf\Internal\Message +{ + /** + * Unique ID for one Node + * + * Generated from protobuf field string uuid = 1; + */ + protected $uuid = ''; + /** + * Attack step type. Can be either AND, OR or DEFENSE + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AttackPath.AttackPathNode.NodeType type = 2; + */ + protected $type = 0; + /** + * User friendly name of the attack step + * + * Generated from protobuf field string display_name = 3; + */ + protected $display_name = ''; + /** + * Attack step labels for metadata + * + * Generated from protobuf field map labels = 4; + */ + private $labels; + /** + * Attack step description + * + * Generated from protobuf field string description = 5; + */ + protected $description = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $uuid + * Unique ID for one Node + * @type int $type + * Attack step type. Can be either AND, OR or DEFENSE + * @type string $display_name + * User friendly name of the attack step + * @type array|\Google\Protobuf\Internal\MapField $labels + * Attack step labels for metadata + * @type string $description + * Attack step description + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\AttackPath::initOnce(); + parent::__construct($data); + } + + /** + * Unique ID for one Node + * + * Generated from protobuf field string uuid = 1; + * @return string + */ + public function getUuid() + { + return $this->uuid; + } + + /** + * Unique ID for one Node + * + * Generated from protobuf field string uuid = 1; + * @param string $var + * @return $this + */ + public function setUuid($var) + { + GPBUtil::checkString($var, True); + $this->uuid = $var; + + return $this; + } + + /** + * Attack step type. Can be either AND, OR or DEFENSE + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AttackPath.AttackPathNode.NodeType type = 2; + * @return int + */ + public function getType() + { + return $this->type; + } + + /** + * Attack step type. Can be either AND, OR or DEFENSE + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AttackPath.AttackPathNode.NodeType type = 2; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode\NodeType::class); + $this->type = $var; + + return $this; + } + + /** + * User friendly name of the attack step + * + * Generated from protobuf field string display_name = 3; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * User friendly name of the attack step + * + * Generated from protobuf field string display_name = 3; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * Attack step labels for metadata + * + * Generated from protobuf field map labels = 4; + * @return \Google\Protobuf\Internal\MapField + */ + public function getLabels() + { + return $this->labels; + } + + /** + * Attack step labels for metadata + * + * Generated from protobuf field map labels = 4; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setLabels($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); + $this->labels = $arr; + + return $this; + } + + /** + * Attack step description + * + * Generated from protobuf field string description = 5; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Attack step description + * + * Generated from protobuf field string description = 5; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AttackStepNode::class, \Google\Cloud\SecurityCenter\V2\AttackPath_AttackPathNode_AttackStepNode::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/NodeType.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/NodeType.php new file mode 100644 index 000000000000..56621f5a2508 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/NodeType.php @@ -0,0 +1,78 @@ +google.cloud.securitycenter.v2.AttackPath.AttackPathNode.NodeType + */ +class NodeType +{ + /** + * Type not specified + * + * Generated from protobuf enum NODE_TYPE_UNSPECIFIED = 0; + */ + const NODE_TYPE_UNSPECIFIED = 0; + /** + * Incoming edge joined with AND + * + * Generated from protobuf enum NODE_TYPE_AND = 1; + */ + const NODE_TYPE_AND = 1; + /** + * Incoming edge joined with OR + * + * Generated from protobuf enum NODE_TYPE_OR = 2; + */ + const NODE_TYPE_OR = 2; + /** + * Incoming edge is defense + * + * Generated from protobuf enum NODE_TYPE_DEFENSE = 3; + */ + const NODE_TYPE_DEFENSE = 3; + /** + * Incoming edge is attacker + * + * Generated from protobuf enum NODE_TYPE_ATTACKER = 4; + */ + const NODE_TYPE_ATTACKER = 4; + + private static $valueToName = [ + self::NODE_TYPE_UNSPECIFIED => 'NODE_TYPE_UNSPECIFIED', + self::NODE_TYPE_AND => 'NODE_TYPE_AND', + self::NODE_TYPE_OR => 'NODE_TYPE_OR', + self::NODE_TYPE_DEFENSE => 'NODE_TYPE_DEFENSE', + self::NODE_TYPE_ATTACKER => 'NODE_TYPE_ATTACKER', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(NodeType::class, \Google\Cloud\SecurityCenter\V2\AttackPath_AttackPathNode_NodeType::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/PathNodeAssociatedFinding.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/PathNodeAssociatedFinding.php new file mode 100644 index 000000000000..3faa12e371ff --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/PathNodeAssociatedFinding.php @@ -0,0 +1,142 @@ +google.cloud.securitycenter.v2.AttackPath.AttackPathNode.PathNodeAssociatedFinding + */ +class PathNodeAssociatedFinding extends \Google\Protobuf\Internal\Message +{ + /** + * Canonical name of the associated findings. Example: + * organizations/123/sources/456/findings/789 + * + * Generated from protobuf field string canonical_finding = 1; + */ + protected $canonical_finding = ''; + /** + * The additional taxonomy group within findings from a given source. + * + * Generated from protobuf field string finding_category = 2; + */ + protected $finding_category = ''; + /** + * Full resource name of the finding. + * + * Generated from protobuf field string name = 3; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $canonical_finding + * Canonical name of the associated findings. Example: + * organizations/123/sources/456/findings/789 + * @type string $finding_category + * The additional taxonomy group within findings from a given source. + * @type string $name + * Full resource name of the finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\AttackPath::initOnce(); + parent::__construct($data); + } + + /** + * Canonical name of the associated findings. Example: + * organizations/123/sources/456/findings/789 + * + * Generated from protobuf field string canonical_finding = 1; + * @return string + */ + public function getCanonicalFinding() + { + return $this->canonical_finding; + } + + /** + * Canonical name of the associated findings. Example: + * organizations/123/sources/456/findings/789 + * + * Generated from protobuf field string canonical_finding = 1; + * @param string $var + * @return $this + */ + public function setCanonicalFinding($var) + { + GPBUtil::checkString($var, True); + $this->canonical_finding = $var; + + return $this; + } + + /** + * The additional taxonomy group within findings from a given source. + * + * Generated from protobuf field string finding_category = 2; + * @return string + */ + public function getFindingCategory() + { + return $this->finding_category; + } + + /** + * The additional taxonomy group within findings from a given source. + * + * Generated from protobuf field string finding_category = 2; + * @param string $var + * @return $this + */ + public function setFindingCategory($var) + { + GPBUtil::checkString($var, True); + $this->finding_category = $var; + + return $this; + } + + /** + * Full resource name of the finding. + * + * Generated from protobuf field string name = 3; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Full resource name of the finding. + * + * Generated from protobuf field string name = 3; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(PathNodeAssociatedFinding::class, \Google\Cloud\SecurityCenter\V2\AttackPath_AttackPathNode_PathNodeAssociatedFinding::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata.php new file mode 100644 index 000000000000..a710970023db --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata.php @@ -0,0 +1,160 @@ +google.cloud.securitycenter.v2.AwsMetadata + */ +class AwsMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * The AWS organization associated with the resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata.AwsOrganization organization = 1; + */ + protected $organization = null; + /** + * A list of AWS organizational units associated with the resource, ordered + * from lowest level (closest to the account) to highest level. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AwsMetadata.AwsOrganizationalUnit organizational_units = 2; + */ + private $organizational_units; + /** + * The AWS account associated with the resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata.AwsAccount account = 3; + */ + protected $account = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V2\AwsMetadata\AwsOrganization $organization + * The AWS organization associated with the resource. + * @type array<\Google\Cloud\SecurityCenter\V2\AwsMetadata\AwsOrganizationalUnit>|\Google\Protobuf\Internal\RepeatedField $organizational_units + * A list of AWS organizational units associated with the resource, ordered + * from lowest level (closest to the account) to highest level. + * @type \Google\Cloud\SecurityCenter\V2\AwsMetadata\AwsAccount $account + * The AWS account associated with the resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Resource::initOnce(); + parent::__construct($data); + } + + /** + * The AWS organization associated with the resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata.AwsOrganization organization = 1; + * @return \Google\Cloud\SecurityCenter\V2\AwsMetadata\AwsOrganization|null + */ + public function getOrganization() + { + return $this->organization; + } + + public function hasOrganization() + { + return isset($this->organization); + } + + public function clearOrganization() + { + unset($this->organization); + } + + /** + * The AWS organization associated with the resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata.AwsOrganization organization = 1; + * @param \Google\Cloud\SecurityCenter\V2\AwsMetadata\AwsOrganization $var + * @return $this + */ + public function setOrganization($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\AwsMetadata\AwsOrganization::class); + $this->organization = $var; + + return $this; + } + + /** + * A list of AWS organizational units associated with the resource, ordered + * from lowest level (closest to the account) to highest level. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AwsMetadata.AwsOrganizationalUnit organizational_units = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getOrganizationalUnits() + { + return $this->organizational_units; + } + + /** + * A list of AWS organizational units associated with the resource, ordered + * from lowest level (closest to the account) to highest level. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AwsMetadata.AwsOrganizationalUnit organizational_units = 2; + * @param array<\Google\Cloud\SecurityCenter\V2\AwsMetadata\AwsOrganizationalUnit>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setOrganizationalUnits($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\AwsMetadata\AwsOrganizationalUnit::class); + $this->organizational_units = $arr; + + return $this; + } + + /** + * The AWS account associated with the resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata.AwsAccount account = 3; + * @return \Google\Cloud\SecurityCenter\V2\AwsMetadata\AwsAccount|null + */ + public function getAccount() + { + return $this->account; + } + + public function hasAccount() + { + return isset($this->account); + } + + public function clearAccount() + { + unset($this->account); + } + + /** + * The AWS account associated with the resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata.AwsAccount account = 3; + * @param \Google\Cloud\SecurityCenter\V2\AwsMetadata\AwsAccount $var + * @return $this + */ + public function setAccount($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\AwsMetadata\AwsAccount::class); + $this->account = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsAccount.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsAccount.php new file mode 100644 index 000000000000..96d785b57625 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsAccount.php @@ -0,0 +1,104 @@ +google.cloud.securitycenter.v2.AwsMetadata.AwsAccount + */ +class AwsAccount extends \Google\Protobuf\Internal\Message +{ + /** + * The unique identifier (ID) of the account, containing exactly 12 digits. + * + * Generated from protobuf field string id = 1; + */ + protected $id = ''; + /** + * The friendly name of this account. + * + * Generated from protobuf field string name = 2; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $id + * The unique identifier (ID) of the account, containing exactly 12 digits. + * @type string $name + * The friendly name of this account. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Resource::initOnce(); + parent::__construct($data); + } + + /** + * The unique identifier (ID) of the account, containing exactly 12 digits. + * + * Generated from protobuf field string id = 1; + * @return string + */ + public function getId() + { + return $this->id; + } + + /** + * The unique identifier (ID) of the account, containing exactly 12 digits. + * + * Generated from protobuf field string id = 1; + * @param string $var + * @return $this + */ + public function setId($var) + { + GPBUtil::checkString($var, True); + $this->id = $var; + + return $this; + } + + /** + * The friendly name of this account. + * + * Generated from protobuf field string name = 2; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The friendly name of this account. + * + * Generated from protobuf field string name = 2; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AwsAccount::class, \Google\Cloud\SecurityCenter\V2\AwsMetadata_AwsAccount::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsOrganization.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsOrganization.php new file mode 100644 index 000000000000..379175d8656a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsOrganization.php @@ -0,0 +1,80 @@ +google.cloud.securitycenter.v2.AwsMetadata.AwsOrganization + */ +class AwsOrganization extends \Google\Protobuf\Internal\Message +{ + /** + * The unique identifier (ID) for the organization. The regex pattern for an + * organization ID string requires "o-" followed by from 10 to 32 lowercase + * letters or digits. + * + * Generated from protobuf field string id = 1; + */ + protected $id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $id + * The unique identifier (ID) for the organization. The regex pattern for an + * organization ID string requires "o-" followed by from 10 to 32 lowercase + * letters or digits. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Resource::initOnce(); + parent::__construct($data); + } + + /** + * The unique identifier (ID) for the organization. The regex pattern for an + * organization ID string requires "o-" followed by from 10 to 32 lowercase + * letters or digits. + * + * Generated from protobuf field string id = 1; + * @return string + */ + public function getId() + { + return $this->id; + } + + /** + * The unique identifier (ID) for the organization. The regex pattern for an + * organization ID string requires "o-" followed by from 10 to 32 lowercase + * letters or digits. + * + * Generated from protobuf field string id = 1; + * @param string $var + * @return $this + */ + public function setId($var) + { + GPBUtil::checkString($var, True); + $this->id = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AwsOrganization::class, \Google\Cloud\SecurityCenter\V2\AwsMetadata_AwsOrganization::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsOrganizationalUnit.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsOrganizationalUnit.php new file mode 100644 index 000000000000..17f3c6caf448 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsOrganizationalUnit.php @@ -0,0 +1,122 @@ +google.cloud.securitycenter.v2.AwsMetadata.AwsOrganizationalUnit + */ +class AwsOrganizationalUnit extends \Google\Protobuf\Internal\Message +{ + /** + * The unique identifier (ID) associated with this OU. The regex pattern for + * an organizational unit ID string requires "ou-" followed by from 4 to 32 + * lowercase letters or digits (the ID of the root that contains the OU). + * This string is followed by a second "-" dash and from 8 to 32 additional + * lowercase letters or digits. For example, "ou-ab12-cd34ef56". + * + * Generated from protobuf field string id = 1; + */ + protected $id = ''; + /** + * The friendly name of the OU. + * + * Generated from protobuf field string name = 2; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $id + * The unique identifier (ID) associated with this OU. The regex pattern for + * an organizational unit ID string requires "ou-" followed by from 4 to 32 + * lowercase letters or digits (the ID of the root that contains the OU). + * This string is followed by a second "-" dash and from 8 to 32 additional + * lowercase letters or digits. For example, "ou-ab12-cd34ef56". + * @type string $name + * The friendly name of the OU. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Resource::initOnce(); + parent::__construct($data); + } + + /** + * The unique identifier (ID) associated with this OU. The regex pattern for + * an organizational unit ID string requires "ou-" followed by from 4 to 32 + * lowercase letters or digits (the ID of the root that contains the OU). + * This string is followed by a second "-" dash and from 8 to 32 additional + * lowercase letters or digits. For example, "ou-ab12-cd34ef56". + * + * Generated from protobuf field string id = 1; + * @return string + */ + public function getId() + { + return $this->id; + } + + /** + * The unique identifier (ID) associated with this OU. The regex pattern for + * an organizational unit ID string requires "ou-" followed by from 4 to 32 + * lowercase letters or digits (the ID of the root that contains the OU). + * This string is followed by a second "-" dash and from 8 to 32 additional + * lowercase letters or digits. For example, "ou-ab12-cd34ef56". + * + * Generated from protobuf field string id = 1; + * @param string $var + * @return $this + */ + public function setId($var) + { + GPBUtil::checkString($var, True); + $this->id = $var; + + return $this; + } + + /** + * The friendly name of the OU. + * + * Generated from protobuf field string name = 2; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The friendly name of the OU. + * + * Generated from protobuf field string name = 2; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AwsOrganizationalUnit::class, \Google\Cloud\SecurityCenter\V2\AwsMetadata_AwsOrganizationalUnit::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata.php new file mode 100644 index 000000000000..5d61d1e0f4a3 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata.php @@ -0,0 +1,160 @@ +google.cloud.securitycenter.v2.AzureMetadata + */ +class AzureMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * A list of Azure management groups associated with the resource, ordered + * from lowest level (closest to the subscription) to highest level. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AzureMetadata.AzureManagementGroup management_groups = 1; + */ + private $management_groups; + /** + * The Azure subscription associated with the resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata.AzureSubscription subscription = 2; + */ + protected $subscription = null; + /** + * The Azure resource group associated with the resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata.AzureResourceGroup resource_group = 3; + */ + protected $resource_group = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V2\AzureMetadata\AzureManagementGroup>|\Google\Protobuf\Internal\RepeatedField $management_groups + * A list of Azure management groups associated with the resource, ordered + * from lowest level (closest to the subscription) to highest level. + * @type \Google\Cloud\SecurityCenter\V2\AzureMetadata\AzureSubscription $subscription + * The Azure subscription associated with the resource. + * @type \Google\Cloud\SecurityCenter\V2\AzureMetadata\AzureResourceGroup $resource_group + * The Azure resource group associated with the resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Resource::initOnce(); + parent::__construct($data); + } + + /** + * A list of Azure management groups associated with the resource, ordered + * from lowest level (closest to the subscription) to highest level. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AzureMetadata.AzureManagementGroup management_groups = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getManagementGroups() + { + return $this->management_groups; + } + + /** + * A list of Azure management groups associated with the resource, ordered + * from lowest level (closest to the subscription) to highest level. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AzureMetadata.AzureManagementGroup management_groups = 1; + * @param array<\Google\Cloud\SecurityCenter\V2\AzureMetadata\AzureManagementGroup>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setManagementGroups($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\AzureMetadata\AzureManagementGroup::class); + $this->management_groups = $arr; + + return $this; + } + + /** + * The Azure subscription associated with the resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata.AzureSubscription subscription = 2; + * @return \Google\Cloud\SecurityCenter\V2\AzureMetadata\AzureSubscription|null + */ + public function getSubscription() + { + return $this->subscription; + } + + public function hasSubscription() + { + return isset($this->subscription); + } + + public function clearSubscription() + { + unset($this->subscription); + } + + /** + * The Azure subscription associated with the resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata.AzureSubscription subscription = 2; + * @param \Google\Cloud\SecurityCenter\V2\AzureMetadata\AzureSubscription $var + * @return $this + */ + public function setSubscription($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\AzureMetadata\AzureSubscription::class); + $this->subscription = $var; + + return $this; + } + + /** + * The Azure resource group associated with the resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata.AzureResourceGroup resource_group = 3; + * @return \Google\Cloud\SecurityCenter\V2\AzureMetadata\AzureResourceGroup|null + */ + public function getResourceGroup() + { + return $this->resource_group; + } + + public function hasResourceGroup() + { + return isset($this->resource_group); + } + + public function clearResourceGroup() + { + unset($this->resource_group); + } + + /** + * The Azure resource group associated with the resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata.AzureResourceGroup resource_group = 3; + * @param \Google\Cloud\SecurityCenter\V2\AzureMetadata\AzureResourceGroup $var + * @return $this + */ + public function setResourceGroup($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\AzureMetadata\AzureResourceGroup::class); + $this->resource_group = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureManagementGroup.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureManagementGroup.php new file mode 100644 index 000000000000..dfc80438bc75 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureManagementGroup.php @@ -0,0 +1,108 @@ +google.cloud.securitycenter.v2.AzureMetadata.AzureManagementGroup + */ +class AzureManagementGroup extends \Google\Protobuf\Internal\Message +{ + /** + * The UUID of the Azure management group, for example, + * "20000000-0001-0000-0000-000000000000". + * + * Generated from protobuf field string id = 1; + */ + protected $id = ''; + /** + * The display name of the Azure management group. + * + * Generated from protobuf field string display_name = 2; + */ + protected $display_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $id + * The UUID of the Azure management group, for example, + * "20000000-0001-0000-0000-000000000000". + * @type string $display_name + * The display name of the Azure management group. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Resource::initOnce(); + parent::__construct($data); + } + + /** + * The UUID of the Azure management group, for example, + * "20000000-0001-0000-0000-000000000000". + * + * Generated from protobuf field string id = 1; + * @return string + */ + public function getId() + { + return $this->id; + } + + /** + * The UUID of the Azure management group, for example, + * "20000000-0001-0000-0000-000000000000". + * + * Generated from protobuf field string id = 1; + * @param string $var + * @return $this + */ + public function setId($var) + { + GPBUtil::checkString($var, True); + $this->id = $var; + + return $this; + } + + /** + * The display name of the Azure management group. + * + * Generated from protobuf field string display_name = 2; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * The display name of the Azure management group. + * + * Generated from protobuf field string display_name = 2; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AzureManagementGroup::class, \Google\Cloud\SecurityCenter\V2\AzureMetadata_AzureManagementGroup::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureResourceGroup.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureResourceGroup.php new file mode 100644 index 000000000000..7be762cc406b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureResourceGroup.php @@ -0,0 +1,70 @@ +google.cloud.securitycenter.v2.AzureMetadata.AzureResourceGroup + */ +class AzureResourceGroup extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the Azure resource group. This is not a UUID. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the Azure resource group. This is not a UUID. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Resource::initOnce(); + parent::__construct($data); + } + + /** + * The name of the Azure resource group. This is not a UUID. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the Azure resource group. This is not a UUID. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AzureResourceGroup::class, \Google\Cloud\SecurityCenter\V2\AzureMetadata_AzureResourceGroup::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureSubscription.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureSubscription.php new file mode 100644 index 000000000000..29b8e99fef59 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureSubscription.php @@ -0,0 +1,108 @@ +google.cloud.securitycenter.v2.AzureMetadata.AzureSubscription + */ +class AzureSubscription extends \Google\Protobuf\Internal\Message +{ + /** + * The UUID of the Azure subscription, for example, + * "291bba3f-e0a5-47bc-a099-3bdcb2a50a05". + * + * Generated from protobuf field string id = 1; + */ + protected $id = ''; + /** + * The display name of the Azure subscription. + * + * Generated from protobuf field string display_name = 2; + */ + protected $display_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $id + * The UUID of the Azure subscription, for example, + * "291bba3f-e0a5-47bc-a099-3bdcb2a50a05". + * @type string $display_name + * The display name of the Azure subscription. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Resource::initOnce(); + parent::__construct($data); + } + + /** + * The UUID of the Azure subscription, for example, + * "291bba3f-e0a5-47bc-a099-3bdcb2a50a05". + * + * Generated from protobuf field string id = 1; + * @return string + */ + public function getId() + { + return $this->id; + } + + /** + * The UUID of the Azure subscription, for example, + * "291bba3f-e0a5-47bc-a099-3bdcb2a50a05". + * + * Generated from protobuf field string id = 1; + * @param string $var + * @return $this + */ + public function setId($var) + { + GPBUtil::checkString($var, True); + $this->id = $var; + + return $this; + } + + /** + * The display name of the Azure subscription. + * + * Generated from protobuf field string display_name = 2; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * The display name of the Azure subscription. + * + * Generated from protobuf field string display_name = 2; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AzureSubscription::class, \Google\Cloud\SecurityCenter\V2\AzureMetadata_AzureSubscription::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BackupDisasterRecovery.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BackupDisasterRecovery.php new file mode 100644 index 000000000000..c95abc803328 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BackupDisasterRecovery.php @@ -0,0 +1,495 @@ +google.cloud.securitycenter.v2.BackupDisasterRecovery + */ +class BackupDisasterRecovery extends \Google\Protobuf\Internal\Message +{ + /** + * The name of a Backup and DR template which comprises one or more backup + * policies. See the [Backup and DR + * documentation](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#temp) + * for more information. For example, `snap-ov`. + * + * Generated from protobuf field string backup_template = 1; + */ + protected $backup_template = ''; + /** + * The names of Backup and DR policies that are associated with a template + * and that define when to run a backup, how frequently to run a backup, and + * how long to retain the backup image. For example, `onvaults`. + * + * Generated from protobuf field repeated string policies = 2; + */ + private $policies; + /** + * The name of a Backup and DR host, which is managed by the backup and + * recovery appliance and known to the management console. The host can be of + * type Generic (for example, Compute Engine, SQL Server, Oracle DB, SMB file + * system, etc.), vCenter, or an ESX server. See the [Backup and DR + * documentation on + * hosts](https://cloud.google.com/backup-disaster-recovery/docs/configuration/manage-hosts-and-their-applications) + * for more information. For example, `centos7-01`. + * + * Generated from protobuf field string host = 3; + */ + protected $host = ''; + /** + * The names of Backup and DR applications. An application is a VM, database, + * or file system on a managed host monitored by a backup and recovery + * appliance. For example, `centos7-01-vol00`, `centos7-01-vol01`, + * `centos7-01-vol02`. + * + * Generated from protobuf field repeated string applications = 4; + */ + private $applications; + /** + * The name of the Backup and DR storage pool that the backup and recovery + * appliance is storing data in. The storage pool could be of type Cloud, + * Primary, Snapshot, or OnVault. See the [Backup and DR documentation on + * storage + * pools](https://cloud.google.com/backup-disaster-recovery/docs/concepts/storage-pools). + * For example, `DiskPoolOne`. + * + * Generated from protobuf field string storage_pool = 5; + */ + protected $storage_pool = ''; + /** + * The names of Backup and DR advanced policy options of a policy applying to + * an application. See the [Backup and DR documentation on policy + * options](https://cloud.google.com/backup-disaster-recovery/docs/create-plan/policy-settings). + * For example, `skipofflineappsincongrp, nounmap`. + * + * Generated from protobuf field repeated string policy_options = 6; + */ + private $policy_options; + /** + * The name of the Backup and DR resource profile that specifies the storage + * media for backups of application and VM data. See the [Backup and DR + * documentation on + * profiles](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#profile). + * For example, `GCP`. + * + * Generated from protobuf field string profile = 7; + */ + protected $profile = ''; + /** + * The name of the Backup and DR appliance that captures, moves, and manages + * the lifecycle of backup data. For example, `backup-server-57137`. + * + * Generated from protobuf field string appliance = 8; + */ + protected $appliance = ''; + /** + * The backup type of the Backup and DR image. + * For example, `Snapshot`, `Remote Snapshot`, `OnVault`. + * + * Generated from protobuf field string backup_type = 9; + */ + protected $backup_type = ''; + /** + * The timestamp at which the Backup and DR backup was created. + * + * Generated from protobuf field .google.protobuf.Timestamp backup_create_time = 10; + */ + protected $backup_create_time = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $backup_template + * The name of a Backup and DR template which comprises one or more backup + * policies. See the [Backup and DR + * documentation](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#temp) + * for more information. For example, `snap-ov`. + * @type array|\Google\Protobuf\Internal\RepeatedField $policies + * The names of Backup and DR policies that are associated with a template + * and that define when to run a backup, how frequently to run a backup, and + * how long to retain the backup image. For example, `onvaults`. + * @type string $host + * The name of a Backup and DR host, which is managed by the backup and + * recovery appliance and known to the management console. The host can be of + * type Generic (for example, Compute Engine, SQL Server, Oracle DB, SMB file + * system, etc.), vCenter, or an ESX server. See the [Backup and DR + * documentation on + * hosts](https://cloud.google.com/backup-disaster-recovery/docs/configuration/manage-hosts-and-their-applications) + * for more information. For example, `centos7-01`. + * @type array|\Google\Protobuf\Internal\RepeatedField $applications + * The names of Backup and DR applications. An application is a VM, database, + * or file system on a managed host monitored by a backup and recovery + * appliance. For example, `centos7-01-vol00`, `centos7-01-vol01`, + * `centos7-01-vol02`. + * @type string $storage_pool + * The name of the Backup and DR storage pool that the backup and recovery + * appliance is storing data in. The storage pool could be of type Cloud, + * Primary, Snapshot, or OnVault. See the [Backup and DR documentation on + * storage + * pools](https://cloud.google.com/backup-disaster-recovery/docs/concepts/storage-pools). + * For example, `DiskPoolOne`. + * @type array|\Google\Protobuf\Internal\RepeatedField $policy_options + * The names of Backup and DR advanced policy options of a policy applying to + * an application. See the [Backup and DR documentation on policy + * options](https://cloud.google.com/backup-disaster-recovery/docs/create-plan/policy-settings). + * For example, `skipofflineappsincongrp, nounmap`. + * @type string $profile + * The name of the Backup and DR resource profile that specifies the storage + * media for backups of application and VM data. See the [Backup and DR + * documentation on + * profiles](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#profile). + * For example, `GCP`. + * @type string $appliance + * The name of the Backup and DR appliance that captures, moves, and manages + * the lifecycle of backup data. For example, `backup-server-57137`. + * @type string $backup_type + * The backup type of the Backup and DR image. + * For example, `Snapshot`, `Remote Snapshot`, `OnVault`. + * @type \Google\Protobuf\Timestamp $backup_create_time + * The timestamp at which the Backup and DR backup was created. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\BackupDisasterRecovery::initOnce(); + parent::__construct($data); + } + + /** + * The name of a Backup and DR template which comprises one or more backup + * policies. See the [Backup and DR + * documentation](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#temp) + * for more information. For example, `snap-ov`. + * + * Generated from protobuf field string backup_template = 1; + * @return string + */ + public function getBackupTemplate() + { + return $this->backup_template; + } + + /** + * The name of a Backup and DR template which comprises one or more backup + * policies. See the [Backup and DR + * documentation](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#temp) + * for more information. For example, `snap-ov`. + * + * Generated from protobuf field string backup_template = 1; + * @param string $var + * @return $this + */ + public function setBackupTemplate($var) + { + GPBUtil::checkString($var, True); + $this->backup_template = $var; + + return $this; + } + + /** + * The names of Backup and DR policies that are associated with a template + * and that define when to run a backup, how frequently to run a backup, and + * how long to retain the backup image. For example, `onvaults`. + * + * Generated from protobuf field repeated string policies = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPolicies() + { + return $this->policies; + } + + /** + * The names of Backup and DR policies that are associated with a template + * and that define when to run a backup, how frequently to run a backup, and + * how long to retain the backup image. For example, `onvaults`. + * + * Generated from protobuf field repeated string policies = 2; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPolicies($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->policies = $arr; + + return $this; + } + + /** + * The name of a Backup and DR host, which is managed by the backup and + * recovery appliance and known to the management console. The host can be of + * type Generic (for example, Compute Engine, SQL Server, Oracle DB, SMB file + * system, etc.), vCenter, or an ESX server. See the [Backup and DR + * documentation on + * hosts](https://cloud.google.com/backup-disaster-recovery/docs/configuration/manage-hosts-and-their-applications) + * for more information. For example, `centos7-01`. + * + * Generated from protobuf field string host = 3; + * @return string + */ + public function getHost() + { + return $this->host; + } + + /** + * The name of a Backup and DR host, which is managed by the backup and + * recovery appliance and known to the management console. The host can be of + * type Generic (for example, Compute Engine, SQL Server, Oracle DB, SMB file + * system, etc.), vCenter, or an ESX server. See the [Backup and DR + * documentation on + * hosts](https://cloud.google.com/backup-disaster-recovery/docs/configuration/manage-hosts-and-their-applications) + * for more information. For example, `centos7-01`. + * + * Generated from protobuf field string host = 3; + * @param string $var + * @return $this + */ + public function setHost($var) + { + GPBUtil::checkString($var, True); + $this->host = $var; + + return $this; + } + + /** + * The names of Backup and DR applications. An application is a VM, database, + * or file system on a managed host monitored by a backup and recovery + * appliance. For example, `centos7-01-vol00`, `centos7-01-vol01`, + * `centos7-01-vol02`. + * + * Generated from protobuf field repeated string applications = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getApplications() + { + return $this->applications; + } + + /** + * The names of Backup and DR applications. An application is a VM, database, + * or file system on a managed host monitored by a backup and recovery + * appliance. For example, `centos7-01-vol00`, `centos7-01-vol01`, + * `centos7-01-vol02`. + * + * Generated from protobuf field repeated string applications = 4; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setApplications($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->applications = $arr; + + return $this; + } + + /** + * The name of the Backup and DR storage pool that the backup and recovery + * appliance is storing data in. The storage pool could be of type Cloud, + * Primary, Snapshot, or OnVault. See the [Backup and DR documentation on + * storage + * pools](https://cloud.google.com/backup-disaster-recovery/docs/concepts/storage-pools). + * For example, `DiskPoolOne`. + * + * Generated from protobuf field string storage_pool = 5; + * @return string + */ + public function getStoragePool() + { + return $this->storage_pool; + } + + /** + * The name of the Backup and DR storage pool that the backup and recovery + * appliance is storing data in. The storage pool could be of type Cloud, + * Primary, Snapshot, or OnVault. See the [Backup and DR documentation on + * storage + * pools](https://cloud.google.com/backup-disaster-recovery/docs/concepts/storage-pools). + * For example, `DiskPoolOne`. + * + * Generated from protobuf field string storage_pool = 5; + * @param string $var + * @return $this + */ + public function setStoragePool($var) + { + GPBUtil::checkString($var, True); + $this->storage_pool = $var; + + return $this; + } + + /** + * The names of Backup and DR advanced policy options of a policy applying to + * an application. See the [Backup and DR documentation on policy + * options](https://cloud.google.com/backup-disaster-recovery/docs/create-plan/policy-settings). + * For example, `skipofflineappsincongrp, nounmap`. + * + * Generated from protobuf field repeated string policy_options = 6; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPolicyOptions() + { + return $this->policy_options; + } + + /** + * The names of Backup and DR advanced policy options of a policy applying to + * an application. See the [Backup and DR documentation on policy + * options](https://cloud.google.com/backup-disaster-recovery/docs/create-plan/policy-settings). + * For example, `skipofflineappsincongrp, nounmap`. + * + * Generated from protobuf field repeated string policy_options = 6; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPolicyOptions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->policy_options = $arr; + + return $this; + } + + /** + * The name of the Backup and DR resource profile that specifies the storage + * media for backups of application and VM data. See the [Backup and DR + * documentation on + * profiles](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#profile). + * For example, `GCP`. + * + * Generated from protobuf field string profile = 7; + * @return string + */ + public function getProfile() + { + return $this->profile; + } + + /** + * The name of the Backup and DR resource profile that specifies the storage + * media for backups of application and VM data. See the [Backup and DR + * documentation on + * profiles](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#profile). + * For example, `GCP`. + * + * Generated from protobuf field string profile = 7; + * @param string $var + * @return $this + */ + public function setProfile($var) + { + GPBUtil::checkString($var, True); + $this->profile = $var; + + return $this; + } + + /** + * The name of the Backup and DR appliance that captures, moves, and manages + * the lifecycle of backup data. For example, `backup-server-57137`. + * + * Generated from protobuf field string appliance = 8; + * @return string + */ + public function getAppliance() + { + return $this->appliance; + } + + /** + * The name of the Backup and DR appliance that captures, moves, and manages + * the lifecycle of backup data. For example, `backup-server-57137`. + * + * Generated from protobuf field string appliance = 8; + * @param string $var + * @return $this + */ + public function setAppliance($var) + { + GPBUtil::checkString($var, True); + $this->appliance = $var; + + return $this; + } + + /** + * The backup type of the Backup and DR image. + * For example, `Snapshot`, `Remote Snapshot`, `OnVault`. + * + * Generated from protobuf field string backup_type = 9; + * @return string + */ + public function getBackupType() + { + return $this->backup_type; + } + + /** + * The backup type of the Backup and DR image. + * For example, `Snapshot`, `Remote Snapshot`, `OnVault`. + * + * Generated from protobuf field string backup_type = 9; + * @param string $var + * @return $this + */ + public function setBackupType($var) + { + GPBUtil::checkString($var, True); + $this->backup_type = $var; + + return $this; + } + + /** + * The timestamp at which the Backup and DR backup was created. + * + * Generated from protobuf field .google.protobuf.Timestamp backup_create_time = 10; + * @return \Google\Protobuf\Timestamp|null + */ + public function getBackupCreateTime() + { + return $this->backup_create_time; + } + + public function hasBackupCreateTime() + { + return isset($this->backup_create_time); + } + + public function clearBackupCreateTime() + { + unset($this->backup_create_time); + } + + /** + * The timestamp at which the Backup and DR backup was created. + * + * Generated from protobuf field .google.protobuf.Timestamp backup_create_time = 10; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setBackupCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->backup_create_time = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BatchCreateResourceValueConfigsRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BatchCreateResourceValueConfigsRequest.php new file mode 100644 index 000000000000..bfc8a78bedf8 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BatchCreateResourceValueConfigsRequest.php @@ -0,0 +1,127 @@ +google.cloud.securitycenter.v2.BatchCreateResourceValueConfigsRequest + */ +class BatchCreateResourceValueConfigsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the new ResourceValueConfig's parent. + * The parent field in the CreateResourceValueConfigRequest + * messages must either be empty or match this field. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The resource value configs to be created. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.CreateResourceValueConfigRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + private $requests; + + /** + * @param string $parent Required. Resource name of the new ResourceValueConfig's parent. + * The parent field in the CreateResourceValueConfigRequest + * messages must either be empty or match this field. Please see + * {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. + * @param \Google\Cloud\SecurityCenter\V2\CreateResourceValueConfigRequest[] $requests Required. The resource value configs to be created. + * + * @return \Google\Cloud\SecurityCenter\V2\BatchCreateResourceValueConfigsRequest + * + * @experimental + */ + public static function build(string $parent, array $requests): self + { + return (new self()) + ->setParent($parent) + ->setRequests($requests); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Resource name of the new ResourceValueConfig's parent. + * The parent field in the CreateResourceValueConfigRequest + * messages must either be empty or match this field. + * @type array<\Google\Cloud\SecurityCenter\V2\CreateResourceValueConfigRequest>|\Google\Protobuf\Internal\RepeatedField $requests + * Required. The resource value configs to be created. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the new ResourceValueConfig's parent. + * The parent field in the CreateResourceValueConfigRequest + * messages must either be empty or match this field. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Resource name of the new ResourceValueConfig's parent. + * The parent field in the CreateResourceValueConfigRequest + * messages must either be empty or match this field. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. The resource value configs to be created. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.CreateResourceValueConfigRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRequests() + { + return $this->requests; + } + + /** + * Required. The resource value configs to be created. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.CreateResourceValueConfigRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param array<\Google\Cloud\SecurityCenter\V2\CreateResourceValueConfigRequest>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRequests($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\CreateResourceValueConfigRequest::class); + $this->requests = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BatchCreateResourceValueConfigsResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BatchCreateResourceValueConfigsResponse.php new file mode 100644 index 000000000000..660411064214 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BatchCreateResourceValueConfigsResponse.php @@ -0,0 +1,67 @@ +google.cloud.securitycenter.v2.BatchCreateResourceValueConfigsResponse + */ +class BatchCreateResourceValueConfigsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The resource value configs created + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_configs = 1; + */ + private $resource_value_configs; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V2\ResourceValueConfig>|\Google\Protobuf\Internal\RepeatedField $resource_value_configs + * The resource value configs created + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * The resource value configs created + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_configs = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getResourceValueConfigs() + { + return $this->resource_value_configs; + } + + /** + * The resource value configs created + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_configs = 1; + * @param array<\Google\Cloud\SecurityCenter\V2\ResourceValueConfig>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setResourceValueConfigs($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ResourceValueConfig::class); + $this->resource_value_configs = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BigQueryExport.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BigQueryExport.php new file mode 100644 index 000000000000..4f52487609e8 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BigQueryExport.php @@ -0,0 +1,457 @@ +google.cloud.securitycenter.v2.BigQueryExport + */ +class BigQueryExport extends \Google\Protobuf\Internal\Message +{ + /** + * The relative resource name of this export. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name. + * The following list shows some examples: + * + + * `organizations/{organization_id}/locations/{location_id}/bigQueryExports/{export_id}` + * + `folders/{folder_id}/locations/{location_id}/bigQueryExports/{export_id}` + * + + * `projects/{project_id}/locations/{location_id}/bigQueryExports/{export_id}` + * This field is provided in responses, and is ignored when provided in create + * requests. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The description of the export (max of 1024 characters). + * + * Generated from protobuf field string description = 2; + */ + protected $description = ''; + /** + * Expression that defines the filter to apply across create/update events + * of findings. The expression is a list of zero or more restrictions combined + * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` + * has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 3; + */ + protected $filter = ''; + /** + * The dataset to write findings' updates to. Its format is + * "projects/[project_id]/datasets/[bigquery_dataset_id]". + * BigQuery Dataset unique ID must contain only letters (a-z, A-Z), numbers + * (0-9), or underscores (_). + * + * Generated from protobuf field string dataset = 4; + */ + protected $dataset = ''; + /** + * Output only. The time at which the BigQuery export was created. + * This field is set by the server and will be ignored if provided on export + * on creation. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. The most recent time at which the BigQuery export was updated. + * This field is set by the server and will be ignored if provided on export + * creation or update. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Output only. Email address of the user who last edited the BigQuery export. + * This field is set by the server and will be ignored if provided on export + * creation or update. + * + * Generated from protobuf field string most_recent_editor = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $most_recent_editor = ''; + /** + * Output only. The service account that needs permission to create table and + * upload data to the BigQuery dataset. + * + * Generated from protobuf field string principal = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $principal = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The relative resource name of this export. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name. + * The following list shows some examples: + * + + * `organizations/{organization_id}/locations/{location_id}/bigQueryExports/{export_id}` + * + `folders/{folder_id}/locations/{location_id}/bigQueryExports/{export_id}` + * + + * `projects/{project_id}/locations/{location_id}/bigQueryExports/{export_id}` + * This field is provided in responses, and is ignored when provided in create + * requests. + * @type string $description + * The description of the export (max of 1024 characters). + * @type string $filter + * Expression that defines the filter to apply across create/update events + * of findings. The expression is a list of zero or more restrictions combined + * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` + * has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * @type string $dataset + * The dataset to write findings' updates to. Its format is + * "projects/[project_id]/datasets/[bigquery_dataset_id]". + * BigQuery Dataset unique ID must contain only letters (a-z, A-Z), numbers + * (0-9), or underscores (_). + * @type \Google\Protobuf\Timestamp $create_time + * Output only. The time at which the BigQuery export was created. + * This field is set by the server and will be ignored if provided on export + * on creation. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. The most recent time at which the BigQuery export was updated. + * This field is set by the server and will be ignored if provided on export + * creation or update. + * @type string $most_recent_editor + * Output only. Email address of the user who last edited the BigQuery export. + * This field is set by the server and will be ignored if provided on export + * creation or update. + * @type string $principal + * Output only. The service account that needs permission to create table and + * upload data to the BigQuery dataset. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\BigqueryExport::initOnce(); + parent::__construct($data); + } + + /** + * The relative resource name of this export. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name. + * The following list shows some examples: + * + + * `organizations/{organization_id}/locations/{location_id}/bigQueryExports/{export_id}` + * + `folders/{folder_id}/locations/{location_id}/bigQueryExports/{export_id}` + * + + * `projects/{project_id}/locations/{location_id}/bigQueryExports/{export_id}` + * This field is provided in responses, and is ignored when provided in create + * requests. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The relative resource name of this export. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name. + * The following list shows some examples: + * + + * `organizations/{organization_id}/locations/{location_id}/bigQueryExports/{export_id}` + * + `folders/{folder_id}/locations/{location_id}/bigQueryExports/{export_id}` + * + + * `projects/{project_id}/locations/{location_id}/bigQueryExports/{export_id}` + * This field is provided in responses, and is ignored when provided in create + * requests. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The description of the export (max of 1024 characters). + * + * Generated from protobuf field string description = 2; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * The description of the export (max of 1024 characters). + * + * Generated from protobuf field string description = 2; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * Expression that defines the filter to apply across create/update events + * of findings. The expression is a list of zero or more restrictions combined + * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` + * has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 3; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Expression that defines the filter to apply across create/update events + * of findings. The expression is a list of zero or more restrictions combined + * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` + * has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 3; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * The dataset to write findings' updates to. Its format is + * "projects/[project_id]/datasets/[bigquery_dataset_id]". + * BigQuery Dataset unique ID must contain only letters (a-z, A-Z), numbers + * (0-9), or underscores (_). + * + * Generated from protobuf field string dataset = 4; + * @return string + */ + public function getDataset() + { + return $this->dataset; + } + + /** + * The dataset to write findings' updates to. Its format is + * "projects/[project_id]/datasets/[bigquery_dataset_id]". + * BigQuery Dataset unique ID must contain only letters (a-z, A-Z), numbers + * (0-9), or underscores (_). + * + * Generated from protobuf field string dataset = 4; + * @param string $var + * @return $this + */ + public function setDataset($var) + { + GPBUtil::checkString($var, True); + $this->dataset = $var; + + return $this; + } + + /** + * Output only. The time at which the BigQuery export was created. + * This field is set by the server and will be ignored if provided on export + * on creation. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCreateTime() + { + return $this->create_time; + } + + public function hasCreateTime() + { + return isset($this->create_time); + } + + public function clearCreateTime() + { + unset($this->create_time); + } + + /** + * Output only. The time at which the BigQuery export was created. + * This field is set by the server and will be ignored if provided on export + * on creation. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->create_time = $var; + + return $this; + } + + /** + * Output only. The most recent time at which the BigQuery export was updated. + * This field is set by the server and will be ignored if provided on export + * creation or update. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getUpdateTime() + { + return $this->update_time; + } + + public function hasUpdateTime() + { + return isset($this->update_time); + } + + public function clearUpdateTime() + { + unset($this->update_time); + } + + /** + * Output only. The most recent time at which the BigQuery export was updated. + * This field is set by the server and will be ignored if provided on export + * creation or update. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->update_time = $var; + + return $this; + } + + /** + * Output only. Email address of the user who last edited the BigQuery export. + * This field is set by the server and will be ignored if provided on export + * creation or update. + * + * Generated from protobuf field string most_recent_editor = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getMostRecentEditor() + { + return $this->most_recent_editor; + } + + /** + * Output only. Email address of the user who last edited the BigQuery export. + * This field is set by the server and will be ignored if provided on export + * creation or update. + * + * Generated from protobuf field string most_recent_editor = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setMostRecentEditor($var) + { + GPBUtil::checkString($var, True); + $this->most_recent_editor = $var; + + return $this; + } + + /** + * Output only. The service account that needs permission to create table and + * upload data to the BigQuery dataset. + * + * Generated from protobuf field string principal = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getPrincipal() + { + return $this->principal; + } + + /** + * Output only. The service account that needs permission to create table and + * upload data to the BigQuery dataset. + * + * Generated from protobuf field string principal = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setPrincipal($var) + { + GPBUtil::checkString($var, True); + $this->principal = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BulkMuteFindingsRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BulkMuteFindingsRequest.php new file mode 100644 index 000000000000..8a1d92e384e0 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BulkMuteFindingsRequest.php @@ -0,0 +1,215 @@ +google.cloud.securitycenter.v2.BulkMuteFindingsRequest + */ +class BulkMuteFindingsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The parent, at which bulk action needs to be applied. If no + * location is specified, findings are updated in global. The following list + * shows some examples: + * + `organizations/[organization_id]` + * + `organizations/[organization_id]/locations/[location_id]` + * + `folders/[folder_id]` + * + `folders/[folder_id]/locations/[location_id]` + * + `projects/[project_id]` + * + `projects/[project_id]/locations/[location_id]` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Expression that identifies findings that should be updated. + * The expression is a list of zero or more restrictions combined + * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` + * has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 2; + */ + protected $filter = ''; + + /** + * @param string $parent Required. The parent, at which bulk action needs to be applied. If no + * location is specified, findings are updated in global. The following list + * shows some examples: + * + * + `organizations/[organization_id]` + * + `organizations/[organization_id]/locations/[location_id]` + * + `folders/[folder_id]` + * + `folders/[folder_id]/locations/[location_id]` + * + `projects/[project_id]` + * + `projects/[project_id]/locations/[location_id]` + * + * @return \Google\Cloud\SecurityCenter\V2\BulkMuteFindingsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The parent, at which bulk action needs to be applied. If no + * location is specified, findings are updated in global. The following list + * shows some examples: + * + `organizations/[organization_id]` + * + `organizations/[organization_id]/locations/[location_id]` + * + `folders/[folder_id]` + * + `folders/[folder_id]/locations/[location_id]` + * + `projects/[project_id]` + * + `projects/[project_id]/locations/[location_id]` + * @type string $filter + * Expression that identifies findings that should be updated. + * The expression is a list of zero or more restrictions combined + * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` + * has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The parent, at which bulk action needs to be applied. If no + * location is specified, findings are updated in global. The following list + * shows some examples: + * + `organizations/[organization_id]` + * + `organizations/[organization_id]/locations/[location_id]` + * + `folders/[folder_id]` + * + `folders/[folder_id]/locations/[location_id]` + * + `projects/[project_id]` + * + `projects/[project_id]/locations/[location_id]` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The parent, at which bulk action needs to be applied. If no + * location is specified, findings are updated in global. The following list + * shows some examples: + * + `organizations/[organization_id]` + * + `organizations/[organization_id]/locations/[location_id]` + * + `folders/[folder_id]` + * + `folders/[folder_id]/locations/[location_id]` + * + `projects/[project_id]` + * + `projects/[project_id]/locations/[location_id]` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Expression that identifies findings that should be updated. + * The expression is a list of zero or more restrictions combined + * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` + * has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 2; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Expression that identifies findings that should be updated. + * The expression is a list of zero or more restrictions combined + * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` + * has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 2; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BulkMuteFindingsResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BulkMuteFindingsResponse.php new file mode 100644 index 000000000000..f42b0ef30f73 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BulkMuteFindingsResponse.php @@ -0,0 +1,33 @@ +google.cloud.securitycenter.v2.BulkMuteFindingsResponse + */ +class BulkMuteFindingsResponse extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudArmor.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudArmor.php new file mode 100644 index 000000000000..6c2d8f970b52 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudArmor.php @@ -0,0 +1,323 @@ +google.cloud.securitycenter.v2.CloudArmor + */ +class CloudArmor extends \Google\Protobuf\Internal\Message +{ + /** + * Information about the [Google Cloud Armor security + * policy](https://cloud.google.com/armor/docs/security-policy-overview) + * relevant to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityPolicy security_policy = 1; + */ + protected $security_policy = null; + /** + * Information about incoming requests evaluated by [Google Cloud Armor + * security + * policies](https://cloud.google.com/armor/docs/security-policy-overview). + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Requests requests = 2; + */ + protected $requests = null; + /** + * Information about potential Layer 7 DDoS attacks identified by [Google + * Cloud Armor Adaptive + * Protection](https://cloud.google.com/armor/docs/adaptive-protection-overview). + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AdaptiveProtection adaptive_protection = 3; + */ + protected $adaptive_protection = null; + /** + * Information about DDoS attack volume and classification. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Attack attack = 4; + */ + protected $attack = null; + /** + * Distinguish between volumetric & protocol DDoS attack and + * application layer attacks. For example, "L3_4" for Layer 3 and Layer 4 DDoS + * attacks, or "L_7" for Layer 7 DDoS attacks. + * + * Generated from protobuf field string threat_vector = 5; + */ + protected $threat_vector = ''; + /** + * Duration of attack from the start until the current moment (updated every 5 + * minutes). + * + * Generated from protobuf field .google.protobuf.Duration duration = 6; + */ + protected $duration = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V2\SecurityPolicy $security_policy + * Information about the [Google Cloud Armor security + * policy](https://cloud.google.com/armor/docs/security-policy-overview) + * relevant to the finding. + * @type \Google\Cloud\SecurityCenter\V2\Requests $requests + * Information about incoming requests evaluated by [Google Cloud Armor + * security + * policies](https://cloud.google.com/armor/docs/security-policy-overview). + * @type \Google\Cloud\SecurityCenter\V2\AdaptiveProtection $adaptive_protection + * Information about potential Layer 7 DDoS attacks identified by [Google + * Cloud Armor Adaptive + * Protection](https://cloud.google.com/armor/docs/adaptive-protection-overview). + * @type \Google\Cloud\SecurityCenter\V2\Attack $attack + * Information about DDoS attack volume and classification. + * @type string $threat_vector + * Distinguish between volumetric & protocol DDoS attack and + * application layer attacks. For example, "L3_4" for Layer 3 and Layer 4 DDoS + * attacks, or "L_7" for Layer 7 DDoS attacks. + * @type \Google\Protobuf\Duration $duration + * Duration of attack from the start until the current moment (updated every 5 + * minutes). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\CloudArmor::initOnce(); + parent::__construct($data); + } + + /** + * Information about the [Google Cloud Armor security + * policy](https://cloud.google.com/armor/docs/security-policy-overview) + * relevant to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityPolicy security_policy = 1; + * @return \Google\Cloud\SecurityCenter\V2\SecurityPolicy|null + */ + public function getSecurityPolicy() + { + return $this->security_policy; + } + + public function hasSecurityPolicy() + { + return isset($this->security_policy); + } + + public function clearSecurityPolicy() + { + unset($this->security_policy); + } + + /** + * Information about the [Google Cloud Armor security + * policy](https://cloud.google.com/armor/docs/security-policy-overview) + * relevant to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityPolicy security_policy = 1; + * @param \Google\Cloud\SecurityCenter\V2\SecurityPolicy $var + * @return $this + */ + public function setSecurityPolicy($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\SecurityPolicy::class); + $this->security_policy = $var; + + return $this; + } + + /** + * Information about incoming requests evaluated by [Google Cloud Armor + * security + * policies](https://cloud.google.com/armor/docs/security-policy-overview). + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Requests requests = 2; + * @return \Google\Cloud\SecurityCenter\V2\Requests|null + */ + public function getRequests() + { + return $this->requests; + } + + public function hasRequests() + { + return isset($this->requests); + } + + public function clearRequests() + { + unset($this->requests); + } + + /** + * Information about incoming requests evaluated by [Google Cloud Armor + * security + * policies](https://cloud.google.com/armor/docs/security-policy-overview). + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Requests requests = 2; + * @param \Google\Cloud\SecurityCenter\V2\Requests $var + * @return $this + */ + public function setRequests($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Requests::class); + $this->requests = $var; + + return $this; + } + + /** + * Information about potential Layer 7 DDoS attacks identified by [Google + * Cloud Armor Adaptive + * Protection](https://cloud.google.com/armor/docs/adaptive-protection-overview). + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AdaptiveProtection adaptive_protection = 3; + * @return \Google\Cloud\SecurityCenter\V2\AdaptiveProtection|null + */ + public function getAdaptiveProtection() + { + return $this->adaptive_protection; + } + + public function hasAdaptiveProtection() + { + return isset($this->adaptive_protection); + } + + public function clearAdaptiveProtection() + { + unset($this->adaptive_protection); + } + + /** + * Information about potential Layer 7 DDoS attacks identified by [Google + * Cloud Armor Adaptive + * Protection](https://cloud.google.com/armor/docs/adaptive-protection-overview). + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AdaptiveProtection adaptive_protection = 3; + * @param \Google\Cloud\SecurityCenter\V2\AdaptiveProtection $var + * @return $this + */ + public function setAdaptiveProtection($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\AdaptiveProtection::class); + $this->adaptive_protection = $var; + + return $this; + } + + /** + * Information about DDoS attack volume and classification. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Attack attack = 4; + * @return \Google\Cloud\SecurityCenter\V2\Attack|null + */ + public function getAttack() + { + return $this->attack; + } + + public function hasAttack() + { + return isset($this->attack); + } + + public function clearAttack() + { + unset($this->attack); + } + + /** + * Information about DDoS attack volume and classification. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Attack attack = 4; + * @param \Google\Cloud\SecurityCenter\V2\Attack $var + * @return $this + */ + public function setAttack($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Attack::class); + $this->attack = $var; + + return $this; + } + + /** + * Distinguish between volumetric & protocol DDoS attack and + * application layer attacks. For example, "L3_4" for Layer 3 and Layer 4 DDoS + * attacks, or "L_7" for Layer 7 DDoS attacks. + * + * Generated from protobuf field string threat_vector = 5; + * @return string + */ + public function getThreatVector() + { + return $this->threat_vector; + } + + /** + * Distinguish between volumetric & protocol DDoS attack and + * application layer attacks. For example, "L3_4" for Layer 3 and Layer 4 DDoS + * attacks, or "L_7" for Layer 7 DDoS attacks. + * + * Generated from protobuf field string threat_vector = 5; + * @param string $var + * @return $this + */ + public function setThreatVector($var) + { + GPBUtil::checkString($var, True); + $this->threat_vector = $var; + + return $this; + } + + /** + * Duration of attack from the start until the current moment (updated every 5 + * minutes). + * + * Generated from protobuf field .google.protobuf.Duration duration = 6; + * @return \Google\Protobuf\Duration|null + */ + public function getDuration() + { + return $this->duration; + } + + public function hasDuration() + { + return isset($this->duration); + } + + public function clearDuration() + { + unset($this->duration); + } + + /** + * Duration of attack from the start until the current moment (updated every 5 + * minutes). + * + * Generated from protobuf field .google.protobuf.Duration duration = 6; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setDuration($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->duration = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpDataProfile.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpDataProfile.php new file mode 100644 index 000000000000..9a1e04dc8d8a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpDataProfile.php @@ -0,0 +1,106 @@ +google.cloud.securitycenter.v2.CloudDlpDataProfile + */ +class CloudDlpDataProfile extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the data profile, for example, + * `projects/123/locations/europe/tableProfiles/8383929`. + * + * Generated from protobuf field string data_profile = 1 [(.google.api.resource_reference) = { + */ + protected $data_profile = ''; + /** + * The resource hierarchy level at which the data profile was generated. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudDlpDataProfile.ParentType parent_type = 2; + */ + protected $parent_type = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $data_profile + * Name of the data profile, for example, + * `projects/123/locations/europe/tableProfiles/8383929`. + * @type int $parent_type + * The resource hierarchy level at which the data profile was generated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\CloudDlpDataProfile::initOnce(); + parent::__construct($data); + } + + /** + * Name of the data profile, for example, + * `projects/123/locations/europe/tableProfiles/8383929`. + * + * Generated from protobuf field string data_profile = 1 [(.google.api.resource_reference) = { + * @return string + */ + public function getDataProfile() + { + return $this->data_profile; + } + + /** + * Name of the data profile, for example, + * `projects/123/locations/europe/tableProfiles/8383929`. + * + * Generated from protobuf field string data_profile = 1 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setDataProfile($var) + { + GPBUtil::checkString($var, True); + $this->data_profile = $var; + + return $this; + } + + /** + * The resource hierarchy level at which the data profile was generated. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudDlpDataProfile.ParentType parent_type = 2; + * @return int + */ + public function getParentType() + { + return $this->parent_type; + } + + /** + * The resource hierarchy level at which the data profile was generated. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudDlpDataProfile.ParentType parent_type = 2; + * @param int $var + * @return $this + */ + public function setParentType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\CloudDlpDataProfile\ParentType::class); + $this->parent_type = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpDataProfile/ParentType.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpDataProfile/ParentType.php new file mode 100644 index 000000000000..03f58e8fc723 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpDataProfile/ParentType.php @@ -0,0 +1,64 @@ +google.cloud.securitycenter.v2.CloudDlpDataProfile.ParentType + */ +class ParentType +{ + /** + * Unspecified parent type. + * + * Generated from protobuf enum PARENT_TYPE_UNSPECIFIED = 0; + */ + const PARENT_TYPE_UNSPECIFIED = 0; + /** + * Organization-level configurations. + * + * Generated from protobuf enum ORGANIZATION = 1; + */ + const ORGANIZATION = 1; + /** + * Project-level configurations. + * + * Generated from protobuf enum PROJECT = 2; + */ + const PROJECT = 2; + + private static $valueToName = [ + self::PARENT_TYPE_UNSPECIFIED => 'PARENT_TYPE_UNSPECIFIED', + self::ORGANIZATION => 'ORGANIZATION', + self::PROJECT => 'PROJECT', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ParentType::class, \Google\Cloud\SecurityCenter\V2\CloudDlpDataProfile_ParentType::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpInspection.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpInspection.php new file mode 100644 index 000000000000..8efb07526191 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpInspection.php @@ -0,0 +1,187 @@ +google.cloud.securitycenter.v2.CloudDlpInspection + */ +class CloudDlpInspection extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the inspection job, for example, + * `projects/123/locations/europe/dlpJobs/i-8383929`. + * + * Generated from protobuf field string inspect_job = 1 [(.google.api.resource_reference) = { + */ + protected $inspect_job = ''; + /** + * The type of information (or + * *[infoType](https://cloud.google.com/dlp/docs/infotypes-reference)*) found, + * for example, `EMAIL_ADDRESS` or `STREET_ADDRESS`. + * + * Generated from protobuf field string info_type = 2; + */ + protected $info_type = ''; + /** + * The number of times Cloud DLP found this infoType within this job + * and resource. + * + * Generated from protobuf field int64 info_type_count = 3; + */ + protected $info_type_count = 0; + /** + * Whether Cloud DLP scanned the complete resource or a sampled subset. + * + * Generated from protobuf field bool full_scan = 4; + */ + protected $full_scan = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $inspect_job + * Name of the inspection job, for example, + * `projects/123/locations/europe/dlpJobs/i-8383929`. + * @type string $info_type + * The type of information (or + * *[infoType](https://cloud.google.com/dlp/docs/infotypes-reference)*) found, + * for example, `EMAIL_ADDRESS` or `STREET_ADDRESS`. + * @type int|string $info_type_count + * The number of times Cloud DLP found this infoType within this job + * and resource. + * @type bool $full_scan + * Whether Cloud DLP scanned the complete resource or a sampled subset. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\CloudDlpInspection::initOnce(); + parent::__construct($data); + } + + /** + * Name of the inspection job, for example, + * `projects/123/locations/europe/dlpJobs/i-8383929`. + * + * Generated from protobuf field string inspect_job = 1 [(.google.api.resource_reference) = { + * @return string + */ + public function getInspectJob() + { + return $this->inspect_job; + } + + /** + * Name of the inspection job, for example, + * `projects/123/locations/europe/dlpJobs/i-8383929`. + * + * Generated from protobuf field string inspect_job = 1 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setInspectJob($var) + { + GPBUtil::checkString($var, True); + $this->inspect_job = $var; + + return $this; + } + + /** + * The type of information (or + * *[infoType](https://cloud.google.com/dlp/docs/infotypes-reference)*) found, + * for example, `EMAIL_ADDRESS` or `STREET_ADDRESS`. + * + * Generated from protobuf field string info_type = 2; + * @return string + */ + public function getInfoType() + { + return $this->info_type; + } + + /** + * The type of information (or + * *[infoType](https://cloud.google.com/dlp/docs/infotypes-reference)*) found, + * for example, `EMAIL_ADDRESS` or `STREET_ADDRESS`. + * + * Generated from protobuf field string info_type = 2; + * @param string $var + * @return $this + */ + public function setInfoType($var) + { + GPBUtil::checkString($var, True); + $this->info_type = $var; + + return $this; + } + + /** + * The number of times Cloud DLP found this infoType within this job + * and resource. + * + * Generated from protobuf field int64 info_type_count = 3; + * @return int|string + */ + public function getInfoTypeCount() + { + return $this->info_type_count; + } + + /** + * The number of times Cloud DLP found this infoType within this job + * and resource. + * + * Generated from protobuf field int64 info_type_count = 3; + * @param int|string $var + * @return $this + */ + public function setInfoTypeCount($var) + { + GPBUtil::checkInt64($var); + $this->info_type_count = $var; + + return $this; + } + + /** + * Whether Cloud DLP scanned the complete resource or a sampled subset. + * + * Generated from protobuf field bool full_scan = 4; + * @return bool + */ + public function getFullScan() + { + return $this->full_scan; + } + + /** + * Whether Cloud DLP scanned the complete resource or a sampled subset. + * + * Generated from protobuf field bool full_scan = 4; + * @param bool $var + * @return $this + */ + public function setFullScan($var) + { + GPBUtil::checkBool($var); + $this->full_scan = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudLoggingEntry.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudLoggingEntry.php new file mode 100644 index 000000000000..4ba37ea34ec1 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudLoggingEntry.php @@ -0,0 +1,196 @@ +google.cloud.securitycenter.v2.CloudLoggingEntry + */ +class CloudLoggingEntry extends \Google\Protobuf\Internal\Message +{ + /** + * A unique identifier for the log entry. + * + * Generated from protobuf field string insert_id = 1; + */ + protected $insert_id = ''; + /** + * The type of the log (part of `log_name`. `log_name` is the resource name of + * the log to which this log entry belongs). For example: + * `cloudresourcemanager.googleapis.com/activity` Note that this field is not + * URL-encoded, unlike in `LogEntry`. + * + * Generated from protobuf field string log_id = 2; + */ + protected $log_id = ''; + /** + * The organization, folder, or project of the monitored resource that + * produced this log entry. + * + * Generated from protobuf field string resource_container = 3; + */ + protected $resource_container = ''; + /** + * The time the event described by the log entry occurred. + * + * Generated from protobuf field .google.protobuf.Timestamp timestamp = 4; + */ + protected $timestamp = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $insert_id + * A unique identifier for the log entry. + * @type string $log_id + * The type of the log (part of `log_name`. `log_name` is the resource name of + * the log to which this log entry belongs). For example: + * `cloudresourcemanager.googleapis.com/activity` Note that this field is not + * URL-encoded, unlike in `LogEntry`. + * @type string $resource_container + * The organization, folder, or project of the monitored resource that + * produced this log entry. + * @type \Google\Protobuf\Timestamp $timestamp + * The time the event described by the log entry occurred. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\LogEntry::initOnce(); + parent::__construct($data); + } + + /** + * A unique identifier for the log entry. + * + * Generated from protobuf field string insert_id = 1; + * @return string + */ + public function getInsertId() + { + return $this->insert_id; + } + + /** + * A unique identifier for the log entry. + * + * Generated from protobuf field string insert_id = 1; + * @param string $var + * @return $this + */ + public function setInsertId($var) + { + GPBUtil::checkString($var, True); + $this->insert_id = $var; + + return $this; + } + + /** + * The type of the log (part of `log_name`. `log_name` is the resource name of + * the log to which this log entry belongs). For example: + * `cloudresourcemanager.googleapis.com/activity` Note that this field is not + * URL-encoded, unlike in `LogEntry`. + * + * Generated from protobuf field string log_id = 2; + * @return string + */ + public function getLogId() + { + return $this->log_id; + } + + /** + * The type of the log (part of `log_name`. `log_name` is the resource name of + * the log to which this log entry belongs). For example: + * `cloudresourcemanager.googleapis.com/activity` Note that this field is not + * URL-encoded, unlike in `LogEntry`. + * + * Generated from protobuf field string log_id = 2; + * @param string $var + * @return $this + */ + public function setLogId($var) + { + GPBUtil::checkString($var, True); + $this->log_id = $var; + + return $this; + } + + /** + * The organization, folder, or project of the monitored resource that + * produced this log entry. + * + * Generated from protobuf field string resource_container = 3; + * @return string + */ + public function getResourceContainer() + { + return $this->resource_container; + } + + /** + * The organization, folder, or project of the monitored resource that + * produced this log entry. + * + * Generated from protobuf field string resource_container = 3; + * @param string $var + * @return $this + */ + public function setResourceContainer($var) + { + GPBUtil::checkString($var, True); + $this->resource_container = $var; + + return $this; + } + + /** + * The time the event described by the log entry occurred. + * + * Generated from protobuf field .google.protobuf.Timestamp timestamp = 4; + * @return \Google\Protobuf\Timestamp|null + */ + public function getTimestamp() + { + return $this->timestamp; + } + + public function hasTimestamp() + { + return isset($this->timestamp); + } + + public function clearTimestamp() + { + unset($this->timestamp); + } + + /** + * The time the event described by the log entry occurred. + * + * Generated from protobuf field .google.protobuf.Timestamp timestamp = 4; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setTimestamp($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->timestamp = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudProvider.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudProvider.php new file mode 100644 index 000000000000..3a7870cb6783 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudProvider.php @@ -0,0 +1,68 @@ +google.cloud.securitycenter.v2.CloudProvider + */ +class CloudProvider +{ + /** + * The cloud provider is unspecified. + * + * Generated from protobuf enum CLOUD_PROVIDER_UNSPECIFIED = 0; + */ + const CLOUD_PROVIDER_UNSPECIFIED = 0; + /** + * The cloud provider is Google Cloud Platform. + * + * Generated from protobuf enum GOOGLE_CLOUD_PLATFORM = 1; + */ + const GOOGLE_CLOUD_PLATFORM = 1; + /** + * The cloud provider is Amazon Web Services. + * + * Generated from protobuf enum AMAZON_WEB_SERVICES = 2; + */ + const AMAZON_WEB_SERVICES = 2; + /** + * The cloud provider is Microsoft Azure. + * + * Generated from protobuf enum MICROSOFT_AZURE = 3; + */ + const MICROSOFT_AZURE = 3; + + private static $valueToName = [ + self::CLOUD_PROVIDER_UNSPECIFIED => 'CLOUD_PROVIDER_UNSPECIFIED', + self::GOOGLE_CLOUD_PLATFORM => 'GOOGLE_CLOUD_PLATFORM', + self::AMAZON_WEB_SERVICES => 'AMAZON_WEB_SERVICES', + self::MICROSOFT_AZURE => 'MICROSOFT_AZURE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Compliance.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Compliance.php new file mode 100644 index 000000000000..fbc12e9a7e38 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Compliance.php @@ -0,0 +1,140 @@ +google.cloud.securitycenter.v2.Compliance + */ +class Compliance extends \Google\Protobuf\Internal\Message +{ + /** + * Industry-wide compliance standards or benchmarks, such as CIS, PCI, and + * OWASP. + * + * Generated from protobuf field string standard = 1; + */ + protected $standard = ''; + /** + * Version of the standard or benchmark, for example, 1.1 + * + * Generated from protobuf field string version = 2; + */ + protected $version = ''; + /** + * Policies within the standard or benchmark, for example, A.12.4.1 + * + * Generated from protobuf field repeated string ids = 3; + */ + private $ids; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $standard + * Industry-wide compliance standards or benchmarks, such as CIS, PCI, and + * OWASP. + * @type string $version + * Version of the standard or benchmark, for example, 1.1 + * @type array|\Google\Protobuf\Internal\RepeatedField $ids + * Policies within the standard or benchmark, for example, A.12.4.1 + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Compliance::initOnce(); + parent::__construct($data); + } + + /** + * Industry-wide compliance standards or benchmarks, such as CIS, PCI, and + * OWASP. + * + * Generated from protobuf field string standard = 1; + * @return string + */ + public function getStandard() + { + return $this->standard; + } + + /** + * Industry-wide compliance standards or benchmarks, such as CIS, PCI, and + * OWASP. + * + * Generated from protobuf field string standard = 1; + * @param string $var + * @return $this + */ + public function setStandard($var) + { + GPBUtil::checkString($var, True); + $this->standard = $var; + + return $this; + } + + /** + * Version of the standard or benchmark, for example, 1.1 + * + * Generated from protobuf field string version = 2; + * @return string + */ + public function getVersion() + { + return $this->version; + } + + /** + * Version of the standard or benchmark, for example, 1.1 + * + * Generated from protobuf field string version = 2; + * @param string $var + * @return $this + */ + public function setVersion($var) + { + GPBUtil::checkString($var, True); + $this->version = $var; + + return $this; + } + + /** + * Policies within the standard or benchmark, for example, A.12.4.1 + * + * Generated from protobuf field repeated string ids = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getIds() + { + return $this->ids; + } + + /** + * Policies within the standard or benchmark, for example, A.12.4.1 + * + * Generated from protobuf field repeated string ids = 3; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setIds($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->ids = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Connection.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Connection.php new file mode 100644 index 000000000000..c7097b6c8384 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Connection.php @@ -0,0 +1,211 @@ +google.cloud.securitycenter.v2.Connection + */ +class Connection extends \Google\Protobuf\Internal\Message +{ + /** + * Destination IP address. Not present for sockets that are listening and not + * connected. + * + * Generated from protobuf field string destination_ip = 1; + */ + protected $destination_ip = ''; + /** + * Destination port. Not present for sockets that are listening and not + * connected. + * + * Generated from protobuf field int32 destination_port = 2; + */ + protected $destination_port = 0; + /** + * Source IP address. + * + * Generated from protobuf field string source_ip = 3; + */ + protected $source_ip = ''; + /** + * Source port. + * + * Generated from protobuf field int32 source_port = 4; + */ + protected $source_port = 0; + /** + * IANA Internet Protocol Number such as TCP(6) and UDP(17). + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Connection.Protocol protocol = 5; + */ + protected $protocol = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $destination_ip + * Destination IP address. Not present for sockets that are listening and not + * connected. + * @type int $destination_port + * Destination port. Not present for sockets that are listening and not + * connected. + * @type string $source_ip + * Source IP address. + * @type int $source_port + * Source port. + * @type int $protocol + * IANA Internet Protocol Number such as TCP(6) and UDP(17). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Connection::initOnce(); + parent::__construct($data); + } + + /** + * Destination IP address. Not present for sockets that are listening and not + * connected. + * + * Generated from protobuf field string destination_ip = 1; + * @return string + */ + public function getDestinationIp() + { + return $this->destination_ip; + } + + /** + * Destination IP address. Not present for sockets that are listening and not + * connected. + * + * Generated from protobuf field string destination_ip = 1; + * @param string $var + * @return $this + */ + public function setDestinationIp($var) + { + GPBUtil::checkString($var, True); + $this->destination_ip = $var; + + return $this; + } + + /** + * Destination port. Not present for sockets that are listening and not + * connected. + * + * Generated from protobuf field int32 destination_port = 2; + * @return int + */ + public function getDestinationPort() + { + return $this->destination_port; + } + + /** + * Destination port. Not present for sockets that are listening and not + * connected. + * + * Generated from protobuf field int32 destination_port = 2; + * @param int $var + * @return $this + */ + public function setDestinationPort($var) + { + GPBUtil::checkInt32($var); + $this->destination_port = $var; + + return $this; + } + + /** + * Source IP address. + * + * Generated from protobuf field string source_ip = 3; + * @return string + */ + public function getSourceIp() + { + return $this->source_ip; + } + + /** + * Source IP address. + * + * Generated from protobuf field string source_ip = 3; + * @param string $var + * @return $this + */ + public function setSourceIp($var) + { + GPBUtil::checkString($var, True); + $this->source_ip = $var; + + return $this; + } + + /** + * Source port. + * + * Generated from protobuf field int32 source_port = 4; + * @return int + */ + public function getSourcePort() + { + return $this->source_port; + } + + /** + * Source port. + * + * Generated from protobuf field int32 source_port = 4; + * @param int $var + * @return $this + */ + public function setSourcePort($var) + { + GPBUtil::checkInt32($var); + $this->source_port = $var; + + return $this; + } + + /** + * IANA Internet Protocol Number such as TCP(6) and UDP(17). + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Connection.Protocol protocol = 5; + * @return int + */ + public function getProtocol() + { + return $this->protocol; + } + + /** + * IANA Internet Protocol Number such as TCP(6) and UDP(17). + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Connection.Protocol protocol = 5; + * @param int $var + * @return $this + */ + public function setProtocol($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Connection\Protocol::class); + $this->protocol = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Connection/Protocol.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Connection/Protocol.php new file mode 100644 index 000000000000..6a3acec59537 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Connection/Protocol.php @@ -0,0 +1,85 @@ +google.cloud.securitycenter.v2.Connection.Protocol + */ +class Protocol +{ + /** + * Unspecified protocol (not HOPOPT). + * + * Generated from protobuf enum PROTOCOL_UNSPECIFIED = 0; + */ + const PROTOCOL_UNSPECIFIED = 0; + /** + * Internet Control Message Protocol. + * + * Generated from protobuf enum ICMP = 1; + */ + const ICMP = 1; + /** + * Transmission Control Protocol. + * + * Generated from protobuf enum TCP = 6; + */ + const TCP = 6; + /** + * User Datagram Protocol. + * + * Generated from protobuf enum UDP = 17; + */ + const UDP = 17; + /** + * Generic Routing Encapsulation. + * + * Generated from protobuf enum GRE = 47; + */ + const GRE = 47; + /** + * Encap Security Payload. + * + * Generated from protobuf enum ESP = 50; + */ + const ESP = 50; + + private static $valueToName = [ + self::PROTOCOL_UNSPECIFIED => 'PROTOCOL_UNSPECIFIED', + self::ICMP => 'ICMP', + self::TCP => 'TCP', + self::UDP => 'UDP', + self::GRE => 'GRE', + self::ESP => 'ESP', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Protocol::class, \Google\Cloud\SecurityCenter\V2\Connection_Protocol::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Contact.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Contact.php new file mode 100644 index 000000000000..ee0ee7e41e87 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Contact.php @@ -0,0 +1,67 @@ +google.cloud.securitycenter.v2.Contact + */ +class Contact extends \Google\Protobuf\Internal\Message +{ + /** + * An email address. For example, "`person123@company.com`". + * + * Generated from protobuf field string email = 1; + */ + protected $email = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $email + * An email address. For example, "`person123@company.com`". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\ContactDetails::initOnce(); + parent::__construct($data); + } + + /** + * An email address. For example, "`person123@company.com`". + * + * Generated from protobuf field string email = 1; + * @return string + */ + public function getEmail() + { + return $this->email; + } + + /** + * An email address. For example, "`person123@company.com`". + * + * Generated from protobuf field string email = 1; + * @param string $var + * @return $this + */ + public function setEmail($var) + { + GPBUtil::checkString($var, True); + $this->email = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ContactDetails.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ContactDetails.php new file mode 100644 index 000000000000..79a31f59f3dc --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ContactDetails.php @@ -0,0 +1,67 @@ +google.cloud.securitycenter.v2.ContactDetails + */ +class ContactDetails extends \Google\Protobuf\Internal\Message +{ + /** + * A list of contacts + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Contact contacts = 1; + */ + private $contacts; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V2\Contact>|\Google\Protobuf\Internal\RepeatedField $contacts + * A list of contacts + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\ContactDetails::initOnce(); + parent::__construct($data); + } + + /** + * A list of contacts + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Contact contacts = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getContacts() + { + return $this->contacts; + } + + /** + * A list of contacts + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Contact contacts = 1; + * @param array<\Google\Cloud\SecurityCenter\V2\Contact>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setContacts($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Contact::class); + $this->contacts = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Container.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Container.php new file mode 100644 index 000000000000..fe9ed184436a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Container.php @@ -0,0 +1,221 @@ +google.cloud.securitycenter.v2.Container + */ +class Container extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the container. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Container image URI provided when configuring a pod or container. This + * string can identify a container image version using mutable tags. + * + * Generated from protobuf field string uri = 2; + */ + protected $uri = ''; + /** + * Optional container image ID, if provided by the container runtime. Uniquely + * identifies the container image launched using a container image digest. + * + * Generated from protobuf field string image_id = 3; + */ + protected $image_id = ''; + /** + * Container labels, as provided by the container runtime. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Label labels = 4; + */ + private $labels; + /** + * The time that the container was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 5; + */ + protected $create_time = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Name of the container. + * @type string $uri + * Container image URI provided when configuring a pod or container. This + * string can identify a container image version using mutable tags. + * @type string $image_id + * Optional container image ID, if provided by the container runtime. Uniquely + * identifies the container image launched using a container image digest. + * @type array<\Google\Cloud\SecurityCenter\V2\Label>|\Google\Protobuf\Internal\RepeatedField $labels + * Container labels, as provided by the container runtime. + * @type \Google\Protobuf\Timestamp $create_time + * The time that the container was created. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Container::initOnce(); + parent::__construct($data); + } + + /** + * Name of the container. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Name of the container. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Container image URI provided when configuring a pod or container. This + * string can identify a container image version using mutable tags. + * + * Generated from protobuf field string uri = 2; + * @return string + */ + public function getUri() + { + return $this->uri; + } + + /** + * Container image URI provided when configuring a pod or container. This + * string can identify a container image version using mutable tags. + * + * Generated from protobuf field string uri = 2; + * @param string $var + * @return $this + */ + public function setUri($var) + { + GPBUtil::checkString($var, True); + $this->uri = $var; + + return $this; + } + + /** + * Optional container image ID, if provided by the container runtime. Uniquely + * identifies the container image launched using a container image digest. + * + * Generated from protobuf field string image_id = 3; + * @return string + */ + public function getImageId() + { + return $this->image_id; + } + + /** + * Optional container image ID, if provided by the container runtime. Uniquely + * identifies the container image launched using a container image digest. + * + * Generated from protobuf field string image_id = 3; + * @param string $var + * @return $this + */ + public function setImageId($var) + { + GPBUtil::checkString($var, True); + $this->image_id = $var; + + return $this; + } + + /** + * Container labels, as provided by the container runtime. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Label labels = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getLabels() + { + return $this->labels; + } + + /** + * Container labels, as provided by the container runtime. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Label labels = 4; + * @param array<\Google\Cloud\SecurityCenter\V2\Label>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setLabels($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Label::class); + $this->labels = $arr; + + return $this; + } + + /** + * The time that the container was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 5; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCreateTime() + { + return $this->create_time; + } + + public function hasCreateTime() + { + return isset($this->create_time); + } + + public function clearCreateTime() + { + unset($this->create_time); + } + + /** + * The time that the container was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 5; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->create_time = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateBigQueryExportRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateBigQueryExportRequest.php new file mode 100644 index 000000000000..67573501164e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateBigQueryExportRequest.php @@ -0,0 +1,193 @@ +google.cloud.securitycenter.v2.CreateBigQueryExportRequest + */ +class CreateBigQueryExportRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the parent resource of the new BigQuery export. Its + * format is "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The BigQuery export being created. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.BigQueryExport big_query_export = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $big_query_export = null; + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * + * Generated from protobuf field string big_query_export_id = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $big_query_export_id = ''; + + /** + * @param string $parent Required. The name of the parent resource of the new BigQuery export. Its + * format is "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". Please see + * {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. + * @param \Google\Cloud\SecurityCenter\V2\BigQueryExport $bigQueryExport Required. The BigQuery export being created. + * @param string $bigQueryExportId Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * + * @return \Google\Cloud\SecurityCenter\V2\CreateBigQueryExportRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\SecurityCenter\V2\BigQueryExport $bigQueryExport, string $bigQueryExportId): self + { + return (new self()) + ->setParent($parent) + ->setBigQueryExport($bigQueryExport) + ->setBigQueryExportId($bigQueryExportId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The name of the parent resource of the new BigQuery export. Its + * format is "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * @type \Google\Cloud\SecurityCenter\V2\BigQueryExport $big_query_export + * Required. The BigQuery export being created. + * @type string $big_query_export_id + * Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the parent resource of the new BigQuery export. Its + * format is "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The name of the parent resource of the new BigQuery export. Its + * format is "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. The BigQuery export being created. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.BigQueryExport big_query_export = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V2\BigQueryExport|null + */ + public function getBigQueryExport() + { + return $this->big_query_export; + } + + public function hasBigQueryExport() + { + return isset($this->big_query_export); + } + + public function clearBigQueryExport() + { + unset($this->big_query_export); + } + + /** + * Required. The BigQuery export being created. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.BigQueryExport big_query_export = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V2\BigQueryExport $var + * @return $this + */ + public function setBigQueryExport($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\BigQueryExport::class); + $this->big_query_export = $var; + + return $this; + } + + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * + * Generated from protobuf field string big_query_export_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getBigQueryExportId() + { + return $this->big_query_export_id; + } + + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * + * Generated from protobuf field string big_query_export_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setBigQueryExportId($var) + { + GPBUtil::checkString($var, True); + $this->big_query_export_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateFindingRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateFindingRequest.php new file mode 100644 index 000000000000..8974b4f9387f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateFindingRequest.php @@ -0,0 +1,203 @@ +google.cloud.securitycenter.v2.CreateFindingRequest + */ +class CreateFindingRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the new finding's parent. The following list + * shows some examples of the format: + * + + * `organizations/[organization_id]/sources/[source_id]` + * + + * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + * + * Generated from protobuf field string finding_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $finding_id = ''; + /** + * Required. The Finding being created. The name and security_marks will be + * ignored as they are both output only fields on this resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $finding = null; + + /** + * @param string $parent Required. Resource name of the new finding's parent. The following list + * shows some examples of the format: + * + + * `organizations/[organization_id]/sources/[source_id]` + * + + * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` + * Please see {@see SecurityCenterClient::sourceName()} for help formatting this field. + * @param \Google\Cloud\SecurityCenter\V2\Finding $finding Required. The Finding being created. The name and security_marks will be + * ignored as they are both output only fields on this resource. + * @param string $findingId Required. Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + * + * @return \Google\Cloud\SecurityCenter\V2\CreateFindingRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\SecurityCenter\V2\Finding $finding, string $findingId): self + { + return (new self()) + ->setParent($parent) + ->setFinding($finding) + ->setFindingId($findingId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Resource name of the new finding's parent. The following list + * shows some examples of the format: + * + + * `organizations/[organization_id]/sources/[source_id]` + * + + * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` + * @type string $finding_id + * Required. Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + * @type \Google\Cloud\SecurityCenter\V2\Finding $finding + * Required. The Finding being created. The name and security_marks will be + * ignored as they are both output only fields on this resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the new finding's parent. The following list + * shows some examples of the format: + * + + * `organizations/[organization_id]/sources/[source_id]` + * + + * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Resource name of the new finding's parent. The following list + * shows some examples of the format: + * + + * `organizations/[organization_id]/sources/[source_id]` + * + + * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + * + * Generated from protobuf field string finding_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getFindingId() + { + return $this->finding_id; + } + + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must be alphanumeric and less than or equal to 32 characters and + * greater than 0 characters in length. + * + * Generated from protobuf field string finding_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setFindingId($var) + { + GPBUtil::checkString($var, True); + $this->finding_id = $var; + + return $this; + } + + /** + * Required. The Finding being created. The name and security_marks will be + * ignored as they are both output only fields on this resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V2\Finding|null + */ + public function getFinding() + { + return $this->finding; + } + + public function hasFinding() + { + return isset($this->finding); + } + + public function clearFinding() + { + unset($this->finding); + } + + /** + * Required. The Finding being created. The name and security_marks will be + * ignored as they are both output only fields on this resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V2\Finding $var + * @return $this + */ + public function setFinding($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Finding::class); + $this->finding = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateMuteConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateMuteConfigRequest.php new file mode 100644 index 000000000000..137dd1b119c6 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateMuteConfigRequest.php @@ -0,0 +1,193 @@ +google.cloud.securitycenter.v2.CreateMuteConfigRequest + */ +class CreateMuteConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the new mute configs's parent. Its format is + * "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The mute config being created. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.MuteConfig mute_config = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $mute_config = null; + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * + * Generated from protobuf field string mute_config_id = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $mute_config_id = ''; + + /** + * @param string $parent Required. Resource name of the new mute configs's parent. Its format is + * "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". Please see + * {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. + * @param \Google\Cloud\SecurityCenter\V2\MuteConfig $muteConfig Required. The mute config being created. + * @param string $muteConfigId Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * + * @return \Google\Cloud\SecurityCenter\V2\CreateMuteConfigRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\SecurityCenter\V2\MuteConfig $muteConfig, string $muteConfigId): self + { + return (new self()) + ->setParent($parent) + ->setMuteConfig($muteConfig) + ->setMuteConfigId($muteConfigId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Resource name of the new mute configs's parent. Its format is + * "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * @type \Google\Cloud\SecurityCenter\V2\MuteConfig $mute_config + * Required. The mute config being created. + * @type string $mute_config_id + * Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the new mute configs's parent. Its format is + * "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Resource name of the new mute configs's parent. Its format is + * "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. The mute config being created. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.MuteConfig mute_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V2\MuteConfig|null + */ + public function getMuteConfig() + { + return $this->mute_config; + } + + public function hasMuteConfig() + { + return isset($this->mute_config); + } + + public function clearMuteConfig() + { + unset($this->mute_config); + } + + /** + * Required. The mute config being created. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.MuteConfig mute_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V2\MuteConfig $var + * @return $this + */ + public function setMuteConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\MuteConfig::class); + $this->mute_config = $var; + + return $this; + } + + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * + * Generated from protobuf field string mute_config_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getMuteConfigId() + { + return $this->mute_config_id; + } + + /** + * Required. Unique identifier provided by the client within the parent scope. + * It must consist of only lowercase letters, numbers, and hyphens, must start + * with a letter, must end with either a letter or a number, and must be 63 + * characters or less. + * + * Generated from protobuf field string mute_config_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setMuteConfigId($var) + { + GPBUtil::checkString($var, True); + $this->mute_config_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateNotificationConfigRequest.php new file mode 100644 index 000000000000..aade0d29f8d1 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateNotificationConfigRequest.php @@ -0,0 +1,203 @@ +google.cloud.securitycenter.v2.CreateNotificationConfigRequest + */ +class CreateNotificationConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the new notification config's parent. Its format + * is "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. + * Unique identifier provided by the client within the parent scope. + * It must be between 1 and 128 characters and contain alphanumeric + * characters, underscores, or hyphens only. + * + * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $config_id = ''; + /** + * Required. The notification config being created. The name and the service + * account will be ignored as they are both output only fields on this + * resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.NotificationConfig notification_config = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $notification_config = null; + + /** + * @param string $parent Required. Resource name of the new notification config's parent. Its format + * is "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". Please see + * {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. + * @param \Google\Cloud\SecurityCenter\V2\NotificationConfig $notificationConfig Required. The notification config being created. The name and the service + * account will be ignored as they are both output only fields on this + * resource. + * @param string $configId Required. + * Unique identifier provided by the client within the parent scope. + * It must be between 1 and 128 characters and contain alphanumeric + * characters, underscores, or hyphens only. + * + * @return \Google\Cloud\SecurityCenter\V2\CreateNotificationConfigRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\SecurityCenter\V2\NotificationConfig $notificationConfig, string $configId): self + { + return (new self()) + ->setParent($parent) + ->setNotificationConfig($notificationConfig) + ->setConfigId($configId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Resource name of the new notification config's parent. Its format + * is "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * @type string $config_id + * Required. + * Unique identifier provided by the client within the parent scope. + * It must be between 1 and 128 characters and contain alphanumeric + * characters, underscores, or hyphens only. + * @type \Google\Cloud\SecurityCenter\V2\NotificationConfig $notification_config + * Required. The notification config being created. The name and the service + * account will be ignored as they are both output only fields on this + * resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the new notification config's parent. Its format + * is "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Resource name of the new notification config's parent. Its format + * is "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. + * Unique identifier provided by the client within the parent scope. + * It must be between 1 and 128 characters and contain alphanumeric + * characters, underscores, or hyphens only. + * + * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getConfigId() + { + return $this->config_id; + } + + /** + * Required. + * Unique identifier provided by the client within the parent scope. + * It must be between 1 and 128 characters and contain alphanumeric + * characters, underscores, or hyphens only. + * + * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setConfigId($var) + { + GPBUtil::checkString($var, True); + $this->config_id = $var; + + return $this; + } + + /** + * Required. The notification config being created. The name and the service + * account will be ignored as they are both output only fields on this + * resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.NotificationConfig notification_config = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V2\NotificationConfig|null + */ + public function getNotificationConfig() + { + return $this->notification_config; + } + + public function hasNotificationConfig() + { + return isset($this->notification_config); + } + + public function clearNotificationConfig() + { + unset($this->notification_config); + } + + /** + * Required. The notification config being created. The name and the service + * account will be ignored as they are both output only fields on this + * resource. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.NotificationConfig notification_config = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V2\NotificationConfig $var + * @return $this + */ + public function setNotificationConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\NotificationConfig::class); + $this->notification_config = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateResourceValueConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateResourceValueConfigRequest.php new file mode 100644 index 000000000000..28978595801a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateResourceValueConfigRequest.php @@ -0,0 +1,111 @@ +google.cloud.securitycenter.v2.CreateResourceValueConfigRequest + */ +class CreateResourceValueConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the new ResourceValueConfig's parent. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The resource value config being created. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_config = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $resource_value_config = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Resource name of the new ResourceValueConfig's parent. + * @type \Google\Cloud\SecurityCenter\V2\ResourceValueConfig $resource_value_config + * Required. The resource value config being created. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the new ResourceValueConfig's parent. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Resource name of the new ResourceValueConfig's parent. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. The resource value config being created. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V2\ResourceValueConfig|null + */ + public function getResourceValueConfig() + { + return $this->resource_value_config; + } + + public function hasResourceValueConfig() + { + return isset($this->resource_value_config); + } + + public function clearResourceValueConfig() + { + unset($this->resource_value_config); + } + + /** + * Required. The resource value config being created. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V2\ResourceValueConfig $var + * @return $this + */ + public function setResourceValueConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ResourceValueConfig::class); + $this->resource_value_config = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateSourceRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateSourceRequest.php new file mode 100644 index 000000000000..b6617f605ad1 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateSourceRequest.php @@ -0,0 +1,137 @@ +google.cloud.securitycenter.v2.CreateSourceRequest + */ +class CreateSourceRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The Source being created, only the display_name and description + * will be used. All other fields will be ignored. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Source source = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $source = null; + + /** + * @param string $parent Required. Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". Please see + * {@see SecurityCenterClient::organizationName()} for help formatting this field. + * @param \Google\Cloud\SecurityCenter\V2\Source $source Required. The Source being created, only the display_name and description + * will be used. All other fields will be ignored. + * + * @return \Google\Cloud\SecurityCenter\V2\CreateSourceRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\SecurityCenter\V2\Source $source): self + { + return (new self()) + ->setParent($parent) + ->setSource($source); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + * @type \Google\Cloud\SecurityCenter\V2\Source $source + * Required. The Source being created, only the display_name and description + * will be used. All other fields will be ignored. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Resource name of the new source's parent. Its format should be + * "organizations/[organization_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Required. The Source being created, only the display_name and description + * will be used. All other fields will be ignored. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Source source = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V2\Source|null + */ + public function getSource() + { + return $this->source; + } + + public function hasSource() + { + return isset($this->source); + } + + public function clearSource() + { + unset($this->source); + } + + /** + * Required. The Source being created, only the display_name and description + * will be used. All other fields will be ignored. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Source source = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V2\Source $var + * @return $this + */ + public function setSource($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Source::class); + $this->source = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve.php new file mode 100644 index 000000000000..97f7f34d10df --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve.php @@ -0,0 +1,330 @@ +google.cloud.securitycenter.v2.Cve + */ +class Cve extends \Google\Protobuf\Internal\Message +{ + /** + * The unique identifier for the vulnerability. e.g. CVE-2021-34527 + * + * Generated from protobuf field string id = 1; + */ + protected $id = ''; + /** + * Additional information about the CVE. + * e.g. https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527 + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Reference references = 2; + */ + private $references; + /** + * Describe Common Vulnerability Scoring System specified at + * https://www.first.org/cvss/v3.1/specification-document + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3 cvssv3 = 3; + */ + protected $cvssv3 = null; + /** + * Whether upstream fix is available for the CVE. + * + * Generated from protobuf field bool upstream_fix_available = 4; + */ + protected $upstream_fix_available = false; + /** + * The potential impact of the vulnerability if it was to be exploited. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cve.RiskRating impact = 5; + */ + protected $impact = 0; + /** + * The exploitation activity of the vulnerability in the wild. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cve.ExploitationActivity exploitation_activity = 6; + */ + protected $exploitation_activity = 0; + /** + * Whether or not the vulnerability has been observed in the wild. + * + * Generated from protobuf field bool observed_in_the_wild = 7; + */ + protected $observed_in_the_wild = false; + /** + * Whether or not the vulnerability was zero day when the finding was + * published. + * + * Generated from protobuf field bool zero_day = 8; + */ + protected $zero_day = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $id + * The unique identifier for the vulnerability. e.g. CVE-2021-34527 + * @type array<\Google\Cloud\SecurityCenter\V2\Reference>|\Google\Protobuf\Internal\RepeatedField $references + * Additional information about the CVE. + * e.g. https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527 + * @type \Google\Cloud\SecurityCenter\V2\Cvssv3 $cvssv3 + * Describe Common Vulnerability Scoring System specified at + * https://www.first.org/cvss/v3.1/specification-document + * @type bool $upstream_fix_available + * Whether upstream fix is available for the CVE. + * @type int $impact + * The potential impact of the vulnerability if it was to be exploited. + * @type int $exploitation_activity + * The exploitation activity of the vulnerability in the wild. + * @type bool $observed_in_the_wild + * Whether or not the vulnerability has been observed in the wild. + * @type bool $zero_day + * Whether or not the vulnerability was zero day when the finding was + * published. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Vulnerability::initOnce(); + parent::__construct($data); + } + + /** + * The unique identifier for the vulnerability. e.g. CVE-2021-34527 + * + * Generated from protobuf field string id = 1; + * @return string + */ + public function getId() + { + return $this->id; + } + + /** + * The unique identifier for the vulnerability. e.g. CVE-2021-34527 + * + * Generated from protobuf field string id = 1; + * @param string $var + * @return $this + */ + public function setId($var) + { + GPBUtil::checkString($var, True); + $this->id = $var; + + return $this; + } + + /** + * Additional information about the CVE. + * e.g. https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527 + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Reference references = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getReferences() + { + return $this->references; + } + + /** + * Additional information about the CVE. + * e.g. https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527 + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Reference references = 2; + * @param array<\Google\Cloud\SecurityCenter\V2\Reference>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setReferences($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Reference::class); + $this->references = $arr; + + return $this; + } + + /** + * Describe Common Vulnerability Scoring System specified at + * https://www.first.org/cvss/v3.1/specification-document + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3 cvssv3 = 3; + * @return \Google\Cloud\SecurityCenter\V2\Cvssv3|null + */ + public function getCvssv3() + { + return $this->cvssv3; + } + + public function hasCvssv3() + { + return isset($this->cvssv3); + } + + public function clearCvssv3() + { + unset($this->cvssv3); + } + + /** + * Describe Common Vulnerability Scoring System specified at + * https://www.first.org/cvss/v3.1/specification-document + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3 cvssv3 = 3; + * @param \Google\Cloud\SecurityCenter\V2\Cvssv3 $var + * @return $this + */ + public function setCvssv3($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Cvssv3::class); + $this->cvssv3 = $var; + + return $this; + } + + /** + * Whether upstream fix is available for the CVE. + * + * Generated from protobuf field bool upstream_fix_available = 4; + * @return bool + */ + public function getUpstreamFixAvailable() + { + return $this->upstream_fix_available; + } + + /** + * Whether upstream fix is available for the CVE. + * + * Generated from protobuf field bool upstream_fix_available = 4; + * @param bool $var + * @return $this + */ + public function setUpstreamFixAvailable($var) + { + GPBUtil::checkBool($var); + $this->upstream_fix_available = $var; + + return $this; + } + + /** + * The potential impact of the vulnerability if it was to be exploited. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cve.RiskRating impact = 5; + * @return int + */ + public function getImpact() + { + return $this->impact; + } + + /** + * The potential impact of the vulnerability if it was to be exploited. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cve.RiskRating impact = 5; + * @param int $var + * @return $this + */ + public function setImpact($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cve\RiskRating::class); + $this->impact = $var; + + return $this; + } + + /** + * The exploitation activity of the vulnerability in the wild. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cve.ExploitationActivity exploitation_activity = 6; + * @return int + */ + public function getExploitationActivity() + { + return $this->exploitation_activity; + } + + /** + * The exploitation activity of the vulnerability in the wild. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cve.ExploitationActivity exploitation_activity = 6; + * @param int $var + * @return $this + */ + public function setExploitationActivity($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cve\ExploitationActivity::class); + $this->exploitation_activity = $var; + + return $this; + } + + /** + * Whether or not the vulnerability has been observed in the wild. + * + * Generated from protobuf field bool observed_in_the_wild = 7; + * @return bool + */ + public function getObservedInTheWild() + { + return $this->observed_in_the_wild; + } + + /** + * Whether or not the vulnerability has been observed in the wild. + * + * Generated from protobuf field bool observed_in_the_wild = 7; + * @param bool $var + * @return $this + */ + public function setObservedInTheWild($var) + { + GPBUtil::checkBool($var); + $this->observed_in_the_wild = $var; + + return $this; + } + + /** + * Whether or not the vulnerability was zero day when the finding was + * published. + * + * Generated from protobuf field bool zero_day = 8; + * @return bool + */ + public function getZeroDay() + { + return $this->zero_day; + } + + /** + * Whether or not the vulnerability was zero day when the finding was + * published. + * + * Generated from protobuf field bool zero_day = 8; + * @param bool $var + * @return $this + */ + public function setZeroDay($var) + { + GPBUtil::checkBool($var); + $this->zero_day = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve/ExploitationActivity.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve/ExploitationActivity.php new file mode 100644 index 000000000000..a9c02c71ba55 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve/ExploitationActivity.php @@ -0,0 +1,87 @@ +google.cloud.securitycenter.v2.Cve.ExploitationActivity + */ +class ExploitationActivity +{ + /** + * Invalid or empty value. + * + * Generated from protobuf enum EXPLOITATION_ACTIVITY_UNSPECIFIED = 0; + */ + const EXPLOITATION_ACTIVITY_UNSPECIFIED = 0; + /** + * Exploitation has been reported or confirmed to widely occur. + * + * Generated from protobuf enum WIDE = 1; + */ + const WIDE = 1; + /** + * Limited reported or confirmed exploitation activities. + * + * Generated from protobuf enum CONFIRMED = 2; + */ + const CONFIRMED = 2; + /** + * Exploit is publicly available. + * + * Generated from protobuf enum AVAILABLE = 3; + */ + const AVAILABLE = 3; + /** + * No known exploitation activity, but has a high potential for + * exploitation. + * + * Generated from protobuf enum ANTICIPATED = 4; + */ + const ANTICIPATED = 4; + /** + * No known exploitation activity. + * + * Generated from protobuf enum NO_KNOWN = 5; + */ + const NO_KNOWN = 5; + + private static $valueToName = [ + self::EXPLOITATION_ACTIVITY_UNSPECIFIED => 'EXPLOITATION_ACTIVITY_UNSPECIFIED', + self::WIDE => 'WIDE', + self::CONFIRMED => 'CONFIRMED', + self::AVAILABLE => 'AVAILABLE', + self::ANTICIPATED => 'ANTICIPATED', + self::NO_KNOWN => 'NO_KNOWN', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ExploitationActivity::class, \Google\Cloud\SecurityCenter\V2\Cve_ExploitationActivity::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve/RiskRating.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve/RiskRating.php new file mode 100644 index 000000000000..29d2e11af4b2 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve/RiskRating.php @@ -0,0 +1,83 @@ +google.cloud.securitycenter.v2.Cve.RiskRating + */ +class RiskRating +{ + /** + * Invalid or empty value. + * + * Generated from protobuf enum RISK_RATING_UNSPECIFIED = 0; + */ + const RISK_RATING_UNSPECIFIED = 0; + /** + * Exploitation would have little to no security impact. + * + * Generated from protobuf enum LOW = 1; + */ + const LOW = 1; + /** + * Exploitation would enable attackers to perform activities, or could allow + * attackers to have a direct impact, but would require additional steps. + * + * Generated from protobuf enum MEDIUM = 2; + */ + const MEDIUM = 2; + /** + * Exploitation would enable attackers to have a notable direct impact + * without needing to overcome any major mitigating factors. + * + * Generated from protobuf enum HIGH = 3; + */ + const HIGH = 3; + /** + * Exploitation would fundamentally undermine the security of affected + * systems, enable actors to perform significant attacks with minimal + * effort, with little to no mitigating factors to overcome. + * + * Generated from protobuf enum CRITICAL = 4; + */ + const CRITICAL = 4; + + private static $valueToName = [ + self::RISK_RATING_UNSPECIFIED => 'RISK_RATING_UNSPECIFIED', + self::LOW => 'LOW', + self::MEDIUM => 'MEDIUM', + self::HIGH => 'HIGH', + self::CRITICAL => 'CRITICAL', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(RiskRating::class, \Google\Cloud\SecurityCenter\V2\Cve_RiskRating::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3.php new file mode 100644 index 000000000000..ab89232be139 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3.php @@ -0,0 +1,391 @@ +google.cloud.securitycenter.v2.Cvssv3 + */ +class Cvssv3 extends \Google\Protobuf\Internal\Message +{ + /** + * The base score is a function of the base metric scores. + * + * Generated from protobuf field double base_score = 1; + */ + protected $base_score = 0.0; + /** + * Base Metrics + * Represents the intrinsic characteristics of a vulnerability that are + * constant over time and across user environments. + * This metric reflects the context by which vulnerability exploitation is + * possible. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.AttackVector attack_vector = 2; + */ + protected $attack_vector = 0; + /** + * This metric describes the conditions beyond the attacker's control that + * must exist in order to exploit the vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.AttackComplexity attack_complexity = 3; + */ + protected $attack_complexity = 0; + /** + * This metric describes the level of privileges an attacker must possess + * before successfully exploiting the vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.PrivilegesRequired privileges_required = 4; + */ + protected $privileges_required = 0; + /** + * This metric captures the requirement for a human user, other than the + * attacker, to participate in the successful compromise of the vulnerable + * component. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.UserInteraction user_interaction = 5; + */ + protected $user_interaction = 0; + /** + * The Scope metric captures whether a vulnerability in one vulnerable + * component impacts resources in components beyond its security scope. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Scope scope = 6; + */ + protected $scope = 0; + /** + * This metric measures the impact to the confidentiality of the information + * resources managed by a software component due to a successfully exploited + * vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Impact confidentiality_impact = 7; + */ + protected $confidentiality_impact = 0; + /** + * This metric measures the impact to integrity of a successfully exploited + * vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Impact integrity_impact = 8; + */ + protected $integrity_impact = 0; + /** + * This metric measures the impact to the availability of the impacted + * component resulting from a successfully exploited vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Impact availability_impact = 9; + */ + protected $availability_impact = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type float $base_score + * The base score is a function of the base metric scores. + * @type int $attack_vector + * Base Metrics + * Represents the intrinsic characteristics of a vulnerability that are + * constant over time and across user environments. + * This metric reflects the context by which vulnerability exploitation is + * possible. + * @type int $attack_complexity + * This metric describes the conditions beyond the attacker's control that + * must exist in order to exploit the vulnerability. + * @type int $privileges_required + * This metric describes the level of privileges an attacker must possess + * before successfully exploiting the vulnerability. + * @type int $user_interaction + * This metric captures the requirement for a human user, other than the + * attacker, to participate in the successful compromise of the vulnerable + * component. + * @type int $scope + * The Scope metric captures whether a vulnerability in one vulnerable + * component impacts resources in components beyond its security scope. + * @type int $confidentiality_impact + * This metric measures the impact to the confidentiality of the information + * resources managed by a software component due to a successfully exploited + * vulnerability. + * @type int $integrity_impact + * This metric measures the impact to integrity of a successfully exploited + * vulnerability. + * @type int $availability_impact + * This metric measures the impact to the availability of the impacted + * component resulting from a successfully exploited vulnerability. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Vulnerability::initOnce(); + parent::__construct($data); + } + + /** + * The base score is a function of the base metric scores. + * + * Generated from protobuf field double base_score = 1; + * @return float + */ + public function getBaseScore() + { + return $this->base_score; + } + + /** + * The base score is a function of the base metric scores. + * + * Generated from protobuf field double base_score = 1; + * @param float $var + * @return $this + */ + public function setBaseScore($var) + { + GPBUtil::checkDouble($var); + $this->base_score = $var; + + return $this; + } + + /** + * Base Metrics + * Represents the intrinsic characteristics of a vulnerability that are + * constant over time and across user environments. + * This metric reflects the context by which vulnerability exploitation is + * possible. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.AttackVector attack_vector = 2; + * @return int + */ + public function getAttackVector() + { + return $this->attack_vector; + } + + /** + * Base Metrics + * Represents the intrinsic characteristics of a vulnerability that are + * constant over time and across user environments. + * This metric reflects the context by which vulnerability exploitation is + * possible. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.AttackVector attack_vector = 2; + * @param int $var + * @return $this + */ + public function setAttackVector($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cvssv3\AttackVector::class); + $this->attack_vector = $var; + + return $this; + } + + /** + * This metric describes the conditions beyond the attacker's control that + * must exist in order to exploit the vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.AttackComplexity attack_complexity = 3; + * @return int + */ + public function getAttackComplexity() + { + return $this->attack_complexity; + } + + /** + * This metric describes the conditions beyond the attacker's control that + * must exist in order to exploit the vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.AttackComplexity attack_complexity = 3; + * @param int $var + * @return $this + */ + public function setAttackComplexity($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cvssv3\AttackComplexity::class); + $this->attack_complexity = $var; + + return $this; + } + + /** + * This metric describes the level of privileges an attacker must possess + * before successfully exploiting the vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.PrivilegesRequired privileges_required = 4; + * @return int + */ + public function getPrivilegesRequired() + { + return $this->privileges_required; + } + + /** + * This metric describes the level of privileges an attacker must possess + * before successfully exploiting the vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.PrivilegesRequired privileges_required = 4; + * @param int $var + * @return $this + */ + public function setPrivilegesRequired($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cvssv3\PrivilegesRequired::class); + $this->privileges_required = $var; + + return $this; + } + + /** + * This metric captures the requirement for a human user, other than the + * attacker, to participate in the successful compromise of the vulnerable + * component. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.UserInteraction user_interaction = 5; + * @return int + */ + public function getUserInteraction() + { + return $this->user_interaction; + } + + /** + * This metric captures the requirement for a human user, other than the + * attacker, to participate in the successful compromise of the vulnerable + * component. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.UserInteraction user_interaction = 5; + * @param int $var + * @return $this + */ + public function setUserInteraction($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cvssv3\UserInteraction::class); + $this->user_interaction = $var; + + return $this; + } + + /** + * The Scope metric captures whether a vulnerability in one vulnerable + * component impacts resources in components beyond its security scope. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Scope scope = 6; + * @return int + */ + public function getScope() + { + return $this->scope; + } + + /** + * The Scope metric captures whether a vulnerability in one vulnerable + * component impacts resources in components beyond its security scope. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Scope scope = 6; + * @param int $var + * @return $this + */ + public function setScope($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cvssv3\Scope::class); + $this->scope = $var; + + return $this; + } + + /** + * This metric measures the impact to the confidentiality of the information + * resources managed by a software component due to a successfully exploited + * vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Impact confidentiality_impact = 7; + * @return int + */ + public function getConfidentialityImpact() + { + return $this->confidentiality_impact; + } + + /** + * This metric measures the impact to the confidentiality of the information + * resources managed by a software component due to a successfully exploited + * vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Impact confidentiality_impact = 7; + * @param int $var + * @return $this + */ + public function setConfidentialityImpact($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cvssv3\Impact::class); + $this->confidentiality_impact = $var; + + return $this; + } + + /** + * This metric measures the impact to integrity of a successfully exploited + * vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Impact integrity_impact = 8; + * @return int + */ + public function getIntegrityImpact() + { + return $this->integrity_impact; + } + + /** + * This metric measures the impact to integrity of a successfully exploited + * vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Impact integrity_impact = 8; + * @param int $var + * @return $this + */ + public function setIntegrityImpact($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cvssv3\Impact::class); + $this->integrity_impact = $var; + + return $this; + } + + /** + * This metric measures the impact to the availability of the impacted + * component resulting from a successfully exploited vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Impact availability_impact = 9; + * @return int + */ + public function getAvailabilityImpact() + { + return $this->availability_impact; + } + + /** + * This metric measures the impact to the availability of the impacted + * component resulting from a successfully exploited vulnerability. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Impact availability_impact = 9; + * @param int $var + * @return $this + */ + public function setAvailabilityImpact($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cvssv3\Impact::class); + $this->availability_impact = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/AttackComplexity.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/AttackComplexity.php new file mode 100644 index 000000000000..5c6149504883 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/AttackComplexity.php @@ -0,0 +1,71 @@ +google.cloud.securitycenter.v2.Cvssv3.AttackComplexity + */ +class AttackComplexity +{ + /** + * Invalid value. + * + * Generated from protobuf enum ATTACK_COMPLEXITY_UNSPECIFIED = 0; + */ + const ATTACK_COMPLEXITY_UNSPECIFIED = 0; + /** + * Specialized access conditions or extenuating circumstances do not exist. + * An attacker can expect repeatable success when attacking the vulnerable + * component. + * + * Generated from protobuf enum ATTACK_COMPLEXITY_LOW = 1; + */ + const ATTACK_COMPLEXITY_LOW = 1; + /** + * A successful attack depends on conditions beyond the attacker's control. + * That is, a successful attack cannot be accomplished at will, but requires + * the attacker to invest in some measurable amount of effort in preparation + * or execution against the vulnerable component before a successful attack + * can be expected. + * + * Generated from protobuf enum ATTACK_COMPLEXITY_HIGH = 2; + */ + const ATTACK_COMPLEXITY_HIGH = 2; + + private static $valueToName = [ + self::ATTACK_COMPLEXITY_UNSPECIFIED => 'ATTACK_COMPLEXITY_UNSPECIFIED', + self::ATTACK_COMPLEXITY_LOW => 'ATTACK_COMPLEXITY_LOW', + self::ATTACK_COMPLEXITY_HIGH => 'ATTACK_COMPLEXITY_HIGH', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AttackComplexity::class, \Google\Cloud\SecurityCenter\V2\Cvssv3_AttackComplexity::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/AttackVector.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/AttackVector.php new file mode 100644 index 000000000000..c6839e85e27f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/AttackVector.php @@ -0,0 +1,84 @@ +google.cloud.securitycenter.v2.Cvssv3.AttackVector + */ +class AttackVector +{ + /** + * Invalid value. + * + * Generated from protobuf enum ATTACK_VECTOR_UNSPECIFIED = 0; + */ + const ATTACK_VECTOR_UNSPECIFIED = 0; + /** + * The vulnerable component is bound to the network stack and the set of + * possible attackers extends beyond the other options listed below, up to + * and including the entire Internet. + * + * Generated from protobuf enum ATTACK_VECTOR_NETWORK = 1; + */ + const ATTACK_VECTOR_NETWORK = 1; + /** + * The vulnerable component is bound to the network stack, but the attack is + * limited at the protocol level to a logically adjacent topology. + * + * Generated from protobuf enum ATTACK_VECTOR_ADJACENT = 2; + */ + const ATTACK_VECTOR_ADJACENT = 2; + /** + * The vulnerable component is not bound to the network stack and the + * attacker's path is via read/write/execute capabilities. + * + * Generated from protobuf enum ATTACK_VECTOR_LOCAL = 3; + */ + const ATTACK_VECTOR_LOCAL = 3; + /** + * The attack requires the attacker to physically touch or manipulate the + * vulnerable component. + * + * Generated from protobuf enum ATTACK_VECTOR_PHYSICAL = 4; + */ + const ATTACK_VECTOR_PHYSICAL = 4; + + private static $valueToName = [ + self::ATTACK_VECTOR_UNSPECIFIED => 'ATTACK_VECTOR_UNSPECIFIED', + self::ATTACK_VECTOR_NETWORK => 'ATTACK_VECTOR_NETWORK', + self::ATTACK_VECTOR_ADJACENT => 'ATTACK_VECTOR_ADJACENT', + self::ATTACK_VECTOR_LOCAL => 'ATTACK_VECTOR_LOCAL', + self::ATTACK_VECTOR_PHYSICAL => 'ATTACK_VECTOR_PHYSICAL', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AttackVector::class, \Google\Cloud\SecurityCenter\V2\Cvssv3_AttackVector::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/Impact.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/Impact.php new file mode 100644 index 000000000000..53d4f5e41900 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/Impact.php @@ -0,0 +1,73 @@ +google.cloud.securitycenter.v2.Cvssv3.Impact + */ +class Impact +{ + /** + * Invalid value. + * + * Generated from protobuf enum IMPACT_UNSPECIFIED = 0; + */ + const IMPACT_UNSPECIFIED = 0; + /** + * High impact. + * + * Generated from protobuf enum IMPACT_HIGH = 1; + */ + const IMPACT_HIGH = 1; + /** + * Low impact. + * + * Generated from protobuf enum IMPACT_LOW = 2; + */ + const IMPACT_LOW = 2; + /** + * No impact. + * + * Generated from protobuf enum IMPACT_NONE = 3; + */ + const IMPACT_NONE = 3; + + private static $valueToName = [ + self::IMPACT_UNSPECIFIED => 'IMPACT_UNSPECIFIED', + self::IMPACT_HIGH => 'IMPACT_HIGH', + self::IMPACT_LOW => 'IMPACT_LOW', + self::IMPACT_NONE => 'IMPACT_NONE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Impact::class, \Google\Cloud\SecurityCenter\V2\Cvssv3_Impact::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/PrivilegesRequired.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/PrivilegesRequired.php new file mode 100644 index 000000000000..859e56b93885 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/PrivilegesRequired.php @@ -0,0 +1,79 @@ +google.cloud.securitycenter.v2.Cvssv3.PrivilegesRequired + */ +class PrivilegesRequired +{ + /** + * Invalid value. + * + * Generated from protobuf enum PRIVILEGES_REQUIRED_UNSPECIFIED = 0; + */ + const PRIVILEGES_REQUIRED_UNSPECIFIED = 0; + /** + * The attacker is unauthorized prior to attack, and therefore does not + * require any access to settings or files of the vulnerable system to + * carry out an attack. + * + * Generated from protobuf enum PRIVILEGES_REQUIRED_NONE = 1; + */ + const PRIVILEGES_REQUIRED_NONE = 1; + /** + * The attacker requires privileges that provide basic user capabilities + * that could normally affect only settings and files owned by a user. + * Alternatively, an attacker with Low privileges has the ability to access + * only non-sensitive resources. + * + * Generated from protobuf enum PRIVILEGES_REQUIRED_LOW = 2; + */ + const PRIVILEGES_REQUIRED_LOW = 2; + /** + * The attacker requires privileges that provide significant (e.g., + * administrative) control over the vulnerable component allowing access to + * component-wide settings and files. + * + * Generated from protobuf enum PRIVILEGES_REQUIRED_HIGH = 3; + */ + const PRIVILEGES_REQUIRED_HIGH = 3; + + private static $valueToName = [ + self::PRIVILEGES_REQUIRED_UNSPECIFIED => 'PRIVILEGES_REQUIRED_UNSPECIFIED', + self::PRIVILEGES_REQUIRED_NONE => 'PRIVILEGES_REQUIRED_NONE', + self::PRIVILEGES_REQUIRED_LOW => 'PRIVILEGES_REQUIRED_LOW', + self::PRIVILEGES_REQUIRED_HIGH => 'PRIVILEGES_REQUIRED_HIGH', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(PrivilegesRequired::class, \Google\Cloud\SecurityCenter\V2\Cvssv3_PrivilegesRequired::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/Scope.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/Scope.php new file mode 100644 index 000000000000..146b335e704a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/Scope.php @@ -0,0 +1,67 @@ +google.cloud.securitycenter.v2.Cvssv3.Scope + */ +class Scope +{ + /** + * Invalid value. + * + * Generated from protobuf enum SCOPE_UNSPECIFIED = 0; + */ + const SCOPE_UNSPECIFIED = 0; + /** + * An exploited vulnerability can only affect resources managed by the same + * security authority. + * + * Generated from protobuf enum SCOPE_UNCHANGED = 1; + */ + const SCOPE_UNCHANGED = 1; + /** + * An exploited vulnerability can affect resources beyond the security scope + * managed by the security authority of the vulnerable component. + * + * Generated from protobuf enum SCOPE_CHANGED = 2; + */ + const SCOPE_CHANGED = 2; + + private static $valueToName = [ + self::SCOPE_UNSPECIFIED => 'SCOPE_UNSPECIFIED', + self::SCOPE_UNCHANGED => 'SCOPE_UNCHANGED', + self::SCOPE_CHANGED => 'SCOPE_CHANGED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Scope::class, \Google\Cloud\SecurityCenter\V2\Cvssv3_Scope::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/UserInteraction.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/UserInteraction.php new file mode 100644 index 000000000000..fb1f4798ae49 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/UserInteraction.php @@ -0,0 +1,67 @@ +google.cloud.securitycenter.v2.Cvssv3.UserInteraction + */ +class UserInteraction +{ + /** + * Invalid value. + * + * Generated from protobuf enum USER_INTERACTION_UNSPECIFIED = 0; + */ + const USER_INTERACTION_UNSPECIFIED = 0; + /** + * The vulnerable system can be exploited without interaction from any user. + * + * Generated from protobuf enum USER_INTERACTION_NONE = 1; + */ + const USER_INTERACTION_NONE = 1; + /** + * Successful exploitation of this vulnerability requires a user to take + * some action before the vulnerability can be exploited. + * + * Generated from protobuf enum USER_INTERACTION_REQUIRED = 2; + */ + const USER_INTERACTION_REQUIRED = 2; + + private static $valueToName = [ + self::USER_INTERACTION_UNSPECIFIED => 'USER_INTERACTION_UNSPECIFIED', + self::USER_INTERACTION_NONE => 'USER_INTERACTION_NONE', + self::USER_INTERACTION_REQUIRED => 'USER_INTERACTION_REQUIRED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(UserInteraction::class, \Google\Cloud\SecurityCenter\V2\Cvssv3_UserInteraction::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Database.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Database.php new file mode 100644 index 000000000000..f4fd26f90546 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Database.php @@ -0,0 +1,287 @@ +google.cloud.securitycenter.v2.Database + */ +class Database extends \Google\Protobuf\Internal\Message +{ + /** + * Some database resources may not have the [full resource + * name](https://google.aip.dev/122#full-resource-names) populated because + * these resource types are not yet supported by Cloud Asset Inventory (e.g. + * Cloud SQL databases). In these cases only the display name will be + * provided. + * The [full resource name](https://google.aip.dev/122#full-resource-names) of + * the database that the user connected to, if it is supported by Cloud Asset + * Inventory. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The human-readable name of the database that the user connected to. + * + * Generated from protobuf field string display_name = 2; + */ + protected $display_name = ''; + /** + * The username used to connect to the database. The username might not be an + * IAM principal and does not have a set format. + * + * Generated from protobuf field string user_name = 3; + */ + protected $user_name = ''; + /** + * The SQL statement that is associated with the database access. + * + * Generated from protobuf field string query = 4; + */ + protected $query = ''; + /** + * The target usernames, roles, or groups of an SQL privilege grant, which is + * not an IAM policy change. + * + * Generated from protobuf field repeated string grantees = 5; + */ + private $grantees; + /** + * The version of the database, for example, POSTGRES_14. + * See [the complete + * list](https://cloud.google.com/sql/docs/mysql/admin-api/rest/v1/SqlDatabaseVersion). + * + * Generated from protobuf field string version = 6; + */ + protected $version = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Some database resources may not have the [full resource + * name](https://google.aip.dev/122#full-resource-names) populated because + * these resource types are not yet supported by Cloud Asset Inventory (e.g. + * Cloud SQL databases). In these cases only the display name will be + * provided. + * The [full resource name](https://google.aip.dev/122#full-resource-names) of + * the database that the user connected to, if it is supported by Cloud Asset + * Inventory. + * @type string $display_name + * The human-readable name of the database that the user connected to. + * @type string $user_name + * The username used to connect to the database. The username might not be an + * IAM principal and does not have a set format. + * @type string $query + * The SQL statement that is associated with the database access. + * @type array|\Google\Protobuf\Internal\RepeatedField $grantees + * The target usernames, roles, or groups of an SQL privilege grant, which is + * not an IAM policy change. + * @type string $version + * The version of the database, for example, POSTGRES_14. + * See [the complete + * list](https://cloud.google.com/sql/docs/mysql/admin-api/rest/v1/SqlDatabaseVersion). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Database::initOnce(); + parent::__construct($data); + } + + /** + * Some database resources may not have the [full resource + * name](https://google.aip.dev/122#full-resource-names) populated because + * these resource types are not yet supported by Cloud Asset Inventory (e.g. + * Cloud SQL databases). In these cases only the display name will be + * provided. + * The [full resource name](https://google.aip.dev/122#full-resource-names) of + * the database that the user connected to, if it is supported by Cloud Asset + * Inventory. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Some database resources may not have the [full resource + * name](https://google.aip.dev/122#full-resource-names) populated because + * these resource types are not yet supported by Cloud Asset Inventory (e.g. + * Cloud SQL databases). In these cases only the display name will be + * provided. + * The [full resource name](https://google.aip.dev/122#full-resource-names) of + * the database that the user connected to, if it is supported by Cloud Asset + * Inventory. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The human-readable name of the database that the user connected to. + * + * Generated from protobuf field string display_name = 2; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * The human-readable name of the database that the user connected to. + * + * Generated from protobuf field string display_name = 2; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * The username used to connect to the database. The username might not be an + * IAM principal and does not have a set format. + * + * Generated from protobuf field string user_name = 3; + * @return string + */ + public function getUserName() + { + return $this->user_name; + } + + /** + * The username used to connect to the database. The username might not be an + * IAM principal and does not have a set format. + * + * Generated from protobuf field string user_name = 3; + * @param string $var + * @return $this + */ + public function setUserName($var) + { + GPBUtil::checkString($var, True); + $this->user_name = $var; + + return $this; + } + + /** + * The SQL statement that is associated with the database access. + * + * Generated from protobuf field string query = 4; + * @return string + */ + public function getQuery() + { + return $this->query; + } + + /** + * The SQL statement that is associated with the database access. + * + * Generated from protobuf field string query = 4; + * @param string $var + * @return $this + */ + public function setQuery($var) + { + GPBUtil::checkString($var, True); + $this->query = $var; + + return $this; + } + + /** + * The target usernames, roles, or groups of an SQL privilege grant, which is + * not an IAM policy change. + * + * Generated from protobuf field repeated string grantees = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getGrantees() + { + return $this->grantees; + } + + /** + * The target usernames, roles, or groups of an SQL privilege grant, which is + * not an IAM policy change. + * + * Generated from protobuf field repeated string grantees = 5; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setGrantees($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->grantees = $arr; + + return $this; + } + + /** + * The version of the database, for example, POSTGRES_14. + * See [the complete + * list](https://cloud.google.com/sql/docs/mysql/admin-api/rest/v1/SqlDatabaseVersion). + * + * Generated from protobuf field string version = 6; + * @return string + */ + public function getVersion() + { + return $this->version; + } + + /** + * The version of the database, for example, POSTGRES_14. + * See [the complete + * list](https://cloud.google.com/sql/docs/mysql/admin-api/rest/v1/SqlDatabaseVersion). + * + * Generated from protobuf field string version = 6; + * @param string $var + * @return $this + */ + public function setVersion($var) + { + GPBUtil::checkString($var, True); + $this->version = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteBigQueryExportRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteBigQueryExportRequest.php new file mode 100644 index 000000000000..e36cbc8fff97 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteBigQueryExportRequest.php @@ -0,0 +1,107 @@ +google.cloud.securitycenter.v2.DeleteBigQueryExportRequest + */ +class DeleteBigQueryExportRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the BigQuery export to delete. The following list + * shows some examples of the format: + * + + * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` + * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` + * + `projects/{project}/locations/{location}/bigQueryExports/{export_id}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. The name of the BigQuery export to delete. The following list + * shows some examples of the format: + * + * + + * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` + * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` + * + `projects/{project}/locations/{location}/bigQueryExports/{export_id}` + * Please see {@see SecurityCenterClient::bigQueryExportName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V2\DeleteBigQueryExportRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The name of the BigQuery export to delete. The following list + * shows some examples of the format: + * + + * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` + * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` + * + `projects/{project}/locations/{location}/bigQueryExports/{export_id}` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the BigQuery export to delete. The following list + * shows some examples of the format: + * + + * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` + * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` + * + `projects/{project}/locations/{location}/bigQueryExports/{export_id}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The name of the BigQuery export to delete. The following list + * shows some examples of the format: + * + + * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` + * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` + * + `projects/{project}/locations/{location}/bigQueryExports/{export_id}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteMuteConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteMuteConfigRequest.php new file mode 100644 index 000000000000..3eadf8908955 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteMuteConfigRequest.php @@ -0,0 +1,123 @@ +google.cloud.securitycenter.v2.DeleteMuteConfigRequest + */ +class DeleteMuteConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the mute config to delete. The following list shows some + * examples of the format: + * + `organizations/{organization}/muteConfigs/{config_id}` + * + + * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` + * + `folders/{folder}/muteConfigs/{config_id}` + * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` + * + `projects/{project}/muteConfigs/{config_id}` + * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Name of the mute config to delete. The following list shows some + * examples of the format: + * + * + `organizations/{organization}/muteConfigs/{config_id}` + * + + * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` + * + `folders/{folder}/muteConfigs/{config_id}` + * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` + * + `projects/{project}/muteConfigs/{config_id}` + * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` + * Please see {@see SecurityCenterClient::muteConfigName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V2\DeleteMuteConfigRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the mute config to delete. The following list shows some + * examples of the format: + * + `organizations/{organization}/muteConfigs/{config_id}` + * + + * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` + * + `folders/{folder}/muteConfigs/{config_id}` + * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` + * + `projects/{project}/muteConfigs/{config_id}` + * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the mute config to delete. The following list shows some + * examples of the format: + * + `organizations/{organization}/muteConfigs/{config_id}` + * + + * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` + * + `folders/{folder}/muteConfigs/{config_id}` + * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` + * + `projects/{project}/muteConfigs/{config_id}` + * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the mute config to delete. The following list shows some + * examples of the format: + * + `organizations/{organization}/muteConfigs/{config_id}` + * + + * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` + * + `folders/{folder}/muteConfigs/{config_id}` + * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` + * + `projects/{project}/muteConfigs/{config_id}` + * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteNotificationConfigRequest.php new file mode 100644 index 000000000000..5cf5f3371b41 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteNotificationConfigRequest.php @@ -0,0 +1,117 @@ +google.cloud.securitycenter.v2.DeleteNotificationConfigRequest + */ +class DeleteNotificationConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the notification config to delete. The following list + * shows some examples of the format: + * + + * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` + * + + * `folders/[folder_id]/locations/[location_id]notificationConfigs/[config_id]` + * + + * `projects/[project_id]/locations/[location_id]notificationConfigs/[config_id]` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Name of the notification config to delete. The following list + * shows some examples of the format: + * + * + + * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` + * + + * `folders/[folder_id]/locations/[location_id]notificationConfigs/[config_id]` + * + + * `projects/[project_id]/locations/[location_id]notificationConfigs/[config_id]` + * Please see {@see SecurityCenterClient::notificationConfigName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V2\DeleteNotificationConfigRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the notification config to delete. The following list + * shows some examples of the format: + * + + * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` + * + + * `folders/[folder_id]/locations/[location_id]notificationConfigs/[config_id]` + * + + * `projects/[project_id]/locations/[location_id]notificationConfigs/[config_id]` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the notification config to delete. The following list + * shows some examples of the format: + * + + * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` + * + + * `folders/[folder_id]/locations/[location_id]notificationConfigs/[config_id]` + * + + * `projects/[project_id]/locations/[location_id]notificationConfigs/[config_id]` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the notification config to delete. The following list + * shows some examples of the format: + * + + * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` + * + + * `folders/[folder_id]/locations/[location_id]notificationConfigs/[config_id]` + * + + * `projects/[project_id]/locations/[location_id]notificationConfigs/[config_id]` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteResourceValueConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteResourceValueConfigRequest.php new file mode 100644 index 000000000000..37b404916549 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteResourceValueConfigRequest.php @@ -0,0 +1,81 @@ +google.cloud.securitycenter.v2.DeleteResourceValueConfigRequest + */ +class DeleteResourceValueConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the ResourceValueConfig to delete + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Name of the ResourceValueConfig to delete + * Please see {@see SecurityCenterClient::resourceValueConfigName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V2\DeleteResourceValueConfigRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the ResourceValueConfig to delete + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the ResourceValueConfig to delete + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the ResourceValueConfig to delete + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/EnvironmentVariable.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/EnvironmentVariable.php new file mode 100644 index 000000000000..2ea98dfa0ed5 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/EnvironmentVariable.php @@ -0,0 +1,102 @@ +google.cloud.securitycenter.v2.EnvironmentVariable + */ +class EnvironmentVariable extends \Google\Protobuf\Internal\Message +{ + /** + * Environment variable name as a JSON encoded string. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Environment variable value as a JSON encoded string. + * + * Generated from protobuf field string val = 2; + */ + protected $val = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Environment variable name as a JSON encoded string. + * @type string $val + * Environment variable value as a JSON encoded string. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Process::initOnce(); + parent::__construct($data); + } + + /** + * Environment variable name as a JSON encoded string. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Environment variable name as a JSON encoded string. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Environment variable value as a JSON encoded string. + * + * Generated from protobuf field string val = 2; + * @return string + */ + public function getVal() + { + return $this->val; + } + + /** + * Environment variable value as a JSON encoded string. + * + * Generated from protobuf field string val = 2; + * @param string $var + * @return $this + */ + public function setVal($var) + { + GPBUtil::checkString($var, True); + $this->val = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExfilResource.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExfilResource.php new file mode 100644 index 000000000000..446c1ad60b44 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExfilResource.php @@ -0,0 +1,121 @@ +google.cloud.securitycenter.v2.ExfilResource + */ +class ExfilResource extends \Google\Protobuf\Internal\Message +{ + /** + * The resource's [full resource + * name](https://cloud.google.com/apis/design/resource_names#full_resource_name). + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Subcomponents of the asset that was exfiltrated, like URIs used during + * exfiltration, table names, databases, and filenames. For example, multiple + * tables might have been exfiltrated from the same Cloud SQL instance, or + * multiple files might have been exfiltrated from the same Cloud Storage + * bucket. + * + * Generated from protobuf field repeated string components = 2; + */ + private $components; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The resource's [full resource + * name](https://cloud.google.com/apis/design/resource_names#full_resource_name). + * @type array|\Google\Protobuf\Internal\RepeatedField $components + * Subcomponents of the asset that was exfiltrated, like URIs used during + * exfiltration, table names, databases, and filenames. For example, multiple + * tables might have been exfiltrated from the same Cloud SQL instance, or + * multiple files might have been exfiltrated from the same Cloud Storage + * bucket. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Exfiltration::initOnce(); + parent::__construct($data); + } + + /** + * The resource's [full resource + * name](https://cloud.google.com/apis/design/resource_names#full_resource_name). + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The resource's [full resource + * name](https://cloud.google.com/apis/design/resource_names#full_resource_name). + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Subcomponents of the asset that was exfiltrated, like URIs used during + * exfiltration, table names, databases, and filenames. For example, multiple + * tables might have been exfiltrated from the same Cloud SQL instance, or + * multiple files might have been exfiltrated from the same Cloud Storage + * bucket. + * + * Generated from protobuf field repeated string components = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getComponents() + { + return $this->components; + } + + /** + * Subcomponents of the asset that was exfiltrated, like URIs used during + * exfiltration, table names, databases, and filenames. For example, multiple + * tables might have been exfiltrated from the same Cloud SQL instance, or + * multiple files might have been exfiltrated from the same Cloud Storage + * bucket. + * + * Generated from protobuf field repeated string components = 2; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setComponents($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->components = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Exfiltration.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Exfiltration.php new file mode 100644 index 000000000000..a0325fa01d65 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Exfiltration.php @@ -0,0 +1,150 @@ +google.cloud.securitycenter.v2.Exfiltration + */ +class Exfiltration extends \Google\Protobuf\Internal\Message +{ + /** + * If there are multiple sources, then the data is considered "joined" between + * them. For instance, BigQuery can join multiple tables, and each + * table would be considered a source. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ExfilResource sources = 1; + */ + private $sources; + /** + * If there are multiple targets, each target would get a complete copy of the + * "joined" source data. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ExfilResource targets = 2; + */ + private $targets; + /** + * Total exfiltrated bytes processed for the entire job. + * + * Generated from protobuf field int64 total_exfiltrated_bytes = 3; + */ + protected $total_exfiltrated_bytes = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V2\ExfilResource>|\Google\Protobuf\Internal\RepeatedField $sources + * If there are multiple sources, then the data is considered "joined" between + * them. For instance, BigQuery can join multiple tables, and each + * table would be considered a source. + * @type array<\Google\Cloud\SecurityCenter\V2\ExfilResource>|\Google\Protobuf\Internal\RepeatedField $targets + * If there are multiple targets, each target would get a complete copy of the + * "joined" source data. + * @type int|string $total_exfiltrated_bytes + * Total exfiltrated bytes processed for the entire job. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Exfiltration::initOnce(); + parent::__construct($data); + } + + /** + * If there are multiple sources, then the data is considered "joined" between + * them. For instance, BigQuery can join multiple tables, and each + * table would be considered a source. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ExfilResource sources = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSources() + { + return $this->sources; + } + + /** + * If there are multiple sources, then the data is considered "joined" between + * them. For instance, BigQuery can join multiple tables, and each + * table would be considered a source. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ExfilResource sources = 1; + * @param array<\Google\Cloud\SecurityCenter\V2\ExfilResource>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSources($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ExfilResource::class); + $this->sources = $arr; + + return $this; + } + + /** + * If there are multiple targets, each target would get a complete copy of the + * "joined" source data. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ExfilResource targets = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTargets() + { + return $this->targets; + } + + /** + * If there are multiple targets, each target would get a complete copy of the + * "joined" source data. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ExfilResource targets = 2; + * @param array<\Google\Cloud\SecurityCenter\V2\ExfilResource>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTargets($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ExfilResource::class); + $this->targets = $arr; + + return $this; + } + + /** + * Total exfiltrated bytes processed for the entire job. + * + * Generated from protobuf field int64 total_exfiltrated_bytes = 3; + * @return int|string + */ + public function getTotalExfiltratedBytes() + { + return $this->total_exfiltrated_bytes; + } + + /** + * Total exfiltrated bytes processed for the entire job. + * + * Generated from protobuf field int64 total_exfiltrated_bytes = 3; + * @param int|string $var + * @return $this + */ + public function setTotalExfiltratedBytes($var) + { + GPBUtil::checkInt64($var); + $this->total_exfiltrated_bytes = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExternalSystem.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExternalSystem.php new file mode 100644 index 000000000000..9c074ab1c339 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExternalSystem.php @@ -0,0 +1,513 @@ +google.cloud.securitycenter.v2.ExternalSystem + */ +class ExternalSystem extends \Google\Protobuf\Internal\Message +{ + /** + * Full resource name of the external system. The following list + * shows some examples: + * + `organizations/1234/sources/5678/findings/123456/externalSystems/jira` + * + + * `organizations/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` + * + `folders/1234/sources/5678/findings/123456/externalSystems/jira` + * + + * `folders/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` + * + `projects/1234/sources/5678/findings/123456/externalSystems/jira` + * + + * `projects/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * References primary/secondary etc assignees in the external system. + * + * Generated from protobuf field repeated string assignees = 2; + */ + private $assignees; + /** + * The identifier that's used to track the finding's corresponding case in the + * external system. + * + * Generated from protobuf field string external_uid = 3; + */ + protected $external_uid = ''; + /** + * The most recent status of the finding's corresponding case, as reported by + * the external system. + * + * Generated from protobuf field string status = 4; + */ + protected $status = ''; + /** + * The time when the case was last updated, as reported by the external + * system. + * + * Generated from protobuf field .google.protobuf.Timestamp external_system_update_time = 5; + */ + protected $external_system_update_time = null; + /** + * The link to the finding's corresponding case in the external system. + * + * Generated from protobuf field string case_uri = 6; + */ + protected $case_uri = ''; + /** + * The priority of the finding's corresponding case in the external system. + * + * Generated from protobuf field string case_priority = 7; + */ + protected $case_priority = ''; + /** + * The SLA of the finding's corresponding case in the external system. + * + * Generated from protobuf field .google.protobuf.Timestamp case_sla = 9; + */ + protected $case_sla = null; + /** + * The time when the case was created, as reported by the external system. + * + * Generated from protobuf field .google.protobuf.Timestamp case_create_time = 10; + */ + protected $case_create_time = null; + /** + * The time when the case was closed, as reported by the external system. + * + * Generated from protobuf field .google.protobuf.Timestamp case_close_time = 11; + */ + protected $case_close_time = null; + /** + * Information about the ticket, if any, that is being used to track the + * resolution of the issue that is identified by this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ExternalSystem.TicketInfo ticket_info = 8; + */ + protected $ticket_info = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Full resource name of the external system. The following list + * shows some examples: + * + `organizations/1234/sources/5678/findings/123456/externalSystems/jira` + * + + * `organizations/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` + * + `folders/1234/sources/5678/findings/123456/externalSystems/jira` + * + + * `folders/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` + * + `projects/1234/sources/5678/findings/123456/externalSystems/jira` + * + + * `projects/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` + * @type array|\Google\Protobuf\Internal\RepeatedField $assignees + * References primary/secondary etc assignees in the external system. + * @type string $external_uid + * The identifier that's used to track the finding's corresponding case in the + * external system. + * @type string $status + * The most recent status of the finding's corresponding case, as reported by + * the external system. + * @type \Google\Protobuf\Timestamp $external_system_update_time + * The time when the case was last updated, as reported by the external + * system. + * @type string $case_uri + * The link to the finding's corresponding case in the external system. + * @type string $case_priority + * The priority of the finding's corresponding case in the external system. + * @type \Google\Protobuf\Timestamp $case_sla + * The SLA of the finding's corresponding case in the external system. + * @type \Google\Protobuf\Timestamp $case_create_time + * The time when the case was created, as reported by the external system. + * @type \Google\Protobuf\Timestamp $case_close_time + * The time when the case was closed, as reported by the external system. + * @type \Google\Cloud\SecurityCenter\V2\ExternalSystem\TicketInfo $ticket_info + * Information about the ticket, if any, that is being used to track the + * resolution of the issue that is identified by this finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\ExternalSystem::initOnce(); + parent::__construct($data); + } + + /** + * Full resource name of the external system. The following list + * shows some examples: + * + `organizations/1234/sources/5678/findings/123456/externalSystems/jira` + * + + * `organizations/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` + * + `folders/1234/sources/5678/findings/123456/externalSystems/jira` + * + + * `folders/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` + * + `projects/1234/sources/5678/findings/123456/externalSystems/jira` + * + + * `projects/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Full resource name of the external system. The following list + * shows some examples: + * + `organizations/1234/sources/5678/findings/123456/externalSystems/jira` + * + + * `organizations/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` + * + `folders/1234/sources/5678/findings/123456/externalSystems/jira` + * + + * `folders/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` + * + `projects/1234/sources/5678/findings/123456/externalSystems/jira` + * + + * `projects/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * References primary/secondary etc assignees in the external system. + * + * Generated from protobuf field repeated string assignees = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAssignees() + { + return $this->assignees; + } + + /** + * References primary/secondary etc assignees in the external system. + * + * Generated from protobuf field repeated string assignees = 2; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAssignees($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->assignees = $arr; + + return $this; + } + + /** + * The identifier that's used to track the finding's corresponding case in the + * external system. + * + * Generated from protobuf field string external_uid = 3; + * @return string + */ + public function getExternalUid() + { + return $this->external_uid; + } + + /** + * The identifier that's used to track the finding's corresponding case in the + * external system. + * + * Generated from protobuf field string external_uid = 3; + * @param string $var + * @return $this + */ + public function setExternalUid($var) + { + GPBUtil::checkString($var, True); + $this->external_uid = $var; + + return $this; + } + + /** + * The most recent status of the finding's corresponding case, as reported by + * the external system. + * + * Generated from protobuf field string status = 4; + * @return string + */ + public function getStatus() + { + return $this->status; + } + + /** + * The most recent status of the finding's corresponding case, as reported by + * the external system. + * + * Generated from protobuf field string status = 4; + * @param string $var + * @return $this + */ + public function setStatus($var) + { + GPBUtil::checkString($var, True); + $this->status = $var; + + return $this; + } + + /** + * The time when the case was last updated, as reported by the external + * system. + * + * Generated from protobuf field .google.protobuf.Timestamp external_system_update_time = 5; + * @return \Google\Protobuf\Timestamp|null + */ + public function getExternalSystemUpdateTime() + { + return $this->external_system_update_time; + } + + public function hasExternalSystemUpdateTime() + { + return isset($this->external_system_update_time); + } + + public function clearExternalSystemUpdateTime() + { + unset($this->external_system_update_time); + } + + /** + * The time when the case was last updated, as reported by the external + * system. + * + * Generated from protobuf field .google.protobuf.Timestamp external_system_update_time = 5; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setExternalSystemUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->external_system_update_time = $var; + + return $this; + } + + /** + * The link to the finding's corresponding case in the external system. + * + * Generated from protobuf field string case_uri = 6; + * @return string + */ + public function getCaseUri() + { + return $this->case_uri; + } + + /** + * The link to the finding's corresponding case in the external system. + * + * Generated from protobuf field string case_uri = 6; + * @param string $var + * @return $this + */ + public function setCaseUri($var) + { + GPBUtil::checkString($var, True); + $this->case_uri = $var; + + return $this; + } + + /** + * The priority of the finding's corresponding case in the external system. + * + * Generated from protobuf field string case_priority = 7; + * @return string + */ + public function getCasePriority() + { + return $this->case_priority; + } + + /** + * The priority of the finding's corresponding case in the external system. + * + * Generated from protobuf field string case_priority = 7; + * @param string $var + * @return $this + */ + public function setCasePriority($var) + { + GPBUtil::checkString($var, True); + $this->case_priority = $var; + + return $this; + } + + /** + * The SLA of the finding's corresponding case in the external system. + * + * Generated from protobuf field .google.protobuf.Timestamp case_sla = 9; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCaseSla() + { + return $this->case_sla; + } + + public function hasCaseSla() + { + return isset($this->case_sla); + } + + public function clearCaseSla() + { + unset($this->case_sla); + } + + /** + * The SLA of the finding's corresponding case in the external system. + * + * Generated from protobuf field .google.protobuf.Timestamp case_sla = 9; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCaseSla($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->case_sla = $var; + + return $this; + } + + /** + * The time when the case was created, as reported by the external system. + * + * Generated from protobuf field .google.protobuf.Timestamp case_create_time = 10; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCaseCreateTime() + { + return $this->case_create_time; + } + + public function hasCaseCreateTime() + { + return isset($this->case_create_time); + } + + public function clearCaseCreateTime() + { + unset($this->case_create_time); + } + + /** + * The time when the case was created, as reported by the external system. + * + * Generated from protobuf field .google.protobuf.Timestamp case_create_time = 10; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCaseCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->case_create_time = $var; + + return $this; + } + + /** + * The time when the case was closed, as reported by the external system. + * + * Generated from protobuf field .google.protobuf.Timestamp case_close_time = 11; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCaseCloseTime() + { + return $this->case_close_time; + } + + public function hasCaseCloseTime() + { + return isset($this->case_close_time); + } + + public function clearCaseCloseTime() + { + unset($this->case_close_time); + } + + /** + * The time when the case was closed, as reported by the external system. + * + * Generated from protobuf field .google.protobuf.Timestamp case_close_time = 11; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCaseCloseTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->case_close_time = $var; + + return $this; + } + + /** + * Information about the ticket, if any, that is being used to track the + * resolution of the issue that is identified by this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ExternalSystem.TicketInfo ticket_info = 8; + * @return \Google\Cloud\SecurityCenter\V2\ExternalSystem\TicketInfo|null + */ + public function getTicketInfo() + { + return $this->ticket_info; + } + + public function hasTicketInfo() + { + return isset($this->ticket_info); + } + + public function clearTicketInfo() + { + unset($this->ticket_info); + } + + /** + * Information about the ticket, if any, that is being used to track the + * resolution of the issue that is identified by this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ExternalSystem.TicketInfo ticket_info = 8; + * @param \Google\Cloud\SecurityCenter\V2\ExternalSystem\TicketInfo $var + * @return $this + */ + public function setTicketInfo($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ExternalSystem\TicketInfo::class); + $this->ticket_info = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExternalSystem/TicketInfo.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExternalSystem/TicketInfo.php new file mode 100644 index 000000000000..b6c42581fe6c --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExternalSystem/TicketInfo.php @@ -0,0 +1,255 @@ +google.cloud.securitycenter.v2.ExternalSystem.TicketInfo + */ +class TicketInfo extends \Google\Protobuf\Internal\Message +{ + /** + * The identifier of the ticket in the ticket system. + * + * Generated from protobuf field string id = 1; + */ + protected $id = ''; + /** + * The assignee of the ticket in the ticket system. + * + * Generated from protobuf field string assignee = 2; + */ + protected $assignee = ''; + /** + * The description of the ticket in the ticket system. + * + * Generated from protobuf field string description = 3; + */ + protected $description = ''; + /** + * The link to the ticket in the ticket system. + * + * Generated from protobuf field string uri = 4; + */ + protected $uri = ''; + /** + * The latest status of the ticket, as reported by the ticket system. + * + * Generated from protobuf field string status = 5; + */ + protected $status = ''; + /** + * The time when the ticket was last updated, as reported by the ticket + * system. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 6; + */ + protected $update_time = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $id + * The identifier of the ticket in the ticket system. + * @type string $assignee + * The assignee of the ticket in the ticket system. + * @type string $description + * The description of the ticket in the ticket system. + * @type string $uri + * The link to the ticket in the ticket system. + * @type string $status + * The latest status of the ticket, as reported by the ticket system. + * @type \Google\Protobuf\Timestamp $update_time + * The time when the ticket was last updated, as reported by the ticket + * system. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\ExternalSystem::initOnce(); + parent::__construct($data); + } + + /** + * The identifier of the ticket in the ticket system. + * + * Generated from protobuf field string id = 1; + * @return string + */ + public function getId() + { + return $this->id; + } + + /** + * The identifier of the ticket in the ticket system. + * + * Generated from protobuf field string id = 1; + * @param string $var + * @return $this + */ + public function setId($var) + { + GPBUtil::checkString($var, True); + $this->id = $var; + + return $this; + } + + /** + * The assignee of the ticket in the ticket system. + * + * Generated from protobuf field string assignee = 2; + * @return string + */ + public function getAssignee() + { + return $this->assignee; + } + + /** + * The assignee of the ticket in the ticket system. + * + * Generated from protobuf field string assignee = 2; + * @param string $var + * @return $this + */ + public function setAssignee($var) + { + GPBUtil::checkString($var, True); + $this->assignee = $var; + + return $this; + } + + /** + * The description of the ticket in the ticket system. + * + * Generated from protobuf field string description = 3; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * The description of the ticket in the ticket system. + * + * Generated from protobuf field string description = 3; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * The link to the ticket in the ticket system. + * + * Generated from protobuf field string uri = 4; + * @return string + */ + public function getUri() + { + return $this->uri; + } + + /** + * The link to the ticket in the ticket system. + * + * Generated from protobuf field string uri = 4; + * @param string $var + * @return $this + */ + public function setUri($var) + { + GPBUtil::checkString($var, True); + $this->uri = $var; + + return $this; + } + + /** + * The latest status of the ticket, as reported by the ticket system. + * + * Generated from protobuf field string status = 5; + * @return string + */ + public function getStatus() + { + return $this->status; + } + + /** + * The latest status of the ticket, as reported by the ticket system. + * + * Generated from protobuf field string status = 5; + * @param string $var + * @return $this + */ + public function setStatus($var) + { + GPBUtil::checkString($var, True); + $this->status = $var; + + return $this; + } + + /** + * The time when the ticket was last updated, as reported by the ticket + * system. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 6; + * @return \Google\Protobuf\Timestamp|null + */ + public function getUpdateTime() + { + return $this->update_time; + } + + public function hasUpdateTime() + { + return isset($this->update_time); + } + + public function clearUpdateTime() + { + unset($this->update_time); + } + + /** + * The time when the ticket was last updated, as reported by the ticket + * system. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 6; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->update_time = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(TicketInfo::class, \Google\Cloud\SecurityCenter\V2\ExternalSystem_TicketInfo::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/File.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/File.php new file mode 100644 index 000000000000..c69daaf28e6f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/File.php @@ -0,0 +1,298 @@ +google.cloud.securitycenter.v2.File + */ +class File extends \Google\Protobuf\Internal\Message +{ + /** + * Absolute path of the file as a JSON encoded string. + * + * Generated from protobuf field string path = 1; + */ + protected $path = ''; + /** + * Size of the file in bytes. + * + * Generated from protobuf field int64 size = 2; + */ + protected $size = 0; + /** + * SHA256 hash of the first hashed_size bytes of the file encoded as a + * hex string. If hashed_size == size, sha256 represents the SHA256 hash + * of the entire file. + * + * Generated from protobuf field string sha256 = 3; + */ + protected $sha256 = ''; + /** + * The length in bytes of the file prefix that was hashed. If + * hashed_size == size, any hashes reported represent the entire + * file. + * + * Generated from protobuf field int64 hashed_size = 4; + */ + protected $hashed_size = 0; + /** + * True when the hash covers only a prefix of the file. + * + * Generated from protobuf field bool partially_hashed = 5; + */ + protected $partially_hashed = false; + /** + * Prefix of the file contents as a JSON-encoded string. + * + * Generated from protobuf field string contents = 6; + */ + protected $contents = ''; + /** + * Path of the file in terms of underlying disk/partition identifiers. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.File.DiskPath disk_path = 7; + */ + protected $disk_path = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $path + * Absolute path of the file as a JSON encoded string. + * @type int|string $size + * Size of the file in bytes. + * @type string $sha256 + * SHA256 hash of the first hashed_size bytes of the file encoded as a + * hex string. If hashed_size == size, sha256 represents the SHA256 hash + * of the entire file. + * @type int|string $hashed_size + * The length in bytes of the file prefix that was hashed. If + * hashed_size == size, any hashes reported represent the entire + * file. + * @type bool $partially_hashed + * True when the hash covers only a prefix of the file. + * @type string $contents + * Prefix of the file contents as a JSON-encoded string. + * @type \Google\Cloud\SecurityCenter\V2\File\DiskPath $disk_path + * Path of the file in terms of underlying disk/partition identifiers. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\File::initOnce(); + parent::__construct($data); + } + + /** + * Absolute path of the file as a JSON encoded string. + * + * Generated from protobuf field string path = 1; + * @return string + */ + public function getPath() + { + return $this->path; + } + + /** + * Absolute path of the file as a JSON encoded string. + * + * Generated from protobuf field string path = 1; + * @param string $var + * @return $this + */ + public function setPath($var) + { + GPBUtil::checkString($var, True); + $this->path = $var; + + return $this; + } + + /** + * Size of the file in bytes. + * + * Generated from protobuf field int64 size = 2; + * @return int|string + */ + public function getSize() + { + return $this->size; + } + + /** + * Size of the file in bytes. + * + * Generated from protobuf field int64 size = 2; + * @param int|string $var + * @return $this + */ + public function setSize($var) + { + GPBUtil::checkInt64($var); + $this->size = $var; + + return $this; + } + + /** + * SHA256 hash of the first hashed_size bytes of the file encoded as a + * hex string. If hashed_size == size, sha256 represents the SHA256 hash + * of the entire file. + * + * Generated from protobuf field string sha256 = 3; + * @return string + */ + public function getSha256() + { + return $this->sha256; + } + + /** + * SHA256 hash of the first hashed_size bytes of the file encoded as a + * hex string. If hashed_size == size, sha256 represents the SHA256 hash + * of the entire file. + * + * Generated from protobuf field string sha256 = 3; + * @param string $var + * @return $this + */ + public function setSha256($var) + { + GPBUtil::checkString($var, True); + $this->sha256 = $var; + + return $this; + } + + /** + * The length in bytes of the file prefix that was hashed. If + * hashed_size == size, any hashes reported represent the entire + * file. + * + * Generated from protobuf field int64 hashed_size = 4; + * @return int|string + */ + public function getHashedSize() + { + return $this->hashed_size; + } + + /** + * The length in bytes of the file prefix that was hashed. If + * hashed_size == size, any hashes reported represent the entire + * file. + * + * Generated from protobuf field int64 hashed_size = 4; + * @param int|string $var + * @return $this + */ + public function setHashedSize($var) + { + GPBUtil::checkInt64($var); + $this->hashed_size = $var; + + return $this; + } + + /** + * True when the hash covers only a prefix of the file. + * + * Generated from protobuf field bool partially_hashed = 5; + * @return bool + */ + public function getPartiallyHashed() + { + return $this->partially_hashed; + } + + /** + * True when the hash covers only a prefix of the file. + * + * Generated from protobuf field bool partially_hashed = 5; + * @param bool $var + * @return $this + */ + public function setPartiallyHashed($var) + { + GPBUtil::checkBool($var); + $this->partially_hashed = $var; + + return $this; + } + + /** + * Prefix of the file contents as a JSON-encoded string. + * + * Generated from protobuf field string contents = 6; + * @return string + */ + public function getContents() + { + return $this->contents; + } + + /** + * Prefix of the file contents as a JSON-encoded string. + * + * Generated from protobuf field string contents = 6; + * @param string $var + * @return $this + */ + public function setContents($var) + { + GPBUtil::checkString($var, True); + $this->contents = $var; + + return $this; + } + + /** + * Path of the file in terms of underlying disk/partition identifiers. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.File.DiskPath disk_path = 7; + * @return \Google\Cloud\SecurityCenter\V2\File\DiskPath|null + */ + public function getDiskPath() + { + return $this->disk_path; + } + + public function hasDiskPath() + { + return isset($this->disk_path); + } + + public function clearDiskPath() + { + unset($this->disk_path); + } + + /** + * Path of the file in terms of underlying disk/partition identifiers. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.File.DiskPath disk_path = 7; + * @param \Google\Cloud\SecurityCenter\V2\File\DiskPath $var + * @return $this + */ + public function setDiskPath($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\File\DiskPath::class); + $this->disk_path = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/File/DiskPath.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/File/DiskPath.php new file mode 100644 index 000000000000..94f841f5981c --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/File/DiskPath.php @@ -0,0 +1,112 @@ +google.cloud.securitycenter.v2.File.DiskPath + */ +class DiskPath extends \Google\Protobuf\Internal\Message +{ + /** + * UUID of the partition (format + * https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid) + * + * Generated from protobuf field string partition_uuid = 1; + */ + protected $partition_uuid = ''; + /** + * Relative path of the file in the partition as a JSON encoded string. + * Example: /home/user1/executable_file.sh + * + * Generated from protobuf field string relative_path = 2; + */ + protected $relative_path = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $partition_uuid + * UUID of the partition (format + * https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid) + * @type string $relative_path + * Relative path of the file in the partition as a JSON encoded string. + * Example: /home/user1/executable_file.sh + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\File::initOnce(); + parent::__construct($data); + } + + /** + * UUID of the partition (format + * https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid) + * + * Generated from protobuf field string partition_uuid = 1; + * @return string + */ + public function getPartitionUuid() + { + return $this->partition_uuid; + } + + /** + * UUID of the partition (format + * https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid) + * + * Generated from protobuf field string partition_uuid = 1; + * @param string $var + * @return $this + */ + public function setPartitionUuid($var) + { + GPBUtil::checkString($var, True); + $this->partition_uuid = $var; + + return $this; + } + + /** + * Relative path of the file in the partition as a JSON encoded string. + * Example: /home/user1/executable_file.sh + * + * Generated from protobuf field string relative_path = 2; + * @return string + */ + public function getRelativePath() + { + return $this->relative_path; + } + + /** + * Relative path of the file in the partition as a JSON encoded string. + * Example: /home/user1/executable_file.sh + * + * Generated from protobuf field string relative_path = 2; + * @param string $var + * @return $this + */ + public function setRelativePath($var) + { + GPBUtil::checkString($var, True); + $this->relative_path = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(DiskPath::class, \Google\Cloud\SecurityCenter\V2\File_DiskPath::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding.php new file mode 100644 index 000000000000..a7ea154b1943 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding.php @@ -0,0 +1,2302 @@ +google.cloud.securitycenter.v2.Finding + */ +class Finding extends \Google\Protobuf\Internal\Message +{ + /** + * The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. The following list shows some examples: + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` + * + + * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Output only. The canonical name of the finding. The following list shows + * some examples: + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` + * + + * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * The prefix is the closest CRM ancestor of the resource associated with the + * finding. + * + * Generated from protobuf field string canonical_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $canonical_name = ''; + /** + * The relative resource name of the source and location the finding belongs + * to. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * This field is immutable after creation time. The following list shows some + * examples: + * + `organizations/{organization_id}/sources/{source_id}` + * + `folders/{folders_id}/sources/{source_id}` + * + `projects/{projects_id}/sources/{source_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}` + * + `folders/{folders_id}/sources/{source_id}/locations/{location_id}` + * + `projects/{projects_id}/sources/{source_id}/locations/{location_id}` + * + * Generated from protobuf field string parent = 3; + */ + protected $parent = ''; + /** + * Immutable. For findings on Google Cloud resources, the full resource + * name of the Google Cloud resource this finding is for. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * When the finding is for a non-Google Cloud resource, the resourceName can + * be a customer or partner defined string. + * + * Generated from protobuf field string resource_name = 4 [(.google.api.field_behavior) = IMMUTABLE]; + */ + protected $resource_name = ''; + /** + * Output only. The state of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Immutable. The additional taxonomy group within findings from a given + * source. Example: "XSS_FLASH_INJECTION" + * + * Generated from protobuf field string category = 7 [(.google.api.field_behavior) = IMMUTABLE]; + */ + protected $category = ''; + /** + * The URI that, if available, points to a web page outside of Security + * Command Center where additional information about the finding can be found. + * This field is guaranteed to be either empty or a well formed URL. + * + * Generated from protobuf field string external_uri = 8; + */ + protected $external_uri = ''; + /** + * Source specific properties. These properties are managed by the source + * that writes the finding. The key names in the source_properties map must be + * between 1 and 255 characters, and must start with a letter and contain + * alphanumeric characters or underscores only. + * + * Generated from protobuf field map source_properties = 9; + */ + private $source_properties; + /** + * Output only. User specified security marks. These marks are entirely + * managed by the user and come from the SecurityMarks resource that belongs + * to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityMarks security_marks = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $security_marks = null; + /** + * The time the finding was first detected. If an existing finding is updated, + * then this is the time the update occurred. + * For example, if the finding represents an open firewall, this property + * captures the time the detector believes the firewall became open. The + * accuracy is determined by the detector. If the finding is later resolved, + * then this time reflects when the finding was resolved. This must not + * be set to a value greater than the current timestamp. + * + * Generated from protobuf field .google.protobuf.Timestamp event_time = 11; + */ + protected $event_time = null; + /** + * Output only. The time at which the finding was created in Security Command + * Center. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * The severity of the finding. This field is managed by the source that + * writes the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.Severity severity = 14; + */ + protected $severity = 0; + /** + * Indicates the mute state of a finding (either muted, unmuted + * or undefined). Unlike other attributes of a finding, a finding provider + * shouldn't set the value of mute. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.Mute mute = 15; + */ + protected $mute = 0; + /** + * The class of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.FindingClass finding_class = 16; + */ + protected $finding_class = 0; + /** + * Represents what's commonly known as an *indicator of compromise* (IoC) in + * computer forensics. This is an artifact observed on a network or in an + * operating system that, with high confidence, indicates a computer + * intrusion. For more information, see [Indicator of + * compromise](https://en.wikipedia.org/wiki/Indicator_of_compromise). + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator indicator = 17; + */ + protected $indicator = null; + /** + * Represents vulnerability-specific fields like CVE and CVSS scores. + * CVE stands for Common Vulnerabilities and Exposures + * (https://cve.mitre.org/about/) + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Vulnerability vulnerability = 18; + */ + protected $vulnerability = null; + /** + * Output only. The most recent time this finding was muted or unmuted. + * + * Generated from protobuf field .google.protobuf.Timestamp mute_update_time = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $mute_update_time = null; + /** + * Output only. Third party SIEM/SOAR fields within SCC, contains external + * system information and external system finding fields. + * + * Generated from protobuf field map external_systems = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $external_systems; + /** + * MITRE ATT&CK tactics and techniques related to this finding. + * See: https://attack.mitre.org + * + * Generated from protobuf field .google.cloud.securitycenter.v2.MitreAttack mitre_attack = 21; + */ + protected $mitre_attack = null; + /** + * Access details associated with the finding, such as more information on the + * caller, which method was accessed, and from where. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Access access = 22; + */ + protected $access = null; + /** + * Contains information about the IP connection associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Connection connections = 23; + */ + private $connections; + /** + * Records additional information about the mute operation, for example, the + * [mute + * configuration](https://cloud.google.com/security-command-center/docs/how-to-mute-findings) + * that muted the finding and the user who muted the finding. + * + * Generated from protobuf field string mute_initiator = 24; + */ + protected $mute_initiator = ''; + /** + * Represents operating system processes associated with the Finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Process processes = 25; + */ + private $processes; + /** + * Output only. Map containing the points of contact for the given finding. + * The key represents the type of contact, while the value contains a list of + * all the contacts that pertain. Please refer to: + * https://cloud.google.com/resource-manager/docs/managing-notification-contacts#notification-categories + * { + * "security": { + * "contacts": [ + * { + * "email": "person1@company.com" + * }, + * { + * "email": "person2@company.com" + * } + * ] + * } + * } + * + * Generated from protobuf field map contacts = 26 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $contacts; + /** + * Contains compliance information for security standards associated to the + * finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Compliance compliances = 27; + */ + private $compliances; + /** + * Output only. The human readable display name of the finding source such as + * "Event Threat Detection" or "Security Health Analytics". + * + * Generated from protobuf field string parent_display_name = 29 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $parent_display_name = ''; + /** + * Contains more details about the finding. + * + * Generated from protobuf field string description = 30; + */ + protected $description = ''; + /** + * Represents exfiltrations associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Exfiltration exfiltration = 31; + */ + protected $exfiltration = null; + /** + * Represents IAM bindings associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.IamBinding iam_bindings = 32; + */ + private $iam_bindings; + /** + * Steps to address the finding. + * + * Generated from protobuf field string next_steps = 33; + */ + protected $next_steps = ''; + /** + * Unique identifier of the module which generated the finding. + * Example: + * folders/598186756061/securityHealthAnalyticsSettings/customModules/56799441161885 + * + * Generated from protobuf field string module_name = 34; + */ + protected $module_name = ''; + /** + * Containers associated with the finding. This field provides information for + * both Kubernetes and non-Kubernetes containers. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Container containers = 35; + */ + private $containers; + /** + * Kubernetes resources associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes kubernetes = 36; + */ + protected $kubernetes = null; + /** + * Database associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Database database = 37; + */ + protected $database = null; + /** + * The results of an attack path simulation relevant to this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AttackExposure attack_exposure = 38; + */ + protected $attack_exposure = null; + /** + * File associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.File files = 39; + */ + private $files; + /** + * Cloud Data Loss Prevention (Cloud DLP) inspection results that are + * associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudDlpInspection cloud_dlp_inspection = 40; + */ + protected $cloud_dlp_inspection = null; + /** + * Cloud DLP data profile that is associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudDlpDataProfile cloud_dlp_data_profile = 41; + */ + protected $cloud_dlp_data_profile = null; + /** + * Signature of the kernel rootkit. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.KernelRootkit kernel_rootkit = 42; + */ + protected $kernel_rootkit = null; + /** + * Contains information about the org policies associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.OrgPolicy org_policies = 43; + */ + private $org_policies; + /** + * Represents an application associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Application application = 45; + */ + protected $application = null; + /** + * Fields related to Backup and DR findings. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.BackupDisasterRecovery backup_disaster_recovery = 47; + */ + protected $backup_disaster_recovery = null; + /** + * The security posture associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityPosture security_posture = 48; + */ + protected $security_posture = null; + /** + * Log entries that are relevant to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.LogEntry log_entries = 49; + */ + private $log_entries; + /** + * The load balancers associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.LoadBalancer load_balancers = 50; + */ + private $load_balancers; + /** + * Fields related to Cloud Armor findings. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudArmor cloud_armor = 51; + */ + protected $cloud_armor = null; + /** + * Notebook associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Notebook notebook = 55; + */ + protected $notebook = null; + /** + * Contains details about a group of security issues that, when the issues + * occur together, represent a greater risk than when the issues occur + * independently. A group of such issues is referred to as a toxic + * combination. + * This field cannot be updated. Its value is ignored in all update requests. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ToxicCombination toxic_combination = 56; + */ + protected $toxic_combination = null; + /** + * Contains details about groups of which this finding is a member. A group is + * a collection of findings that are related in some way. + * This field cannot be updated. Its value is ignored in all update requests. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.GroupMembership group_memberships = 57; + */ + private $group_memberships; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. The following list shows some examples: + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` + * + + * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * @type string $canonical_name + * Output only. The canonical name of the finding. The following list shows + * some examples: + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` + * + + * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * The prefix is the closest CRM ancestor of the resource associated with the + * finding. + * @type string $parent + * The relative resource name of the source and location the finding belongs + * to. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * This field is immutable after creation time. The following list shows some + * examples: + * + `organizations/{organization_id}/sources/{source_id}` + * + `folders/{folders_id}/sources/{source_id}` + * + `projects/{projects_id}/sources/{source_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}` + * + `folders/{folders_id}/sources/{source_id}/locations/{location_id}` + * + `projects/{projects_id}/sources/{source_id}/locations/{location_id}` + * @type string $resource_name + * Immutable. For findings on Google Cloud resources, the full resource + * name of the Google Cloud resource this finding is for. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * When the finding is for a non-Google Cloud resource, the resourceName can + * be a customer or partner defined string. + * @type int $state + * Output only. The state of the finding. + * @type string $category + * Immutable. The additional taxonomy group within findings from a given + * source. Example: "XSS_FLASH_INJECTION" + * @type string $external_uri + * The URI that, if available, points to a web page outside of Security + * Command Center where additional information about the finding can be found. + * This field is guaranteed to be either empty or a well formed URL. + * @type array|\Google\Protobuf\Internal\MapField $source_properties + * Source specific properties. These properties are managed by the source + * that writes the finding. The key names in the source_properties map must be + * between 1 and 255 characters, and must start with a letter and contain + * alphanumeric characters or underscores only. + * @type \Google\Cloud\SecurityCenter\V2\SecurityMarks $security_marks + * Output only. User specified security marks. These marks are entirely + * managed by the user and come from the SecurityMarks resource that belongs + * to the finding. + * @type \Google\Protobuf\Timestamp $event_time + * The time the finding was first detected. If an existing finding is updated, + * then this is the time the update occurred. + * For example, if the finding represents an open firewall, this property + * captures the time the detector believes the firewall became open. The + * accuracy is determined by the detector. If the finding is later resolved, + * then this time reflects when the finding was resolved. This must not + * be set to a value greater than the current timestamp. + * @type \Google\Protobuf\Timestamp $create_time + * Output only. The time at which the finding was created in Security Command + * Center. + * @type int $severity + * The severity of the finding. This field is managed by the source that + * writes the finding. + * @type int $mute + * Indicates the mute state of a finding (either muted, unmuted + * or undefined). Unlike other attributes of a finding, a finding provider + * shouldn't set the value of mute. + * @type int $finding_class + * The class of the finding. + * @type \Google\Cloud\SecurityCenter\V2\Indicator $indicator + * Represents what's commonly known as an *indicator of compromise* (IoC) in + * computer forensics. This is an artifact observed on a network or in an + * operating system that, with high confidence, indicates a computer + * intrusion. For more information, see [Indicator of + * compromise](https://en.wikipedia.org/wiki/Indicator_of_compromise). + * @type \Google\Cloud\SecurityCenter\V2\Vulnerability $vulnerability + * Represents vulnerability-specific fields like CVE and CVSS scores. + * CVE stands for Common Vulnerabilities and Exposures + * (https://cve.mitre.org/about/) + * @type \Google\Protobuf\Timestamp $mute_update_time + * Output only. The most recent time this finding was muted or unmuted. + * @type array|\Google\Protobuf\Internal\MapField $external_systems + * Output only. Third party SIEM/SOAR fields within SCC, contains external + * system information and external system finding fields. + * @type \Google\Cloud\SecurityCenter\V2\MitreAttack $mitre_attack + * MITRE ATT&CK tactics and techniques related to this finding. + * See: https://attack.mitre.org + * @type \Google\Cloud\SecurityCenter\V2\Access $access + * Access details associated with the finding, such as more information on the + * caller, which method was accessed, and from where. + * @type array<\Google\Cloud\SecurityCenter\V2\Connection>|\Google\Protobuf\Internal\RepeatedField $connections + * Contains information about the IP connection associated with the finding. + * @type string $mute_initiator + * Records additional information about the mute operation, for example, the + * [mute + * configuration](https://cloud.google.com/security-command-center/docs/how-to-mute-findings) + * that muted the finding and the user who muted the finding. + * @type array<\Google\Cloud\SecurityCenter\V2\Process>|\Google\Protobuf\Internal\RepeatedField $processes + * Represents operating system processes associated with the Finding. + * @type array|\Google\Protobuf\Internal\MapField $contacts + * Output only. Map containing the points of contact for the given finding. + * The key represents the type of contact, while the value contains a list of + * all the contacts that pertain. Please refer to: + * https://cloud.google.com/resource-manager/docs/managing-notification-contacts#notification-categories + * { + * "security": { + * "contacts": [ + * { + * "email": "person1@company.com" + * }, + * { + * "email": "person2@company.com" + * } + * ] + * } + * } + * @type array<\Google\Cloud\SecurityCenter\V2\Compliance>|\Google\Protobuf\Internal\RepeatedField $compliances + * Contains compliance information for security standards associated to the + * finding. + * @type string $parent_display_name + * Output only. The human readable display name of the finding source such as + * "Event Threat Detection" or "Security Health Analytics". + * @type string $description + * Contains more details about the finding. + * @type \Google\Cloud\SecurityCenter\V2\Exfiltration $exfiltration + * Represents exfiltrations associated with the finding. + * @type array<\Google\Cloud\SecurityCenter\V2\IamBinding>|\Google\Protobuf\Internal\RepeatedField $iam_bindings + * Represents IAM bindings associated with the finding. + * @type string $next_steps + * Steps to address the finding. + * @type string $module_name + * Unique identifier of the module which generated the finding. + * Example: + * folders/598186756061/securityHealthAnalyticsSettings/customModules/56799441161885 + * @type array<\Google\Cloud\SecurityCenter\V2\Container>|\Google\Protobuf\Internal\RepeatedField $containers + * Containers associated with the finding. This field provides information for + * both Kubernetes and non-Kubernetes containers. + * @type \Google\Cloud\SecurityCenter\V2\Kubernetes $kubernetes + * Kubernetes resources associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\Database $database + * Database associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\AttackExposure $attack_exposure + * The results of an attack path simulation relevant to this finding. + * @type array<\Google\Cloud\SecurityCenter\V2\File>|\Google\Protobuf\Internal\RepeatedField $files + * File associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\CloudDlpInspection $cloud_dlp_inspection + * Cloud Data Loss Prevention (Cloud DLP) inspection results that are + * associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\CloudDlpDataProfile $cloud_dlp_data_profile + * Cloud DLP data profile that is associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\KernelRootkit $kernel_rootkit + * Signature of the kernel rootkit. + * @type array<\Google\Cloud\SecurityCenter\V2\OrgPolicy>|\Google\Protobuf\Internal\RepeatedField $org_policies + * Contains information about the org policies associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\Application $application + * Represents an application associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\BackupDisasterRecovery $backup_disaster_recovery + * Fields related to Backup and DR findings. + * @type \Google\Cloud\SecurityCenter\V2\SecurityPosture $security_posture + * The security posture associated with the finding. + * @type array<\Google\Cloud\SecurityCenter\V2\LogEntry>|\Google\Protobuf\Internal\RepeatedField $log_entries + * Log entries that are relevant to the finding. + * @type array<\Google\Cloud\SecurityCenter\V2\LoadBalancer>|\Google\Protobuf\Internal\RepeatedField $load_balancers + * The load balancers associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\CloudArmor $cloud_armor + * Fields related to Cloud Armor findings. + * @type \Google\Cloud\SecurityCenter\V2\Notebook $notebook + * Notebook associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\ToxicCombination $toxic_combination + * Contains details about a group of security issues that, when the issues + * occur together, represent a greater risk than when the issues occur + * independently. A group of such issues is referred to as a toxic + * combination. + * This field cannot be updated. Its value is ignored in all update requests. + * @type array<\Google\Cloud\SecurityCenter\V2\GroupMembership>|\Google\Protobuf\Internal\RepeatedField $group_memberships + * Contains details about groups of which this finding is a member. A group is + * a collection of findings that are related in some way. + * This field cannot be updated. Its value is ignored in all update requests. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Finding::initOnce(); + parent::__construct($data); + } + + /** + * The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. The following list shows some examples: + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` + * + + * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. The following list shows some examples: + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` + * + + * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Output only. The canonical name of the finding. The following list shows + * some examples: + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` + * + + * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * The prefix is the closest CRM ancestor of the resource associated with the + * finding. + * + * Generated from protobuf field string canonical_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getCanonicalName() + { + return $this->canonical_name; + } + + /** + * Output only. The canonical name of the finding. The following list shows + * some examples: + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` + * + + * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * The prefix is the closest CRM ancestor of the resource associated with the + * finding. + * + * Generated from protobuf field string canonical_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setCanonicalName($var) + { + GPBUtil::checkString($var, True); + $this->canonical_name = $var; + + return $this; + } + + /** + * The relative resource name of the source and location the finding belongs + * to. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * This field is immutable after creation time. The following list shows some + * examples: + * + `organizations/{organization_id}/sources/{source_id}` + * + `folders/{folders_id}/sources/{source_id}` + * + `projects/{projects_id}/sources/{source_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}` + * + `folders/{folders_id}/sources/{source_id}/locations/{location_id}` + * + `projects/{projects_id}/sources/{source_id}/locations/{location_id}` + * + * Generated from protobuf field string parent = 3; + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * The relative resource name of the source and location the finding belongs + * to. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * This field is immutable after creation time. The following list shows some + * examples: + * + `organizations/{organization_id}/sources/{source_id}` + * + `folders/{folders_id}/sources/{source_id}` + * + `projects/{projects_id}/sources/{source_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}` + * + `folders/{folders_id}/sources/{source_id}/locations/{location_id}` + * + `projects/{projects_id}/sources/{source_id}/locations/{location_id}` + * + * Generated from protobuf field string parent = 3; + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Immutable. For findings on Google Cloud resources, the full resource + * name of the Google Cloud resource this finding is for. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * When the finding is for a non-Google Cloud resource, the resourceName can + * be a customer or partner defined string. + * + * Generated from protobuf field string resource_name = 4 [(.google.api.field_behavior) = IMMUTABLE]; + * @return string + */ + public function getResourceName() + { + return $this->resource_name; + } + + /** + * Immutable. For findings on Google Cloud resources, the full resource + * name of the Google Cloud resource this finding is for. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * When the finding is for a non-Google Cloud resource, the resourceName can + * be a customer or partner defined string. + * + * Generated from protobuf field string resource_name = 4 [(.google.api.field_behavior) = IMMUTABLE]; + * @param string $var + * @return $this + */ + public function setResourceName($var) + { + GPBUtil::checkString($var, True); + $this->resource_name = $var; + + return $this; + } + + /** + * Output only. The state of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. The state of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Finding\State::class); + $this->state = $var; + + return $this; + } + + /** + * Immutable. The additional taxonomy group within findings from a given + * source. Example: "XSS_FLASH_INJECTION" + * + * Generated from protobuf field string category = 7 [(.google.api.field_behavior) = IMMUTABLE]; + * @return string + */ + public function getCategory() + { + return $this->category; + } + + /** + * Immutable. The additional taxonomy group within findings from a given + * source. Example: "XSS_FLASH_INJECTION" + * + * Generated from protobuf field string category = 7 [(.google.api.field_behavior) = IMMUTABLE]; + * @param string $var + * @return $this + */ + public function setCategory($var) + { + GPBUtil::checkString($var, True); + $this->category = $var; + + return $this; + } + + /** + * The URI that, if available, points to a web page outside of Security + * Command Center where additional information about the finding can be found. + * This field is guaranteed to be either empty or a well formed URL. + * + * Generated from protobuf field string external_uri = 8; + * @return string + */ + public function getExternalUri() + { + return $this->external_uri; + } + + /** + * The URI that, if available, points to a web page outside of Security + * Command Center where additional information about the finding can be found. + * This field is guaranteed to be either empty or a well formed URL. + * + * Generated from protobuf field string external_uri = 8; + * @param string $var + * @return $this + */ + public function setExternalUri($var) + { + GPBUtil::checkString($var, True); + $this->external_uri = $var; + + return $this; + } + + /** + * Source specific properties. These properties are managed by the source + * that writes the finding. The key names in the source_properties map must be + * between 1 and 255 characters, and must start with a letter and contain + * alphanumeric characters or underscores only. + * + * Generated from protobuf field map source_properties = 9; + * @return \Google\Protobuf\Internal\MapField + */ + public function getSourceProperties() + { + return $this->source_properties; + } + + /** + * Source specific properties. These properties are managed by the source + * that writes the finding. The key names in the source_properties map must be + * between 1 and 255 characters, and must start with a letter and contain + * alphanumeric characters or underscores only. + * + * Generated from protobuf field map source_properties = 9; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setSourceProperties($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Value::class); + $this->source_properties = $arr; + + return $this; + } + + /** + * Output only. User specified security marks. These marks are entirely + * managed by the user and come from the SecurityMarks resource that belongs + * to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityMarks security_marks = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Cloud\SecurityCenter\V2\SecurityMarks|null + */ + public function getSecurityMarks() + { + return $this->security_marks; + } + + public function hasSecurityMarks() + { + return isset($this->security_marks); + } + + public function clearSecurityMarks() + { + unset($this->security_marks); + } + + /** + * Output only. User specified security marks. These marks are entirely + * managed by the user and come from the SecurityMarks resource that belongs + * to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityMarks security_marks = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\SecurityCenter\V2\SecurityMarks $var + * @return $this + */ + public function setSecurityMarks($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\SecurityMarks::class); + $this->security_marks = $var; + + return $this; + } + + /** + * The time the finding was first detected. If an existing finding is updated, + * then this is the time the update occurred. + * For example, if the finding represents an open firewall, this property + * captures the time the detector believes the firewall became open. The + * accuracy is determined by the detector. If the finding is later resolved, + * then this time reflects when the finding was resolved. This must not + * be set to a value greater than the current timestamp. + * + * Generated from protobuf field .google.protobuf.Timestamp event_time = 11; + * @return \Google\Protobuf\Timestamp|null + */ + public function getEventTime() + { + return $this->event_time; + } + + public function hasEventTime() + { + return isset($this->event_time); + } + + public function clearEventTime() + { + unset($this->event_time); + } + + /** + * The time the finding was first detected. If an existing finding is updated, + * then this is the time the update occurred. + * For example, if the finding represents an open firewall, this property + * captures the time the detector believes the firewall became open. The + * accuracy is determined by the detector. If the finding is later resolved, + * then this time reflects when the finding was resolved. This must not + * be set to a value greater than the current timestamp. + * + * Generated from protobuf field .google.protobuf.Timestamp event_time = 11; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setEventTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->event_time = $var; + + return $this; + } + + /** + * Output only. The time at which the finding was created in Security Command + * Center. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCreateTime() + { + return $this->create_time; + } + + public function hasCreateTime() + { + return isset($this->create_time); + } + + public function clearCreateTime() + { + unset($this->create_time); + } + + /** + * Output only. The time at which the finding was created in Security Command + * Center. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->create_time = $var; + + return $this; + } + + /** + * The severity of the finding. This field is managed by the source that + * writes the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.Severity severity = 14; + * @return int + */ + public function getSeverity() + { + return $this->severity; + } + + /** + * The severity of the finding. This field is managed by the source that + * writes the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.Severity severity = 14; + * @param int $var + * @return $this + */ + public function setSeverity($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Finding\Severity::class); + $this->severity = $var; + + return $this; + } + + /** + * Indicates the mute state of a finding (either muted, unmuted + * or undefined). Unlike other attributes of a finding, a finding provider + * shouldn't set the value of mute. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.Mute mute = 15; + * @return int + */ + public function getMute() + { + return $this->mute; + } + + /** + * Indicates the mute state of a finding (either muted, unmuted + * or undefined). Unlike other attributes of a finding, a finding provider + * shouldn't set the value of mute. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.Mute mute = 15; + * @param int $var + * @return $this + */ + public function setMute($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Finding\Mute::class); + $this->mute = $var; + + return $this; + } + + /** + * The class of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.FindingClass finding_class = 16; + * @return int + */ + public function getFindingClass() + { + return $this->finding_class; + } + + /** + * The class of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.FindingClass finding_class = 16; + * @param int $var + * @return $this + */ + public function setFindingClass($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Finding\FindingClass::class); + $this->finding_class = $var; + + return $this; + } + + /** + * Represents what's commonly known as an *indicator of compromise* (IoC) in + * computer forensics. This is an artifact observed on a network or in an + * operating system that, with high confidence, indicates a computer + * intrusion. For more information, see [Indicator of + * compromise](https://en.wikipedia.org/wiki/Indicator_of_compromise). + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator indicator = 17; + * @return \Google\Cloud\SecurityCenter\V2\Indicator|null + */ + public function getIndicator() + { + return $this->indicator; + } + + public function hasIndicator() + { + return isset($this->indicator); + } + + public function clearIndicator() + { + unset($this->indicator); + } + + /** + * Represents what's commonly known as an *indicator of compromise* (IoC) in + * computer forensics. This is an artifact observed on a network or in an + * operating system that, with high confidence, indicates a computer + * intrusion. For more information, see [Indicator of + * compromise](https://en.wikipedia.org/wiki/Indicator_of_compromise). + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator indicator = 17; + * @param \Google\Cloud\SecurityCenter\V2\Indicator $var + * @return $this + */ + public function setIndicator($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Indicator::class); + $this->indicator = $var; + + return $this; + } + + /** + * Represents vulnerability-specific fields like CVE and CVSS scores. + * CVE stands for Common Vulnerabilities and Exposures + * (https://cve.mitre.org/about/) + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Vulnerability vulnerability = 18; + * @return \Google\Cloud\SecurityCenter\V2\Vulnerability|null + */ + public function getVulnerability() + { + return $this->vulnerability; + } + + public function hasVulnerability() + { + return isset($this->vulnerability); + } + + public function clearVulnerability() + { + unset($this->vulnerability); + } + + /** + * Represents vulnerability-specific fields like CVE and CVSS scores. + * CVE stands for Common Vulnerabilities and Exposures + * (https://cve.mitre.org/about/) + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Vulnerability vulnerability = 18; + * @param \Google\Cloud\SecurityCenter\V2\Vulnerability $var + * @return $this + */ + public function setVulnerability($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Vulnerability::class); + $this->vulnerability = $var; + + return $this; + } + + /** + * Output only. The most recent time this finding was muted or unmuted. + * + * Generated from protobuf field .google.protobuf.Timestamp mute_update_time = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getMuteUpdateTime() + { + return $this->mute_update_time; + } + + public function hasMuteUpdateTime() + { + return isset($this->mute_update_time); + } + + public function clearMuteUpdateTime() + { + unset($this->mute_update_time); + } + + /** + * Output only. The most recent time this finding was muted or unmuted. + * + * Generated from protobuf field .google.protobuf.Timestamp mute_update_time = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setMuteUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->mute_update_time = $var; + + return $this; + } + + /** + * Output only. Third party SIEM/SOAR fields within SCC, contains external + * system information and external system finding fields. + * + * Generated from protobuf field map external_systems = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Internal\MapField + */ + public function getExternalSystems() + { + return $this->external_systems; + } + + /** + * Output only. Third party SIEM/SOAR fields within SCC, contains external + * system information and external system finding fields. + * + * Generated from protobuf field map external_systems = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setExternalSystems($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ExternalSystem::class); + $this->external_systems = $arr; + + return $this; + } + + /** + * MITRE ATT&CK tactics and techniques related to this finding. + * See: https://attack.mitre.org + * + * Generated from protobuf field .google.cloud.securitycenter.v2.MitreAttack mitre_attack = 21; + * @return \Google\Cloud\SecurityCenter\V2\MitreAttack|null + */ + public function getMitreAttack() + { + return $this->mitre_attack; + } + + public function hasMitreAttack() + { + return isset($this->mitre_attack); + } + + public function clearMitreAttack() + { + unset($this->mitre_attack); + } + + /** + * MITRE ATT&CK tactics and techniques related to this finding. + * See: https://attack.mitre.org + * + * Generated from protobuf field .google.cloud.securitycenter.v2.MitreAttack mitre_attack = 21; + * @param \Google\Cloud\SecurityCenter\V2\MitreAttack $var + * @return $this + */ + public function setMitreAttack($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\MitreAttack::class); + $this->mitre_attack = $var; + + return $this; + } + + /** + * Access details associated with the finding, such as more information on the + * caller, which method was accessed, and from where. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Access access = 22; + * @return \Google\Cloud\SecurityCenter\V2\Access|null + */ + public function getAccess() + { + return $this->access; + } + + public function hasAccess() + { + return isset($this->access); + } + + public function clearAccess() + { + unset($this->access); + } + + /** + * Access details associated with the finding, such as more information on the + * caller, which method was accessed, and from where. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Access access = 22; + * @param \Google\Cloud\SecurityCenter\V2\Access $var + * @return $this + */ + public function setAccess($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Access::class); + $this->access = $var; + + return $this; + } + + /** + * Contains information about the IP connection associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Connection connections = 23; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getConnections() + { + return $this->connections; + } + + /** + * Contains information about the IP connection associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Connection connections = 23; + * @param array<\Google\Cloud\SecurityCenter\V2\Connection>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setConnections($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Connection::class); + $this->connections = $arr; + + return $this; + } + + /** + * Records additional information about the mute operation, for example, the + * [mute + * configuration](https://cloud.google.com/security-command-center/docs/how-to-mute-findings) + * that muted the finding and the user who muted the finding. + * + * Generated from protobuf field string mute_initiator = 24; + * @return string + */ + public function getMuteInitiator() + { + return $this->mute_initiator; + } + + /** + * Records additional information about the mute operation, for example, the + * [mute + * configuration](https://cloud.google.com/security-command-center/docs/how-to-mute-findings) + * that muted the finding and the user who muted the finding. + * + * Generated from protobuf field string mute_initiator = 24; + * @param string $var + * @return $this + */ + public function setMuteInitiator($var) + { + GPBUtil::checkString($var, True); + $this->mute_initiator = $var; + + return $this; + } + + /** + * Represents operating system processes associated with the Finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Process processes = 25; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getProcesses() + { + return $this->processes; + } + + /** + * Represents operating system processes associated with the Finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Process processes = 25; + * @param array<\Google\Cloud\SecurityCenter\V2\Process>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setProcesses($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Process::class); + $this->processes = $arr; + + return $this; + } + + /** + * Output only. Map containing the points of contact for the given finding. + * The key represents the type of contact, while the value contains a list of + * all the contacts that pertain. Please refer to: + * https://cloud.google.com/resource-manager/docs/managing-notification-contacts#notification-categories + * { + * "security": { + * "contacts": [ + * { + * "email": "person1@company.com" + * }, + * { + * "email": "person2@company.com" + * } + * ] + * } + * } + * + * Generated from protobuf field map contacts = 26 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Internal\MapField + */ + public function getContacts() + { + return $this->contacts; + } + + /** + * Output only. Map containing the points of contact for the given finding. + * The key represents the type of contact, while the value contains a list of + * all the contacts that pertain. Please refer to: + * https://cloud.google.com/resource-manager/docs/managing-notification-contacts#notification-categories + * { + * "security": { + * "contacts": [ + * { + * "email": "person1@company.com" + * }, + * { + * "email": "person2@company.com" + * } + * ] + * } + * } + * + * Generated from protobuf field map contacts = 26 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setContacts($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ContactDetails::class); + $this->contacts = $arr; + + return $this; + } + + /** + * Contains compliance information for security standards associated to the + * finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Compliance compliances = 27; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getCompliances() + { + return $this->compliances; + } + + /** + * Contains compliance information for security standards associated to the + * finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Compliance compliances = 27; + * @param array<\Google\Cloud\SecurityCenter\V2\Compliance>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setCompliances($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Compliance::class); + $this->compliances = $arr; + + return $this; + } + + /** + * Output only. The human readable display name of the finding source such as + * "Event Threat Detection" or "Security Health Analytics". + * + * Generated from protobuf field string parent_display_name = 29 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getParentDisplayName() + { + return $this->parent_display_name; + } + + /** + * Output only. The human readable display name of the finding source such as + * "Event Threat Detection" or "Security Health Analytics". + * + * Generated from protobuf field string parent_display_name = 29 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setParentDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->parent_display_name = $var; + + return $this; + } + + /** + * Contains more details about the finding. + * + * Generated from protobuf field string description = 30; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Contains more details about the finding. + * + * Generated from protobuf field string description = 30; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * Represents exfiltrations associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Exfiltration exfiltration = 31; + * @return \Google\Cloud\SecurityCenter\V2\Exfiltration|null + */ + public function getExfiltration() + { + return $this->exfiltration; + } + + public function hasExfiltration() + { + return isset($this->exfiltration); + } + + public function clearExfiltration() + { + unset($this->exfiltration); + } + + /** + * Represents exfiltrations associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Exfiltration exfiltration = 31; + * @param \Google\Cloud\SecurityCenter\V2\Exfiltration $var + * @return $this + */ + public function setExfiltration($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Exfiltration::class); + $this->exfiltration = $var; + + return $this; + } + + /** + * Represents IAM bindings associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.IamBinding iam_bindings = 32; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getIamBindings() + { + return $this->iam_bindings; + } + + /** + * Represents IAM bindings associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.IamBinding iam_bindings = 32; + * @param array<\Google\Cloud\SecurityCenter\V2\IamBinding>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setIamBindings($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\IamBinding::class); + $this->iam_bindings = $arr; + + return $this; + } + + /** + * Steps to address the finding. + * + * Generated from protobuf field string next_steps = 33; + * @return string + */ + public function getNextSteps() + { + return $this->next_steps; + } + + /** + * Steps to address the finding. + * + * Generated from protobuf field string next_steps = 33; + * @param string $var + * @return $this + */ + public function setNextSteps($var) + { + GPBUtil::checkString($var, True); + $this->next_steps = $var; + + return $this; + } + + /** + * Unique identifier of the module which generated the finding. + * Example: + * folders/598186756061/securityHealthAnalyticsSettings/customModules/56799441161885 + * + * Generated from protobuf field string module_name = 34; + * @return string + */ + public function getModuleName() + { + return $this->module_name; + } + + /** + * Unique identifier of the module which generated the finding. + * Example: + * folders/598186756061/securityHealthAnalyticsSettings/customModules/56799441161885 + * + * Generated from protobuf field string module_name = 34; + * @param string $var + * @return $this + */ + public function setModuleName($var) + { + GPBUtil::checkString($var, True); + $this->module_name = $var; + + return $this; + } + + /** + * Containers associated with the finding. This field provides information for + * both Kubernetes and non-Kubernetes containers. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Container containers = 35; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getContainers() + { + return $this->containers; + } + + /** + * Containers associated with the finding. This field provides information for + * both Kubernetes and non-Kubernetes containers. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Container containers = 35; + * @param array<\Google\Cloud\SecurityCenter\V2\Container>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setContainers($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Container::class); + $this->containers = $arr; + + return $this; + } + + /** + * Kubernetes resources associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes kubernetes = 36; + * @return \Google\Cloud\SecurityCenter\V2\Kubernetes|null + */ + public function getKubernetes() + { + return $this->kubernetes; + } + + public function hasKubernetes() + { + return isset($this->kubernetes); + } + + public function clearKubernetes() + { + unset($this->kubernetes); + } + + /** + * Kubernetes resources associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes kubernetes = 36; + * @param \Google\Cloud\SecurityCenter\V2\Kubernetes $var + * @return $this + */ + public function setKubernetes($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Kubernetes::class); + $this->kubernetes = $var; + + return $this; + } + + /** + * Database associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Database database = 37; + * @return \Google\Cloud\SecurityCenter\V2\Database|null + */ + public function getDatabase() + { + return $this->database; + } + + public function hasDatabase() + { + return isset($this->database); + } + + public function clearDatabase() + { + unset($this->database); + } + + /** + * Database associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Database database = 37; + * @param \Google\Cloud\SecurityCenter\V2\Database $var + * @return $this + */ + public function setDatabase($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Database::class); + $this->database = $var; + + return $this; + } + + /** + * The results of an attack path simulation relevant to this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AttackExposure attack_exposure = 38; + * @return \Google\Cloud\SecurityCenter\V2\AttackExposure|null + */ + public function getAttackExposure() + { + return $this->attack_exposure; + } + + public function hasAttackExposure() + { + return isset($this->attack_exposure); + } + + public function clearAttackExposure() + { + unset($this->attack_exposure); + } + + /** + * The results of an attack path simulation relevant to this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AttackExposure attack_exposure = 38; + * @param \Google\Cloud\SecurityCenter\V2\AttackExposure $var + * @return $this + */ + public function setAttackExposure($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\AttackExposure::class); + $this->attack_exposure = $var; + + return $this; + } + + /** + * File associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.File files = 39; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFiles() + { + return $this->files; + } + + /** + * File associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.File files = 39; + * @param array<\Google\Cloud\SecurityCenter\V2\File>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFiles($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\File::class); + $this->files = $arr; + + return $this; + } + + /** + * Cloud Data Loss Prevention (Cloud DLP) inspection results that are + * associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudDlpInspection cloud_dlp_inspection = 40; + * @return \Google\Cloud\SecurityCenter\V2\CloudDlpInspection|null + */ + public function getCloudDlpInspection() + { + return $this->cloud_dlp_inspection; + } + + public function hasCloudDlpInspection() + { + return isset($this->cloud_dlp_inspection); + } + + public function clearCloudDlpInspection() + { + unset($this->cloud_dlp_inspection); + } + + /** + * Cloud Data Loss Prevention (Cloud DLP) inspection results that are + * associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudDlpInspection cloud_dlp_inspection = 40; + * @param \Google\Cloud\SecurityCenter\V2\CloudDlpInspection $var + * @return $this + */ + public function setCloudDlpInspection($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\CloudDlpInspection::class); + $this->cloud_dlp_inspection = $var; + + return $this; + } + + /** + * Cloud DLP data profile that is associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudDlpDataProfile cloud_dlp_data_profile = 41; + * @return \Google\Cloud\SecurityCenter\V2\CloudDlpDataProfile|null + */ + public function getCloudDlpDataProfile() + { + return $this->cloud_dlp_data_profile; + } + + public function hasCloudDlpDataProfile() + { + return isset($this->cloud_dlp_data_profile); + } + + public function clearCloudDlpDataProfile() + { + unset($this->cloud_dlp_data_profile); + } + + /** + * Cloud DLP data profile that is associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudDlpDataProfile cloud_dlp_data_profile = 41; + * @param \Google\Cloud\SecurityCenter\V2\CloudDlpDataProfile $var + * @return $this + */ + public function setCloudDlpDataProfile($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\CloudDlpDataProfile::class); + $this->cloud_dlp_data_profile = $var; + + return $this; + } + + /** + * Signature of the kernel rootkit. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.KernelRootkit kernel_rootkit = 42; + * @return \Google\Cloud\SecurityCenter\V2\KernelRootkit|null + */ + public function getKernelRootkit() + { + return $this->kernel_rootkit; + } + + public function hasKernelRootkit() + { + return isset($this->kernel_rootkit); + } + + public function clearKernelRootkit() + { + unset($this->kernel_rootkit); + } + + /** + * Signature of the kernel rootkit. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.KernelRootkit kernel_rootkit = 42; + * @param \Google\Cloud\SecurityCenter\V2\KernelRootkit $var + * @return $this + */ + public function setKernelRootkit($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\KernelRootkit::class); + $this->kernel_rootkit = $var; + + return $this; + } + + /** + * Contains information about the org policies associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.OrgPolicy org_policies = 43; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getOrgPolicies() + { + return $this->org_policies; + } + + /** + * Contains information about the org policies associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.OrgPolicy org_policies = 43; + * @param array<\Google\Cloud\SecurityCenter\V2\OrgPolicy>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setOrgPolicies($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\OrgPolicy::class); + $this->org_policies = $arr; + + return $this; + } + + /** + * Represents an application associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Application application = 45; + * @return \Google\Cloud\SecurityCenter\V2\Application|null + */ + public function getApplication() + { + return $this->application; + } + + public function hasApplication() + { + return isset($this->application); + } + + public function clearApplication() + { + unset($this->application); + } + + /** + * Represents an application associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Application application = 45; + * @param \Google\Cloud\SecurityCenter\V2\Application $var + * @return $this + */ + public function setApplication($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Application::class); + $this->application = $var; + + return $this; + } + + /** + * Fields related to Backup and DR findings. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.BackupDisasterRecovery backup_disaster_recovery = 47; + * @return \Google\Cloud\SecurityCenter\V2\BackupDisasterRecovery|null + */ + public function getBackupDisasterRecovery() + { + return $this->backup_disaster_recovery; + } + + public function hasBackupDisasterRecovery() + { + return isset($this->backup_disaster_recovery); + } + + public function clearBackupDisasterRecovery() + { + unset($this->backup_disaster_recovery); + } + + /** + * Fields related to Backup and DR findings. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.BackupDisasterRecovery backup_disaster_recovery = 47; + * @param \Google\Cloud\SecurityCenter\V2\BackupDisasterRecovery $var + * @return $this + */ + public function setBackupDisasterRecovery($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\BackupDisasterRecovery::class); + $this->backup_disaster_recovery = $var; + + return $this; + } + + /** + * The security posture associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityPosture security_posture = 48; + * @return \Google\Cloud\SecurityCenter\V2\SecurityPosture|null + */ + public function getSecurityPosture() + { + return $this->security_posture; + } + + public function hasSecurityPosture() + { + return isset($this->security_posture); + } + + public function clearSecurityPosture() + { + unset($this->security_posture); + } + + /** + * The security posture associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityPosture security_posture = 48; + * @param \Google\Cloud\SecurityCenter\V2\SecurityPosture $var + * @return $this + */ + public function setSecurityPosture($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\SecurityPosture::class); + $this->security_posture = $var; + + return $this; + } + + /** + * Log entries that are relevant to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.LogEntry log_entries = 49; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getLogEntries() + { + return $this->log_entries; + } + + /** + * Log entries that are relevant to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.LogEntry log_entries = 49; + * @param array<\Google\Cloud\SecurityCenter\V2\LogEntry>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setLogEntries($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\LogEntry::class); + $this->log_entries = $arr; + + return $this; + } + + /** + * The load balancers associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.LoadBalancer load_balancers = 50; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getLoadBalancers() + { + return $this->load_balancers; + } + + /** + * The load balancers associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.LoadBalancer load_balancers = 50; + * @param array<\Google\Cloud\SecurityCenter\V2\LoadBalancer>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setLoadBalancers($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\LoadBalancer::class); + $this->load_balancers = $arr; + + return $this; + } + + /** + * Fields related to Cloud Armor findings. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudArmor cloud_armor = 51; + * @return \Google\Cloud\SecurityCenter\V2\CloudArmor|null + */ + public function getCloudArmor() + { + return $this->cloud_armor; + } + + public function hasCloudArmor() + { + return isset($this->cloud_armor); + } + + public function clearCloudArmor() + { + unset($this->cloud_armor); + } + + /** + * Fields related to Cloud Armor findings. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudArmor cloud_armor = 51; + * @param \Google\Cloud\SecurityCenter\V2\CloudArmor $var + * @return $this + */ + public function setCloudArmor($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\CloudArmor::class); + $this->cloud_armor = $var; + + return $this; + } + + /** + * Notebook associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Notebook notebook = 55; + * @return \Google\Cloud\SecurityCenter\V2\Notebook|null + */ + public function getNotebook() + { + return $this->notebook; + } + + public function hasNotebook() + { + return isset($this->notebook); + } + + public function clearNotebook() + { + unset($this->notebook); + } + + /** + * Notebook associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Notebook notebook = 55; + * @param \Google\Cloud\SecurityCenter\V2\Notebook $var + * @return $this + */ + public function setNotebook($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Notebook::class); + $this->notebook = $var; + + return $this; + } + + /** + * Contains details about a group of security issues that, when the issues + * occur together, represent a greater risk than when the issues occur + * independently. A group of such issues is referred to as a toxic + * combination. + * This field cannot be updated. Its value is ignored in all update requests. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ToxicCombination toxic_combination = 56; + * @return \Google\Cloud\SecurityCenter\V2\ToxicCombination|null + */ + public function getToxicCombination() + { + return $this->toxic_combination; + } + + public function hasToxicCombination() + { + return isset($this->toxic_combination); + } + + public function clearToxicCombination() + { + unset($this->toxic_combination); + } + + /** + * Contains details about a group of security issues that, when the issues + * occur together, represent a greater risk than when the issues occur + * independently. A group of such issues is referred to as a toxic + * combination. + * This field cannot be updated. Its value is ignored in all update requests. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ToxicCombination toxic_combination = 56; + * @param \Google\Cloud\SecurityCenter\V2\ToxicCombination $var + * @return $this + */ + public function setToxicCombination($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ToxicCombination::class); + $this->toxic_combination = $var; + + return $this; + } + + /** + * Contains details about groups of which this finding is a member. A group is + * a collection of findings that are related in some way. + * This field cannot be updated. Its value is ignored in all update requests. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.GroupMembership group_memberships = 57; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getGroupMemberships() + { + return $this->group_memberships; + } + + /** + * Contains details about groups of which this finding is a member. A group is + * a collection of findings that are related in some way. + * This field cannot be updated. Its value is ignored in all update requests. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.GroupMembership group_memberships = 57; + * @param array<\Google\Cloud\SecurityCenter\V2\GroupMembership>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setGroupMemberships($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\GroupMembership::class); + $this->group_memberships = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/FindingClass.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/FindingClass.php new file mode 100644 index 000000000000..371e6709d428 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/FindingClass.php @@ -0,0 +1,103 @@ +google.cloud.securitycenter.v2.Finding.FindingClass + */ +class FindingClass +{ + /** + * Unspecified finding class. + * + * Generated from protobuf enum FINDING_CLASS_UNSPECIFIED = 0; + */ + const FINDING_CLASS_UNSPECIFIED = 0; + /** + * Describes unwanted or malicious activity. + * + * Generated from protobuf enum THREAT = 1; + */ + const THREAT = 1; + /** + * Describes a potential weakness in software that increases risk to + * Confidentiality & Integrity & Availability. + * + * Generated from protobuf enum VULNERABILITY = 2; + */ + const VULNERABILITY = 2; + /** + * Describes a potential weakness in cloud resource/asset configuration that + * increases risk. + * + * Generated from protobuf enum MISCONFIGURATION = 3; + */ + const MISCONFIGURATION = 3; + /** + * Describes a security observation that is for informational purposes. + * + * Generated from protobuf enum OBSERVATION = 4; + */ + const OBSERVATION = 4; + /** + * Describes an error that prevents some SCC functionality. + * + * Generated from protobuf enum SCC_ERROR = 5; + */ + const SCC_ERROR = 5; + /** + * Describes a potential security risk due to a change in the security + * posture. + * + * Generated from protobuf enum POSTURE_VIOLATION = 6; + */ + const POSTURE_VIOLATION = 6; + /** + * Describes a combination of security issues that represent a more severe + * security problem when taken together. + * + * Generated from protobuf enum TOXIC_COMBINATION = 7; + */ + const TOXIC_COMBINATION = 7; + + private static $valueToName = [ + self::FINDING_CLASS_UNSPECIFIED => 'FINDING_CLASS_UNSPECIFIED', + self::THREAT => 'THREAT', + self::VULNERABILITY => 'VULNERABILITY', + self::MISCONFIGURATION => 'MISCONFIGURATION', + self::OBSERVATION => 'OBSERVATION', + self::SCC_ERROR => 'SCC_ERROR', + self::POSTURE_VIOLATION => 'POSTURE_VIOLATION', + self::TOXIC_COMBINATION => 'TOXIC_COMBINATION', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(FindingClass::class, \Google\Cloud\SecurityCenter\V2\Finding_FindingClass::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/Mute.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/Mute.php new file mode 100644 index 000000000000..1f10f5dfe266 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/Mute.php @@ -0,0 +1,71 @@ +google.cloud.securitycenter.v2.Finding.Mute + */ +class Mute +{ + /** + * Unspecified. + * + * Generated from protobuf enum MUTE_UNSPECIFIED = 0; + */ + const MUTE_UNSPECIFIED = 0; + /** + * Finding has been muted. + * + * Generated from protobuf enum MUTED = 1; + */ + const MUTED = 1; + /** + * Finding has been unmuted. + * + * Generated from protobuf enum UNMUTED = 2; + */ + const UNMUTED = 2; + /** + * Finding has never been muted/unmuted. + * + * Generated from protobuf enum UNDEFINED = 3; + */ + const UNDEFINED = 3; + + private static $valueToName = [ + self::MUTE_UNSPECIFIED => 'MUTE_UNSPECIFIED', + self::MUTED => 'MUTED', + self::UNMUTED => 'UNMUTED', + self::UNDEFINED => 'UNDEFINED', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Mute::class, \Google\Cloud\SecurityCenter\V2\Finding_Mute::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/Severity.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/Severity.php new file mode 100644 index 000000000000..24567f407c53 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/Severity.php @@ -0,0 +1,116 @@ +google.cloud.securitycenter.v2.Finding.Severity + */ +class Severity +{ + /** + * This value is used for findings when a source doesn't write a severity + * value. + * + * Generated from protobuf enum SEVERITY_UNSPECIFIED = 0; + */ + const SEVERITY_UNSPECIFIED = 0; + /** + * Vulnerability: + * A critical vulnerability is easily discoverable by an external actor, + * exploitable, and results in the direct ability to execute arbitrary code, + * exfiltrate data, and otherwise gain additional access and privileges to + * cloud resources and workloads. Examples include publicly accessible + * unprotected user data and public SSH access with weak or no + * passwords. + * Threat: + * Indicates a threat that is able to access, modify, or delete data or + * execute unauthorized code within existing resources. + * + * Generated from protobuf enum CRITICAL = 1; + */ + const CRITICAL = 1; + /** + * Vulnerability: + * A high risk vulnerability can be easily discovered and exploited in + * combination with other vulnerabilities in order to gain direct access and + * the ability to execute arbitrary code, exfiltrate data, and otherwise + * gain additional access and privileges to cloud resources and workloads. + * An example is a database with weak or no passwords that is only + * accessible internally. This database could easily be compromised by an + * actor that had access to the internal network. + * Threat: + * Indicates a threat that is able to create new computational resources in + * an environment but not able to access data or execute code in existing + * resources. + * + * Generated from protobuf enum HIGH = 2; + */ + const HIGH = 2; + /** + * Vulnerability: + * A medium risk vulnerability could be used by an actor to gain access to + * resources or privileges that enable them to eventually (through multiple + * steps or a complex exploit) gain access and the ability to execute + * arbitrary code or exfiltrate data. An example is a service account with + * access to more projects than it should have. If an actor gains access to + * the service account, they could potentially use that access to manipulate + * a project the service account was not intended to. + * Threat: + * Indicates a threat that is able to cause operational impact but may not + * access data or execute unauthorized code. + * + * Generated from protobuf enum MEDIUM = 3; + */ + const MEDIUM = 3; + /** + * Vulnerability: + * A low risk vulnerability hampers a security organization's ability to + * detect vulnerabilities or active threats in their deployment, or prevents + * the root cause investigation of security issues. An example is monitoring + * and logs being disabled for resource configurations and access. + * Threat: + * Indicates a threat that has obtained minimal access to an environment but + * is not able to access data, execute code, or create resources. + * + * Generated from protobuf enum LOW = 4; + */ + const LOW = 4; + + private static $valueToName = [ + self::SEVERITY_UNSPECIFIED => 'SEVERITY_UNSPECIFIED', + self::CRITICAL => 'CRITICAL', + self::HIGH => 'HIGH', + self::MEDIUM => 'MEDIUM', + self::LOW => 'LOW', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Severity::class, \Google\Cloud\SecurityCenter\V2\Finding_Severity::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/State.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/State.php new file mode 100644 index 000000000000..2638592fa61a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/State.php @@ -0,0 +1,65 @@ +google.cloud.securitycenter.v2.Finding.State + */ +class State +{ + /** + * Unspecified state. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The finding requires attention and has not been addressed yet. + * + * Generated from protobuf enum ACTIVE = 1; + */ + const ACTIVE = 1; + /** + * The finding has been fixed, triaged as a non-issue or otherwise addressed + * and is no longer active. + * + * Generated from protobuf enum INACTIVE = 2; + */ + const INACTIVE = 2; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::ACTIVE => 'ACTIVE', + self::INACTIVE => 'INACTIVE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(State::class, \Google\Cloud\SecurityCenter\V2\Finding_State::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Folder.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Folder.php new file mode 100644 index 000000000000..26ba49e37801 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Folder.php @@ -0,0 +1,106 @@ +google.cloud.securitycenter.v2.Folder + */ +class Folder extends \Google\Protobuf\Internal\Message +{ + /** + * Full resource name of this folder. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_folder = 1; + */ + protected $resource_folder = ''; + /** + * The user defined display name for this folder. + * + * Generated from protobuf field string resource_folder_display_name = 2; + */ + protected $resource_folder_display_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $resource_folder + * Full resource name of this folder. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * @type string $resource_folder_display_name + * The user defined display name for this folder. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Folder::initOnce(); + parent::__construct($data); + } + + /** + * Full resource name of this folder. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_folder = 1; + * @return string + */ + public function getResourceFolder() + { + return $this->resource_folder; + } + + /** + * Full resource name of this folder. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string resource_folder = 1; + * @param string $var + * @return $this + */ + public function setResourceFolder($var) + { + GPBUtil::checkString($var, True); + $this->resource_folder = $var; + + return $this; + } + + /** + * The user defined display name for this folder. + * + * Generated from protobuf field string resource_folder_display_name = 2; + * @return string + */ + public function getResourceFolderDisplayName() + { + return $this->resource_folder_display_name; + } + + /** + * The user defined display name for this folder. + * + * Generated from protobuf field string resource_folder_display_name = 2; + * @param string $var + * @return $this + */ + public function setResourceFolderDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->resource_folder_display_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GcpMetadata.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GcpMetadata.php new file mode 100644 index 000000000000..e9fa5e33a613 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GcpMetadata.php @@ -0,0 +1,246 @@ +google.cloud.securitycenter.v2.GcpMetadata + */ +class GcpMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * The full resource name of project that the resource belongs to. + * + * Generated from protobuf field string project = 1; + */ + protected $project = ''; + /** + * The project ID that the resource belongs to. + * + * Generated from protobuf field string project_display_name = 2; + */ + protected $project_display_name = ''; + /** + * The full resource name of resource's parent. + * + * Generated from protobuf field string parent = 3; + */ + protected $parent = ''; + /** + * The human readable name of resource's parent. + * + * Generated from protobuf field string parent_display_name = 4; + */ + protected $parent_display_name = ''; + /** + * Output only. Contains a Folder message for each folder in the assets + * ancestry. The first folder is the deepest nested folder, and the last + * folder is the folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Folder folders = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $folders; + /** + * The name of the organization that the resource belongs to. + * + * Generated from protobuf field string organization = 6; + */ + protected $organization = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $project + * The full resource name of project that the resource belongs to. + * @type string $project_display_name + * The project ID that the resource belongs to. + * @type string $parent + * The full resource name of resource's parent. + * @type string $parent_display_name + * The human readable name of resource's parent. + * @type array<\Google\Cloud\SecurityCenter\V2\Folder>|\Google\Protobuf\Internal\RepeatedField $folders + * Output only. Contains a Folder message for each folder in the assets + * ancestry. The first folder is the deepest nested folder, and the last + * folder is the folder directly under the Organization. + * @type string $organization + * The name of the organization that the resource belongs to. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Resource::initOnce(); + parent::__construct($data); + } + + /** + * The full resource name of project that the resource belongs to. + * + * Generated from protobuf field string project = 1; + * @return string + */ + public function getProject() + { + return $this->project; + } + + /** + * The full resource name of project that the resource belongs to. + * + * Generated from protobuf field string project = 1; + * @param string $var + * @return $this + */ + public function setProject($var) + { + GPBUtil::checkString($var, True); + $this->project = $var; + + return $this; + } + + /** + * The project ID that the resource belongs to. + * + * Generated from protobuf field string project_display_name = 2; + * @return string + */ + public function getProjectDisplayName() + { + return $this->project_display_name; + } + + /** + * The project ID that the resource belongs to. + * + * Generated from protobuf field string project_display_name = 2; + * @param string $var + * @return $this + */ + public function setProjectDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->project_display_name = $var; + + return $this; + } + + /** + * The full resource name of resource's parent. + * + * Generated from protobuf field string parent = 3; + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * The full resource name of resource's parent. + * + * Generated from protobuf field string parent = 3; + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The human readable name of resource's parent. + * + * Generated from protobuf field string parent_display_name = 4; + * @return string + */ + public function getParentDisplayName() + { + return $this->parent_display_name; + } + + /** + * The human readable name of resource's parent. + * + * Generated from protobuf field string parent_display_name = 4; + * @param string $var + * @return $this + */ + public function setParentDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->parent_display_name = $var; + + return $this; + } + + /** + * Output only. Contains a Folder message for each folder in the assets + * ancestry. The first folder is the deepest nested folder, and the last + * folder is the folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Folder folders = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getFolders() + { + return $this->folders; + } + + /** + * Output only. Contains a Folder message for each folder in the assets + * ancestry. The first folder is the deepest nested folder, and the last + * folder is the folder directly under the Organization. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Folder folders = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param array<\Google\Cloud\SecurityCenter\V2\Folder>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setFolders($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Folder::class); + $this->folders = $arr; + + return $this; + } + + /** + * The name of the organization that the resource belongs to. + * + * Generated from protobuf field string organization = 6; + * @return string + */ + public function getOrganization() + { + return $this->organization; + } + + /** + * The name of the organization that the resource belongs to. + * + * Generated from protobuf field string organization = 6; + * @param string $var + * @return $this + */ + public function setOrganization($var) + { + GPBUtil::checkString($var, True); + $this->organization = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Geolocation.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Geolocation.php new file mode 100644 index 000000000000..7b27b438ecde --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Geolocation.php @@ -0,0 +1,67 @@ +google.cloud.securitycenter.v2.Geolocation + */ +class Geolocation extends \Google\Protobuf\Internal\Message +{ + /** + * A CLDR. + * + * Generated from protobuf field string region_code = 1; + */ + protected $region_code = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $region_code + * A CLDR. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Access::initOnce(); + parent::__construct($data); + } + + /** + * A CLDR. + * + * Generated from protobuf field string region_code = 1; + * @return string + */ + public function getRegionCode() + { + return $this->region_code; + } + + /** + * A CLDR. + * + * Generated from protobuf field string region_code = 1; + * @param string $var + * @return $this + */ + public function setRegionCode($var) + { + GPBUtil::checkString($var, True); + $this->region_code = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetBigQueryExportRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetBigQueryExportRequest.php new file mode 100644 index 000000000000..f0ea3c80ccba --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetBigQueryExportRequest.php @@ -0,0 +1,107 @@ +google.cloud.securitycenter.v2.GetBigQueryExportRequest + */ +class GetBigQueryExportRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the BigQuery export to retrieve. The following list shows + * some examples of the format: + * + + * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` + * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` + * + `projects/{project}locations/{location}//bigQueryExports/{export_id}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Name of the BigQuery export to retrieve. The following list shows + * some examples of the format: + * + * + + * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` + * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` + * + `projects/{project}locations/{location}//bigQueryExports/{export_id}` + * Please see {@see SecurityCenterClient::bigQueryExportName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V2\GetBigQueryExportRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the BigQuery export to retrieve. The following list shows + * some examples of the format: + * + + * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` + * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` + * + `projects/{project}locations/{location}//bigQueryExports/{export_id}` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the BigQuery export to retrieve. The following list shows + * some examples of the format: + * + + * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` + * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` + * + `projects/{project}locations/{location}//bigQueryExports/{export_id}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the BigQuery export to retrieve. The following list shows + * some examples of the format: + * + + * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` + * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` + * + `projects/{project}locations/{location}//bigQueryExports/{export_id}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetMuteConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetMuteConfigRequest.php new file mode 100644 index 000000000000..654e9634e259 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetMuteConfigRequest.php @@ -0,0 +1,123 @@ +google.cloud.securitycenter.v2.GetMuteConfigRequest + */ +class GetMuteConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the mute config to retrieve. The following list shows + * some examples of the format: + * + `organizations/{organization}/muteConfigs/{config_id}` + * + + * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` + * + `folders/{folder}/muteConfigs/{config_id}` + * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` + * + `projects/{project}/muteConfigs/{config_id}` + * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Name of the mute config to retrieve. The following list shows + * some examples of the format: + * + * + `organizations/{organization}/muteConfigs/{config_id}` + * + + * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` + * + `folders/{folder}/muteConfigs/{config_id}` + * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` + * + `projects/{project}/muteConfigs/{config_id}` + * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` + * Please see {@see SecurityCenterClient::muteConfigName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V2\GetMuteConfigRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the mute config to retrieve. The following list shows + * some examples of the format: + * + `organizations/{organization}/muteConfigs/{config_id}` + * + + * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` + * + `folders/{folder}/muteConfigs/{config_id}` + * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` + * + `projects/{project}/muteConfigs/{config_id}` + * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the mute config to retrieve. The following list shows + * some examples of the format: + * + `organizations/{organization}/muteConfigs/{config_id}` + * + + * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` + * + `folders/{folder}/muteConfigs/{config_id}` + * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` + * + `projects/{project}/muteConfigs/{config_id}` + * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the mute config to retrieve. The following list shows + * some examples of the format: + * + `organizations/{organization}/muteConfigs/{config_id}` + * + + * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` + * + `folders/{folder}/muteConfigs/{config_id}` + * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` + * + `projects/{project}/muteConfigs/{config_id}` + * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetNotificationConfigRequest.php new file mode 100644 index 000000000000..5199b55491b9 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetNotificationConfigRequest.php @@ -0,0 +1,117 @@ +google.cloud.securitycenter.v2.GetNotificationConfigRequest + */ +class GetNotificationConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the notification config to get. The following list shows + * some examples of the format: + * + + * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` + * + + * `folders/[folder_id]/locations/[location_id]/notificationConfigs/[config_id]` + * + + * `projects/[project_id]/locations/[location_id]/notificationConfigs/[config_id]` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Name of the notification config to get. The following list shows + * some examples of the format: + * + * + + * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` + * + + * `folders/[folder_id]/locations/[location_id]/notificationConfigs/[config_id]` + * + + * `projects/[project_id]/locations/[location_id]/notificationConfigs/[config_id]` + * Please see {@see SecurityCenterClient::notificationConfigName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V2\GetNotificationConfigRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the notification config to get. The following list shows + * some examples of the format: + * + + * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` + * + + * `folders/[folder_id]/locations/[location_id]/notificationConfigs/[config_id]` + * + + * `projects/[project_id]/locations/[location_id]/notificationConfigs/[config_id]` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the notification config to get. The following list shows + * some examples of the format: + * + + * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` + * + + * `folders/[folder_id]/locations/[location_id]/notificationConfigs/[config_id]` + * + + * `projects/[project_id]/locations/[location_id]/notificationConfigs/[config_id]` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the notification config to get. The following list shows + * some examples of the format: + * + + * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` + * + + * `folders/[folder_id]/locations/[location_id]/notificationConfigs/[config_id]` + * + + * `projects/[project_id]/locations/[location_id]/notificationConfigs/[config_id]` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetResourceValueConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetResourceValueConfigRequest.php new file mode 100644 index 000000000000..cd092f990b0f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetResourceValueConfigRequest.php @@ -0,0 +1,86 @@ +google.cloud.securitycenter.v2.GetResourceValueConfigRequest + */ +class GetResourceValueConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the resource value config to retrieve. Its format is + * organizations/{organization}/resourceValueConfigs/{config_id}. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Name of the resource value config to retrieve. Its format is + * organizations/{organization}/resourceValueConfigs/{config_id}. Please see + * {@see SecurityCenterClient::resourceValueConfigName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V2\GetResourceValueConfigRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Name of the resource value config to retrieve. Its format is + * organizations/{organization}/resourceValueConfigs/{config_id}. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the resource value config to retrieve. Its format is + * organizations/{organization}/resourceValueConfigs/{config_id}. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Name of the resource value config to retrieve. Its format is + * organizations/{organization}/resourceValueConfigs/{config_id}. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetSimulationRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetSimulationRequest.php new file mode 100644 index 000000000000..48849de351ad --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetSimulationRequest.php @@ -0,0 +1,99 @@ +google.cloud.securitycenter.v2.GetSimulationRequest + */ +class GetSimulationRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The organization name or simulation name of this simulation + * Valid format: + * "organizations/{organization}/simulations/latest" + * "organizations/{organization}/simulations/{simulation}" + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. The organization name or simulation name of this simulation + * + * Valid format: + * "organizations/{organization}/simulations/latest" + * "organizations/{organization}/simulations/{simulation}" + * Please see {@see SecurityCenterClient::simulationName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V2\GetSimulationRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The organization name or simulation name of this simulation + * Valid format: + * "organizations/{organization}/simulations/latest" + * "organizations/{organization}/simulations/{simulation}" + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The organization name or simulation name of this simulation + * Valid format: + * "organizations/{organization}/simulations/latest" + * "organizations/{organization}/simulations/{simulation}" + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The organization name or simulation name of this simulation + * Valid format: + * "organizations/{organization}/simulations/latest" + * "organizations/{organization}/simulations/{simulation}" + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetSourceRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetSourceRequest.php new file mode 100644 index 000000000000..cd90dcc92cf9 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetSourceRequest.php @@ -0,0 +1,86 @@ +google.cloud.securitycenter.v2.GetSourceRequest + */ +class GetSourceRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Relative resource name of the source. Its format is + * "organizations/[organization_id]/source/[source_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. Relative resource name of the source. Its format is + * "organizations/[organization_id]/source/[source_id]". Please see + * {@see SecurityCenterClient::sourceName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V2\GetSourceRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Relative resource name of the source. Its format is + * "organizations/[organization_id]/source/[source_id]". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Relative resource name of the source. Its format is + * "organizations/[organization_id]/source/[source_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Relative resource name of the source. Its format is + * "organizations/[organization_id]/source/[source_id]". + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetValuedResourceRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetValuedResourceRequest.php new file mode 100644 index 000000000000..fae32a7a0a52 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetValuedResourceRequest.php @@ -0,0 +1,92 @@ +google.cloud.securitycenter.v2.GetValuedResourceRequest + */ +class GetValuedResourceRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of this valued resource + * Valid format: + * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. The name of this valued resource + * + * Valid format: + * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" + * Please see {@see SecurityCenterClient::valuedResourceName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V2\GetValuedResourceRequest + * + * @experimental + */ + public static function build(string $name): self + { + return (new self()) + ->setName($name); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The name of this valued resource + * Valid format: + * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of this valued resource + * Valid format: + * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The name of this valued resource + * Valid format: + * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupFindingsRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupFindingsRequest.php new file mode 100644 index 000000000000..1ab125053017 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupFindingsRequest.php @@ -0,0 +1,473 @@ +google.cloud.securitycenter.v2.GroupFindingsRequest + */ +class GroupFindingsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the source to groupBy. If no location is specified, + * finding is assumed to be in global. + * The following list shows some examples: + * + `organizations/[organization_id]/sources/[source_id]` + * + + * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` + * + `folders/[folder_id]/sources/[source_id]` + * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` + * + `projects/[project_id]/sources/[source_id]` + * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` + * To groupBy across all sources provide a source_id of `-`. The following + * list shows some examples: + * + `organizations/{organization_id}/sources/-` + * + `organizations/{organization_id}/sources/-/locations/[location_id]` + * + `folders/{folder_id}/sources/-` + * + `folders/{folder_id}/sources/-/locations/[location_id]` + * + `projects/{project_id}/sources/-` + * + `projects/{project_id}/sources/-/locations/[location_id]` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * severity: `=`, `:` + * * security_marks.marks: `=`, `:` + * * resource: + * * resource.name: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.type: `=`, `:` + * + * Generated from protobuf field string filter = 2; + */ + protected $filter = ''; + /** + * Required. Expression that defines what assets fields to use for grouping. + * The string value should follow SQL syntax: comma separated list of fields. + * For example: "parent,resource_name". + * + * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $group_by = ''; + /** + * The value returned by the last `GroupFindingsResponse`; indicates + * that this is a continuation of a prior `GroupFindings` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 7; + */ + protected $page_token = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 8; + */ + protected $page_size = 0; + + /** + * @param string $parent Required. Name of the source to groupBy. If no location is specified, + * finding is assumed to be in global. + * The following list shows some examples: + * + * + `organizations/[organization_id]/sources/[source_id]` + * + + * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` + * + `folders/[folder_id]/sources/[source_id]` + * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` + * + `projects/[project_id]/sources/[source_id]` + * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` + * + * To groupBy across all sources provide a source_id of `-`. The following + * list shows some examples: + * + * + `organizations/{organization_id}/sources/-` + * + `organizations/{organization_id}/sources/-/locations/[location_id]` + * + `folders/{folder_id}/sources/-` + * + `folders/{folder_id}/sources/-/locations/[location_id]` + * + `projects/{project_id}/sources/-` + * + `projects/{project_id}/sources/-/locations/[location_id]` + * Please see {@see SecurityCenterClient::sourceName()} for help formatting this field. + * @param string $groupBy Required. Expression that defines what assets fields to use for grouping. + * The string value should follow SQL syntax: comma separated list of fields. + * For example: "parent,resource_name". + * + * @return \Google\Cloud\SecurityCenter\V2\GroupFindingsRequest + * + * @experimental + */ + public static function build(string $parent, string $groupBy): self + { + return (new self()) + ->setParent($parent) + ->setGroupBy($groupBy); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Name of the source to groupBy. If no location is specified, + * finding is assumed to be in global. + * The following list shows some examples: + * + `organizations/[organization_id]/sources/[source_id]` + * + + * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` + * + `folders/[folder_id]/sources/[source_id]` + * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` + * + `projects/[project_id]/sources/[source_id]` + * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` + * To groupBy across all sources provide a source_id of `-`. The following + * list shows some examples: + * + `organizations/{organization_id}/sources/-` + * + `organizations/{organization_id}/sources/-/locations/[location_id]` + * + `folders/{folder_id}/sources/-` + * + `folders/{folder_id}/sources/-/locations/[location_id]` + * + `projects/{project_id}/sources/-` + * + `projects/{project_id}/sources/-/locations/[location_id]` + * @type string $filter + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * severity: `=`, `:` + * * security_marks.marks: `=`, `:` + * * resource: + * * resource.name: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.type: `=`, `:` + * @type string $group_by + * Required. Expression that defines what assets fields to use for grouping. + * The string value should follow SQL syntax: comma separated list of fields. + * For example: "parent,resource_name". + * @type string $page_token + * The value returned by the last `GroupFindingsResponse`; indicates + * that this is a continuation of a prior `GroupFindings` call, and + * that the system should return the next page of data. + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the source to groupBy. If no location is specified, + * finding is assumed to be in global. + * The following list shows some examples: + * + `organizations/[organization_id]/sources/[source_id]` + * + + * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` + * + `folders/[folder_id]/sources/[source_id]` + * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` + * + `projects/[project_id]/sources/[source_id]` + * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` + * To groupBy across all sources provide a source_id of `-`. The following + * list shows some examples: + * + `organizations/{organization_id}/sources/-` + * + `organizations/{organization_id}/sources/-/locations/[location_id]` + * + `folders/{folder_id}/sources/-` + * + `folders/{folder_id}/sources/-/locations/[location_id]` + * + `projects/{project_id}/sources/-` + * + `projects/{project_id}/sources/-/locations/[location_id]` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Name of the source to groupBy. If no location is specified, + * finding is assumed to be in global. + * The following list shows some examples: + * + `organizations/[organization_id]/sources/[source_id]` + * + + * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` + * + `folders/[folder_id]/sources/[source_id]` + * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` + * + `projects/[project_id]/sources/[source_id]` + * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` + * To groupBy across all sources provide a source_id of `-`. The following + * list shows some examples: + * + `organizations/{organization_id}/sources/-` + * + `organizations/{organization_id}/sources/-/locations/[location_id]` + * + `folders/{folder_id}/sources/-` + * + `folders/{folder_id}/sources/-/locations/[location_id]` + * + `projects/{project_id}/sources/-` + * + `projects/{project_id}/sources/-/locations/[location_id]` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * severity: `=`, `:` + * * security_marks.marks: `=`, `:` + * * resource: + * * resource.name: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.type: `=`, `:` + * + * Generated from protobuf field string filter = 2; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * severity: `=`, `:` + * * security_marks.marks: `=`, `:` + * * resource: + * * resource.name: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.type: `=`, `:` + * + * Generated from protobuf field string filter = 2; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * Required. Expression that defines what assets fields to use for grouping. + * The string value should follow SQL syntax: comma separated list of fields. + * For example: "parent,resource_name". + * + * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getGroupBy() + { + return $this->group_by; + } + + /** + * Required. Expression that defines what assets fields to use for grouping. + * The string value should follow SQL syntax: comma separated list of fields. + * For example: "parent,resource_name". + * + * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setGroupBy($var) + { + GPBUtil::checkString($var, True); + $this->group_by = $var; + + return $this; + } + + /** + * The value returned by the last `GroupFindingsResponse`; indicates + * that this is a continuation of a prior `GroupFindings` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 7; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last `GroupFindingsResponse`; indicates + * that this is a continuation of a prior `GroupFindings` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 7; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 8; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 8; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupFindingsResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupFindingsResponse.php new file mode 100644 index 000000000000..7a788afbb0c1 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupFindingsResponse.php @@ -0,0 +1,147 @@ +google.cloud.securitycenter.v2.GroupFindingsResponse + */ +class GroupFindingsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.GroupResult group_by_results = 1; + */ + private $group_by_results; + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + */ + protected $next_page_token = ''; + /** + * The total number of results matching the query. + * + * Generated from protobuf field int32 total_size = 4; + */ + protected $total_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V2\GroupResult>|\Google\Protobuf\Internal\RepeatedField $group_by_results + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * @type string $next_page_token + * Token to retrieve the next page of results, or empty if there are no more + * results. + * @type int $total_size + * The total number of results matching the query. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.GroupResult group_by_results = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getGroupByResults() + { + return $this->group_by_results; + } + + /** + * Group results. There exists an element for each existing unique + * combination of property/values. The element contains a count for the number + * of times those specific property/values appear. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.GroupResult group_by_results = 1; + * @param array<\Google\Cloud\SecurityCenter\V2\GroupResult>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setGroupByResults($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\GroupResult::class); + $this->group_by_results = $arr; + + return $this; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + + /** + * The total number of results matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @return int + */ + public function getTotalSize() + { + return $this->total_size; + } + + /** + * The total number of results matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @param int $var + * @return $this + */ + public function setTotalSize($var) + { + GPBUtil::checkInt32($var); + $this->total_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupMembership.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupMembership.php new file mode 100644 index 000000000000..0aa6e9447a72 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupMembership.php @@ -0,0 +1,102 @@ +google.cloud.securitycenter.v2.GroupMembership + */ +class GroupMembership extends \Google\Protobuf\Internal\Message +{ + /** + * Type of group. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.GroupMembership.GroupType group_type = 1; + */ + protected $group_type = 0; + /** + * ID of the group. + * + * Generated from protobuf field string group_id = 2; + */ + protected $group_id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $group_type + * Type of group. + * @type string $group_id + * ID of the group. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\GroupMembership::initOnce(); + parent::__construct($data); + } + + /** + * Type of group. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.GroupMembership.GroupType group_type = 1; + * @return int + */ + public function getGroupType() + { + return $this->group_type; + } + + /** + * Type of group. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.GroupMembership.GroupType group_type = 1; + * @param int $var + * @return $this + */ + public function setGroupType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\GroupMembership\GroupType::class); + $this->group_type = $var; + + return $this; + } + + /** + * ID of the group. + * + * Generated from protobuf field string group_id = 2; + * @return string + */ + public function getGroupId() + { + return $this->group_id; + } + + /** + * ID of the group. + * + * Generated from protobuf field string group_id = 2; + * @param string $var + * @return $this + */ + public function setGroupId($var) + { + GPBUtil::checkString($var, True); + $this->group_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupMembership/GroupType.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupMembership/GroupType.php new file mode 100644 index 000000000000..669e285de554 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupMembership/GroupType.php @@ -0,0 +1,57 @@ +google.cloud.securitycenter.v2.GroupMembership.GroupType + */ +class GroupType +{ + /** + * Default value. + * + * Generated from protobuf enum GROUP_TYPE_UNSPECIFIED = 0; + */ + const GROUP_TYPE_UNSPECIFIED = 0; + /** + * Group represents a toxic combination. + * + * Generated from protobuf enum GROUP_TYPE_TOXIC_COMBINATION = 1; + */ + const GROUP_TYPE_TOXIC_COMBINATION = 1; + + private static $valueToName = [ + self::GROUP_TYPE_UNSPECIFIED => 'GROUP_TYPE_UNSPECIFIED', + self::GROUP_TYPE_TOXIC_COMBINATION => 'GROUP_TYPE_TOXIC_COMBINATION', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(GroupType::class, \Google\Cloud\SecurityCenter\V2\GroupMembership_GroupType::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupResult.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupResult.php new file mode 100644 index 000000000000..967cde22d6ee --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupResult.php @@ -0,0 +1,101 @@ +google.cloud.securitycenter.v2.GroupResult + */ +class GroupResult extends \Google\Protobuf\Internal\Message +{ + /** + * Properties matching the groupBy fields in the request. + * + * Generated from protobuf field map properties = 1; + */ + private $properties; + /** + * Total count of resources for the given properties. + * + * Generated from protobuf field int64 count = 2; + */ + protected $count = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\MapField $properties + * Properties matching the groupBy fields in the request. + * @type int|string $count + * Total count of resources for the given properties. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Properties matching the groupBy fields in the request. + * + * Generated from protobuf field map properties = 1; + * @return \Google\Protobuf\Internal\MapField + */ + public function getProperties() + { + return $this->properties; + } + + /** + * Properties matching the groupBy fields in the request. + * + * Generated from protobuf field map properties = 1; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setProperties($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Value::class); + $this->properties = $arr; + + return $this; + } + + /** + * Total count of resources for the given properties. + * + * Generated from protobuf field int64 count = 2; + * @return int|string + */ + public function getCount() + { + return $this->count; + } + + /** + * Total count of resources for the given properties. + * + * Generated from protobuf field int64 count = 2; + * @param int|string $var + * @return $this + */ + public function setCount($var) + { + GPBUtil::checkInt64($var); + $this->count = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/IamBinding.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/IamBinding.php new file mode 100644 index 000000000000..ad104e3b8b40 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/IamBinding.php @@ -0,0 +1,144 @@ +google.cloud.securitycenter.v2.IamBinding + */ +class IamBinding extends \Google\Protobuf\Internal\Message +{ + /** + * The action that was performed on a Binding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.IamBinding.Action action = 1; + */ + protected $action = 0; + /** + * Role that is assigned to "members". + * For example, "roles/viewer", "roles/editor", or "roles/owner". + * + * Generated from protobuf field string role = 2; + */ + protected $role = ''; + /** + * A single identity requesting access for a Cloud Platform resource, for + * example, "foo@google.com". + * + * Generated from protobuf field string member = 3; + */ + protected $member = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $action + * The action that was performed on a Binding. + * @type string $role + * Role that is assigned to "members". + * For example, "roles/viewer", "roles/editor", or "roles/owner". + * @type string $member + * A single identity requesting access for a Cloud Platform resource, for + * example, "foo@google.com". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\IamBinding::initOnce(); + parent::__construct($data); + } + + /** + * The action that was performed on a Binding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.IamBinding.Action action = 1; + * @return int + */ + public function getAction() + { + return $this->action; + } + + /** + * The action that was performed on a Binding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.IamBinding.Action action = 1; + * @param int $var + * @return $this + */ + public function setAction($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\IamBinding\Action::class); + $this->action = $var; + + return $this; + } + + /** + * Role that is assigned to "members". + * For example, "roles/viewer", "roles/editor", or "roles/owner". + * + * Generated from protobuf field string role = 2; + * @return string + */ + public function getRole() + { + return $this->role; + } + + /** + * Role that is assigned to "members". + * For example, "roles/viewer", "roles/editor", or "roles/owner". + * + * Generated from protobuf field string role = 2; + * @param string $var + * @return $this + */ + public function setRole($var) + { + GPBUtil::checkString($var, True); + $this->role = $var; + + return $this; + } + + /** + * A single identity requesting access for a Cloud Platform resource, for + * example, "foo@google.com". + * + * Generated from protobuf field string member = 3; + * @return string + */ + public function getMember() + { + return $this->member; + } + + /** + * A single identity requesting access for a Cloud Platform resource, for + * example, "foo@google.com". + * + * Generated from protobuf field string member = 3; + * @param string $var + * @return $this + */ + public function setMember($var) + { + GPBUtil::checkString($var, True); + $this->member = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/IamBinding/Action.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/IamBinding/Action.php new file mode 100644 index 000000000000..a202e95ac477 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/IamBinding/Action.php @@ -0,0 +1,64 @@ +google.cloud.securitycenter.v2.IamBinding.Action + */ +class Action +{ + /** + * Unspecified. + * + * Generated from protobuf enum ACTION_UNSPECIFIED = 0; + */ + const ACTION_UNSPECIFIED = 0; + /** + * Addition of a Binding. + * + * Generated from protobuf enum ADD = 1; + */ + const ADD = 1; + /** + * Removal of a Binding. + * + * Generated from protobuf enum REMOVE = 2; + */ + const REMOVE = 2; + + private static $valueToName = [ + self::ACTION_UNSPECIFIED => 'ACTION_UNSPECIFIED', + self::ADD => 'ADD', + self::REMOVE => 'REMOVE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Action::class, \Google\Cloud\SecurityCenter\V2\IamBinding_Action::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator.php new file mode 100644 index 000000000000..cee7a882ad65 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator.php @@ -0,0 +1,177 @@ +google.cloud.securitycenter.v2.Indicator + */ +class Indicator extends \Google\Protobuf\Internal\Message +{ + /** + * The list of IP addresses that are associated with the finding. + * + * Generated from protobuf field repeated string ip_addresses = 1; + */ + private $ip_addresses; + /** + * List of domains associated to the Finding. + * + * Generated from protobuf field repeated string domains = 2; + */ + private $domains; + /** + * The list of matched signatures indicating that the given + * process is present in the environment. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Indicator.ProcessSignature signatures = 3; + */ + private $signatures; + /** + * The list of URIs associated to the Findings. + * + * Generated from protobuf field repeated string uris = 4; + */ + private $uris; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\RepeatedField $ip_addresses + * The list of IP addresses that are associated with the finding. + * @type array|\Google\Protobuf\Internal\RepeatedField $domains + * List of domains associated to the Finding. + * @type array<\Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature>|\Google\Protobuf\Internal\RepeatedField $signatures + * The list of matched signatures indicating that the given + * process is present in the environment. + * @type array|\Google\Protobuf\Internal\RepeatedField $uris + * The list of URIs associated to the Findings. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Indicator::initOnce(); + parent::__construct($data); + } + + /** + * The list of IP addresses that are associated with the finding. + * + * Generated from protobuf field repeated string ip_addresses = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getIpAddresses() + { + return $this->ip_addresses; + } + + /** + * The list of IP addresses that are associated with the finding. + * + * Generated from protobuf field repeated string ip_addresses = 1; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setIpAddresses($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->ip_addresses = $arr; + + return $this; + } + + /** + * List of domains associated to the Finding. + * + * Generated from protobuf field repeated string domains = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDomains() + { + return $this->domains; + } + + /** + * List of domains associated to the Finding. + * + * Generated from protobuf field repeated string domains = 2; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDomains($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->domains = $arr; + + return $this; + } + + /** + * The list of matched signatures indicating that the given + * process is present in the environment. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Indicator.ProcessSignature signatures = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSignatures() + { + return $this->signatures; + } + + /** + * The list of matched signatures indicating that the given + * process is present in the environment. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Indicator.ProcessSignature signatures = 3; + * @param array<\Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSignatures($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature::class); + $this->signatures = $arr; + + return $this; + } + + /** + * The list of URIs associated to the Findings. + * + * Generated from protobuf field repeated string uris = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getUris() + { + return $this->uris; + } + + /** + * The list of URIs associated to the Findings. + * + * Generated from protobuf field repeated string uris = 4; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setUris($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->uris = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature.php new file mode 100644 index 000000000000..8841ee7d687f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature.php @@ -0,0 +1,145 @@ +google.cloud.securitycenter.v2.Indicator.ProcessSignature + */ +class ProcessSignature extends \Google\Protobuf\Internal\Message +{ + /** + * Describes the type of resource associated with the signature. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator.ProcessSignature.SignatureType signature_type = 8; + */ + protected $signature_type = 0; + protected $signature; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\MemoryHashSignature $memory_hash_signature + * Signature indicating that a binary family was matched. + * @type \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\YaraRuleSignature $yara_rule_signature + * Signature indicating that a YARA rule was matched. + * @type int $signature_type + * Describes the type of resource associated with the signature. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Indicator::initOnce(); + parent::__construct($data); + } + + /** + * Signature indicating that a binary family was matched. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator.ProcessSignature.MemoryHashSignature memory_hash_signature = 6; + * @return \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\MemoryHashSignature|null + */ + public function getMemoryHashSignature() + { + return $this->readOneof(6); + } + + public function hasMemoryHashSignature() + { + return $this->hasOneof(6); + } + + /** + * Signature indicating that a binary family was matched. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator.ProcessSignature.MemoryHashSignature memory_hash_signature = 6; + * @param \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\MemoryHashSignature $var + * @return $this + */ + public function setMemoryHashSignature($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\MemoryHashSignature::class); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * Signature indicating that a YARA rule was matched. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator.ProcessSignature.YaraRuleSignature yara_rule_signature = 7; + * @return \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\YaraRuleSignature|null + */ + public function getYaraRuleSignature() + { + return $this->readOneof(7); + } + + public function hasYaraRuleSignature() + { + return $this->hasOneof(7); + } + + /** + * Signature indicating that a YARA rule was matched. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator.ProcessSignature.YaraRuleSignature yara_rule_signature = 7; + * @param \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\YaraRuleSignature $var + * @return $this + */ + public function setYaraRuleSignature($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\YaraRuleSignature::class); + $this->writeOneof(7, $var); + + return $this; + } + + /** + * Describes the type of resource associated with the signature. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator.ProcessSignature.SignatureType signature_type = 8; + * @return int + */ + public function getSignatureType() + { + return $this->signature_type; + } + + /** + * Describes the type of resource associated with the signature. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator.ProcessSignature.SignatureType signature_type = 8; + * @param int $var + * @return $this + */ + public function setSignatureType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\SignatureType::class); + $this->signature_type = $var; + + return $this; + } + + /** + * @return string + */ + public function getSignature() + { + return $this->whichOneof("signature"); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ProcessSignature::class, \Google\Cloud\SecurityCenter\V2\Indicator_ProcessSignature::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/MemoryHashSignature.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/MemoryHashSignature.php new file mode 100644 index 000000000000..ca33f9a35908 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/MemoryHashSignature.php @@ -0,0 +1,108 @@ +google.cloud.securitycenter.v2.Indicator.ProcessSignature.MemoryHashSignature + */ +class MemoryHashSignature extends \Google\Protobuf\Internal\Message +{ + /** + * The binary family. + * + * Generated from protobuf field string binary_family = 1; + */ + protected $binary_family = ''; + /** + * The list of memory hash detections contributing to the binary family + * match. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Indicator.ProcessSignature.MemoryHashSignature.Detection detections = 4; + */ + private $detections; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $binary_family + * The binary family. + * @type array<\Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\MemoryHashSignature\Detection>|\Google\Protobuf\Internal\RepeatedField $detections + * The list of memory hash detections contributing to the binary family + * match. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Indicator::initOnce(); + parent::__construct($data); + } + + /** + * The binary family. + * + * Generated from protobuf field string binary_family = 1; + * @return string + */ + public function getBinaryFamily() + { + return $this->binary_family; + } + + /** + * The binary family. + * + * Generated from protobuf field string binary_family = 1; + * @param string $var + * @return $this + */ + public function setBinaryFamily($var) + { + GPBUtil::checkString($var, True); + $this->binary_family = $var; + + return $this; + } + + /** + * The list of memory hash detections contributing to the binary family + * match. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Indicator.ProcessSignature.MemoryHashSignature.Detection detections = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getDetections() + { + return $this->detections; + } + + /** + * The list of memory hash detections contributing to the binary family + * match. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Indicator.ProcessSignature.MemoryHashSignature.Detection detections = 4; + * @param array<\Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\MemoryHashSignature\Detection>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setDetections($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\MemoryHashSignature\Detection::class); + $this->detections = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(MemoryHashSignature::class, \Google\Cloud\SecurityCenter\V2\Indicator_ProcessSignature_MemoryHashSignature::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/MemoryHashSignature/Detection.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/MemoryHashSignature/Detection.php new file mode 100644 index 000000000000..a5a19cc0677f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/MemoryHashSignature/Detection.php @@ -0,0 +1,112 @@ +google.cloud.securitycenter.v2.Indicator.ProcessSignature.MemoryHashSignature.Detection + */ +class Detection extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the binary associated with the memory hash + * signature detection. + * + * Generated from protobuf field string binary = 2; + */ + protected $binary = ''; + /** + * The percentage of memory page hashes in the signature + * that were matched. + * + * Generated from protobuf field double percent_pages_matched = 3; + */ + protected $percent_pages_matched = 0.0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $binary + * The name of the binary associated with the memory hash + * signature detection. + * @type float $percent_pages_matched + * The percentage of memory page hashes in the signature + * that were matched. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Indicator::initOnce(); + parent::__construct($data); + } + + /** + * The name of the binary associated with the memory hash + * signature detection. + * + * Generated from protobuf field string binary = 2; + * @return string + */ + public function getBinary() + { + return $this->binary; + } + + /** + * The name of the binary associated with the memory hash + * signature detection. + * + * Generated from protobuf field string binary = 2; + * @param string $var + * @return $this + */ + public function setBinary($var) + { + GPBUtil::checkString($var, True); + $this->binary = $var; + + return $this; + } + + /** + * The percentage of memory page hashes in the signature + * that were matched. + * + * Generated from protobuf field double percent_pages_matched = 3; + * @return float + */ + public function getPercentPagesMatched() + { + return $this->percent_pages_matched; + } + + /** + * The percentage of memory page hashes in the signature + * that were matched. + * + * Generated from protobuf field double percent_pages_matched = 3; + * @param float $var + * @return $this + */ + public function setPercentPagesMatched($var) + { + GPBUtil::checkDouble($var); + $this->percent_pages_matched = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Detection::class, \Google\Cloud\SecurityCenter\V2\Indicator_ProcessSignature_MemoryHashSignature_Detection::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/SignatureType.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/SignatureType.php new file mode 100644 index 000000000000..ff34fb5649f8 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/SignatureType.php @@ -0,0 +1,64 @@ +google.cloud.securitycenter.v2.Indicator.ProcessSignature.SignatureType + */ +class SignatureType +{ + /** + * The default signature type. + * + * Generated from protobuf enum SIGNATURE_TYPE_UNSPECIFIED = 0; + */ + const SIGNATURE_TYPE_UNSPECIFIED = 0; + /** + * Used for signatures concerning processes. + * + * Generated from protobuf enum SIGNATURE_TYPE_PROCESS = 1; + */ + const SIGNATURE_TYPE_PROCESS = 1; + /** + * Used for signatures concerning disks. + * + * Generated from protobuf enum SIGNATURE_TYPE_FILE = 2; + */ + const SIGNATURE_TYPE_FILE = 2; + + private static $valueToName = [ + self::SIGNATURE_TYPE_UNSPECIFIED => 'SIGNATURE_TYPE_UNSPECIFIED', + self::SIGNATURE_TYPE_PROCESS => 'SIGNATURE_TYPE_PROCESS', + self::SIGNATURE_TYPE_FILE => 'SIGNATURE_TYPE_FILE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SignatureType::class, \Google\Cloud\SecurityCenter\V2\Indicator_ProcessSignature_SignatureType::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/YaraRuleSignature.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/YaraRuleSignature.php new file mode 100644 index 000000000000..61aa230b37b4 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/YaraRuleSignature.php @@ -0,0 +1,70 @@ +google.cloud.securitycenter.v2.Indicator.ProcessSignature.YaraRuleSignature + */ +class YaraRuleSignature extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the YARA rule. + * + * Generated from protobuf field string yara_rule = 5; + */ + protected $yara_rule = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $yara_rule + * The name of the YARA rule. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Indicator::initOnce(); + parent::__construct($data); + } + + /** + * The name of the YARA rule. + * + * Generated from protobuf field string yara_rule = 5; + * @return string + */ + public function getYaraRule() + { + return $this->yara_rule; + } + + /** + * The name of the YARA rule. + * + * Generated from protobuf field string yara_rule = 5; + * @param string $var + * @return $this + */ + public function setYaraRule($var) + { + GPBUtil::checkString($var, True); + $this->yara_rule = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(YaraRuleSignature::class, \Google\Cloud\SecurityCenter\V2\Indicator_ProcessSignature_YaraRuleSignature::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/KernelRootkit.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/KernelRootkit.php new file mode 100644 index 000000000000..55a43f4ea22f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/KernelRootkit.php @@ -0,0 +1,367 @@ +google.cloud.securitycenter.v2.KernelRootkit + */ +class KernelRootkit extends \Google\Protobuf\Internal\Message +{ + /** + * Rootkit name, when available. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * True if unexpected modifications of kernel code memory are present. + * + * Generated from protobuf field bool unexpected_code_modification = 2; + */ + protected $unexpected_code_modification = false; + /** + * True if unexpected modifications of kernel read-only data memory are + * present. + * + * Generated from protobuf field bool unexpected_read_only_data_modification = 3; + */ + protected $unexpected_read_only_data_modification = false; + /** + * True if `ftrace` points are present with callbacks pointing to regions + * that are not in the expected kernel or module code range. + * + * Generated from protobuf field bool unexpected_ftrace_handler = 4; + */ + protected $unexpected_ftrace_handler = false; + /** + * True if `kprobe` points are present with callbacks pointing to regions + * that are not in the expected kernel or module code range. + * + * Generated from protobuf field bool unexpected_kprobe_handler = 5; + */ + protected $unexpected_kprobe_handler = false; + /** + * True if kernel code pages that are not in the expected kernel or module + * code regions are present. + * + * Generated from protobuf field bool unexpected_kernel_code_pages = 6; + */ + protected $unexpected_kernel_code_pages = false; + /** + * True if system call handlers that are are not in the expected kernel or + * module code regions are present. + * + * Generated from protobuf field bool unexpected_system_call_handler = 7; + */ + protected $unexpected_system_call_handler = false; + /** + * True if interrupt handlers that are are not in the expected kernel or + * module code regions are present. + * + * Generated from protobuf field bool unexpected_interrupt_handler = 8; + */ + protected $unexpected_interrupt_handler = false; + /** + * True if unexpected processes in the scheduler run queue are present. Such + * processes are in the run queue, but not in the process task list. + * + * Generated from protobuf field bool unexpected_processes_in_runqueue = 9; + */ + protected $unexpected_processes_in_runqueue = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Rootkit name, when available. + * @type bool $unexpected_code_modification + * True if unexpected modifications of kernel code memory are present. + * @type bool $unexpected_read_only_data_modification + * True if unexpected modifications of kernel read-only data memory are + * present. + * @type bool $unexpected_ftrace_handler + * True if `ftrace` points are present with callbacks pointing to regions + * that are not in the expected kernel or module code range. + * @type bool $unexpected_kprobe_handler + * True if `kprobe` points are present with callbacks pointing to regions + * that are not in the expected kernel or module code range. + * @type bool $unexpected_kernel_code_pages + * True if kernel code pages that are not in the expected kernel or module + * code regions are present. + * @type bool $unexpected_system_call_handler + * True if system call handlers that are are not in the expected kernel or + * module code regions are present. + * @type bool $unexpected_interrupt_handler + * True if interrupt handlers that are are not in the expected kernel or + * module code regions are present. + * @type bool $unexpected_processes_in_runqueue + * True if unexpected processes in the scheduler run queue are present. Such + * processes are in the run queue, but not in the process task list. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\KernelRootkit::initOnce(); + parent::__construct($data); + } + + /** + * Rootkit name, when available. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Rootkit name, when available. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * True if unexpected modifications of kernel code memory are present. + * + * Generated from protobuf field bool unexpected_code_modification = 2; + * @return bool + */ + public function getUnexpectedCodeModification() + { + return $this->unexpected_code_modification; + } + + /** + * True if unexpected modifications of kernel code memory are present. + * + * Generated from protobuf field bool unexpected_code_modification = 2; + * @param bool $var + * @return $this + */ + public function setUnexpectedCodeModification($var) + { + GPBUtil::checkBool($var); + $this->unexpected_code_modification = $var; + + return $this; + } + + /** + * True if unexpected modifications of kernel read-only data memory are + * present. + * + * Generated from protobuf field bool unexpected_read_only_data_modification = 3; + * @return bool + */ + public function getUnexpectedReadOnlyDataModification() + { + return $this->unexpected_read_only_data_modification; + } + + /** + * True if unexpected modifications of kernel read-only data memory are + * present. + * + * Generated from protobuf field bool unexpected_read_only_data_modification = 3; + * @param bool $var + * @return $this + */ + public function setUnexpectedReadOnlyDataModification($var) + { + GPBUtil::checkBool($var); + $this->unexpected_read_only_data_modification = $var; + + return $this; + } + + /** + * True if `ftrace` points are present with callbacks pointing to regions + * that are not in the expected kernel or module code range. + * + * Generated from protobuf field bool unexpected_ftrace_handler = 4; + * @return bool + */ + public function getUnexpectedFtraceHandler() + { + return $this->unexpected_ftrace_handler; + } + + /** + * True if `ftrace` points are present with callbacks pointing to regions + * that are not in the expected kernel or module code range. + * + * Generated from protobuf field bool unexpected_ftrace_handler = 4; + * @param bool $var + * @return $this + */ + public function setUnexpectedFtraceHandler($var) + { + GPBUtil::checkBool($var); + $this->unexpected_ftrace_handler = $var; + + return $this; + } + + /** + * True if `kprobe` points are present with callbacks pointing to regions + * that are not in the expected kernel or module code range. + * + * Generated from protobuf field bool unexpected_kprobe_handler = 5; + * @return bool + */ + public function getUnexpectedKprobeHandler() + { + return $this->unexpected_kprobe_handler; + } + + /** + * True if `kprobe` points are present with callbacks pointing to regions + * that are not in the expected kernel or module code range. + * + * Generated from protobuf field bool unexpected_kprobe_handler = 5; + * @param bool $var + * @return $this + */ + public function setUnexpectedKprobeHandler($var) + { + GPBUtil::checkBool($var); + $this->unexpected_kprobe_handler = $var; + + return $this; + } + + /** + * True if kernel code pages that are not in the expected kernel or module + * code regions are present. + * + * Generated from protobuf field bool unexpected_kernel_code_pages = 6; + * @return bool + */ + public function getUnexpectedKernelCodePages() + { + return $this->unexpected_kernel_code_pages; + } + + /** + * True if kernel code pages that are not in the expected kernel or module + * code regions are present. + * + * Generated from protobuf field bool unexpected_kernel_code_pages = 6; + * @param bool $var + * @return $this + */ + public function setUnexpectedKernelCodePages($var) + { + GPBUtil::checkBool($var); + $this->unexpected_kernel_code_pages = $var; + + return $this; + } + + /** + * True if system call handlers that are are not in the expected kernel or + * module code regions are present. + * + * Generated from protobuf field bool unexpected_system_call_handler = 7; + * @return bool + */ + public function getUnexpectedSystemCallHandler() + { + return $this->unexpected_system_call_handler; + } + + /** + * True if system call handlers that are are not in the expected kernel or + * module code regions are present. + * + * Generated from protobuf field bool unexpected_system_call_handler = 7; + * @param bool $var + * @return $this + */ + public function setUnexpectedSystemCallHandler($var) + { + GPBUtil::checkBool($var); + $this->unexpected_system_call_handler = $var; + + return $this; + } + + /** + * True if interrupt handlers that are are not in the expected kernel or + * module code regions are present. + * + * Generated from protobuf field bool unexpected_interrupt_handler = 8; + * @return bool + */ + public function getUnexpectedInterruptHandler() + { + return $this->unexpected_interrupt_handler; + } + + /** + * True if interrupt handlers that are are not in the expected kernel or + * module code regions are present. + * + * Generated from protobuf field bool unexpected_interrupt_handler = 8; + * @param bool $var + * @return $this + */ + public function setUnexpectedInterruptHandler($var) + { + GPBUtil::checkBool($var); + $this->unexpected_interrupt_handler = $var; + + return $this; + } + + /** + * True if unexpected processes in the scheduler run queue are present. Such + * processes are in the run queue, but not in the process task list. + * + * Generated from protobuf field bool unexpected_processes_in_runqueue = 9; + * @return bool + */ + public function getUnexpectedProcessesInRunqueue() + { + return $this->unexpected_processes_in_runqueue; + } + + /** + * True if unexpected processes in the scheduler run queue are present. Such + * processes are in the run queue, but not in the process task list. + * + * Generated from protobuf field bool unexpected_processes_in_runqueue = 9; + * @param bool $var + * @return $this + */ + public function setUnexpectedProcessesInRunqueue($var) + { + GPBUtil::checkBool($var); + $this->unexpected_processes_in_runqueue = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes.php new file mode 100644 index 000000000000..29312fe40a92 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes.php @@ -0,0 +1,319 @@ +google.cloud.securitycenter.v2.Kubernetes + */ +class Kubernetes extends \Google\Protobuf\Internal\Message +{ + /** + * Kubernetes + * [Pods](https://cloud.google.com/kubernetes-engine/docs/concepts/pod) + * associated with the finding. This field contains Pod records for each + * container that is owned by a Pod. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Pod pods = 1; + */ + private $pods; + /** + * Provides Kubernetes + * [node](https://cloud.google.com/kubernetes-engine/docs/concepts/cluster-architecture#nodes) + * information. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Node nodes = 2; + */ + private $nodes; + /** + * GKE [node + * pools](https://cloud.google.com/kubernetes-engine/docs/concepts/node-pools) + * associated with the finding. This field contains node pool information for + * each node, when it is available. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.NodePool node_pools = 3; + */ + private $node_pools; + /** + * Provides Kubernetes role information for findings that involve [Roles or + * ClusterRoles](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Role roles = 4; + */ + private $roles; + /** + * Provides Kubernetes role binding information for findings that involve + * [RoleBindings or + * ClusterRoleBindings](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Binding bindings = 5; + */ + private $bindings; + /** + * Provides information on any Kubernetes access reviews (privilege checks) + * relevant to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.AccessReview access_reviews = 6; + */ + private $access_reviews; + /** + * Kubernetes objects related to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Object objects = 7; + */ + private $objects; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Pod>|\Google\Protobuf\Internal\RepeatedField $pods + * Kubernetes + * [Pods](https://cloud.google.com/kubernetes-engine/docs/concepts/pod) + * associated with the finding. This field contains Pod records for each + * container that is owned by a Pod. + * @type array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Node>|\Google\Protobuf\Internal\RepeatedField $nodes + * Provides Kubernetes + * [node](https://cloud.google.com/kubernetes-engine/docs/concepts/cluster-architecture#nodes) + * information. + * @type array<\Google\Cloud\SecurityCenter\V2\Kubernetes\NodePool>|\Google\Protobuf\Internal\RepeatedField $node_pools + * GKE [node + * pools](https://cloud.google.com/kubernetes-engine/docs/concepts/node-pools) + * associated with the finding. This field contains node pool information for + * each node, when it is available. + * @type array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Role>|\Google\Protobuf\Internal\RepeatedField $roles + * Provides Kubernetes role information for findings that involve [Roles or + * ClusterRoles](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). + * @type array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Binding>|\Google\Protobuf\Internal\RepeatedField $bindings + * Provides Kubernetes role binding information for findings that involve + * [RoleBindings or + * ClusterRoleBindings](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). + * @type array<\Google\Cloud\SecurityCenter\V2\Kubernetes\AccessReview>|\Google\Protobuf\Internal\RepeatedField $access_reviews + * Provides information on any Kubernetes access reviews (privilege checks) + * relevant to the finding. + * @type array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Object>|\Google\Protobuf\Internal\RepeatedField $objects + * Kubernetes objects related to the finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Kubernetes::initOnce(); + parent::__construct($data); + } + + /** + * Kubernetes + * [Pods](https://cloud.google.com/kubernetes-engine/docs/concepts/pod) + * associated with the finding. This field contains Pod records for each + * container that is owned by a Pod. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Pod pods = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPods() + { + return $this->pods; + } + + /** + * Kubernetes + * [Pods](https://cloud.google.com/kubernetes-engine/docs/concepts/pod) + * associated with the finding. This field contains Pod records for each + * container that is owned by a Pod. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Pod pods = 1; + * @param array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Pod>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPods($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Kubernetes\Pod::class); + $this->pods = $arr; + + return $this; + } + + /** + * Provides Kubernetes + * [node](https://cloud.google.com/kubernetes-engine/docs/concepts/cluster-architecture#nodes) + * information. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Node nodes = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getNodes() + { + return $this->nodes; + } + + /** + * Provides Kubernetes + * [node](https://cloud.google.com/kubernetes-engine/docs/concepts/cluster-architecture#nodes) + * information. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Node nodes = 2; + * @param array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Node>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setNodes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Kubernetes\Node::class); + $this->nodes = $arr; + + return $this; + } + + /** + * GKE [node + * pools](https://cloud.google.com/kubernetes-engine/docs/concepts/node-pools) + * associated with the finding. This field contains node pool information for + * each node, when it is available. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.NodePool node_pools = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getNodePools() + { + return $this->node_pools; + } + + /** + * GKE [node + * pools](https://cloud.google.com/kubernetes-engine/docs/concepts/node-pools) + * associated with the finding. This field contains node pool information for + * each node, when it is available. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.NodePool node_pools = 3; + * @param array<\Google\Cloud\SecurityCenter\V2\Kubernetes\NodePool>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setNodePools($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Kubernetes\NodePool::class); + $this->node_pools = $arr; + + return $this; + } + + /** + * Provides Kubernetes role information for findings that involve [Roles or + * ClusterRoles](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Role roles = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRoles() + { + return $this->roles; + } + + /** + * Provides Kubernetes role information for findings that involve [Roles or + * ClusterRoles](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Role roles = 4; + * @param array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Role>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRoles($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Kubernetes\Role::class); + $this->roles = $arr; + + return $this; + } + + /** + * Provides Kubernetes role binding information for findings that involve + * [RoleBindings or + * ClusterRoleBindings](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Binding bindings = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getBindings() + { + return $this->bindings; + } + + /** + * Provides Kubernetes role binding information for findings that involve + * [RoleBindings or + * ClusterRoleBindings](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Binding bindings = 5; + * @param array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Binding>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setBindings($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Kubernetes\Binding::class); + $this->bindings = $arr; + + return $this; + } + + /** + * Provides information on any Kubernetes access reviews (privilege checks) + * relevant to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.AccessReview access_reviews = 6; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAccessReviews() + { + return $this->access_reviews; + } + + /** + * Provides information on any Kubernetes access reviews (privilege checks) + * relevant to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.AccessReview access_reviews = 6; + * @param array<\Google\Cloud\SecurityCenter\V2\Kubernetes\AccessReview>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAccessReviews($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Kubernetes\AccessReview::class); + $this->access_reviews = $arr; + + return $this; + } + + /** + * Kubernetes objects related to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Object objects = 7; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getObjects() + { + return $this->objects; + } + + /** + * Kubernetes objects related to the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Object objects = 7; + * @param array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Object>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setObjects($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Kubernetes\Object::class); + $this->objects = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/AccessReview.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/AccessReview.php new file mode 100644 index 000000000000..5619df16fb08 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/AccessReview.php @@ -0,0 +1,289 @@ +google.cloud.securitycenter.v2.Kubernetes.AccessReview + */ +class AccessReview extends \Google\Protobuf\Internal\Message +{ + /** + * The API group of the resource. "*" means all. + * + * Generated from protobuf field string group = 1; + */ + protected $group = ''; + /** + * Namespace of the action being requested. Currently, there is no + * distinction between no namespace and all namespaces. Both + * are represented by "" (empty). + * + * Generated from protobuf field string ns = 2; + */ + protected $ns = ''; + /** + * The name of the resource being requested. Empty means all. + * + * Generated from protobuf field string name = 3; + */ + protected $name = ''; + /** + * The optional resource type requested. "*" means all. + * + * Generated from protobuf field string resource = 4; + */ + protected $resource = ''; + /** + * The optional subresource type. + * + * Generated from protobuf field string subresource = 5; + */ + protected $subresource = ''; + /** + * A Kubernetes resource API verb, like get, list, watch, create, update, + * delete, proxy. "*" means all. + * + * Generated from protobuf field string verb = 6; + */ + protected $verb = ''; + /** + * The API version of the resource. "*" means all. + * + * Generated from protobuf field string version = 7; + */ + protected $version = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $group + * The API group of the resource. "*" means all. + * @type string $ns + * Namespace of the action being requested. Currently, there is no + * distinction between no namespace and all namespaces. Both + * are represented by "" (empty). + * @type string $name + * The name of the resource being requested. Empty means all. + * @type string $resource + * The optional resource type requested. "*" means all. + * @type string $subresource + * The optional subresource type. + * @type string $verb + * A Kubernetes resource API verb, like get, list, watch, create, update, + * delete, proxy. "*" means all. + * @type string $version + * The API version of the resource. "*" means all. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Kubernetes::initOnce(); + parent::__construct($data); + } + + /** + * The API group of the resource. "*" means all. + * + * Generated from protobuf field string group = 1; + * @return string + */ + public function getGroup() + { + return $this->group; + } + + /** + * The API group of the resource. "*" means all. + * + * Generated from protobuf field string group = 1; + * @param string $var + * @return $this + */ + public function setGroup($var) + { + GPBUtil::checkString($var, True); + $this->group = $var; + + return $this; + } + + /** + * Namespace of the action being requested. Currently, there is no + * distinction between no namespace and all namespaces. Both + * are represented by "" (empty). + * + * Generated from protobuf field string ns = 2; + * @return string + */ + public function getNs() + { + return $this->ns; + } + + /** + * Namespace of the action being requested. Currently, there is no + * distinction between no namespace and all namespaces. Both + * are represented by "" (empty). + * + * Generated from protobuf field string ns = 2; + * @param string $var + * @return $this + */ + public function setNs($var) + { + GPBUtil::checkString($var, True); + $this->ns = $var; + + return $this; + } + + /** + * The name of the resource being requested. Empty means all. + * + * Generated from protobuf field string name = 3; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the resource being requested. Empty means all. + * + * Generated from protobuf field string name = 3; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The optional resource type requested. "*" means all. + * + * Generated from protobuf field string resource = 4; + * @return string + */ + public function getResource() + { + return $this->resource; + } + + /** + * The optional resource type requested. "*" means all. + * + * Generated from protobuf field string resource = 4; + * @param string $var + * @return $this + */ + public function setResource($var) + { + GPBUtil::checkString($var, True); + $this->resource = $var; + + return $this; + } + + /** + * The optional subresource type. + * + * Generated from protobuf field string subresource = 5; + * @return string + */ + public function getSubresource() + { + return $this->subresource; + } + + /** + * The optional subresource type. + * + * Generated from protobuf field string subresource = 5; + * @param string $var + * @return $this + */ + public function setSubresource($var) + { + GPBUtil::checkString($var, True); + $this->subresource = $var; + + return $this; + } + + /** + * A Kubernetes resource API verb, like get, list, watch, create, update, + * delete, proxy. "*" means all. + * + * Generated from protobuf field string verb = 6; + * @return string + */ + public function getVerb() + { + return $this->verb; + } + + /** + * A Kubernetes resource API verb, like get, list, watch, create, update, + * delete, proxy. "*" means all. + * + * Generated from protobuf field string verb = 6; + * @param string $var + * @return $this + */ + public function setVerb($var) + { + GPBUtil::checkString($var, True); + $this->verb = $var; + + return $this; + } + + /** + * The API version of the resource. "*" means all. + * + * Generated from protobuf field string version = 7; + * @return string + */ + public function getVersion() + { + return $this->version; + } + + /** + * The API version of the resource. "*" means all. + * + * Generated from protobuf field string version = 7; + * @param string $var + * @return $this + */ + public function setVersion($var) + { + GPBUtil::checkString($var, True); + $this->version = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AccessReview::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_AccessReview::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Binding.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Binding.php new file mode 100644 index 000000000000..c6ad46478d48 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Binding.php @@ -0,0 +1,186 @@ +google.cloud.securitycenter.v2.Kubernetes.Binding + */ +class Binding extends \Google\Protobuf\Internal\Message +{ + /** + * Namespace for the binding. + * + * Generated from protobuf field string ns = 1; + */ + protected $ns = ''; + /** + * Name for the binding. + * + * Generated from protobuf field string name = 2; + */ + protected $name = ''; + /** + * The Role or ClusterRole referenced by the binding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes.Role role = 3; + */ + protected $role = null; + /** + * Represents one or more subjects that are bound to the role. Not always + * available for PATCH requests. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Subject subjects = 4; + */ + private $subjects; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $ns + * Namespace for the binding. + * @type string $name + * Name for the binding. + * @type \Google\Cloud\SecurityCenter\V2\Kubernetes\Role $role + * The Role or ClusterRole referenced by the binding. + * @type array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Subject>|\Google\Protobuf\Internal\RepeatedField $subjects + * Represents one or more subjects that are bound to the role. Not always + * available for PATCH requests. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Kubernetes::initOnce(); + parent::__construct($data); + } + + /** + * Namespace for the binding. + * + * Generated from protobuf field string ns = 1; + * @return string + */ + public function getNs() + { + return $this->ns; + } + + /** + * Namespace for the binding. + * + * Generated from protobuf field string ns = 1; + * @param string $var + * @return $this + */ + public function setNs($var) + { + GPBUtil::checkString($var, True); + $this->ns = $var; + + return $this; + } + + /** + * Name for the binding. + * + * Generated from protobuf field string name = 2; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Name for the binding. + * + * Generated from protobuf field string name = 2; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The Role or ClusterRole referenced by the binding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes.Role role = 3; + * @return \Google\Cloud\SecurityCenter\V2\Kubernetes\Role|null + */ + public function getRole() + { + return $this->role; + } + + public function hasRole() + { + return isset($this->role); + } + + public function clearRole() + { + unset($this->role); + } + + /** + * The Role or ClusterRole referenced by the binding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes.Role role = 3; + * @param \Google\Cloud\SecurityCenter\V2\Kubernetes\Role $var + * @return $this + */ + public function setRole($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Kubernetes\Role::class); + $this->role = $var; + + return $this; + } + + /** + * Represents one or more subjects that are bound to the role. Not always + * available for PATCH requests. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Subject subjects = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSubjects() + { + return $this->subjects; + } + + /** + * Represents one or more subjects that are bound to the role. Not always + * available for PATCH requests. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Subject subjects = 4; + * @param array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Subject>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSubjects($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Kubernetes\Subject::class); + $this->subjects = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Binding::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_Binding::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Node.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Node.php new file mode 100644 index 000000000000..ec42e14203a0 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Node.php @@ -0,0 +1,74 @@ +google.cloud.securitycenter.v2.Kubernetes.Node + */ +class Node extends \Google\Protobuf\Internal\Message +{ + /** + * [Full resource name](https://google.aip.dev/122#full-resource-names) of + * the Compute Engine VM running the cluster node. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * [Full resource name](https://google.aip.dev/122#full-resource-names) of + * the Compute Engine VM running the cluster node. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Kubernetes::initOnce(); + parent::__construct($data); + } + + /** + * [Full resource name](https://google.aip.dev/122#full-resource-names) of + * the Compute Engine VM running the cluster node. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * [Full resource name](https://google.aip.dev/122#full-resource-names) of + * the Compute Engine VM running the cluster node. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Node::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_Node::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/NodePool.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/NodePool.php new file mode 100644 index 000000000000..fe5da418e6ce --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/NodePool.php @@ -0,0 +1,104 @@ +google.cloud.securitycenter.v2.Kubernetes.NodePool + */ +class NodePool extends \Google\Protobuf\Internal\Message +{ + /** + * Kubernetes node pool name. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Nodes associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Node nodes = 2; + */ + private $nodes; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Kubernetes node pool name. + * @type array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Node>|\Google\Protobuf\Internal\RepeatedField $nodes + * Nodes associated with the finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Kubernetes::initOnce(); + parent::__construct($data); + } + + /** + * Kubernetes node pool name. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Kubernetes node pool name. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Nodes associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Node nodes = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getNodes() + { + return $this->nodes; + } + + /** + * Nodes associated with the finding. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Node nodes = 2; + * @param array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Node>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setNodes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Kubernetes\Node::class); + $this->nodes = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(NodePool::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_NodePool::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Object.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Object.php new file mode 100644 index 000000000000..ad51d0f9697d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Object.php @@ -0,0 +1,220 @@ +google.cloud.securitycenter.v2.Kubernetes.Object + */ +class Object extends \Google\Protobuf\Internal\Message +{ + /** + * Kubernetes object group, such as "policy.k8s.io/v1". + * + * Generated from protobuf field string group = 1; + */ + protected $group = ''; + /** + * Kubernetes object kind, such as "Namespace". + * + * Generated from protobuf field string kind = 2; + */ + protected $kind = ''; + /** + * Kubernetes object namespace. Must be a valid DNS label. Named + * "ns" to avoid collision with C++ namespace keyword. For details see + * https://kubernetes.io/docs/tasks/administer-cluster/namespaces/. + * + * Generated from protobuf field string ns = 3; + */ + protected $ns = ''; + /** + * Kubernetes object name. For details see + * https://kubernetes.io/docs/concepts/overview/working-with-objects/names/. + * + * Generated from protobuf field string name = 4; + */ + protected $name = ''; + /** + * Pod containers associated with this finding, if any. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Container containers = 5; + */ + private $containers; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $group + * Kubernetes object group, such as "policy.k8s.io/v1". + * @type string $kind + * Kubernetes object kind, such as "Namespace". + * @type string $ns + * Kubernetes object namespace. Must be a valid DNS label. Named + * "ns" to avoid collision with C++ namespace keyword. For details see + * https://kubernetes.io/docs/tasks/administer-cluster/namespaces/. + * @type string $name + * Kubernetes object name. For details see + * https://kubernetes.io/docs/concepts/overview/working-with-objects/names/. + * @type array<\Google\Cloud\SecurityCenter\V2\Container>|\Google\Protobuf\Internal\RepeatedField $containers + * Pod containers associated with this finding, if any. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Kubernetes::initOnce(); + parent::__construct($data); + } + + /** + * Kubernetes object group, such as "policy.k8s.io/v1". + * + * Generated from protobuf field string group = 1; + * @return string + */ + public function getGroup() + { + return $this->group; + } + + /** + * Kubernetes object group, such as "policy.k8s.io/v1". + * + * Generated from protobuf field string group = 1; + * @param string $var + * @return $this + */ + public function setGroup($var) + { + GPBUtil::checkString($var, True); + $this->group = $var; + + return $this; + } + + /** + * Kubernetes object kind, such as "Namespace". + * + * Generated from protobuf field string kind = 2; + * @return string + */ + public function getKind() + { + return $this->kind; + } + + /** + * Kubernetes object kind, such as "Namespace". + * + * Generated from protobuf field string kind = 2; + * @param string $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkString($var, True); + $this->kind = $var; + + return $this; + } + + /** + * Kubernetes object namespace. Must be a valid DNS label. Named + * "ns" to avoid collision with C++ namespace keyword. For details see + * https://kubernetes.io/docs/tasks/administer-cluster/namespaces/. + * + * Generated from protobuf field string ns = 3; + * @return string + */ + public function getNs() + { + return $this->ns; + } + + /** + * Kubernetes object namespace. Must be a valid DNS label. Named + * "ns" to avoid collision with C++ namespace keyword. For details see + * https://kubernetes.io/docs/tasks/administer-cluster/namespaces/. + * + * Generated from protobuf field string ns = 3; + * @param string $var + * @return $this + */ + public function setNs($var) + { + GPBUtil::checkString($var, True); + $this->ns = $var; + + return $this; + } + + /** + * Kubernetes object name. For details see + * https://kubernetes.io/docs/concepts/overview/working-with-objects/names/. + * + * Generated from protobuf field string name = 4; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Kubernetes object name. For details see + * https://kubernetes.io/docs/concepts/overview/working-with-objects/names/. + * + * Generated from protobuf field string name = 4; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Pod containers associated with this finding, if any. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Container containers = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getContainers() + { + return $this->containers; + } + + /** + * Pod containers associated with this finding, if any. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Container containers = 5; + * @param array<\Google\Cloud\SecurityCenter\V2\Container>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setContainers($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Container::class); + $this->containers = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Object::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_Object::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Pod.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Pod.php new file mode 100644 index 000000000000..cf46fb898afa --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Pod.php @@ -0,0 +1,176 @@ +google.cloud.securitycenter.v2.Kubernetes.Pod + */ +class Pod extends \Google\Protobuf\Internal\Message +{ + /** + * Kubernetes Pod namespace. + * + * Generated from protobuf field string ns = 1; + */ + protected $ns = ''; + /** + * Kubernetes Pod name. + * + * Generated from protobuf field string name = 2; + */ + protected $name = ''; + /** + * Pod labels. For Kubernetes containers, these are applied to the + * container. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Label labels = 3; + */ + private $labels; + /** + * Pod containers associated with this finding, if any. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Container containers = 4; + */ + private $containers; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $ns + * Kubernetes Pod namespace. + * @type string $name + * Kubernetes Pod name. + * @type array<\Google\Cloud\SecurityCenter\V2\Label>|\Google\Protobuf\Internal\RepeatedField $labels + * Pod labels. For Kubernetes containers, these are applied to the + * container. + * @type array<\Google\Cloud\SecurityCenter\V2\Container>|\Google\Protobuf\Internal\RepeatedField $containers + * Pod containers associated with this finding, if any. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Kubernetes::initOnce(); + parent::__construct($data); + } + + /** + * Kubernetes Pod namespace. + * + * Generated from protobuf field string ns = 1; + * @return string + */ + public function getNs() + { + return $this->ns; + } + + /** + * Kubernetes Pod namespace. + * + * Generated from protobuf field string ns = 1; + * @param string $var + * @return $this + */ + public function setNs($var) + { + GPBUtil::checkString($var, True); + $this->ns = $var; + + return $this; + } + + /** + * Kubernetes Pod name. + * + * Generated from protobuf field string name = 2; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Kubernetes Pod name. + * + * Generated from protobuf field string name = 2; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Pod labels. For Kubernetes containers, these are applied to the + * container. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Label labels = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getLabels() + { + return $this->labels; + } + + /** + * Pod labels. For Kubernetes containers, these are applied to the + * container. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Label labels = 3; + * @param array<\Google\Cloud\SecurityCenter\V2\Label>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setLabels($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Label::class); + $this->labels = $arr; + + return $this; + } + + /** + * Pod containers associated with this finding, if any. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Container containers = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getContainers() + { + return $this->containers; + } + + /** + * Pod containers associated with this finding, if any. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Container containers = 4; + * @param array<\Google\Cloud\SecurityCenter\V2\Container>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setContainers($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Container::class); + $this->containers = $arr; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Pod::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_Pod::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Role.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Role.php new file mode 100644 index 000000000000..3df042edbea6 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Role.php @@ -0,0 +1,138 @@ +google.cloud.securitycenter.v2.Kubernetes.Role + */ +class Role extends \Google\Protobuf\Internal\Message +{ + /** + * Role type. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes.Role.Kind kind = 1; + */ + protected $kind = 0; + /** + * Role namespace. + * + * Generated from protobuf field string ns = 2; + */ + protected $ns = ''; + /** + * Role name. + * + * Generated from protobuf field string name = 3; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $kind + * Role type. + * @type string $ns + * Role namespace. + * @type string $name + * Role name. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Kubernetes::initOnce(); + parent::__construct($data); + } + + /** + * Role type. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes.Role.Kind kind = 1; + * @return int + */ + public function getKind() + { + return $this->kind; + } + + /** + * Role type. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes.Role.Kind kind = 1; + * @param int $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Kubernetes\Role\Kind::class); + $this->kind = $var; + + return $this; + } + + /** + * Role namespace. + * + * Generated from protobuf field string ns = 2; + * @return string + */ + public function getNs() + { + return $this->ns; + } + + /** + * Role namespace. + * + * Generated from protobuf field string ns = 2; + * @param string $var + * @return $this + */ + public function setNs($var) + { + GPBUtil::checkString($var, True); + $this->ns = $var; + + return $this; + } + + /** + * Role name. + * + * Generated from protobuf field string name = 3; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Role name. + * + * Generated from protobuf field string name = 3; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Role::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_Role::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Role/Kind.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Role/Kind.php new file mode 100644 index 000000000000..f714eb7e8d73 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Role/Kind.php @@ -0,0 +1,64 @@ +google.cloud.securitycenter.v2.Kubernetes.Role.Kind + */ +class Kind +{ + /** + * Role type is not specified. + * + * Generated from protobuf enum KIND_UNSPECIFIED = 0; + */ + const KIND_UNSPECIFIED = 0; + /** + * Kubernetes Role. + * + * Generated from protobuf enum ROLE = 1; + */ + const ROLE = 1; + /** + * Kubernetes ClusterRole. + * + * Generated from protobuf enum CLUSTER_ROLE = 2; + */ + const CLUSTER_ROLE = 2; + + private static $valueToName = [ + self::KIND_UNSPECIFIED => 'KIND_UNSPECIFIED', + self::ROLE => 'ROLE', + self::CLUSTER_ROLE => 'CLUSTER_ROLE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Kind::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_Role_Kind::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Subject.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Subject.php new file mode 100644 index 000000000000..63e46fb3411d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Subject.php @@ -0,0 +1,138 @@ +google.cloud.securitycenter.v2.Kubernetes.Subject + */ +class Subject extends \Google\Protobuf\Internal\Message +{ + /** + * Authentication type for the subject. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes.Subject.AuthType kind = 1; + */ + protected $kind = 0; + /** + * Namespace for the subject. + * + * Generated from protobuf field string ns = 2; + */ + protected $ns = ''; + /** + * Name for the subject. + * + * Generated from protobuf field string name = 3; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $kind + * Authentication type for the subject. + * @type string $ns + * Namespace for the subject. + * @type string $name + * Name for the subject. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Kubernetes::initOnce(); + parent::__construct($data); + } + + /** + * Authentication type for the subject. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes.Subject.AuthType kind = 1; + * @return int + */ + public function getKind() + { + return $this->kind; + } + + /** + * Authentication type for the subject. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes.Subject.AuthType kind = 1; + * @param int $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Kubernetes\Subject\AuthType::class); + $this->kind = $var; + + return $this; + } + + /** + * Namespace for the subject. + * + * Generated from protobuf field string ns = 2; + * @return string + */ + public function getNs() + { + return $this->ns; + } + + /** + * Namespace for the subject. + * + * Generated from protobuf field string ns = 2; + * @param string $var + * @return $this + */ + public function setNs($var) + { + GPBUtil::checkString($var, True); + $this->ns = $var; + + return $this; + } + + /** + * Name for the subject. + * + * Generated from protobuf field string name = 3; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Name for the subject. + * + * Generated from protobuf field string name = 3; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Subject::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_Subject::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Subject/AuthType.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Subject/AuthType.php new file mode 100644 index 000000000000..c651f2876eb9 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Subject/AuthType.php @@ -0,0 +1,71 @@ +google.cloud.securitycenter.v2.Kubernetes.Subject.AuthType + */ +class AuthType +{ + /** + * Authentication is not specified. + * + * Generated from protobuf enum AUTH_TYPE_UNSPECIFIED = 0; + */ + const AUTH_TYPE_UNSPECIFIED = 0; + /** + * User with valid certificate. + * + * Generated from protobuf enum USER = 1; + */ + const USER = 1; + /** + * Users managed by Kubernetes API with credentials stored as secrets. + * + * Generated from protobuf enum SERVICEACCOUNT = 2; + */ + const SERVICEACCOUNT = 2; + /** + * Collection of users. + * + * Generated from protobuf enum GROUP = 3; + */ + const GROUP = 3; + + private static $valueToName = [ + self::AUTH_TYPE_UNSPECIFIED => 'AUTH_TYPE_UNSPECIFIED', + self::USER => 'USER', + self::SERVICEACCOUNT => 'SERVICEACCOUNT', + self::GROUP => 'GROUP', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(AuthType::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_Subject_AuthType::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Label.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Label.php new file mode 100644 index 000000000000..fcdf751ff4ef --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Label.php @@ -0,0 +1,104 @@ +google.cloud.securitycenter.v2.Label + */ +class Label extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the label. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Value that corresponds to the label's name. + * + * Generated from protobuf field string value = 2; + */ + protected $value = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Name of the label. + * @type string $value + * Value that corresponds to the label's name. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Label::initOnce(); + parent::__construct($data); + } + + /** + * Name of the label. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Name of the label. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Value that corresponds to the label's name. + * + * Generated from protobuf field string value = 2; + * @return string + */ + public function getValue() + { + return $this->value; + } + + /** + * Value that corresponds to the label's name. + * + * Generated from protobuf field string value = 2; + * @param string $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkString($var, True); + $this->value = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListAttackPathsRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListAttackPathsRequest.php new file mode 100644 index 000000000000..ffa62ff39865 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListAttackPathsRequest.php @@ -0,0 +1,230 @@ +google.cloud.securitycenter.v2.ListAttackPathsRequest + */ +class ListAttackPathsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of parent to list attack paths. + * Valid formats: + * "organizations/{organization}", + * "organizations/{organization}/simulations/{simulation}" + * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" + * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The filter expression that filters the attack path in the response. + * Supported fields: + * * `valued_resources` supports = + * + * Generated from protobuf field string filter = 2; + */ + protected $filter = ''; + /** + * The value returned by the last `ListAttackPathsResponse`; indicates + * that this is a continuation of a prior `ListAttackPaths` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 4; + */ + protected $page_size = 0; + + /** + * @param string $parent Required. Name of parent to list attack paths. + * + * Valid formats: + * "organizations/{organization}", + * "organizations/{organization}/simulations/{simulation}" + * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" + * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" + * Please see {@see SecurityCenterClient::organizationValuedResourceName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V2\ListAttackPathsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Name of parent to list attack paths. + * Valid formats: + * "organizations/{organization}", + * "organizations/{organization}/simulations/{simulation}" + * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" + * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" + * @type string $filter + * The filter expression that filters the attack path in the response. + * Supported fields: + * * `valued_resources` supports = + * @type string $page_token + * The value returned by the last `ListAttackPathsResponse`; indicates + * that this is a continuation of a prior `ListAttackPaths` call, and + * that the system should return the next page of data. + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of parent to list attack paths. + * Valid formats: + * "organizations/{organization}", + * "organizations/{organization}/simulations/{simulation}" + * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" + * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Name of parent to list attack paths. + * Valid formats: + * "organizations/{organization}", + * "organizations/{organization}/simulations/{simulation}" + * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" + * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The filter expression that filters the attack path in the response. + * Supported fields: + * * `valued_resources` supports = + * + * Generated from protobuf field string filter = 2; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * The filter expression that filters the attack path in the response. + * Supported fields: + * * `valued_resources` supports = + * + * Generated from protobuf field string filter = 2; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * The value returned by the last `ListAttackPathsResponse`; indicates + * that this is a continuation of a prior `ListAttackPaths` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 3; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last `ListAttackPathsResponse`; indicates + * that this is a continuation of a prior `ListAttackPaths` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 3; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 4; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 4; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListAttackPathsResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListAttackPathsResponse.php new file mode 100644 index 000000000000..6ea8a37d2c60 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListAttackPathsResponse.php @@ -0,0 +1,106 @@ +google.cloud.securitycenter.v2.ListAttackPathsResponse + */ +class ListAttackPathsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The attack paths that the attack path simulation identified. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath attack_paths = 1; + */ + private $attack_paths; + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V2\AttackPath>|\Google\Protobuf\Internal\RepeatedField $attack_paths + * The attack paths that the attack path simulation identified. + * @type string $next_page_token + * Token to retrieve the next page of results, or empty if there are no more + * results. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * The attack paths that the attack path simulation identified. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath attack_paths = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAttackPaths() + { + return $this->attack_paths; + } + + /** + * The attack paths that the attack path simulation identified. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath attack_paths = 1; + * @param array<\Google\Cloud\SecurityCenter\V2\AttackPath>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAttackPaths($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\AttackPath::class); + $this->attack_paths = $arr; + + return $this; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListBigQueryExportsRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListBigQueryExportsRequest.php new file mode 100644 index 000000000000..d6e1e47072cf --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListBigQueryExportsRequest.php @@ -0,0 +1,189 @@ +google.cloud.securitycenter.v2.ListBigQueryExportsRequest + */ +class ListBigQueryExportsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The parent, which owns the collection of BigQuery exports. Its + * format is "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListBigQueryExports` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListBigQueryExports` + * must match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + + /** + * @param string $parent Required. The parent, which owns the collection of BigQuery exports. Its + * format is "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". Please see + * {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V2\ListBigQueryExportsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The parent, which owns the collection of BigQuery exports. Its + * format is "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * @type int $page_size + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * @type string $page_token + * A page token, received from a previous `ListBigQueryExports` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListBigQueryExports` + * must match the call that provided the page token. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The parent, which owns the collection of BigQuery exports. Its + * format is "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The parent, which owns the collection of BigQuery exports. Its + * format is "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 2; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * A page token, received from a previous `ListBigQueryExports` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListBigQueryExports` + * must match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * A page token, received from a previous `ListBigQueryExports` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListBigQueryExports` + * must match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListBigQueryExportsResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListBigQueryExportsResponse.php new file mode 100644 index 000000000000..a661ed3a90c3 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListBigQueryExportsResponse.php @@ -0,0 +1,105 @@ +google.cloud.securitycenter.v2.ListBigQueryExportsResponse + */ +class ListBigQueryExportsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The BigQuery exports from the specified parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.BigQueryExport big_query_exports = 1; + */ + private $big_query_exports; + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V2\BigQueryExport>|\Google\Protobuf\Internal\RepeatedField $big_query_exports + * The BigQuery exports from the specified parent. + * @type string $next_page_token + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * The BigQuery exports from the specified parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.BigQueryExport big_query_exports = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getBigQueryExports() + { + return $this->big_query_exports; + } + + /** + * The BigQuery exports from the specified parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.BigQueryExport big_query_exports = 1; + * @param array<\Google\Cloud\SecurityCenter\V2\BigQueryExport>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setBigQueryExports($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\BigQueryExport::class); + $this->big_query_exports = $arr; + + return $this; + } + + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsRequest.php new file mode 100644 index 000000000000..159938828312 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsRequest.php @@ -0,0 +1,572 @@ +google.cloud.securitycenter.v2.ListFindingsRequest + */ +class ListFindingsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of the source the findings belong to. If no location is + * specified, the default is global. The following list shows some examples: + * + `organizations/[organization_id]/sources/[source_id]` + * + + * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` + * + `folders/[folder_id]/sources/[source_id]` + * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` + * + `projects/[project_id]/sources/[source_id]` + * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` + * To list across all sources provide a source_id of `-`. The following + * list shows some examples: + * + `organizations/{organization_id}/sources/-` + * + `organizations/{organization_id}/sources/-/locations/{location_id}` + * + `folders/{folder_id}/sources/-` + * + `folders/{folder_id}/sources/-locations/{location_id}` + * + `projects/{projects_id}/sources/-` + * + `projects/{projects_id}/sources/-/locations/{location_id}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * severity: `=`, `:` + * * security_marks.marks: `=`, `:` + * * resource: + * * resource.name: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.type: `=`, `:` + * * resource.folders.resource_folder: `=`, `:` + * * resource.display_name: `=`, `:` + * + * Generated from protobuf field string filter = 2; + */ + protected $filter = ''; + /** + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,parent". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,parent". Redundant space characters in the + * syntax are insignificant. "name desc,parent" and " + * name desc , parent " are equivalent. + * The following fields are supported: + * name + * parent + * state + * category + * resource_name + * event_time + * security_marks.marks + * + * Generated from protobuf field string order_by = 3; + */ + protected $order_by = ''; + /** + * A field mask to specify the Finding fields to be listed in the response. + * An empty field mask will list all fields. + * + * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; + */ + protected $field_mask = null; + /** + * The value returned by the last `ListFindingsResponse`; indicates + * that this is a continuation of a prior `ListFindings` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 8; + */ + protected $page_token = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 9; + */ + protected $page_size = 0; + + /** + * @param string $parent Required. Name of the source the findings belong to. If no location is + * specified, the default is global. The following list shows some examples: + * + * + `organizations/[organization_id]/sources/[source_id]` + * + + * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` + * + `folders/[folder_id]/sources/[source_id]` + * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` + * + `projects/[project_id]/sources/[source_id]` + * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` + * + * To list across all sources provide a source_id of `-`. The following + * list shows some examples: + * + * + `organizations/{organization_id}/sources/-` + * + `organizations/{organization_id}/sources/-/locations/{location_id}` + * + `folders/{folder_id}/sources/-` + * + `folders/{folder_id}/sources/-locations/{location_id}` + * + `projects/{projects_id}/sources/-` + * + `projects/{projects_id}/sources/-/locations/{location_id}` + * Please see {@see SecurityCenterClient::sourceName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V2\ListFindingsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Name of the source the findings belong to. If no location is + * specified, the default is global. The following list shows some examples: + * + `organizations/[organization_id]/sources/[source_id]` + * + + * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` + * + `folders/[folder_id]/sources/[source_id]` + * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` + * + `projects/[project_id]/sources/[source_id]` + * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` + * To list across all sources provide a source_id of `-`. The following + * list shows some examples: + * + `organizations/{organization_id}/sources/-` + * + `organizations/{organization_id}/sources/-/locations/{location_id}` + * + `folders/{folder_id}/sources/-` + * + `folders/{folder_id}/sources/-locations/{location_id}` + * + `projects/{projects_id}/sources/-` + * + `projects/{projects_id}/sources/-/locations/{location_id}` + * @type string $filter + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * severity: `=`, `:` + * * security_marks.marks: `=`, `:` + * * resource: + * * resource.name: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.type: `=`, `:` + * * resource.folders.resource_folder: `=`, `:` + * * resource.display_name: `=`, `:` + * @type string $order_by + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,parent". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,parent". Redundant space characters in the + * syntax are insignificant. "name desc,parent" and " + * name desc , parent " are equivalent. + * The following fields are supported: + * name + * parent + * state + * category + * resource_name + * event_time + * security_marks.marks + * @type \Google\Protobuf\FieldMask $field_mask + * A field mask to specify the Finding fields to be listed in the response. + * An empty field mask will list all fields. + * @type string $page_token + * The value returned by the last `ListFindingsResponse`; indicates + * that this is a continuation of a prior `ListFindings` call, and + * that the system should return the next page of data. + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of the source the findings belong to. If no location is + * specified, the default is global. The following list shows some examples: + * + `organizations/[organization_id]/sources/[source_id]` + * + + * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` + * + `folders/[folder_id]/sources/[source_id]` + * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` + * + `projects/[project_id]/sources/[source_id]` + * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` + * To list across all sources provide a source_id of `-`. The following + * list shows some examples: + * + `organizations/{organization_id}/sources/-` + * + `organizations/{organization_id}/sources/-/locations/{location_id}` + * + `folders/{folder_id}/sources/-` + * + `folders/{folder_id}/sources/-locations/{location_id}` + * + `projects/{projects_id}/sources/-` + * + `projects/{projects_id}/sources/-/locations/{location_id}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Name of the source the findings belong to. If no location is + * specified, the default is global. The following list shows some examples: + * + `organizations/[organization_id]/sources/[source_id]` + * + + * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` + * + `folders/[folder_id]/sources/[source_id]` + * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` + * + `projects/[project_id]/sources/[source_id]` + * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` + * To list across all sources provide a source_id of `-`. The following + * list shows some examples: + * + `organizations/{organization_id}/sources/-` + * + `organizations/{organization_id}/sources/-/locations/{location_id}` + * + `folders/{folder_id}/sources/-` + * + `folders/{folder_id}/sources/-locations/{location_id}` + * + `projects/{projects_id}/sources/-` + * + `projects/{projects_id}/sources/-/locations/{location_id}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * severity: `=`, `:` + * * security_marks.marks: `=`, `:` + * * resource: + * * resource.name: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.type: `=`, `:` + * * resource.folders.resource_folder: `=`, `:` + * * resource.display_name: `=`, `:` + * + * Generated from protobuf field string filter = 2; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Expression that defines the filter to apply across findings. + * The expression is a list of one or more restrictions combined via logical + * operators `AND` and `OR`. + * Parentheses are supported, and `OR` has higher precedence than `AND`. + * Restrictions have the form ` ` and may have a `-` + * character in front of them to indicate negation. Examples include: + * * name + * * security_marks.marks.marka + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * The following field and operator combinations are supported: + * * name: `=` + * * parent: `=`, `:` + * * resource_name: `=`, `:` + * * state: `=`, `:` + * * category: `=`, `:` + * * external_uri: `=`, `:` + * * event_time: `=`, `>`, `<`, `>=`, `<=` + * Usage: This should be milliseconds since epoch or an RFC3339 string. + * Examples: + * `event_time = "2019-06-10T16:07:18-07:00"` + * `event_time = 1560208038000` + * * severity: `=`, `:` + * * security_marks.marks: `=`, `:` + * * resource: + * * resource.name: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.type: `=`, `:` + * * resource.folders.resource_folder: `=`, `:` + * * resource.display_name: `=`, `:` + * + * Generated from protobuf field string filter = 2; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,parent". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,parent". Redundant space characters in the + * syntax are insignificant. "name desc,parent" and " + * name desc , parent " are equivalent. + * The following fields are supported: + * name + * parent + * state + * category + * resource_name + * event_time + * security_marks.marks + * + * Generated from protobuf field string order_by = 3; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Expression that defines what fields and order to use for sorting. The + * string value should follow SQL syntax: comma separated list of fields. For + * example: "name,parent". The default sorting order + * is ascending. To specify descending order for a field, a suffix " desc" + * should be appended to the field name. For example: "name + * desc,parent". Redundant space characters in the + * syntax are insignificant. "name desc,parent" and " + * name desc , parent " are equivalent. + * The following fields are supported: + * name + * parent + * state + * category + * resource_name + * event_time + * security_marks.marks + * + * Generated from protobuf field string order_by = 3; + * @param string $var + * @return $this + */ + public function setOrderBy($var) + { + GPBUtil::checkString($var, True); + $this->order_by = $var; + + return $this; + } + + /** + * A field mask to specify the Finding fields to be listed in the response. + * An empty field mask will list all fields. + * + * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; + * @return \Google\Protobuf\FieldMask|null + */ + public function getFieldMask() + { + return $this->field_mask; + } + + public function hasFieldMask() + { + return isset($this->field_mask); + } + + public function clearFieldMask() + { + unset($this->field_mask); + } + + /** + * A field mask to specify the Finding fields to be listed in the response. + * An empty field mask will list all fields. + * + * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setFieldMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->field_mask = $var; + + return $this; + } + + /** + * The value returned by the last `ListFindingsResponse`; indicates + * that this is a continuation of a prior `ListFindings` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 8; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last `ListFindingsResponse`; indicates + * that this is a continuation of a prior `ListFindings` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 8; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 9; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 9; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse.php new file mode 100644 index 000000000000..6efe3b380fa9 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse.php @@ -0,0 +1,139 @@ +google.cloud.securitycenter.v2.ListFindingsResponse + */ +class ListFindingsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Findings matching the list request. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ListFindingsResponse.ListFindingsResult list_findings_results = 1; + */ + private $list_findings_results; + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + */ + protected $next_page_token = ''; + /** + * The total number of findings matching the query. + * + * Generated from protobuf field int32 total_size = 4; + */ + protected $total_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V2\ListFindingsResponse\ListFindingsResult>|\Google\Protobuf\Internal\RepeatedField $list_findings_results + * Findings matching the list request. + * @type string $next_page_token + * Token to retrieve the next page of results, or empty if there are no more + * results. + * @type int $total_size + * The total number of findings matching the query. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Findings matching the list request. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ListFindingsResponse.ListFindingsResult list_findings_results = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getListFindingsResults() + { + return $this->list_findings_results; + } + + /** + * Findings matching the list request. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ListFindingsResponse.ListFindingsResult list_findings_results = 1; + * @param array<\Google\Cloud\SecurityCenter\V2\ListFindingsResponse\ListFindingsResult>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setListFindingsResults($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ListFindingsResponse\ListFindingsResult::class); + $this->list_findings_results = $arr; + + return $this; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 3; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + + /** + * The total number of findings matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @return int + */ + public function getTotalSize() + { + return $this->total_size; + } + + /** + * The total number of findings matching the query. + * + * Generated from protobuf field int32 total_size = 4; + * @param int $var + * @return $this + */ + public function setTotalSize($var) + { + GPBUtil::checkInt32($var); + $this->total_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse/ListFindingsResult.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse/ListFindingsResult.php new file mode 100644 index 000000000000..dbc0910fe001 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse/ListFindingsResult.php @@ -0,0 +1,124 @@ +google.cloud.securitycenter.v2.ListFindingsResponse.ListFindingsResult + */ +class ListFindingsResult extends \Google\Protobuf\Internal\Message +{ + /** + * Finding matching the search request. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 1; + */ + protected $finding = null; + /** + * Output only. Resource that is associated with this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ListFindingsResponse.ListFindingsResult.Resource resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $resource = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V2\Finding $finding + * Finding matching the search request. + * @type \Google\Cloud\SecurityCenter\V2\ListFindingsResponse\ListFindingsResult\Resource $resource + * Output only. Resource that is associated with this finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Finding matching the search request. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 1; + * @return \Google\Cloud\SecurityCenter\V2\Finding|null + */ + public function getFinding() + { + return $this->finding; + } + + public function hasFinding() + { + return isset($this->finding); + } + + public function clearFinding() + { + unset($this->finding); + } + + /** + * Finding matching the search request. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 1; + * @param \Google\Cloud\SecurityCenter\V2\Finding $var + * @return $this + */ + public function setFinding($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Finding::class); + $this->finding = $var; + + return $this; + } + + /** + * Output only. Resource that is associated with this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ListFindingsResponse.ListFindingsResult.Resource resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Cloud\SecurityCenter\V2\ListFindingsResponse\ListFindingsResult\Resource|null + */ + public function getResource() + { + return $this->resource; + } + + public function hasResource() + { + return isset($this->resource); + } + + public function clearResource() + { + unset($this->resource); + } + + /** + * Output only. Resource that is associated with this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ListFindingsResponse.ListFindingsResult.Resource resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\SecurityCenter\V2\ListFindingsResponse\ListFindingsResult\Resource $var + * @return $this + */ + public function setResource($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ListFindingsResponse\ListFindingsResult\Resource::class); + $this->resource = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ListFindingsResult::class, \Google\Cloud\SecurityCenter\V2\ListFindingsResponse_ListFindingsResult::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse/ListFindingsResult/Resource.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse/ListFindingsResult/Resource.php new file mode 100644 index 000000000000..7edd55ff73d7 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse/ListFindingsResult/Resource.php @@ -0,0 +1,467 @@ +google.cloud.securitycenter.v2.ListFindingsResponse.ListFindingsResult.Resource + */ +class Resource extends \Google\Protobuf\Internal\Message +{ + /** + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The human readable name of the resource. + * + * Generated from protobuf field string display_name = 2; + */ + protected $display_name = ''; + /** + * The full resource type of the resource. + * + * Generated from protobuf field string type = 3; + */ + protected $type = ''; + /** + * Indicates which cloud provider the finding is from. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; + */ + protected $cloud_provider = 0; + /** + * The service or resource provider associated with the resource. + * + * Generated from protobuf field string service = 5; + */ + protected $service = ''; + /** + * The region or location of the service (if applicable). + * + * Generated from protobuf field string location = 6; + */ + protected $location = ''; + /** + * Provides the path to the resource within the resource hierarchy. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath resource_path = 10; + */ + protected $resource_path = null; + /** + * A string representation of the resource path. + * For Google Cloud, it has the format of + * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} + * where there can be any number of folders. + * For AWS, it has the format of + * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} + * where there can be any number of organizational units. + * For Azure, it has the format of + * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} + * where there can be any number of management groups. + * + * Generated from protobuf field string resource_path_string = 11; + */ + protected $resource_path_string = ''; + protected $cloud_provider_metadata; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * @type string $display_name + * The human readable name of the resource. + * @type string $type + * The full resource type of the resource. + * @type int $cloud_provider + * Indicates which cloud provider the finding is from. + * @type string $service + * The service or resource provider associated with the resource. + * @type string $location + * The region or location of the service (if applicable). + * @type \Google\Cloud\SecurityCenter\V2\GcpMetadata $gcp_metadata + * The GCP metadata associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\AwsMetadata $aws_metadata + * The AWS metadata associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\AzureMetadata $azure_metadata + * The Azure metadata associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\ResourcePath $resource_path + * Provides the path to the resource within the resource hierarchy. + * @type string $resource_path_string + * A string representation of the resource path. + * For Google Cloud, it has the format of + * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} + * where there can be any number of folders. + * For AWS, it has the format of + * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} + * where there can be any number of organizational units. + * For Azure, it has the format of + * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} + * where there can be any number of management groups. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The human readable name of the resource. + * + * Generated from protobuf field string display_name = 2; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * The human readable name of the resource. + * + * Generated from protobuf field string display_name = 2; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * The full resource type of the resource. + * + * Generated from protobuf field string type = 3; + * @return string + */ + public function getType() + { + return $this->type; + } + + /** + * The full resource type of the resource. + * + * Generated from protobuf field string type = 3; + * @param string $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkString($var, True); + $this->type = $var; + + return $this; + } + + /** + * Indicates which cloud provider the finding is from. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; + * @return int + */ + public function getCloudProvider() + { + return $this->cloud_provider; + } + + /** + * Indicates which cloud provider the finding is from. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; + * @param int $var + * @return $this + */ + public function setCloudProvider($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\CloudProvider::class); + $this->cloud_provider = $var; + + return $this; + } + + /** + * The service or resource provider associated with the resource. + * + * Generated from protobuf field string service = 5; + * @return string + */ + public function getService() + { + return $this->service; + } + + /** + * The service or resource provider associated with the resource. + * + * Generated from protobuf field string service = 5; + * @param string $var + * @return $this + */ + public function setService($var) + { + GPBUtil::checkString($var, True); + $this->service = $var; + + return $this; + } + + /** + * The region or location of the service (if applicable). + * + * Generated from protobuf field string location = 6; + * @return string + */ + public function getLocation() + { + return $this->location; + } + + /** + * The region or location of the service (if applicable). + * + * Generated from protobuf field string location = 6; + * @param string $var + * @return $this + */ + public function setLocation($var) + { + GPBUtil::checkString($var, True); + $this->location = $var; + + return $this; + } + + /** + * The GCP metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.GcpMetadata gcp_metadata = 7; + * @return \Google\Cloud\SecurityCenter\V2\GcpMetadata|null + */ + public function getGcpMetadata() + { + return $this->readOneof(7); + } + + public function hasGcpMetadata() + { + return $this->hasOneof(7); + } + + /** + * The GCP metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.GcpMetadata gcp_metadata = 7; + * @param \Google\Cloud\SecurityCenter\V2\GcpMetadata $var + * @return $this + */ + public function setGcpMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\GcpMetadata::class); + $this->writeOneof(7, $var); + + return $this; + } + + /** + * The AWS metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata aws_metadata = 8; + * @return \Google\Cloud\SecurityCenter\V2\AwsMetadata|null + */ + public function getAwsMetadata() + { + return $this->readOneof(8); + } + + public function hasAwsMetadata() + { + return $this->hasOneof(8); + } + + /** + * The AWS metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata aws_metadata = 8; + * @param \Google\Cloud\SecurityCenter\V2\AwsMetadata $var + * @return $this + */ + public function setAwsMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\AwsMetadata::class); + $this->writeOneof(8, $var); + + return $this; + } + + /** + * The Azure metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata azure_metadata = 9; + * @return \Google\Cloud\SecurityCenter\V2\AzureMetadata|null + */ + public function getAzureMetadata() + { + return $this->readOneof(9); + } + + public function hasAzureMetadata() + { + return $this->hasOneof(9); + } + + /** + * The Azure metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata azure_metadata = 9; + * @param \Google\Cloud\SecurityCenter\V2\AzureMetadata $var + * @return $this + */ + public function setAzureMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\AzureMetadata::class); + $this->writeOneof(9, $var); + + return $this; + } + + /** + * Provides the path to the resource within the resource hierarchy. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath resource_path = 10; + * @return \Google\Cloud\SecurityCenter\V2\ResourcePath|null + */ + public function getResourcePath() + { + return $this->resource_path; + } + + public function hasResourcePath() + { + return isset($this->resource_path); + } + + public function clearResourcePath() + { + unset($this->resource_path); + } + + /** + * Provides the path to the resource within the resource hierarchy. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath resource_path = 10; + * @param \Google\Cloud\SecurityCenter\V2\ResourcePath $var + * @return $this + */ + public function setResourcePath($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ResourcePath::class); + $this->resource_path = $var; + + return $this; + } + + /** + * A string representation of the resource path. + * For Google Cloud, it has the format of + * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} + * where there can be any number of folders. + * For AWS, it has the format of + * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} + * where there can be any number of organizational units. + * For Azure, it has the format of + * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} + * where there can be any number of management groups. + * + * Generated from protobuf field string resource_path_string = 11; + * @return string + */ + public function getResourcePathString() + { + return $this->resource_path_string; + } + + /** + * A string representation of the resource path. + * For Google Cloud, it has the format of + * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} + * where there can be any number of folders. + * For AWS, it has the format of + * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} + * where there can be any number of organizational units. + * For Azure, it has the format of + * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} + * where there can be any number of management groups. + * + * Generated from protobuf field string resource_path_string = 11; + * @param string $var + * @return $this + */ + public function setResourcePathString($var) + { + GPBUtil::checkString($var, True); + $this->resource_path_string = $var; + + return $this; + } + + /** + * @return string + */ + public function getCloudProviderMetadata() + { + return $this->whichOneof("cloud_provider_metadata"); + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Resource::class, \Google\Cloud\SecurityCenter\V2\ListFindingsResponse_ListFindingsResult_Resource::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListMuteConfigsRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListMuteConfigsRequest.php new file mode 100644 index 000000000000..25486891126a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListMuteConfigsRequest.php @@ -0,0 +1,200 @@ +google.cloud.securitycenter.v2.ListMuteConfigsRequest + */ +class ListMuteConfigsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The parent, which owns the collection of mute configs. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]", + * "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", + * "projects/[project_id]/locations/[location_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListMuteConfigs` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListMuteConfigs` must + * match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + + /** + * @param string $parent Required. The parent, which owns the collection of mute configs. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]", + * "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", + * "projects/[project_id]/locations/[location_id]". Please see + * {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V2\ListMuteConfigsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The parent, which owns the collection of mute configs. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]", + * "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", + * "projects/[project_id]/locations/[location_id]". + * @type int $page_size + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * @type string $page_token + * A page token, received from a previous `ListMuteConfigs` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListMuteConfigs` must + * match the call that provided the page token. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The parent, which owns the collection of mute configs. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]", + * "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", + * "projects/[project_id]/locations/[location_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The parent, which owns the collection of mute configs. Its format + * is "organizations/[organization_id]", "folders/[folder_id]", + * "projects/[project_id]", + * "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", + * "projects/[project_id]/locations/[location_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 2; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * A page token, received from a previous `ListMuteConfigs` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListMuteConfigs` must + * match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * A page token, received from a previous `ListMuteConfigs` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListMuteConfigs` must + * match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListMuteConfigsResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListMuteConfigsResponse.php new file mode 100644 index 000000000000..62a7df0534be --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListMuteConfigsResponse.php @@ -0,0 +1,105 @@ +google.cloud.securitycenter.v2.ListMuteConfigsResponse + */ +class ListMuteConfigsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The mute configs from the specified parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MuteConfig mute_configs = 1; + */ + private $mute_configs; + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V2\MuteConfig>|\Google\Protobuf\Internal\RepeatedField $mute_configs + * The mute configs from the specified parent. + * @type string $next_page_token + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * The mute configs from the specified parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MuteConfig mute_configs = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getMuteConfigs() + { + return $this->mute_configs; + } + + /** + * The mute configs from the specified parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MuteConfig mute_configs = 1; + * @param array<\Google\Cloud\SecurityCenter\V2\MuteConfig>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setMuteConfigs($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\MuteConfig::class); + $this->mute_configs = $arr; + + return $this; + } + + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * + * Generated from protobuf field string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListNotificationConfigsRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListNotificationConfigsRequest.php new file mode 100644 index 000000000000..616b9f14ce7e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListNotificationConfigsRequest.php @@ -0,0 +1,181 @@ +google.cloud.securitycenter.v2.ListNotificationConfigsRequest + */ +class ListNotificationConfigsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the parent in which to list the notification + * configurations. Its format is + * "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The value returned by the last `ListNotificationConfigsResponse`; indicates + * that this is a continuation of a prior `ListNotificationConfigs` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 2; + */ + protected $page_token = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 3; + */ + protected $page_size = 0; + + /** + * @param string $parent Required. The name of the parent in which to list the notification + * configurations. Its format is + * "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". Please see + * {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V2\ListNotificationConfigsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The name of the parent in which to list the notification + * configurations. Its format is + * "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * @type string $page_token + * The value returned by the last `ListNotificationConfigsResponse`; indicates + * that this is a continuation of a prior `ListNotificationConfigs` call, and + * that the system should return the next page of data. + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the parent in which to list the notification + * configurations. Its format is + * "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The name of the parent in which to list the notification + * configurations. Its format is + * "organizations/[organization_id]/locations/[location_id]", + * "folders/[folder_id]/locations/[location_id]", or + * "projects/[project_id]/locations/[location_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The value returned by the last `ListNotificationConfigsResponse`; indicates + * that this is a continuation of a prior `ListNotificationConfigs` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 2; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last `ListNotificationConfigsResponse`; indicates + * that this is a continuation of a prior `ListNotificationConfigs` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 2; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 3; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 3; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListNotificationConfigsResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListNotificationConfigsResponse.php new file mode 100644 index 000000000000..83f774e2d736 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListNotificationConfigsResponse.php @@ -0,0 +1,105 @@ +google.cloud.securitycenter.v2.ListNotificationConfigsResponse + */ +class ListNotificationConfigsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Notification configs belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.NotificationConfig notification_configs = 1; + */ + private $notification_configs; + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V2\NotificationConfig>|\Google\Protobuf\Internal\RepeatedField $notification_configs + * Notification configs belonging to the requested parent. + * @type string $next_page_token + * Token to retrieve the next page of results, or empty if there are no more + * results. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Notification configs belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.NotificationConfig notification_configs = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getNotificationConfigs() + { + return $this->notification_configs; + } + + /** + * Notification configs belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.NotificationConfig notification_configs = 1; + * @param array<\Google\Cloud\SecurityCenter\V2\NotificationConfig>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setNotificationConfigs($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\NotificationConfig::class); + $this->notification_configs = $arr; + + return $this; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListResourceValueConfigsRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListResourceValueConfigsRequest.php new file mode 100644 index 000000000000..3083c60fd32e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListResourceValueConfigsRequest.php @@ -0,0 +1,191 @@ +google.cloud.securitycenter.v2.ListResourceValueConfigsRequest + */ +class ListResourceValueConfigsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The parent, which owns the collection of resource value configs. + * Its format is + * "organizations/[organization_id]" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListResourceValueConfigs` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListResourceValueConfigs` must match the call that provided the + * page token. + * page_size can be specified, and the new page_size will be used. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + + /** + * @param string $parent Required. The parent, which owns the collection of resource value configs. + * Its format is + * "organizations/[organization_id]" + * Please see {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V2\ListResourceValueConfigsRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The parent, which owns the collection of resource value configs. + * Its format is + * "organizations/[organization_id]" + * @type int $page_size + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * @type string $page_token + * A page token, received from a previous `ListResourceValueConfigs` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListResourceValueConfigs` must match the call that provided the + * page token. + * page_size can be specified, and the new page_size will be used. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The parent, which owns the collection of resource value configs. + * Its format is + * "organizations/[organization_id]" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The parent, which owns the collection of resource value configs. + * Its format is + * "organizations/[organization_id]" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of configs to return. The service may return fewer than + * this value. + * If unspecified, at most 10 configs will be returned. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 2; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * A page token, received from a previous `ListResourceValueConfigs` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListResourceValueConfigs` must match the call that provided the + * page token. + * page_size can be specified, and the new page_size will be used. + * + * Generated from protobuf field string page_token = 3; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * A page token, received from a previous `ListResourceValueConfigs` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListResourceValueConfigs` must match the call that provided the + * page token. + * page_size can be specified, and the new page_size will be used. + * + * Generated from protobuf field string page_token = 3; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListResourceValueConfigsResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListResourceValueConfigsResponse.php new file mode 100644 index 000000000000..6c4bc793f92f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListResourceValueConfigsResponse.php @@ -0,0 +1,105 @@ +google.cloud.securitycenter.v2.ListResourceValueConfigsResponse + */ +class ListResourceValueConfigsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The resource value configs from the specified parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_configs = 1; + */ + private $resource_value_configs; + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is empty, there are no subsequent pages. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V2\ResourceValueConfig>|\Google\Protobuf\Internal\RepeatedField $resource_value_configs + * The resource value configs from the specified parent. + * @type string $next_page_token + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is empty, there are no subsequent pages. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * The resource value configs from the specified parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_configs = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getResourceValueConfigs() + { + return $this->resource_value_configs; + } + + /** + * The resource value configs from the specified parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_configs = 1; + * @param array<\Google\Cloud\SecurityCenter\V2\ResourceValueConfig>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setResourceValueConfigs($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ResourceValueConfig::class); + $this->resource_value_configs = $arr; + + return $this; + } + + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is empty, there are no subsequent pages. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * A token, which can be sent as `page_token` to retrieve the next page. + * If this field is empty, there are no subsequent pages. + * + * Generated from protobuf field string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListSourcesRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListSourcesRequest.php new file mode 100644 index 000000000000..643ac6477dd6 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListSourcesRequest.php @@ -0,0 +1,171 @@ +google.cloud.securitycenter.v2.ListSourcesRequest + */ +class ListSourcesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the parent of sources to list. Its format should + * be "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The value returned by the last `ListSourcesResponse`; indicates + * that this is a continuation of a prior `ListSources` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 2; + */ + protected $page_token = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 7; + */ + protected $page_size = 0; + + /** + * @param string $parent Required. Resource name of the parent of sources to list. Its format should + * be "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". Please see + * {@see SecurityCenterClient::projectName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V2\ListSourcesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Resource name of the parent of sources to list. Its format should + * be "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * @type string $page_token + * The value returned by the last `ListSourcesResponse`; indicates + * that this is a continuation of a prior `ListSources` call, and + * that the system should return the next page of data. + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the parent of sources to list. Its format should + * be "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Resource name of the parent of sources to list. Its format should + * be "organizations/[organization_id]", "folders/[folder_id]", or + * "projects/[project_id]". + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The value returned by the last `ListSourcesResponse`; indicates + * that this is a continuation of a prior `ListSources` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 2; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last `ListSourcesResponse`; indicates + * that this is a continuation of a prior `ListSources` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 2; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 7; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 7; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListSourcesResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListSourcesResponse.php new file mode 100644 index 000000000000..6e2ebe4e3fbe --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListSourcesResponse.php @@ -0,0 +1,105 @@ +google.cloud.securitycenter.v2.ListSourcesResponse + */ +class ListSourcesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Sources belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Source sources = 1; + */ + private $sources; + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V2\Source>|\Google\Protobuf\Internal\RepeatedField $sources + * Sources belonging to the requested parent. + * @type string $next_page_token + * Token to retrieve the next page of results, or empty if there are no more + * results. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Sources belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Source sources = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getSources() + { + return $this->sources; + } + + /** + * Sources belonging to the requested parent. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Source sources = 1; + * @param array<\Google\Cloud\SecurityCenter\V2\Source>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setSources($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Source::class); + $this->sources = $arr; + + return $this; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListValuedResourcesRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListValuedResourcesRequest.php new file mode 100644 index 000000000000..796336e2ecc8 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListValuedResourcesRequest.php @@ -0,0 +1,298 @@ +google.cloud.securitycenter.v2.ListValuedResourcesRequest + */ +class ListValuedResourcesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Name of parent to list exposed resources. + * Valid formats: + * "organizations/{organization}", + * "organizations/{organization}/simulations/{simulation}" + * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The filter expression that filters the valued resources in the response. + * Supported fields: + * * `resource_value` supports = + * * `resource_type` supports = + * + * Generated from protobuf field string filter = 2; + */ + protected $filter = ''; + /** + * The value returned by the last `ListValuedResourcesResponse`; indicates + * that this is a continuation of a prior `ListValuedResources` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 4; + */ + protected $page_size = 0; + /** + * Optional. The fields by which to order the valued resources response. + * Supported fields: + * * `exposed_score` + * * `resource_value` + * * `resource_type` + * Values should be a comma separated list of fields. For example: + * `exposed_score,resource_value`. + * The default sorting order is descending. To specify ascending or descending + * order for a field, append a " ASC" or a " DESC" suffix, respectively; for + * example: `exposed_score DESC`. + * + * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $order_by = ''; + + /** + * @param string $parent Required. Name of parent to list exposed resources. + * + * Valid formats: + * "organizations/{organization}", + * "organizations/{organization}/simulations/{simulation}" + * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" + * Please see {@see SecurityCenterClient::simulationName()} for help formatting this field. + * + * @return \Google\Cloud\SecurityCenter\V2\ListValuedResourcesRequest + * + * @experimental + */ + public static function build(string $parent): self + { + return (new self()) + ->setParent($parent); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Name of parent to list exposed resources. + * Valid formats: + * "organizations/{organization}", + * "organizations/{organization}/simulations/{simulation}" + * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" + * @type string $filter + * The filter expression that filters the valued resources in the response. + * Supported fields: + * * `resource_value` supports = + * * `resource_type` supports = + * @type string $page_token + * The value returned by the last `ListValuedResourcesResponse`; indicates + * that this is a continuation of a prior `ListValuedResources` call, and + * that the system should return the next page of data. + * @type int $page_size + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * @type string $order_by + * Optional. The fields by which to order the valued resources response. + * Supported fields: + * * `exposed_score` + * * `resource_value` + * * `resource_type` + * Values should be a comma separated list of fields. For example: + * `exposed_score,resource_value`. + * The default sorting order is descending. To specify ascending or descending + * order for a field, append a " ASC" or a " DESC" suffix, respectively; for + * example: `exposed_score DESC`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Name of parent to list exposed resources. + * Valid formats: + * "organizations/{organization}", + * "organizations/{organization}/simulations/{simulation}" + * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Name of parent to list exposed resources. + * Valid formats: + * "organizations/{organization}", + * "organizations/{organization}/simulations/{simulation}" + * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * The filter expression that filters the valued resources in the response. + * Supported fields: + * * `resource_value` supports = + * * `resource_type` supports = + * + * Generated from protobuf field string filter = 2; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * The filter expression that filters the valued resources in the response. + * Supported fields: + * * `resource_value` supports = + * * `resource_type` supports = + * + * Generated from protobuf field string filter = 2; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * The value returned by the last `ListValuedResourcesResponse`; indicates + * that this is a continuation of a prior `ListValuedResources` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 3; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The value returned by the last `ListValuedResourcesResponse`; indicates + * that this is a continuation of a prior `ListValuedResources` call, and + * that the system should return the next page of data. + * + * Generated from protobuf field string page_token = 3; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 4; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of results to return in a single response. Default is + * 10, minimum is 1, maximum is 1000. + * + * Generated from protobuf field int32 page_size = 4; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * Optional. The fields by which to order the valued resources response. + * Supported fields: + * * `exposed_score` + * * `resource_value` + * * `resource_type` + * Values should be a comma separated list of fields. For example: + * `exposed_score,resource_value`. + * The default sorting order is descending. To specify ascending or descending + * order for a field, append a " ASC" or a " DESC" suffix, respectively; for + * example: `exposed_score DESC`. + * + * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Optional. The fields by which to order the valued resources response. + * Supported fields: + * * `exposed_score` + * * `resource_value` + * * `resource_type` + * Values should be a comma separated list of fields. For example: + * `exposed_score,resource_value`. + * The default sorting order is descending. To specify ascending or descending + * order for a field, append a " ASC" or a " DESC" suffix, respectively; for + * example: `exposed_score DESC`. + * + * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setOrderBy($var) + { + GPBUtil::checkString($var, True); + $this->order_by = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListValuedResourcesResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListValuedResourcesResponse.php new file mode 100644 index 000000000000..304f314b179b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListValuedResourcesResponse.php @@ -0,0 +1,139 @@ +google.cloud.securitycenter.v2.ListValuedResourcesResponse + */ +class ListValuedResourcesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The valued resources that the attack path simulation identified. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ValuedResource valued_resources = 1; + */ + private $valued_resources; + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + /** + * The estimated total number of results matching the query. + * + * Generated from protobuf field int32 total_size = 3; + */ + protected $total_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V2\ValuedResource>|\Google\Protobuf\Internal\RepeatedField $valued_resources + * The valued resources that the attack path simulation identified. + * @type string $next_page_token + * Token to retrieve the next page of results, or empty if there are no more + * results. + * @type int $total_size + * The estimated total number of results matching the query. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * The valued resources that the attack path simulation identified. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ValuedResource valued_resources = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getValuedResources() + { + return $this->valued_resources; + } + + /** + * The valued resources that the attack path simulation identified. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ValuedResource valued_resources = 1; + * @param array<\Google\Cloud\SecurityCenter\V2\ValuedResource>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setValuedResources($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ValuedResource::class); + $this->valued_resources = $arr; + + return $this; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token to retrieve the next page of results, or empty if there are no more + * results. + * + * Generated from protobuf field string next_page_token = 2; + * @param string $var + * @return $this + */ + public function setNextPageToken($var) + { + GPBUtil::checkString($var, True); + $this->next_page_token = $var; + + return $this; + } + + /** + * The estimated total number of results matching the query. + * + * Generated from protobuf field int32 total_size = 3; + * @return int + */ + public function getTotalSize() + { + return $this->total_size; + } + + /** + * The estimated total number of results matching the query. + * + * Generated from protobuf field int32 total_size = 3; + * @param int $var + * @return $this + */ + public function setTotalSize($var) + { + GPBUtil::checkInt32($var); + $this->total_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/LoadBalancer.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/LoadBalancer.php new file mode 100644 index 000000000000..7c260905a4f9 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/LoadBalancer.php @@ -0,0 +1,68 @@ +google.cloud.securitycenter.v2.LoadBalancer + */ +class LoadBalancer extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the load balancer associated with the finding. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the load balancer associated with the finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\LoadBalancer::initOnce(); + parent::__construct($data); + } + + /** + * The name of the load balancer associated with the finding. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the load balancer associated with the finding. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/LogEntry.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/LogEntry.php new file mode 100644 index 000000000000..78fde8306fed --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/LogEntry.php @@ -0,0 +1,75 @@ +google.cloud.securitycenter.v2.LogEntry + */ +class LogEntry extends \Google\Protobuf\Internal\Message +{ + protected $log_entry; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V2\CloudLoggingEntry $cloud_logging_entry + * An individual entry in a log stored in Cloud Logging. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\LogEntry::initOnce(); + parent::__construct($data); + } + + /** + * An individual entry in a log stored in Cloud Logging. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudLoggingEntry cloud_logging_entry = 1; + * @return \Google\Cloud\SecurityCenter\V2\CloudLoggingEntry|null + */ + public function getCloudLoggingEntry() + { + return $this->readOneof(1); + } + + public function hasCloudLoggingEntry() + { + return $this->hasOneof(1); + } + + /** + * An individual entry in a log stored in Cloud Logging. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudLoggingEntry cloud_logging_entry = 1; + * @param \Google\Cloud\SecurityCenter\V2\CloudLoggingEntry $var + * @return $this + */ + public function setCloudLoggingEntry($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\CloudLoggingEntry::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * @return string + */ + public function getLogEntry() + { + return $this->whichOneof("log_entry"); + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack.php new file mode 100644 index 000000000000..500205976e94 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack.php @@ -0,0 +1,228 @@ +google.cloud.securitycenter.v2.MitreAttack + */ +class MitreAttack extends \Google\Protobuf\Internal\Message +{ + /** + * The MITRE ATT&CK tactic most closely represented by this finding, if any. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.MitreAttack.Tactic primary_tactic = 1; + */ + protected $primary_tactic = 0; + /** + * The MITRE ATT&CK technique most closely represented by this finding, if + * any. primary_techniques is a repeated field because there are multiple + * levels of MITRE ATT&CK techniques. If the technique most closely + * represented by this finding is a sub-technique (e.g. `SCANNING_IP_BLOCKS`), + * both the sub-technique and its parent technique(s) will be listed (e.g. + * `SCANNING_IP_BLOCKS`, `ACTIVE_SCANNING`). + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MitreAttack.Technique primary_techniques = 2; + */ + private $primary_techniques; + /** + * Additional MITRE ATT&CK tactics related to this finding, if any. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MitreAttack.Tactic additional_tactics = 3; + */ + private $additional_tactics; + /** + * Additional MITRE ATT&CK techniques related to this finding, if any, along + * with any of their respective parent techniques. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MitreAttack.Technique additional_techniques = 4; + */ + private $additional_techniques; + /** + * The MITRE ATT&CK version referenced by the above fields. E.g. "8". + * + * Generated from protobuf field string version = 5; + */ + protected $version = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $primary_tactic + * The MITRE ATT&CK tactic most closely represented by this finding, if any. + * @type array|\Google\Protobuf\Internal\RepeatedField $primary_techniques + * The MITRE ATT&CK technique most closely represented by this finding, if + * any. primary_techniques is a repeated field because there are multiple + * levels of MITRE ATT&CK techniques. If the technique most closely + * represented by this finding is a sub-technique (e.g. `SCANNING_IP_BLOCKS`), + * both the sub-technique and its parent technique(s) will be listed (e.g. + * `SCANNING_IP_BLOCKS`, `ACTIVE_SCANNING`). + * @type array|\Google\Protobuf\Internal\RepeatedField $additional_tactics + * Additional MITRE ATT&CK tactics related to this finding, if any. + * @type array|\Google\Protobuf\Internal\RepeatedField $additional_techniques + * Additional MITRE ATT&CK techniques related to this finding, if any, along + * with any of their respective parent techniques. + * @type string $version + * The MITRE ATT&CK version referenced by the above fields. E.g. "8". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\MitreAttack::initOnce(); + parent::__construct($data); + } + + /** + * The MITRE ATT&CK tactic most closely represented by this finding, if any. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.MitreAttack.Tactic primary_tactic = 1; + * @return int + */ + public function getPrimaryTactic() + { + return $this->primary_tactic; + } + + /** + * The MITRE ATT&CK tactic most closely represented by this finding, if any. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.MitreAttack.Tactic primary_tactic = 1; + * @param int $var + * @return $this + */ + public function setPrimaryTactic($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\MitreAttack\Tactic::class); + $this->primary_tactic = $var; + + return $this; + } + + /** + * The MITRE ATT&CK technique most closely represented by this finding, if + * any. primary_techniques is a repeated field because there are multiple + * levels of MITRE ATT&CK techniques. If the technique most closely + * represented by this finding is a sub-technique (e.g. `SCANNING_IP_BLOCKS`), + * both the sub-technique and its parent technique(s) will be listed (e.g. + * `SCANNING_IP_BLOCKS`, `ACTIVE_SCANNING`). + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MitreAttack.Technique primary_techniques = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPrimaryTechniques() + { + return $this->primary_techniques; + } + + /** + * The MITRE ATT&CK technique most closely represented by this finding, if + * any. primary_techniques is a repeated field because there are multiple + * levels of MITRE ATT&CK techniques. If the technique most closely + * represented by this finding is a sub-technique (e.g. `SCANNING_IP_BLOCKS`), + * both the sub-technique and its parent technique(s) will be listed (e.g. + * `SCANNING_IP_BLOCKS`, `ACTIVE_SCANNING`). + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MitreAttack.Technique primary_techniques = 2; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPrimaryTechniques($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\SecurityCenter\V2\MitreAttack\Technique::class); + $this->primary_techniques = $arr; + + return $this; + } + + /** + * Additional MITRE ATT&CK tactics related to this finding, if any. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MitreAttack.Tactic additional_tactics = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAdditionalTactics() + { + return $this->additional_tactics; + } + + /** + * Additional MITRE ATT&CK tactics related to this finding, if any. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MitreAttack.Tactic additional_tactics = 3; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAdditionalTactics($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\SecurityCenter\V2\MitreAttack\Tactic::class); + $this->additional_tactics = $arr; + + return $this; + } + + /** + * Additional MITRE ATT&CK techniques related to this finding, if any, along + * with any of their respective parent techniques. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MitreAttack.Technique additional_techniques = 4; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getAdditionalTechniques() + { + return $this->additional_techniques; + } + + /** + * Additional MITRE ATT&CK techniques related to this finding, if any, along + * with any of their respective parent techniques. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MitreAttack.Technique additional_techniques = 4; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setAdditionalTechniques($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\SecurityCenter\V2\MitreAttack\Technique::class); + $this->additional_techniques = $arr; + + return $this; + } + + /** + * The MITRE ATT&CK version referenced by the above fields. E.g. "8". + * + * Generated from protobuf field string version = 5; + * @return string + */ + public function getVersion() + { + return $this->version; + } + + /** + * The MITRE ATT&CK version referenced by the above fields. E.g. "8". + * + * Generated from protobuf field string version = 5; + * @param string $var + * @return $this + */ + public function setVersion($var) + { + GPBUtil::checkString($var, True); + $this->version = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack/Tactic.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack/Tactic.php new file mode 100644 index 000000000000..dbd3df8c5849 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack/Tactic.php @@ -0,0 +1,149 @@ +google.cloud.securitycenter.v2.MitreAttack.Tactic + */ +class Tactic +{ + /** + * Unspecified value. + * + * Generated from protobuf enum TACTIC_UNSPECIFIED = 0; + */ + const TACTIC_UNSPECIFIED = 0; + /** + * TA0043 + * + * Generated from protobuf enum RECONNAISSANCE = 1; + */ + const RECONNAISSANCE = 1; + /** + * TA0042 + * + * Generated from protobuf enum RESOURCE_DEVELOPMENT = 2; + */ + const RESOURCE_DEVELOPMENT = 2; + /** + * TA0001 + * + * Generated from protobuf enum INITIAL_ACCESS = 5; + */ + const INITIAL_ACCESS = 5; + /** + * TA0002 + * + * Generated from protobuf enum EXECUTION = 3; + */ + const EXECUTION = 3; + /** + * TA0003 + * + * Generated from protobuf enum PERSISTENCE = 6; + */ + const PERSISTENCE = 6; + /** + * TA0004 + * + * Generated from protobuf enum PRIVILEGE_ESCALATION = 8; + */ + const PRIVILEGE_ESCALATION = 8; + /** + * TA0005 + * + * Generated from protobuf enum DEFENSE_EVASION = 7; + */ + const DEFENSE_EVASION = 7; + /** + * TA0006 + * + * Generated from protobuf enum CREDENTIAL_ACCESS = 9; + */ + const CREDENTIAL_ACCESS = 9; + /** + * TA0007 + * + * Generated from protobuf enum DISCOVERY = 10; + */ + const DISCOVERY = 10; + /** + * TA0008 + * + * Generated from protobuf enum LATERAL_MOVEMENT = 11; + */ + const LATERAL_MOVEMENT = 11; + /** + * TA0009 + * + * Generated from protobuf enum COLLECTION = 12; + */ + const COLLECTION = 12; + /** + * TA0011 + * + * Generated from protobuf enum COMMAND_AND_CONTROL = 4; + */ + const COMMAND_AND_CONTROL = 4; + /** + * TA0010 + * + * Generated from protobuf enum EXFILTRATION = 13; + */ + const EXFILTRATION = 13; + /** + * TA0040 + * + * Generated from protobuf enum IMPACT = 14; + */ + const IMPACT = 14; + + private static $valueToName = [ + self::TACTIC_UNSPECIFIED => 'TACTIC_UNSPECIFIED', + self::RECONNAISSANCE => 'RECONNAISSANCE', + self::RESOURCE_DEVELOPMENT => 'RESOURCE_DEVELOPMENT', + self::INITIAL_ACCESS => 'INITIAL_ACCESS', + self::EXECUTION => 'EXECUTION', + self::PERSISTENCE => 'PERSISTENCE', + self::PRIVILEGE_ESCALATION => 'PRIVILEGE_ESCALATION', + self::DEFENSE_EVASION => 'DEFENSE_EVASION', + self::CREDENTIAL_ACCESS => 'CREDENTIAL_ACCESS', + self::DISCOVERY => 'DISCOVERY', + self::LATERAL_MOVEMENT => 'LATERAL_MOVEMENT', + self::COLLECTION => 'COLLECTION', + self::COMMAND_AND_CONTROL => 'COMMAND_AND_CONTROL', + self::EXFILTRATION => 'EXFILTRATION', + self::IMPACT => 'IMPACT', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Tactic::class, \Google\Cloud\SecurityCenter\V2\MitreAttack_Tactic::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack/Technique.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack/Technique.php new file mode 100644 index 000000000000..158c67ead96a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack/Technique.php @@ -0,0 +1,486 @@ +google.cloud.securitycenter.v2.MitreAttack.Technique + */ +class Technique +{ + /** + * Unspecified value. + * + * Generated from protobuf enum TECHNIQUE_UNSPECIFIED = 0; + */ + const TECHNIQUE_UNSPECIFIED = 0; + /** + * T1036 + * + * Generated from protobuf enum MASQUERADING = 49; + */ + const MASQUERADING = 49; + /** + * T1036.005 + * + * Generated from protobuf enum MATCH_LEGITIMATE_NAME_OR_LOCATION = 50; + */ + const MATCH_LEGITIMATE_NAME_OR_LOCATION = 50; + /** + * T1037 + * + * Generated from protobuf enum BOOT_OR_LOGON_INITIALIZATION_SCRIPTS = 37; + */ + const BOOT_OR_LOGON_INITIALIZATION_SCRIPTS = 37; + /** + * T1037.005 + * + * Generated from protobuf enum STARTUP_ITEMS = 38; + */ + const STARTUP_ITEMS = 38; + /** + * T1046 + * + * Generated from protobuf enum NETWORK_SERVICE_DISCOVERY = 32; + */ + const NETWORK_SERVICE_DISCOVERY = 32; + /** + * T1057 + * + * Generated from protobuf enum PROCESS_DISCOVERY = 56; + */ + const PROCESS_DISCOVERY = 56; + /** + * T1059 + * + * Generated from protobuf enum COMMAND_AND_SCRIPTING_INTERPRETER = 6; + */ + const COMMAND_AND_SCRIPTING_INTERPRETER = 6; + /** + * T1059.004 + * + * Generated from protobuf enum UNIX_SHELL = 7; + */ + const UNIX_SHELL = 7; + /** + * T1059.006 + * + * Generated from protobuf enum PYTHON = 59; + */ + const PYTHON = 59; + /** + * T1069 + * + * Generated from protobuf enum PERMISSION_GROUPS_DISCOVERY = 18; + */ + const PERMISSION_GROUPS_DISCOVERY = 18; + /** + * T1069.003 + * + * Generated from protobuf enum CLOUD_GROUPS = 19; + */ + const CLOUD_GROUPS = 19; + /** + * T1071 + * + * Generated from protobuf enum APPLICATION_LAYER_PROTOCOL = 45; + */ + const APPLICATION_LAYER_PROTOCOL = 45; + /** + * T1071.004 + * + * Generated from protobuf enum DNS = 46; + */ + const DNS = 46; + /** + * T1072 + * + * Generated from protobuf enum SOFTWARE_DEPLOYMENT_TOOLS = 47; + */ + const SOFTWARE_DEPLOYMENT_TOOLS = 47; + /** + * T1078 + * + * Generated from protobuf enum VALID_ACCOUNTS = 14; + */ + const VALID_ACCOUNTS = 14; + /** + * T1078.001 + * + * Generated from protobuf enum DEFAULT_ACCOUNTS = 35; + */ + const DEFAULT_ACCOUNTS = 35; + /** + * T1078.003 + * + * Generated from protobuf enum LOCAL_ACCOUNTS = 15; + */ + const LOCAL_ACCOUNTS = 15; + /** + * T1078.004 + * + * Generated from protobuf enum CLOUD_ACCOUNTS = 16; + */ + const CLOUD_ACCOUNTS = 16; + /** + * T1090 + * + * Generated from protobuf enum PROXY = 9; + */ + const PROXY = 9; + /** + * T1090.002 + * + * Generated from protobuf enum EXTERNAL_PROXY = 10; + */ + const EXTERNAL_PROXY = 10; + /** + * T1090.003 + * + * Generated from protobuf enum MULTI_HOP_PROXY = 11; + */ + const MULTI_HOP_PROXY = 11; + /** + * T1098 + * + * Generated from protobuf enum ACCOUNT_MANIPULATION = 22; + */ + const ACCOUNT_MANIPULATION = 22; + /** + * T1098.001 + * + * Generated from protobuf enum ADDITIONAL_CLOUD_CREDENTIALS = 40; + */ + const ADDITIONAL_CLOUD_CREDENTIALS = 40; + /** + * T1098.004 + * + * Generated from protobuf enum SSH_AUTHORIZED_KEYS = 23; + */ + const SSH_AUTHORIZED_KEYS = 23; + /** + * T1098.006 + * + * Generated from protobuf enum ADDITIONAL_CONTAINER_CLUSTER_ROLES = 58; + */ + const ADDITIONAL_CONTAINER_CLUSTER_ROLES = 58; + /** + * T1105 + * + * Generated from protobuf enum INGRESS_TOOL_TRANSFER = 3; + */ + const INGRESS_TOOL_TRANSFER = 3; + /** + * T1106 + * + * Generated from protobuf enum NATIVE_API = 4; + */ + const NATIVE_API = 4; + /** + * T1110 + * + * Generated from protobuf enum BRUTE_FORCE = 44; + */ + const BRUTE_FORCE = 44; + /** + * T1129 + * + * Generated from protobuf enum SHARED_MODULES = 5; + */ + const SHARED_MODULES = 5; + /** + * T1134 + * + * Generated from protobuf enum ACCESS_TOKEN_MANIPULATION = 33; + */ + const ACCESS_TOKEN_MANIPULATION = 33; + /** + * T1134.001 + * + * Generated from protobuf enum TOKEN_IMPERSONATION_OR_THEFT = 39; + */ + const TOKEN_IMPERSONATION_OR_THEFT = 39; + /** + * T1190 + * + * Generated from protobuf enum EXPLOIT_PUBLIC_FACING_APPLICATION = 27; + */ + const EXPLOIT_PUBLIC_FACING_APPLICATION = 27; + /** + * T1484 + * + * Generated from protobuf enum DOMAIN_POLICY_MODIFICATION = 30; + */ + const DOMAIN_POLICY_MODIFICATION = 30; + /** + * T1485 + * + * Generated from protobuf enum DATA_DESTRUCTION = 29; + */ + const DATA_DESTRUCTION = 29; + /** + * T1489 + * + * Generated from protobuf enum SERVICE_STOP = 52; + */ + const SERVICE_STOP = 52; + /** + * T1490 + * + * Generated from protobuf enum INHIBIT_SYSTEM_RECOVERY = 36; + */ + const INHIBIT_SYSTEM_RECOVERY = 36; + /** + * T1496 + * + * Generated from protobuf enum RESOURCE_HIJACKING = 8; + */ + const RESOURCE_HIJACKING = 8; + /** + * T1498 + * + * Generated from protobuf enum NETWORK_DENIAL_OF_SERVICE = 17; + */ + const NETWORK_DENIAL_OF_SERVICE = 17; + /** + * T1526 + * + * Generated from protobuf enum CLOUD_SERVICE_DISCOVERY = 48; + */ + const CLOUD_SERVICE_DISCOVERY = 48; + /** + * T1528 + * + * Generated from protobuf enum STEAL_APPLICATION_ACCESS_TOKEN = 42; + */ + const STEAL_APPLICATION_ACCESS_TOKEN = 42; + /** + * T1531 + * + * Generated from protobuf enum ACCOUNT_ACCESS_REMOVAL = 51; + */ + const ACCOUNT_ACCESS_REMOVAL = 51; + /** + * T1539 + * + * Generated from protobuf enum STEAL_WEB_SESSION_COOKIE = 25; + */ + const STEAL_WEB_SESSION_COOKIE = 25; + /** + * T1543 + * + * Generated from protobuf enum CREATE_OR_MODIFY_SYSTEM_PROCESS = 24; + */ + const CREATE_OR_MODIFY_SYSTEM_PROCESS = 24; + /** + * T1548 + * + * Generated from protobuf enum ABUSE_ELEVATION_CONTROL_MECHANISM = 34; + */ + const ABUSE_ELEVATION_CONTROL_MECHANISM = 34; + /** + * T1552 + * + * Generated from protobuf enum UNSECURED_CREDENTIALS = 13; + */ + const UNSECURED_CREDENTIALS = 13; + /** + * T1556 + * + * Generated from protobuf enum MODIFY_AUTHENTICATION_PROCESS = 28; + */ + const MODIFY_AUTHENTICATION_PROCESS = 28; + /** + * T1562 + * + * Generated from protobuf enum IMPAIR_DEFENSES = 31; + */ + const IMPAIR_DEFENSES = 31; + /** + * T1562.001 + * + * Generated from protobuf enum DISABLE_OR_MODIFY_TOOLS = 55; + */ + const DISABLE_OR_MODIFY_TOOLS = 55; + /** + * T1567 + * + * Generated from protobuf enum EXFILTRATION_OVER_WEB_SERVICE = 20; + */ + const EXFILTRATION_OVER_WEB_SERVICE = 20; + /** + * T1567.002 + * + * Generated from protobuf enum EXFILTRATION_TO_CLOUD_STORAGE = 21; + */ + const EXFILTRATION_TO_CLOUD_STORAGE = 21; + /** + * T1568 + * + * Generated from protobuf enum DYNAMIC_RESOLUTION = 12; + */ + const DYNAMIC_RESOLUTION = 12; + /** + * T1570 + * + * Generated from protobuf enum LATERAL_TOOL_TRANSFER = 41; + */ + const LATERAL_TOOL_TRANSFER = 41; + /** + * T1578 + * + * Generated from protobuf enum MODIFY_CLOUD_COMPUTE_INFRASTRUCTURE = 26; + */ + const MODIFY_CLOUD_COMPUTE_INFRASTRUCTURE = 26; + /** + * T1578.001 + * + * Generated from protobuf enum CREATE_SNAPSHOT = 54; + */ + const CREATE_SNAPSHOT = 54; + /** + * T1580 + * + * Generated from protobuf enum CLOUD_INFRASTRUCTURE_DISCOVERY = 53; + */ + const CLOUD_INFRASTRUCTURE_DISCOVERY = 53; + /** + * T1588 + * + * Generated from protobuf enum OBTAIN_CAPABILITIES = 43; + */ + const OBTAIN_CAPABILITIES = 43; + /** + * T1595 + * + * Generated from protobuf enum ACTIVE_SCANNING = 1; + */ + const ACTIVE_SCANNING = 1; + /** + * T1595.001 + * + * Generated from protobuf enum SCANNING_IP_BLOCKS = 2; + */ + const SCANNING_IP_BLOCKS = 2; + /** + * T1613 + * + * Generated from protobuf enum CONTAINER_ADMINISTRATION_COMMAND = 60; + */ + const CONTAINER_ADMINISTRATION_COMMAND = 60; + /** + * T1611 + * + * Generated from protobuf enum ESCAPE_TO_HOST = 61; + */ + const ESCAPE_TO_HOST = 61; + /** + * T1613 + * + * Generated from protobuf enum CONTAINER_AND_RESOURCE_DISCOVERY = 57; + */ + const CONTAINER_AND_RESOURCE_DISCOVERY = 57; + /** + * T1649 + * + * Generated from protobuf enum STEAL_OR_FORGE_AUTHENTICATION_CERTIFICATES = 62; + */ + const STEAL_OR_FORGE_AUTHENTICATION_CERTIFICATES = 62; + + private static $valueToName = [ + self::TECHNIQUE_UNSPECIFIED => 'TECHNIQUE_UNSPECIFIED', + self::MASQUERADING => 'MASQUERADING', + self::MATCH_LEGITIMATE_NAME_OR_LOCATION => 'MATCH_LEGITIMATE_NAME_OR_LOCATION', + self::BOOT_OR_LOGON_INITIALIZATION_SCRIPTS => 'BOOT_OR_LOGON_INITIALIZATION_SCRIPTS', + self::STARTUP_ITEMS => 'STARTUP_ITEMS', + self::NETWORK_SERVICE_DISCOVERY => 'NETWORK_SERVICE_DISCOVERY', + self::PROCESS_DISCOVERY => 'PROCESS_DISCOVERY', + self::COMMAND_AND_SCRIPTING_INTERPRETER => 'COMMAND_AND_SCRIPTING_INTERPRETER', + self::UNIX_SHELL => 'UNIX_SHELL', + self::PYTHON => 'PYTHON', + self::PERMISSION_GROUPS_DISCOVERY => 'PERMISSION_GROUPS_DISCOVERY', + self::CLOUD_GROUPS => 'CLOUD_GROUPS', + self::APPLICATION_LAYER_PROTOCOL => 'APPLICATION_LAYER_PROTOCOL', + self::DNS => 'DNS', + self::SOFTWARE_DEPLOYMENT_TOOLS => 'SOFTWARE_DEPLOYMENT_TOOLS', + self::VALID_ACCOUNTS => 'VALID_ACCOUNTS', + self::DEFAULT_ACCOUNTS => 'DEFAULT_ACCOUNTS', + self::LOCAL_ACCOUNTS => 'LOCAL_ACCOUNTS', + self::CLOUD_ACCOUNTS => 'CLOUD_ACCOUNTS', + self::PROXY => 'PROXY', + self::EXTERNAL_PROXY => 'EXTERNAL_PROXY', + self::MULTI_HOP_PROXY => 'MULTI_HOP_PROXY', + self::ACCOUNT_MANIPULATION => 'ACCOUNT_MANIPULATION', + self::ADDITIONAL_CLOUD_CREDENTIALS => 'ADDITIONAL_CLOUD_CREDENTIALS', + self::SSH_AUTHORIZED_KEYS => 'SSH_AUTHORIZED_KEYS', + self::ADDITIONAL_CONTAINER_CLUSTER_ROLES => 'ADDITIONAL_CONTAINER_CLUSTER_ROLES', + self::INGRESS_TOOL_TRANSFER => 'INGRESS_TOOL_TRANSFER', + self::NATIVE_API => 'NATIVE_API', + self::BRUTE_FORCE => 'BRUTE_FORCE', + self::SHARED_MODULES => 'SHARED_MODULES', + self::ACCESS_TOKEN_MANIPULATION => 'ACCESS_TOKEN_MANIPULATION', + self::TOKEN_IMPERSONATION_OR_THEFT => 'TOKEN_IMPERSONATION_OR_THEFT', + self::EXPLOIT_PUBLIC_FACING_APPLICATION => 'EXPLOIT_PUBLIC_FACING_APPLICATION', + self::DOMAIN_POLICY_MODIFICATION => 'DOMAIN_POLICY_MODIFICATION', + self::DATA_DESTRUCTION => 'DATA_DESTRUCTION', + self::SERVICE_STOP => 'SERVICE_STOP', + self::INHIBIT_SYSTEM_RECOVERY => 'INHIBIT_SYSTEM_RECOVERY', + self::RESOURCE_HIJACKING => 'RESOURCE_HIJACKING', + self::NETWORK_DENIAL_OF_SERVICE => 'NETWORK_DENIAL_OF_SERVICE', + self::CLOUD_SERVICE_DISCOVERY => 'CLOUD_SERVICE_DISCOVERY', + self::STEAL_APPLICATION_ACCESS_TOKEN => 'STEAL_APPLICATION_ACCESS_TOKEN', + self::ACCOUNT_ACCESS_REMOVAL => 'ACCOUNT_ACCESS_REMOVAL', + self::STEAL_WEB_SESSION_COOKIE => 'STEAL_WEB_SESSION_COOKIE', + self::CREATE_OR_MODIFY_SYSTEM_PROCESS => 'CREATE_OR_MODIFY_SYSTEM_PROCESS', + self::ABUSE_ELEVATION_CONTROL_MECHANISM => 'ABUSE_ELEVATION_CONTROL_MECHANISM', + self::UNSECURED_CREDENTIALS => 'UNSECURED_CREDENTIALS', + self::MODIFY_AUTHENTICATION_PROCESS => 'MODIFY_AUTHENTICATION_PROCESS', + self::IMPAIR_DEFENSES => 'IMPAIR_DEFENSES', + self::DISABLE_OR_MODIFY_TOOLS => 'DISABLE_OR_MODIFY_TOOLS', + self::EXFILTRATION_OVER_WEB_SERVICE => 'EXFILTRATION_OVER_WEB_SERVICE', + self::EXFILTRATION_TO_CLOUD_STORAGE => 'EXFILTRATION_TO_CLOUD_STORAGE', + self::DYNAMIC_RESOLUTION => 'DYNAMIC_RESOLUTION', + self::LATERAL_TOOL_TRANSFER => 'LATERAL_TOOL_TRANSFER', + self::MODIFY_CLOUD_COMPUTE_INFRASTRUCTURE => 'MODIFY_CLOUD_COMPUTE_INFRASTRUCTURE', + self::CREATE_SNAPSHOT => 'CREATE_SNAPSHOT', + self::CLOUD_INFRASTRUCTURE_DISCOVERY => 'CLOUD_INFRASTRUCTURE_DISCOVERY', + self::OBTAIN_CAPABILITIES => 'OBTAIN_CAPABILITIES', + self::ACTIVE_SCANNING => 'ACTIVE_SCANNING', + self::SCANNING_IP_BLOCKS => 'SCANNING_IP_BLOCKS', + self::CONTAINER_ADMINISTRATION_COMMAND => 'CONTAINER_ADMINISTRATION_COMMAND', + self::ESCAPE_TO_HOST => 'ESCAPE_TO_HOST', + self::CONTAINER_AND_RESOURCE_DISCOVERY => 'CONTAINER_AND_RESOURCE_DISCOVERY', + self::STEAL_OR_FORGE_AUTHENTICATION_CERTIFICATES => 'STEAL_OR_FORGE_AUTHENTICATION_CERTIFICATES', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(Technique::class, \Google\Cloud\SecurityCenter\V2\MitreAttack_Technique::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MuteConfig.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MuteConfig.php new file mode 100644 index 000000000000..2d22fc8b58d6 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MuteConfig.php @@ -0,0 +1,420 @@ +google.cloud.securitycenter.v2.MuteConfig + */ +class MuteConfig extends \Google\Protobuf\Internal\Message +{ + /** + * This field will be ignored if provided on config creation. The following + * list shows some examples of the format: + * + `organizations/{organization}/muteConfigs/{mute_config}` + * + + * `organizations/{organization}locations/{location}//muteConfigs/{mute_config}` + * + `folders/{folder}/muteConfigs/{mute_config}` + * + `folders/{folder}/locations/{location}/muteConfigs/{mute_config}` + * + `projects/{project}/muteConfigs/{mute_config}` + * + `projects/{project}/locations/{location}/muteConfigs/{mute_config}` + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * A description of the mute config. + * + * Generated from protobuf field string description = 2; + */ + protected $description = ''; + /** + * Required. An expression that defines the filter to apply across + * create/update events of findings. While creating a filter string, be + * mindful of the scope in which the mute configuration is being created. + * E.g., If a filter contains project = X but is created under the project = Y + * scope, it might not match any findings. + * The following field and operator combinations are supported: + * * severity: `=`, `:` + * * category: `=`, `:` + * * resource.name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.folders.resource_folder: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.type: `=`, `:` + * * finding_class: `=`, `:` + * * indicator.ip_addresses: `=`, `:` + * * indicator.domains: `=`, `:` + * + * Generated from protobuf field string filter = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $filter = ''; + /** + * Output only. The time at which the mute config was created. + * This field is set by the server and will be ignored if provided on config + * creation. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. The most recent time at which the mute config was updated. + * This field is set by the server and will be ignored if provided on config + * creation or update. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Output only. Email address of the user who last edited the mute config. + * This field is set by the server and will be ignored if provided on config + * creation or update. + * + * Generated from protobuf field string most_recent_editor = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $most_recent_editor = ''; + /** + * Required. The type of the mute config, which determines what type of mute + * state the config affects. Immutable after creation. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.MuteConfig.MuteConfigType type = 8 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $type = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * This field will be ignored if provided on config creation. The following + * list shows some examples of the format: + * + `organizations/{organization}/muteConfigs/{mute_config}` + * + + * `organizations/{organization}locations/{location}//muteConfigs/{mute_config}` + * + `folders/{folder}/muteConfigs/{mute_config}` + * + `folders/{folder}/locations/{location}/muteConfigs/{mute_config}` + * + `projects/{project}/muteConfigs/{mute_config}` + * + `projects/{project}/locations/{location}/muteConfigs/{mute_config}` + * @type string $description + * A description of the mute config. + * @type string $filter + * Required. An expression that defines the filter to apply across + * create/update events of findings. While creating a filter string, be + * mindful of the scope in which the mute configuration is being created. + * E.g., If a filter contains project = X but is created under the project = Y + * scope, it might not match any findings. + * The following field and operator combinations are supported: + * * severity: `=`, `:` + * * category: `=`, `:` + * * resource.name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.folders.resource_folder: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.type: `=`, `:` + * * finding_class: `=`, `:` + * * indicator.ip_addresses: `=`, `:` + * * indicator.domains: `=`, `:` + * @type \Google\Protobuf\Timestamp $create_time + * Output only. The time at which the mute config was created. + * This field is set by the server and will be ignored if provided on config + * creation. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. The most recent time at which the mute config was updated. + * This field is set by the server and will be ignored if provided on config + * creation or update. + * @type string $most_recent_editor + * Output only. Email address of the user who last edited the mute config. + * This field is set by the server and will be ignored if provided on config + * creation or update. + * @type int $type + * Required. The type of the mute config, which determines what type of mute + * state the config affects. Immutable after creation. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\MuteConfig::initOnce(); + parent::__construct($data); + } + + /** + * This field will be ignored if provided on config creation. The following + * list shows some examples of the format: + * + `organizations/{organization}/muteConfigs/{mute_config}` + * + + * `organizations/{organization}locations/{location}//muteConfigs/{mute_config}` + * + `folders/{folder}/muteConfigs/{mute_config}` + * + `folders/{folder}/locations/{location}/muteConfigs/{mute_config}` + * + `projects/{project}/muteConfigs/{mute_config}` + * + `projects/{project}/locations/{location}/muteConfigs/{mute_config}` + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * This field will be ignored if provided on config creation. The following + * list shows some examples of the format: + * + `organizations/{organization}/muteConfigs/{mute_config}` + * + + * `organizations/{organization}locations/{location}//muteConfigs/{mute_config}` + * + `folders/{folder}/muteConfigs/{mute_config}` + * + `folders/{folder}/locations/{location}/muteConfigs/{mute_config}` + * + `projects/{project}/muteConfigs/{mute_config}` + * + `projects/{project}/locations/{location}/muteConfigs/{mute_config}` + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * A description of the mute config. + * + * Generated from protobuf field string description = 2; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * A description of the mute config. + * + * Generated from protobuf field string description = 2; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * Required. An expression that defines the filter to apply across + * create/update events of findings. While creating a filter string, be + * mindful of the scope in which the mute configuration is being created. + * E.g., If a filter contains project = X but is created under the project = Y + * scope, it might not match any findings. + * The following field and operator combinations are supported: + * * severity: `=`, `:` + * * category: `=`, `:` + * * resource.name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.folders.resource_folder: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.type: `=`, `:` + * * finding_class: `=`, `:` + * * indicator.ip_addresses: `=`, `:` + * * indicator.domains: `=`, `:` + * + * Generated from protobuf field string filter = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Required. An expression that defines the filter to apply across + * create/update events of findings. While creating a filter string, be + * mindful of the scope in which the mute configuration is being created. + * E.g., If a filter contains project = X but is created under the project = Y + * scope, it might not match any findings. + * The following field and operator combinations are supported: + * * severity: `=`, `:` + * * category: `=`, `:` + * * resource.name: `=`, `:` + * * resource.project_name: `=`, `:` + * * resource.project_display_name: `=`, `:` + * * resource.folders.resource_folder: `=`, `:` + * * resource.parent_name: `=`, `:` + * * resource.parent_display_name: `=`, `:` + * * resource.type: `=`, `:` + * * finding_class: `=`, `:` + * * indicator.ip_addresses: `=`, `:` + * * indicator.domains: `=`, `:` + * + * Generated from protobuf field string filter = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * Output only. The time at which the mute config was created. + * This field is set by the server and will be ignored if provided on config + * creation. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCreateTime() + { + return $this->create_time; + } + + public function hasCreateTime() + { + return isset($this->create_time); + } + + public function clearCreateTime() + { + unset($this->create_time); + } + + /** + * Output only. The time at which the mute config was created. + * This field is set by the server and will be ignored if provided on config + * creation. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->create_time = $var; + + return $this; + } + + /** + * Output only. The most recent time at which the mute config was updated. + * This field is set by the server and will be ignored if provided on config + * creation or update. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getUpdateTime() + { + return $this->update_time; + } + + public function hasUpdateTime() + { + return isset($this->update_time); + } + + public function clearUpdateTime() + { + unset($this->update_time); + } + + /** + * Output only. The most recent time at which the mute config was updated. + * This field is set by the server and will be ignored if provided on config + * creation or update. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->update_time = $var; + + return $this; + } + + /** + * Output only. Email address of the user who last edited the mute config. + * This field is set by the server and will be ignored if provided on config + * creation or update. + * + * Generated from protobuf field string most_recent_editor = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getMostRecentEditor() + { + return $this->most_recent_editor; + } + + /** + * Output only. Email address of the user who last edited the mute config. + * This field is set by the server and will be ignored if provided on config + * creation or update. + * + * Generated from protobuf field string most_recent_editor = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setMostRecentEditor($var) + { + GPBUtil::checkString($var, True); + $this->most_recent_editor = $var; + + return $this; + } + + /** + * Required. The type of the mute config, which determines what type of mute + * state the config affects. Immutable after creation. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.MuteConfig.MuteConfigType type = 8 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getType() + { + return $this->type; + } + + /** + * Required. The type of the mute config, which determines what type of mute + * state the config affects. Immutable after creation. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.MuteConfig.MuteConfigType type = 8 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\MuteConfig\MuteConfigType::class); + $this->type = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MuteConfig/MuteConfigType.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MuteConfig/MuteConfigType.php new file mode 100644 index 000000000000..c78c97ba5b5c --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MuteConfig/MuteConfigType.php @@ -0,0 +1,63 @@ +google.cloud.securitycenter.v2.MuteConfig.MuteConfigType + */ +class MuteConfigType +{ + /** + * Unused. + * + * Generated from protobuf enum MUTE_CONFIG_TYPE_UNSPECIFIED = 0; + */ + const MUTE_CONFIG_TYPE_UNSPECIFIED = 0; + /** + * A static mute config, which sets the static mute state of future matching + * findings to muted. Once the static mute state has been set, finding or + * config modifications will not affect the state. + * + * Generated from protobuf enum STATIC = 1; + */ + const PBSTATIC = 1; + + private static $valueToName = [ + self::MUTE_CONFIG_TYPE_UNSPECIFIED => 'MUTE_CONFIG_TYPE_UNSPECIFIED', + self::PBSTATIC => 'STATIC', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + $pbconst = __CLASS__. '::PB' . strtoupper($name); + if (!defined($pbconst)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($pbconst); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(MuteConfigType::class, \Google\Cloud\SecurityCenter\V2\MuteConfig_MuteConfigType::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Notebook.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Notebook.php new file mode 100644 index 000000000000..91286a3b1b30 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Notebook.php @@ -0,0 +1,181 @@ +google.cloud.securitycenter.v2.Notebook + */ +class Notebook extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the notebook. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The source notebook service, for example, "Colab Enterprise". + * + * Generated from protobuf field string service = 2; + */ + protected $service = ''; + /** + * The user ID of the latest author to modify the notebook. + * + * Generated from protobuf field string last_author = 3; + */ + protected $last_author = ''; + /** + * The most recent time the notebook was updated. + * + * Generated from protobuf field .google.protobuf.Timestamp notebook_update_time = 4; + */ + protected $notebook_update_time = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the notebook. + * @type string $service + * The source notebook service, for example, "Colab Enterprise". + * @type string $last_author + * The user ID of the latest author to modify the notebook. + * @type \Google\Protobuf\Timestamp $notebook_update_time + * The most recent time the notebook was updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Notebook::initOnce(); + parent::__construct($data); + } + + /** + * The name of the notebook. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the notebook. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The source notebook service, for example, "Colab Enterprise". + * + * Generated from protobuf field string service = 2; + * @return string + */ + public function getService() + { + return $this->service; + } + + /** + * The source notebook service, for example, "Colab Enterprise". + * + * Generated from protobuf field string service = 2; + * @param string $var + * @return $this + */ + public function setService($var) + { + GPBUtil::checkString($var, True); + $this->service = $var; + + return $this; + } + + /** + * The user ID of the latest author to modify the notebook. + * + * Generated from protobuf field string last_author = 3; + * @return string + */ + public function getLastAuthor() + { + return $this->last_author; + } + + /** + * The user ID of the latest author to modify the notebook. + * + * Generated from protobuf field string last_author = 3; + * @param string $var + * @return $this + */ + public function setLastAuthor($var) + { + GPBUtil::checkString($var, True); + $this->last_author = $var; + + return $this; + } + + /** + * The most recent time the notebook was updated. + * + * Generated from protobuf field .google.protobuf.Timestamp notebook_update_time = 4; + * @return \Google\Protobuf\Timestamp|null + */ + public function getNotebookUpdateTime() + { + return $this->notebook_update_time; + } + + public function hasNotebookUpdateTime() + { + return isset($this->notebook_update_time); + } + + public function clearNotebookUpdateTime() + { + unset($this->notebook_update_time); + } + + /** + * The most recent time the notebook was updated. + * + * Generated from protobuf field .google.protobuf.Timestamp notebook_update_time = 4; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setNotebookUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->notebook_update_time = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationConfig.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationConfig.php new file mode 100644 index 000000000000..762556b94f42 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationConfig.php @@ -0,0 +1,253 @@ +google.cloud.securitycenter.v2.NotificationConfig + */ +class NotificationConfig extends \Google\Protobuf\Internal\Message +{ + /** + * The relative resource name of this notification config. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * The following list shows some examples: + * + + * `organizations/{organization_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` + * + + * `folders/{folder_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` + * + + * `projects/{project_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The description of the notification config (max of 1024 characters). + * + * Generated from protobuf field string description = 2; + */ + protected $description = ''; + /** + * The Pub/Sub topic to send notifications to. Its format is + * "projects/[project_id]/topics/[topic]". + * + * Generated from protobuf field string pubsub_topic = 3 [(.google.api.resource_reference) = { + */ + protected $pubsub_topic = ''; + /** + * Output only. The service account that needs "pubsub.topics.publish" + * permission to publish to the Pub/Sub topic. + * + * Generated from protobuf field string service_account = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $service_account = ''; + protected $notify_config; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The relative resource name of this notification config. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * The following list shows some examples: + * + + * `organizations/{organization_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` + * + + * `folders/{folder_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` + * + + * `projects/{project_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` + * @type string $description + * The description of the notification config (max of 1024 characters). + * @type string $pubsub_topic + * The Pub/Sub topic to send notifications to. Its format is + * "projects/[project_id]/topics/[topic]". + * @type string $service_account + * Output only. The service account that needs "pubsub.topics.publish" + * permission to publish to the Pub/Sub topic. + * @type \Google\Cloud\SecurityCenter\V2\NotificationConfig\StreamingConfig $streaming_config + * The config for triggering streaming-based notifications. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\NotificationConfig::initOnce(); + parent::__construct($data); + } + + /** + * The relative resource name of this notification config. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * The following list shows some examples: + * + + * `organizations/{organization_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` + * + + * `folders/{folder_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` + * + + * `projects/{project_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The relative resource name of this notification config. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * The following list shows some examples: + * + + * `organizations/{organization_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` + * + + * `folders/{folder_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` + * + + * `projects/{project_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The description of the notification config (max of 1024 characters). + * + * Generated from protobuf field string description = 2; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * The description of the notification config (max of 1024 characters). + * + * Generated from protobuf field string description = 2; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * The Pub/Sub topic to send notifications to. Its format is + * "projects/[project_id]/topics/[topic]". + * + * Generated from protobuf field string pubsub_topic = 3 [(.google.api.resource_reference) = { + * @return string + */ + public function getPubsubTopic() + { + return $this->pubsub_topic; + } + + /** + * The Pub/Sub topic to send notifications to. Its format is + * "projects/[project_id]/topics/[topic]". + * + * Generated from protobuf field string pubsub_topic = 3 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setPubsubTopic($var) + { + GPBUtil::checkString($var, True); + $this->pubsub_topic = $var; + + return $this; + } + + /** + * Output only. The service account that needs "pubsub.topics.publish" + * permission to publish to the Pub/Sub topic. + * + * Generated from protobuf field string service_account = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getServiceAccount() + { + return $this->service_account; + } + + /** + * Output only. The service account that needs "pubsub.topics.publish" + * permission to publish to the Pub/Sub topic. + * + * Generated from protobuf field string service_account = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setServiceAccount($var) + { + GPBUtil::checkString($var, True); + $this->service_account = $var; + + return $this; + } + + /** + * The config for triggering streaming-based notifications. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.NotificationConfig.StreamingConfig streaming_config = 5; + * @return \Google\Cloud\SecurityCenter\V2\NotificationConfig\StreamingConfig|null + */ + public function getStreamingConfig() + { + return $this->readOneof(5); + } + + public function hasStreamingConfig() + { + return $this->hasOneof(5); + } + + /** + * The config for triggering streaming-based notifications. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.NotificationConfig.StreamingConfig streaming_config = 5; + * @param \Google\Cloud\SecurityCenter\V2\NotificationConfig\StreamingConfig $var + * @return $this + */ + public function setStreamingConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\NotificationConfig\StreamingConfig::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * @return string + */ + public function getNotifyConfig() + { + return $this->whichOneof("notify_config"); + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationConfig/StreamingConfig.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationConfig/StreamingConfig.php new file mode 100644 index 000000000000..d6fbef5cd427 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationConfig/StreamingConfig.php @@ -0,0 +1,131 @@ +google.cloud.securitycenter.v2.NotificationConfig.StreamingConfig + */ +class StreamingConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Expression that defines the filter to apply across create/update events + * of assets or findings as specified by the event type. The expression is a + * list of zero or more restrictions combined via logical operators `AND` + * and `OR`. Parentheses are supported, and `OR` has higher precedence than + * `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 1; + */ + protected $filter = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $filter + * Expression that defines the filter to apply across create/update events + * of assets or findings as specified by the event type. The expression is a + * list of zero or more restrictions combined via logical operators `AND` + * and `OR`. Parentheses are supported, and `OR` has higher precedence than + * `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\NotificationConfig::initOnce(); + parent::__construct($data); + } + + /** + * Expression that defines the filter to apply across create/update events + * of assets or findings as specified by the event type. The expression is a + * list of zero or more restrictions combined via logical operators `AND` + * and `OR`. Parentheses are supported, and `OR` has higher precedence than + * `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 1; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Expression that defines the filter to apply across create/update events + * of assets or findings as specified by the event type. The expression is a + * list of zero or more restrictions combined via logical operators `AND` + * and `OR`. Parentheses are supported, and `OR` has higher precedence than + * `AND`. + * Restrictions have the form ` ` and may have a + * `-` character in front of them to indicate negation. The fields map to + * those defined in the corresponding resource. + * The supported operators are: + * * `=` for all value types. + * * `>`, `<`, `>=`, `<=` for integer values. + * * `:`, meaning substring matching, for strings. + * The supported value types are: + * * string literals in quotes. + * * integer literals without quotes. + * * boolean literals `true` and `false` without quotes. + * + * Generated from protobuf field string filter = 1; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(StreamingConfig::class, \Google\Cloud\SecurityCenter\V2\NotificationConfig_StreamingConfig::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationMessage.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationMessage.php new file mode 100644 index 000000000000..fc90b3d93ba7 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationMessage.php @@ -0,0 +1,156 @@ +google.cloud.securitycenter.v2.NotificationMessage + */ +class NotificationMessage extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the notification config that generated current notification. + * + * Generated from protobuf field string notification_config_name = 1; + */ + protected $notification_config_name = ''; + /** + * The Cloud resource tied to this notification's Finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Resource resource = 3; + */ + protected $resource = null; + protected $event; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $notification_config_name + * Name of the notification config that generated current notification. + * @type \Google\Cloud\SecurityCenter\V2\Finding $finding + * If it's a Finding based notification config, this field will be + * populated. + * @type \Google\Cloud\SecurityCenter\V2\Resource $resource + * The Cloud resource tied to this notification's Finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\NotificationMessage::initOnce(); + parent::__construct($data); + } + + /** + * Name of the notification config that generated current notification. + * + * Generated from protobuf field string notification_config_name = 1; + * @return string + */ + public function getNotificationConfigName() + { + return $this->notification_config_name; + } + + /** + * Name of the notification config that generated current notification. + * + * Generated from protobuf field string notification_config_name = 1; + * @param string $var + * @return $this + */ + public function setNotificationConfigName($var) + { + GPBUtil::checkString($var, True); + $this->notification_config_name = $var; + + return $this; + } + + /** + * If it's a Finding based notification config, this field will be + * populated. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 2; + * @return \Google\Cloud\SecurityCenter\V2\Finding|null + */ + public function getFinding() + { + return $this->readOneof(2); + } + + public function hasFinding() + { + return $this->hasOneof(2); + } + + /** + * If it's a Finding based notification config, this field will be + * populated. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 2; + * @param \Google\Cloud\SecurityCenter\V2\Finding $var + * @return $this + */ + public function setFinding($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Finding::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * The Cloud resource tied to this notification's Finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Resource resource = 3; + * @return \Google\Cloud\SecurityCenter\V2\Resource|null + */ + public function getResource() + { + return $this->resource; + } + + public function hasResource() + { + return isset($this->resource); + } + + public function clearResource() + { + unset($this->resource); + } + + /** + * The Cloud resource tied to this notification's Finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Resource resource = 3; + * @param \Google\Cloud\SecurityCenter\V2\Resource $var + * @return $this + */ + public function setResource($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Resource::class); + $this->resource = $var; + + return $this; + } + + /** + * @return string + */ + public function getEvent() + { + return $this->whichOneof("event"); + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/OrgPolicy.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/OrgPolicy.php new file mode 100644 index 000000000000..a23d78837a19 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/OrgPolicy.php @@ -0,0 +1,75 @@ +google.cloud.securitycenter.v2.OrgPolicy + */ +class OrgPolicy extends \Google\Protobuf\Internal\Message +{ + /** + * The resource name of the org policy. + * Example: + * "organizations/{organization_id}/policies/{constraint_name}" + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The resource name of the org policy. + * Example: + * "organizations/{organization_id}/policies/{constraint_name}" + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\OrgPolicy::initOnce(); + parent::__construct($data); + } + + /** + * The resource name of the org policy. + * Example: + * "organizations/{organization_id}/policies/{constraint_name}" + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The resource name of the org policy. + * Example: + * "organizations/{organization_id}/policies/{constraint_name}" + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Package.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Package.php new file mode 100644 index 000000000000..3837e34efec1 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Package.php @@ -0,0 +1,169 @@ +google.cloud.securitycenter.v2.Package + */ +class Package extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the package where the vulnerability was detected. + * + * Generated from protobuf field string package_name = 1; + */ + protected $package_name = ''; + /** + * The CPE URI where the vulnerability was detected. + * + * Generated from protobuf field string cpe_uri = 2; + */ + protected $cpe_uri = ''; + /** + * Type of package, for example, os, maven, or go. + * + * Generated from protobuf field string package_type = 3; + */ + protected $package_type = ''; + /** + * The version of the package. + * + * Generated from protobuf field string package_version = 4; + */ + protected $package_version = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $package_name + * The name of the package where the vulnerability was detected. + * @type string $cpe_uri + * The CPE URI where the vulnerability was detected. + * @type string $package_type + * Type of package, for example, os, maven, or go. + * @type string $package_version + * The version of the package. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Vulnerability::initOnce(); + parent::__construct($data); + } + + /** + * The name of the package where the vulnerability was detected. + * + * Generated from protobuf field string package_name = 1; + * @return string + */ + public function getPackageName() + { + return $this->package_name; + } + + /** + * The name of the package where the vulnerability was detected. + * + * Generated from protobuf field string package_name = 1; + * @param string $var + * @return $this + */ + public function setPackageName($var) + { + GPBUtil::checkString($var, True); + $this->package_name = $var; + + return $this; + } + + /** + * The CPE URI where the vulnerability was detected. + * + * Generated from protobuf field string cpe_uri = 2; + * @return string + */ + public function getCpeUri() + { + return $this->cpe_uri; + } + + /** + * The CPE URI where the vulnerability was detected. + * + * Generated from protobuf field string cpe_uri = 2; + * @param string $var + * @return $this + */ + public function setCpeUri($var) + { + GPBUtil::checkString($var, True); + $this->cpe_uri = $var; + + return $this; + } + + /** + * Type of package, for example, os, maven, or go. + * + * Generated from protobuf field string package_type = 3; + * @return string + */ + public function getPackageType() + { + return $this->package_type; + } + + /** + * Type of package, for example, os, maven, or go. + * + * Generated from protobuf field string package_type = 3; + * @param string $var + * @return $this + */ + public function setPackageType($var) + { + GPBUtil::checkString($var, True); + $this->package_type = $var; + + return $this; + } + + /** + * The version of the package. + * + * Generated from protobuf field string package_version = 4; + * @return string + */ + public function getPackageVersion() + { + return $this->package_version; + } + + /** + * The version of the package. + * + * Generated from protobuf field string package_version = 4; + * @param string $var + * @return $this + */ + public function setPackageVersion($var) + { + GPBUtil::checkString($var, True); + $this->package_version = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Process.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Process.php new file mode 100644 index 000000000000..e66d564c995f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Process.php @@ -0,0 +1,409 @@ +google.cloud.securitycenter.v2.Process + */ +class Process extends \Google\Protobuf\Internal\Message +{ + /** + * The process name, as displayed in utilities like `top` and `ps`. This name + * can be accessed through `/proc/[pid]/comm` and changed with + * `prctl(PR_SET_NAME)`. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * File information for the process executable. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.File binary = 2; + */ + protected $binary = null; + /** + * File information for libraries loaded by the process. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.File libraries = 3; + */ + private $libraries; + /** + * When the process represents the invocation of a script, `binary` provides + * information about the interpreter, while `script` provides information + * about the script file provided to the interpreter. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.File script = 4; + */ + protected $script = null; + /** + * Process arguments as JSON encoded strings. + * + * Generated from protobuf field repeated string args = 5; + */ + private $args; + /** + * True if `args` is incomplete. + * + * Generated from protobuf field bool arguments_truncated = 6; + */ + protected $arguments_truncated = false; + /** + * Process environment variables. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.EnvironmentVariable env_variables = 7; + */ + private $env_variables; + /** + * True if `env_variables` is incomplete. + * + * Generated from protobuf field bool env_variables_truncated = 8; + */ + protected $env_variables_truncated = false; + /** + * The process ID. + * + * Generated from protobuf field int64 pid = 9; + */ + protected $pid = 0; + /** + * The parent process ID. + * + * Generated from protobuf field int64 parent_pid = 10; + */ + protected $parent_pid = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The process name, as displayed in utilities like `top` and `ps`. This name + * can be accessed through `/proc/[pid]/comm` and changed with + * `prctl(PR_SET_NAME)`. + * @type \Google\Cloud\SecurityCenter\V2\File $binary + * File information for the process executable. + * @type array<\Google\Cloud\SecurityCenter\V2\File>|\Google\Protobuf\Internal\RepeatedField $libraries + * File information for libraries loaded by the process. + * @type \Google\Cloud\SecurityCenter\V2\File $script + * When the process represents the invocation of a script, `binary` provides + * information about the interpreter, while `script` provides information + * about the script file provided to the interpreter. + * @type array|\Google\Protobuf\Internal\RepeatedField $args + * Process arguments as JSON encoded strings. + * @type bool $arguments_truncated + * True if `args` is incomplete. + * @type array<\Google\Cloud\SecurityCenter\V2\EnvironmentVariable>|\Google\Protobuf\Internal\RepeatedField $env_variables + * Process environment variables. + * @type bool $env_variables_truncated + * True if `env_variables` is incomplete. + * @type int|string $pid + * The process ID. + * @type int|string $parent_pid + * The parent process ID. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Process::initOnce(); + parent::__construct($data); + } + + /** + * The process name, as displayed in utilities like `top` and `ps`. This name + * can be accessed through `/proc/[pid]/comm` and changed with + * `prctl(PR_SET_NAME)`. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The process name, as displayed in utilities like `top` and `ps`. This name + * can be accessed through `/proc/[pid]/comm` and changed with + * `prctl(PR_SET_NAME)`. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * File information for the process executable. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.File binary = 2; + * @return \Google\Cloud\SecurityCenter\V2\File|null + */ + public function getBinary() + { + return $this->binary; + } + + public function hasBinary() + { + return isset($this->binary); + } + + public function clearBinary() + { + unset($this->binary); + } + + /** + * File information for the process executable. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.File binary = 2; + * @param \Google\Cloud\SecurityCenter\V2\File $var + * @return $this + */ + public function setBinary($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\File::class); + $this->binary = $var; + + return $this; + } + + /** + * File information for libraries loaded by the process. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.File libraries = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getLibraries() + { + return $this->libraries; + } + + /** + * File information for libraries loaded by the process. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.File libraries = 3; + * @param array<\Google\Cloud\SecurityCenter\V2\File>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setLibraries($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\File::class); + $this->libraries = $arr; + + return $this; + } + + /** + * When the process represents the invocation of a script, `binary` provides + * information about the interpreter, while `script` provides information + * about the script file provided to the interpreter. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.File script = 4; + * @return \Google\Cloud\SecurityCenter\V2\File|null + */ + public function getScript() + { + return $this->script; + } + + public function hasScript() + { + return isset($this->script); + } + + public function clearScript() + { + unset($this->script); + } + + /** + * When the process represents the invocation of a script, `binary` provides + * information about the interpreter, while `script` provides information + * about the script file provided to the interpreter. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.File script = 4; + * @param \Google\Cloud\SecurityCenter\V2\File $var + * @return $this + */ + public function setScript($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\File::class); + $this->script = $var; + + return $this; + } + + /** + * Process arguments as JSON encoded strings. + * + * Generated from protobuf field repeated string args = 5; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getArgs() + { + return $this->args; + } + + /** + * Process arguments as JSON encoded strings. + * + * Generated from protobuf field repeated string args = 5; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setArgs($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->args = $arr; + + return $this; + } + + /** + * True if `args` is incomplete. + * + * Generated from protobuf field bool arguments_truncated = 6; + * @return bool + */ + public function getArgumentsTruncated() + { + return $this->arguments_truncated; + } + + /** + * True if `args` is incomplete. + * + * Generated from protobuf field bool arguments_truncated = 6; + * @param bool $var + * @return $this + */ + public function setArgumentsTruncated($var) + { + GPBUtil::checkBool($var); + $this->arguments_truncated = $var; + + return $this; + } + + /** + * Process environment variables. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.EnvironmentVariable env_variables = 7; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getEnvVariables() + { + return $this->env_variables; + } + + /** + * Process environment variables. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.EnvironmentVariable env_variables = 7; + * @param array<\Google\Cloud\SecurityCenter\V2\EnvironmentVariable>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setEnvVariables($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\EnvironmentVariable::class); + $this->env_variables = $arr; + + return $this; + } + + /** + * True if `env_variables` is incomplete. + * + * Generated from protobuf field bool env_variables_truncated = 8; + * @return bool + */ + public function getEnvVariablesTruncated() + { + return $this->env_variables_truncated; + } + + /** + * True if `env_variables` is incomplete. + * + * Generated from protobuf field bool env_variables_truncated = 8; + * @param bool $var + * @return $this + */ + public function setEnvVariablesTruncated($var) + { + GPBUtil::checkBool($var); + $this->env_variables_truncated = $var; + + return $this; + } + + /** + * The process ID. + * + * Generated from protobuf field int64 pid = 9; + * @return int|string + */ + public function getPid() + { + return $this->pid; + } + + /** + * The process ID. + * + * Generated from protobuf field int64 pid = 9; + * @param int|string $var + * @return $this + */ + public function setPid($var) + { + GPBUtil::checkInt64($var); + $this->pid = $var; + + return $this; + } + + /** + * The parent process ID. + * + * Generated from protobuf field int64 parent_pid = 10; + * @return int|string + */ + public function getParentPid() + { + return $this->parent_pid; + } + + /** + * The parent process ID. + * + * Generated from protobuf field int64 parent_pid = 10; + * @param int|string $var + * @return $this + */ + public function setParentPid($var) + { + GPBUtil::checkInt64($var); + $this->parent_pid = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Reference.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Reference.php new file mode 100644 index 000000000000..5c8b35a270b9 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Reference.php @@ -0,0 +1,105 @@ +google.cloud.securitycenter.v2.Reference + */ +class Reference extends \Google\Protobuf\Internal\Message +{ + /** + * Source of the reference e.g. NVD + * + * Generated from protobuf field string source = 1; + */ + protected $source = ''; + /** + * Uri for the mentioned source e.g. + * https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527. + * + * Generated from protobuf field string uri = 2; + */ + protected $uri = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $source + * Source of the reference e.g. NVD + * @type string $uri + * Uri for the mentioned source e.g. + * https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Vulnerability::initOnce(); + parent::__construct($data); + } + + /** + * Source of the reference e.g. NVD + * + * Generated from protobuf field string source = 1; + * @return string + */ + public function getSource() + { + return $this->source; + } + + /** + * Source of the reference e.g. NVD + * + * Generated from protobuf field string source = 1; + * @param string $var + * @return $this + */ + public function setSource($var) + { + GPBUtil::checkString($var, True); + $this->source = $var; + + return $this; + } + + /** + * Uri for the mentioned source e.g. + * https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527. + * + * Generated from protobuf field string uri = 2; + * @return string + */ + public function getUri() + { + return $this->uri; + } + + /** + * Uri for the mentioned source e.g. + * https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527. + * + * Generated from protobuf field string uri = 2; + * @param string $var + * @return $this + */ + public function setUri($var) + { + GPBUtil::checkString($var, True); + $this->uri = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Requests.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Requests.php new file mode 100644 index 000000000000..057e47a71238 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Requests.php @@ -0,0 +1,177 @@ +google.cloud.securitycenter.v2.Requests + */ +class Requests extends \Google\Protobuf\Internal\Message +{ + /** + * For 'Increasing deny ratio', the ratio is the denied traffic divided by the + * allowed traffic. For 'Allowed traffic spike', the ratio is the allowed + * traffic in the short term divided by allowed traffic in the long term. + * + * Generated from protobuf field double ratio = 1; + */ + protected $ratio = 0.0; + /** + * Allowed RPS (requests per second) in the short term. + * + * Generated from protobuf field int32 short_term_allowed = 2; + */ + protected $short_term_allowed = 0; + /** + * Allowed RPS (requests per second) over the long term. + * + * Generated from protobuf field int32 long_term_allowed = 3; + */ + protected $long_term_allowed = 0; + /** + * Denied RPS (requests per second) over the long term. + * + * Generated from protobuf field int32 long_term_denied = 4; + */ + protected $long_term_denied = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type float $ratio + * For 'Increasing deny ratio', the ratio is the denied traffic divided by the + * allowed traffic. For 'Allowed traffic spike', the ratio is the allowed + * traffic in the short term divided by allowed traffic in the long term. + * @type int $short_term_allowed + * Allowed RPS (requests per second) in the short term. + * @type int $long_term_allowed + * Allowed RPS (requests per second) over the long term. + * @type int $long_term_denied + * Denied RPS (requests per second) over the long term. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\CloudArmor::initOnce(); + parent::__construct($data); + } + + /** + * For 'Increasing deny ratio', the ratio is the denied traffic divided by the + * allowed traffic. For 'Allowed traffic spike', the ratio is the allowed + * traffic in the short term divided by allowed traffic in the long term. + * + * Generated from protobuf field double ratio = 1; + * @return float + */ + public function getRatio() + { + return $this->ratio; + } + + /** + * For 'Increasing deny ratio', the ratio is the denied traffic divided by the + * allowed traffic. For 'Allowed traffic spike', the ratio is the allowed + * traffic in the short term divided by allowed traffic in the long term. + * + * Generated from protobuf field double ratio = 1; + * @param float $var + * @return $this + */ + public function setRatio($var) + { + GPBUtil::checkDouble($var); + $this->ratio = $var; + + return $this; + } + + /** + * Allowed RPS (requests per second) in the short term. + * + * Generated from protobuf field int32 short_term_allowed = 2; + * @return int + */ + public function getShortTermAllowed() + { + return $this->short_term_allowed; + } + + /** + * Allowed RPS (requests per second) in the short term. + * + * Generated from protobuf field int32 short_term_allowed = 2; + * @param int $var + * @return $this + */ + public function setShortTermAllowed($var) + { + GPBUtil::checkInt32($var); + $this->short_term_allowed = $var; + + return $this; + } + + /** + * Allowed RPS (requests per second) over the long term. + * + * Generated from protobuf field int32 long_term_allowed = 3; + * @return int + */ + public function getLongTermAllowed() + { + return $this->long_term_allowed; + } + + /** + * Allowed RPS (requests per second) over the long term. + * + * Generated from protobuf field int32 long_term_allowed = 3; + * @param int $var + * @return $this + */ + public function setLongTermAllowed($var) + { + GPBUtil::checkInt32($var); + $this->long_term_allowed = $var; + + return $this; + } + + /** + * Denied RPS (requests per second) over the long term. + * + * Generated from protobuf field int32 long_term_denied = 4; + * @return int + */ + public function getLongTermDenied() + { + return $this->long_term_denied; + } + + /** + * Denied RPS (requests per second) over the long term. + * + * Generated from protobuf field int32 long_term_denied = 4; + * @param int $var + * @return $this + */ + public function setLongTermDenied($var) + { + GPBUtil::checkInt32($var); + $this->long_term_denied = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Resource.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Resource.php new file mode 100644 index 000000000000..644e65332382 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Resource.php @@ -0,0 +1,463 @@ +google.cloud.securitycenter.v2.Resource + */ +class Resource extends \Google\Protobuf\Internal\Message +{ + /** + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The human readable name of the resource. + * + * Generated from protobuf field string display_name = 2; + */ + protected $display_name = ''; + /** + * The full resource type of the resource. + * + * Generated from protobuf field string type = 3; + */ + protected $type = ''; + /** + * Indicates which cloud provider the finding is from. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; + */ + protected $cloud_provider = 0; + /** + * The service or resource provider associated with the resource. + * + * Generated from protobuf field string service = 5; + */ + protected $service = ''; + /** + * The region or location of the service (if applicable). + * + * Generated from protobuf field string location = 6; + */ + protected $location = ''; + /** + * Provides the path to the resource within the resource hierarchy. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath resource_path = 10; + */ + protected $resource_path = null; + /** + * A string representation of the resource path. + * For Google Cloud, it has the format of + * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} + * where there can be any number of folders. + * For AWS, it has the format of + * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} + * where there can be any number of organizational units. + * For Azure, it has the format of + * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} + * where there can be any number of management groups. + * + * Generated from protobuf field string resource_path_string = 11; + */ + protected $resource_path_string = ''; + protected $cloud_provider_metadata; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * @type string $display_name + * The human readable name of the resource. + * @type string $type + * The full resource type of the resource. + * @type int $cloud_provider + * Indicates which cloud provider the finding is from. + * @type string $service + * The service or resource provider associated with the resource. + * @type string $location + * The region or location of the service (if applicable). + * @type \Google\Cloud\SecurityCenter\V2\GcpMetadata $gcp_metadata + * The GCP metadata associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\AwsMetadata $aws_metadata + * The AWS metadata associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\AzureMetadata $azure_metadata + * The Azure metadata associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\ResourcePath $resource_path + * Provides the path to the resource within the resource hierarchy. + * @type string $resource_path_string + * A string representation of the resource path. + * For Google Cloud, it has the format of + * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} + * where there can be any number of folders. + * For AWS, it has the format of + * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} + * where there can be any number of organizational units. + * For Azure, it has the format of + * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} + * where there can be any number of management groups. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Resource::initOnce(); + parent::__construct($data); + } + + /** + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The full resource name of the resource. See: + * https://cloud.google.com/apis/design/resource_names#full_resource_name + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The human readable name of the resource. + * + * Generated from protobuf field string display_name = 2; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * The human readable name of the resource. + * + * Generated from protobuf field string display_name = 2; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * The full resource type of the resource. + * + * Generated from protobuf field string type = 3; + * @return string + */ + public function getType() + { + return $this->type; + } + + /** + * The full resource type of the resource. + * + * Generated from protobuf field string type = 3; + * @param string $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkString($var, True); + $this->type = $var; + + return $this; + } + + /** + * Indicates which cloud provider the finding is from. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; + * @return int + */ + public function getCloudProvider() + { + return $this->cloud_provider; + } + + /** + * Indicates which cloud provider the finding is from. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; + * @param int $var + * @return $this + */ + public function setCloudProvider($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\CloudProvider::class); + $this->cloud_provider = $var; + + return $this; + } + + /** + * The service or resource provider associated with the resource. + * + * Generated from protobuf field string service = 5; + * @return string + */ + public function getService() + { + return $this->service; + } + + /** + * The service or resource provider associated with the resource. + * + * Generated from protobuf field string service = 5; + * @param string $var + * @return $this + */ + public function setService($var) + { + GPBUtil::checkString($var, True); + $this->service = $var; + + return $this; + } + + /** + * The region or location of the service (if applicable). + * + * Generated from protobuf field string location = 6; + * @return string + */ + public function getLocation() + { + return $this->location; + } + + /** + * The region or location of the service (if applicable). + * + * Generated from protobuf field string location = 6; + * @param string $var + * @return $this + */ + public function setLocation($var) + { + GPBUtil::checkString($var, True); + $this->location = $var; + + return $this; + } + + /** + * The GCP metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.GcpMetadata gcp_metadata = 7; + * @return \Google\Cloud\SecurityCenter\V2\GcpMetadata|null + */ + public function getGcpMetadata() + { + return $this->readOneof(7); + } + + public function hasGcpMetadata() + { + return $this->hasOneof(7); + } + + /** + * The GCP metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.GcpMetadata gcp_metadata = 7; + * @param \Google\Cloud\SecurityCenter\V2\GcpMetadata $var + * @return $this + */ + public function setGcpMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\GcpMetadata::class); + $this->writeOneof(7, $var); + + return $this; + } + + /** + * The AWS metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata aws_metadata = 8; + * @return \Google\Cloud\SecurityCenter\V2\AwsMetadata|null + */ + public function getAwsMetadata() + { + return $this->readOneof(8); + } + + public function hasAwsMetadata() + { + return $this->hasOneof(8); + } + + /** + * The AWS metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata aws_metadata = 8; + * @param \Google\Cloud\SecurityCenter\V2\AwsMetadata $var + * @return $this + */ + public function setAwsMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\AwsMetadata::class); + $this->writeOneof(8, $var); + + return $this; + } + + /** + * The Azure metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata azure_metadata = 9; + * @return \Google\Cloud\SecurityCenter\V2\AzureMetadata|null + */ + public function getAzureMetadata() + { + return $this->readOneof(9); + } + + public function hasAzureMetadata() + { + return $this->hasOneof(9); + } + + /** + * The Azure metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata azure_metadata = 9; + * @param \Google\Cloud\SecurityCenter\V2\AzureMetadata $var + * @return $this + */ + public function setAzureMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\AzureMetadata::class); + $this->writeOneof(9, $var); + + return $this; + } + + /** + * Provides the path to the resource within the resource hierarchy. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath resource_path = 10; + * @return \Google\Cloud\SecurityCenter\V2\ResourcePath|null + */ + public function getResourcePath() + { + return $this->resource_path; + } + + public function hasResourcePath() + { + return isset($this->resource_path); + } + + public function clearResourcePath() + { + unset($this->resource_path); + } + + /** + * Provides the path to the resource within the resource hierarchy. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath resource_path = 10; + * @param \Google\Cloud\SecurityCenter\V2\ResourcePath $var + * @return $this + */ + public function setResourcePath($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ResourcePath::class); + $this->resource_path = $var; + + return $this; + } + + /** + * A string representation of the resource path. + * For Google Cloud, it has the format of + * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} + * where there can be any number of folders. + * For AWS, it has the format of + * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} + * where there can be any number of organizational units. + * For Azure, it has the format of + * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} + * where there can be any number of management groups. + * + * Generated from protobuf field string resource_path_string = 11; + * @return string + */ + public function getResourcePathString() + { + return $this->resource_path_string; + } + + /** + * A string representation of the resource path. + * For Google Cloud, it has the format of + * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} + * where there can be any number of folders. + * For AWS, it has the format of + * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} + * where there can be any number of organizational units. + * For Azure, it has the format of + * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} + * where there can be any number of management groups. + * + * Generated from protobuf field string resource_path_string = 11; + * @param string $var + * @return $this + */ + public function setResourcePathString($var) + { + GPBUtil::checkString($var, True); + $this->resource_path_string = $var; + + return $this; + } + + /** + * @return string + */ + public function getCloudProviderMetadata() + { + return $this->whichOneof("cloud_provider_metadata"); + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourcePath.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourcePath.php new file mode 100644 index 000000000000..dd0c1b98dddd --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourcePath.php @@ -0,0 +1,72 @@ +google.cloud.securitycenter.v2.ResourcePath + */ +class ResourcePath extends \Google\Protobuf\Internal\Message +{ + /** + * The list of nodes that make the up resource path, ordered from lowest + * level to highest level. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourcePath.ResourcePathNode nodes = 1; + */ + private $nodes; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array<\Google\Cloud\SecurityCenter\V2\ResourcePath\ResourcePathNode>|\Google\Protobuf\Internal\RepeatedField $nodes + * The list of nodes that make the up resource path, ordered from lowest + * level to highest level. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Resource::initOnce(); + parent::__construct($data); + } + + /** + * The list of nodes that make the up resource path, ordered from lowest + * level to highest level. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourcePath.ResourcePathNode nodes = 1; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getNodes() + { + return $this->nodes; + } + + /** + * The list of nodes that make the up resource path, ordered from lowest + * level to highest level. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourcePath.ResourcePathNode nodes = 1; + * @param array<\Google\Cloud\SecurityCenter\V2\ResourcePath\ResourcePathNode>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setNodes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ResourcePath\ResourcePathNode::class); + $this->nodes = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourcePath/ResourcePathNode.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourcePath/ResourcePathNode.php new file mode 100644 index 000000000000..96d25aecdc50 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourcePath/ResourcePathNode.php @@ -0,0 +1,139 @@ +google.cloud.securitycenter.v2.ResourcePath.ResourcePathNode + */ +class ResourcePathNode extends \Google\Protobuf\Internal\Message +{ + /** + * The type of resource this node represents. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath.ResourcePathNodeType node_type = 1; + */ + protected $node_type = 0; + /** + * The ID of the resource this node represents. + * + * Generated from protobuf field string id = 2; + */ + protected $id = ''; + /** + * The display name of the resource this node represents. + * + * Generated from protobuf field string display_name = 3; + */ + protected $display_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $node_type + * The type of resource this node represents. + * @type string $id + * The ID of the resource this node represents. + * @type string $display_name + * The display name of the resource this node represents. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Resource::initOnce(); + parent::__construct($data); + } + + /** + * The type of resource this node represents. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath.ResourcePathNodeType node_type = 1; + * @return int + */ + public function getNodeType() + { + return $this->node_type; + } + + /** + * The type of resource this node represents. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath.ResourcePathNodeType node_type = 1; + * @param int $var + * @return $this + */ + public function setNodeType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\ResourcePath\ResourcePathNodeType::class); + $this->node_type = $var; + + return $this; + } + + /** + * The ID of the resource this node represents. + * + * Generated from protobuf field string id = 2; + * @return string + */ + public function getId() + { + return $this->id; + } + + /** + * The ID of the resource this node represents. + * + * Generated from protobuf field string id = 2; + * @param string $var + * @return $this + */ + public function setId($var) + { + GPBUtil::checkString($var, True); + $this->id = $var; + + return $this; + } + + /** + * The display name of the resource this node represents. + * + * Generated from protobuf field string display_name = 3; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * The display name of the resource this node represents. + * + * Generated from protobuf field string display_name = 3; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ResourcePathNode::class, \Google\Cloud\SecurityCenter\V2\ResourcePath_ResourcePathNode::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourcePath/ResourcePathNodeType.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourcePath/ResourcePathNodeType.php new file mode 100644 index 000000000000..027689d46c5a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourcePath/ResourcePathNodeType.php @@ -0,0 +1,113 @@ +google.cloud.securitycenter.v2.ResourcePath.ResourcePathNodeType + */ +class ResourcePathNodeType +{ + /** + * Node type is unspecified. + * + * Generated from protobuf enum RESOURCE_PATH_NODE_TYPE_UNSPECIFIED = 0; + */ + const RESOURCE_PATH_NODE_TYPE_UNSPECIFIED = 0; + /** + * The node represents a Google Cloud organization. + * + * Generated from protobuf enum GCP_ORGANIZATION = 1; + */ + const GCP_ORGANIZATION = 1; + /** + * The node represents a Google Cloud folder. + * + * Generated from protobuf enum GCP_FOLDER = 2; + */ + const GCP_FOLDER = 2; + /** + * The node represents a Google Cloud project. + * + * Generated from protobuf enum GCP_PROJECT = 3; + */ + const GCP_PROJECT = 3; + /** + * The node represents an AWS organization. + * + * Generated from protobuf enum AWS_ORGANIZATION = 4; + */ + const AWS_ORGANIZATION = 4; + /** + * The node represents an AWS organizational unit. + * + * Generated from protobuf enum AWS_ORGANIZATIONAL_UNIT = 5; + */ + const AWS_ORGANIZATIONAL_UNIT = 5; + /** + * The node represents an AWS account. + * + * Generated from protobuf enum AWS_ACCOUNT = 6; + */ + const AWS_ACCOUNT = 6; + /** + * The node represents an Azure management group. + * + * Generated from protobuf enum AZURE_MANAGEMENT_GROUP = 7; + */ + const AZURE_MANAGEMENT_GROUP = 7; + /** + * The node represents an Azure subscription. + * + * Generated from protobuf enum AZURE_SUBSCRIPTION = 8; + */ + const AZURE_SUBSCRIPTION = 8; + /** + * The node represents an Azure resource group. + * + * Generated from protobuf enum AZURE_RESOURCE_GROUP = 9; + */ + const AZURE_RESOURCE_GROUP = 9; + + private static $valueToName = [ + self::RESOURCE_PATH_NODE_TYPE_UNSPECIFIED => 'RESOURCE_PATH_NODE_TYPE_UNSPECIFIED', + self::GCP_ORGANIZATION => 'GCP_ORGANIZATION', + self::GCP_FOLDER => 'GCP_FOLDER', + self::GCP_PROJECT => 'GCP_PROJECT', + self::AWS_ORGANIZATION => 'AWS_ORGANIZATION', + self::AWS_ORGANIZATIONAL_UNIT => 'AWS_ORGANIZATIONAL_UNIT', + self::AWS_ACCOUNT => 'AWS_ACCOUNT', + self::AZURE_MANAGEMENT_GROUP => 'AZURE_MANAGEMENT_GROUP', + self::AZURE_SUBSCRIPTION => 'AZURE_SUBSCRIPTION', + self::AZURE_RESOURCE_GROUP => 'AZURE_RESOURCE_GROUP', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ResourcePathNodeType::class, \Google\Cloud\SecurityCenter\V2\ResourcePath_ResourcePathNodeType::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValue.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValue.php new file mode 100644 index 000000000000..0952e0b3d347 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValue.php @@ -0,0 +1,75 @@ +google.cloud.securitycenter.v2.ResourceValue + */ +class ResourceValue +{ + /** + * Unspecific value + * + * Generated from protobuf enum RESOURCE_VALUE_UNSPECIFIED = 0; + */ + const RESOURCE_VALUE_UNSPECIFIED = 0; + /** + * High resource value + * + * Generated from protobuf enum HIGH = 1; + */ + const HIGH = 1; + /** + * Medium resource value + * + * Generated from protobuf enum MEDIUM = 2; + */ + const MEDIUM = 2; + /** + * Low resource value + * + * Generated from protobuf enum LOW = 3; + */ + const LOW = 3; + /** + * No resource value, e.g. ignore these resources + * + * Generated from protobuf enum NONE = 4; + */ + const NONE = 4; + + private static $valueToName = [ + self::RESOURCE_VALUE_UNSPECIFIED => 'RESOURCE_VALUE_UNSPECIFIED', + self::HIGH => 'HIGH', + self::MEDIUM => 'MEDIUM', + self::LOW => 'LOW', + self::NONE => 'NONE', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfig.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfig.php new file mode 100644 index 000000000000..390eee2b4943 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfig.php @@ -0,0 +1,506 @@ +google.cloud.securitycenter.v2.ResourceValueConfig + */ +class ResourceValueConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Name for the resource value configuration + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Resource value level this expression represents + * Only required when there is no SDP mapping in the request + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValue resource_value = 2; + */ + protected $resource_value = 0; + /** + * Required. Tag values combined with AND to check against. + * Values in the form "tagValues/123" + * Example: [ "tagValues/123", "tagValues/456", "tagValues/789" ] + * https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing + * + * Generated from protobuf field repeated string tag_values = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + private $tag_values; + /** + * Apply resource_value only to resources that match resource_type. + * resource_type will be checked with AND of other resources. + * For example, "storage.googleapis.com/Bucket" with resource_value "HIGH" + * will apply "HIGH" value only to "storage.googleapis.com/Bucket" resources. + * + * Generated from protobuf field string resource_type = 4; + */ + protected $resource_type = ''; + /** + * Project or folder to scope this configuration to. + * For example, "project/456" would apply this configuration only to resources + * in "project/456" scope will be checked with AND of other + * resources. + * + * Generated from protobuf field string scope = 5; + */ + protected $scope = ''; + /** + * List of resource labels to search for, evaluated with AND. + * For example, "resource_labels_selector": {"key": "value", "env": "prod"} + * will match resources with labels "key": "value" AND "env": + * "prod" + * https://cloud.google.com/resource-manager/docs/creating-managing-labels + * + * Generated from protobuf field map resource_labels_selector = 6; + */ + private $resource_labels_selector; + /** + * Description of the resource value configuration. + * + * Generated from protobuf field string description = 7; + */ + protected $description = ''; + /** + * Output only. Timestamp this resource value configuration was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. Timestamp this resource value configuration was last updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Cloud provider this configuration applies to + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 10; + */ + protected $cloud_provider = 0; + /** + * A mapping of the sensitivity on Sensitive Data Protection finding to + * resource values. This mapping can only be used in combination with a + * resource_type that is related to BigQuery, e.g. + * "bigquery.googleapis.com/Dataset". + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValueConfig.SensitiveDataProtectionMapping sensitive_data_protection_mapping = 11; + */ + protected $sensitive_data_protection_mapping = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Name for the resource value configuration + * @type int $resource_value + * Resource value level this expression represents + * Only required when there is no SDP mapping in the request + * @type array|\Google\Protobuf\Internal\RepeatedField $tag_values + * Required. Tag values combined with AND to check against. + * Values in the form "tagValues/123" + * Example: [ "tagValues/123", "tagValues/456", "tagValues/789" ] + * https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing + * @type string $resource_type + * Apply resource_value only to resources that match resource_type. + * resource_type will be checked with AND of other resources. + * For example, "storage.googleapis.com/Bucket" with resource_value "HIGH" + * will apply "HIGH" value only to "storage.googleapis.com/Bucket" resources. + * @type string $scope + * Project or folder to scope this configuration to. + * For example, "project/456" would apply this configuration only to resources + * in "project/456" scope will be checked with AND of other + * resources. + * @type array|\Google\Protobuf\Internal\MapField $resource_labels_selector + * List of resource labels to search for, evaluated with AND. + * For example, "resource_labels_selector": {"key": "value", "env": "prod"} + * will match resources with labels "key": "value" AND "env": + * "prod" + * https://cloud.google.com/resource-manager/docs/creating-managing-labels + * @type string $description + * Description of the resource value configuration. + * @type \Google\Protobuf\Timestamp $create_time + * Output only. Timestamp this resource value configuration was created. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. Timestamp this resource value configuration was last updated. + * @type int $cloud_provider + * Cloud provider this configuration applies to + * @type \Google\Cloud\SecurityCenter\V2\ResourceValueConfig\SensitiveDataProtectionMapping $sensitive_data_protection_mapping + * A mapping of the sensitivity on Sensitive Data Protection finding to + * resource values. This mapping can only be used in combination with a + * resource_type that is related to BigQuery, e.g. + * "bigquery.googleapis.com/Dataset". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\ResourceValueConfig::initOnce(); + parent::__construct($data); + } + + /** + * Name for the resource value configuration + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Name for the resource value configuration + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Resource value level this expression represents + * Only required when there is no SDP mapping in the request + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValue resource_value = 2; + * @return int + */ + public function getResourceValue() + { + return $this->resource_value; + } + + /** + * Resource value level this expression represents + * Only required when there is no SDP mapping in the request + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValue resource_value = 2; + * @param int $var + * @return $this + */ + public function setResourceValue($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\ResourceValue::class); + $this->resource_value = $var; + + return $this; + } + + /** + * Required. Tag values combined with AND to check against. + * Values in the form "tagValues/123" + * Example: [ "tagValues/123", "tagValues/456", "tagValues/789" ] + * https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing + * + * Generated from protobuf field repeated string tag_values = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getTagValues() + { + return $this->tag_values; + } + + /** + * Required. Tag values combined with AND to check against. + * Values in the form "tagValues/123" + * Example: [ "tagValues/123", "tagValues/456", "tagValues/789" ] + * https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing + * + * Generated from protobuf field repeated string tag_values = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setTagValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->tag_values = $arr; + + return $this; + } + + /** + * Apply resource_value only to resources that match resource_type. + * resource_type will be checked with AND of other resources. + * For example, "storage.googleapis.com/Bucket" with resource_value "HIGH" + * will apply "HIGH" value only to "storage.googleapis.com/Bucket" resources. + * + * Generated from protobuf field string resource_type = 4; + * @return string + */ + public function getResourceType() + { + return $this->resource_type; + } + + /** + * Apply resource_value only to resources that match resource_type. + * resource_type will be checked with AND of other resources. + * For example, "storage.googleapis.com/Bucket" with resource_value "HIGH" + * will apply "HIGH" value only to "storage.googleapis.com/Bucket" resources. + * + * Generated from protobuf field string resource_type = 4; + * @param string $var + * @return $this + */ + public function setResourceType($var) + { + GPBUtil::checkString($var, True); + $this->resource_type = $var; + + return $this; + } + + /** + * Project or folder to scope this configuration to. + * For example, "project/456" would apply this configuration only to resources + * in "project/456" scope will be checked with AND of other + * resources. + * + * Generated from protobuf field string scope = 5; + * @return string + */ + public function getScope() + { + return $this->scope; + } + + /** + * Project or folder to scope this configuration to. + * For example, "project/456" would apply this configuration only to resources + * in "project/456" scope will be checked with AND of other + * resources. + * + * Generated from protobuf field string scope = 5; + * @param string $var + * @return $this + */ + public function setScope($var) + { + GPBUtil::checkString($var, True); + $this->scope = $var; + + return $this; + } + + /** + * List of resource labels to search for, evaluated with AND. + * For example, "resource_labels_selector": {"key": "value", "env": "prod"} + * will match resources with labels "key": "value" AND "env": + * "prod" + * https://cloud.google.com/resource-manager/docs/creating-managing-labels + * + * Generated from protobuf field map resource_labels_selector = 6; + * @return \Google\Protobuf\Internal\MapField + */ + public function getResourceLabelsSelector() + { + return $this->resource_labels_selector; + } + + /** + * List of resource labels to search for, evaluated with AND. + * For example, "resource_labels_selector": {"key": "value", "env": "prod"} + * will match resources with labels "key": "value" AND "env": + * "prod" + * https://cloud.google.com/resource-manager/docs/creating-managing-labels + * + * Generated from protobuf field map resource_labels_selector = 6; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setResourceLabelsSelector($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); + $this->resource_labels_selector = $arr; + + return $this; + } + + /** + * Description of the resource value configuration. + * + * Generated from protobuf field string description = 7; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Description of the resource value configuration. + * + * Generated from protobuf field string description = 7; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * Output only. Timestamp this resource value configuration was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCreateTime() + { + return $this->create_time; + } + + public function hasCreateTime() + { + return isset($this->create_time); + } + + public function clearCreateTime() + { + unset($this->create_time); + } + + /** + * Output only. Timestamp this resource value configuration was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->create_time = $var; + + return $this; + } + + /** + * Output only. Timestamp this resource value configuration was last updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getUpdateTime() + { + return $this->update_time; + } + + public function hasUpdateTime() + { + return isset($this->update_time); + } + + public function clearUpdateTime() + { + unset($this->update_time); + } + + /** + * Output only. Timestamp this resource value configuration was last updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setUpdateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->update_time = $var; + + return $this; + } + + /** + * Cloud provider this configuration applies to + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 10; + * @return int + */ + public function getCloudProvider() + { + return $this->cloud_provider; + } + + /** + * Cloud provider this configuration applies to + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 10; + * @param int $var + * @return $this + */ + public function setCloudProvider($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\CloudProvider::class); + $this->cloud_provider = $var; + + return $this; + } + + /** + * A mapping of the sensitivity on Sensitive Data Protection finding to + * resource values. This mapping can only be used in combination with a + * resource_type that is related to BigQuery, e.g. + * "bigquery.googleapis.com/Dataset". + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValueConfig.SensitiveDataProtectionMapping sensitive_data_protection_mapping = 11; + * @return \Google\Cloud\SecurityCenter\V2\ResourceValueConfig\SensitiveDataProtectionMapping|null + */ + public function getSensitiveDataProtectionMapping() + { + return $this->sensitive_data_protection_mapping; + } + + public function hasSensitiveDataProtectionMapping() + { + return isset($this->sensitive_data_protection_mapping); + } + + public function clearSensitiveDataProtectionMapping() + { + unset($this->sensitive_data_protection_mapping); + } + + /** + * A mapping of the sensitivity on Sensitive Data Protection finding to + * resource values. This mapping can only be used in combination with a + * resource_type that is related to BigQuery, e.g. + * "bigquery.googleapis.com/Dataset". + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValueConfig.SensitiveDataProtectionMapping sensitive_data_protection_mapping = 11; + * @param \Google\Cloud\SecurityCenter\V2\ResourceValueConfig\SensitiveDataProtectionMapping $var + * @return $this + */ + public function setSensitiveDataProtectionMapping($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ResourceValueConfig\SensitiveDataProtectionMapping::class); + $this->sensitive_data_protection_mapping = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfig/SensitiveDataProtectionMapping.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfig/SensitiveDataProtectionMapping.php new file mode 100644 index 000000000000..6107bec83cff --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfig/SensitiveDataProtectionMapping.php @@ -0,0 +1,114 @@ +google.cloud.securitycenter.v2.ResourceValueConfig.SensitiveDataProtectionMapping + */ +class SensitiveDataProtectionMapping extends \Google\Protobuf\Internal\Message +{ + /** + * Resource value mapping for high-sensitivity Sensitive Data Protection + * findings + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValue high_sensitivity_mapping = 1; + */ + protected $high_sensitivity_mapping = 0; + /** + * Resource value mapping for medium-sensitivity Sensitive Data Protection + * findings + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValue medium_sensitivity_mapping = 2; + */ + protected $medium_sensitivity_mapping = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $high_sensitivity_mapping + * Resource value mapping for high-sensitivity Sensitive Data Protection + * findings + * @type int $medium_sensitivity_mapping + * Resource value mapping for medium-sensitivity Sensitive Data Protection + * findings + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\ResourceValueConfig::initOnce(); + parent::__construct($data); + } + + /** + * Resource value mapping for high-sensitivity Sensitive Data Protection + * findings + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValue high_sensitivity_mapping = 1; + * @return int + */ + public function getHighSensitivityMapping() + { + return $this->high_sensitivity_mapping; + } + + /** + * Resource value mapping for high-sensitivity Sensitive Data Protection + * findings + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValue high_sensitivity_mapping = 1; + * @param int $var + * @return $this + */ + public function setHighSensitivityMapping($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\ResourceValue::class); + $this->high_sensitivity_mapping = $var; + + return $this; + } + + /** + * Resource value mapping for medium-sensitivity Sensitive Data Protection + * findings + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValue medium_sensitivity_mapping = 2; + * @return int + */ + public function getMediumSensitivityMapping() + { + return $this->medium_sensitivity_mapping; + } + + /** + * Resource value mapping for medium-sensitivity Sensitive Data Protection + * findings + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValue medium_sensitivity_mapping = 2; + * @param int $var + * @return $this + */ + public function setMediumSensitivityMapping($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\ResourceValue::class); + $this->medium_sensitivity_mapping = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(SensitiveDataProtectionMapping::class, \Google\Cloud\SecurityCenter\V2\ResourceValueConfig_SensitiveDataProtectionMapping::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfigMetadata.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfigMetadata.php new file mode 100644 index 000000000000..2691859ffff0 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfigMetadata.php @@ -0,0 +1,67 @@ +google.cloud.securitycenter.v2.ResourceValueConfigMetadata + */ +class ResourceValueConfigMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * Resource value config name + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Resource value config name + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\ValuedResource::initOnce(); + parent::__construct($data); + } + + /** + * Resource value config name + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Resource value config name + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityBulletin.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityBulletin.php new file mode 100644 index 000000000000..8909dfe27dd2 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityBulletin.php @@ -0,0 +1,149 @@ +google.cloud.securitycenter.v2.SecurityBulletin + */ +class SecurityBulletin extends \Google\Protobuf\Internal\Message +{ + /** + * ID of the bulletin corresponding to the vulnerability. + * + * Generated from protobuf field string bulletin_id = 1; + */ + protected $bulletin_id = ''; + /** + * Submission time of this Security Bulletin. + * + * Generated from protobuf field .google.protobuf.Timestamp submission_time = 2; + */ + protected $submission_time = null; + /** + * This represents a version that the cluster receiving this notification + * should be upgraded to, based on its current version. For example, 1.15.0 + * + * Generated from protobuf field string suggested_upgrade_version = 3; + */ + protected $suggested_upgrade_version = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $bulletin_id + * ID of the bulletin corresponding to the vulnerability. + * @type \Google\Protobuf\Timestamp $submission_time + * Submission time of this Security Bulletin. + * @type string $suggested_upgrade_version + * This represents a version that the cluster receiving this notification + * should be upgraded to, based on its current version. For example, 1.15.0 + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Vulnerability::initOnce(); + parent::__construct($data); + } + + /** + * ID of the bulletin corresponding to the vulnerability. + * + * Generated from protobuf field string bulletin_id = 1; + * @return string + */ + public function getBulletinId() + { + return $this->bulletin_id; + } + + /** + * ID of the bulletin corresponding to the vulnerability. + * + * Generated from protobuf field string bulletin_id = 1; + * @param string $var + * @return $this + */ + public function setBulletinId($var) + { + GPBUtil::checkString($var, True); + $this->bulletin_id = $var; + + return $this; + } + + /** + * Submission time of this Security Bulletin. + * + * Generated from protobuf field .google.protobuf.Timestamp submission_time = 2; + * @return \Google\Protobuf\Timestamp|null + */ + public function getSubmissionTime() + { + return $this->submission_time; + } + + public function hasSubmissionTime() + { + return isset($this->submission_time); + } + + public function clearSubmissionTime() + { + unset($this->submission_time); + } + + /** + * Submission time of this Security Bulletin. + * + * Generated from protobuf field .google.protobuf.Timestamp submission_time = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setSubmissionTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->submission_time = $var; + + return $this; + } + + /** + * This represents a version that the cluster receiving this notification + * should be upgraded to, based on its current version. For example, 1.15.0 + * + * Generated from protobuf field string suggested_upgrade_version = 3; + * @return string + */ + public function getSuggestedUpgradeVersion() + { + return $this->suggested_upgrade_version; + } + + /** + * This represents a version that the cluster receiving this notification + * should be upgraded to, based on its current version. For example, 1.15.0 + * + * Generated from protobuf field string suggested_upgrade_version = 3; + * @param string $var + * @return $this + */ + public function setSuggestedUpgradeVersion($var) + { + GPBUtil::checkString($var, True); + $this->suggested_upgrade_version = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityMarks.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityMarks.php new file mode 100644 index 000000000000..599094423a8e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityMarks.php @@ -0,0 +1,250 @@ +google.cloud.securitycenter.v2.SecurityMarks + */ +class SecurityMarks extends \Google\Protobuf\Internal\Message +{ + /** + * The relative resource name of the SecurityMarks. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * The following list shows some examples: + * + `organizations/{organization_id}/assets/{asset_id}/securityMarks` + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Mutable user specified security marks belonging to the parent resource. + * Constraints are as follows: + * * Keys and values are treated as case insensitive + * * Keys must be between 1 - 256 characters (inclusive) + * * Keys must be letters, numbers, underscores, or dashes + * * Values have leading and trailing whitespace trimmed, remaining + * characters must be between 1 - 4096 characters (inclusive) + * + * Generated from protobuf field map marks = 2; + */ + private $marks; + /** + * The canonical name of the marks. The following list shows some examples: + * + `organizations/{organization_id}/assets/{asset_id}/securityMarks` + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` + * + `folders/{folder_id}/assets/{asset_id}/securityMarks` + * + + * `folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` + * + `projects/{project_number}/assets/{asset_id}/securityMarks` + * + + * `projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks` + * + + * `projects/{project_number}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` + * + * Generated from protobuf field string canonical_name = 3; + */ + protected $canonical_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The relative resource name of the SecurityMarks. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * The following list shows some examples: + * + `organizations/{organization_id}/assets/{asset_id}/securityMarks` + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` + * @type array|\Google\Protobuf\Internal\MapField $marks + * Mutable user specified security marks belonging to the parent resource. + * Constraints are as follows: + * * Keys and values are treated as case insensitive + * * Keys must be between 1 - 256 characters (inclusive) + * * Keys must be letters, numbers, underscores, or dashes + * * Values have leading and trailing whitespace trimmed, remaining + * characters must be between 1 - 4096 characters (inclusive) + * @type string $canonical_name + * The canonical name of the marks. The following list shows some examples: + * + `organizations/{organization_id}/assets/{asset_id}/securityMarks` + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` + * + `folders/{folder_id}/assets/{asset_id}/securityMarks` + * + + * `folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` + * + `projects/{project_number}/assets/{asset_id}/securityMarks` + * + + * `projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks` + * + + * `projects/{project_number}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecurityMarks::initOnce(); + parent::__construct($data); + } + + /** + * The relative resource name of the SecurityMarks. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * The following list shows some examples: + * + `organizations/{organization_id}/assets/{asset_id}/securityMarks` + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The relative resource name of the SecurityMarks. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * The following list shows some examples: + * + `organizations/{organization_id}/assets/{asset_id}/securityMarks` + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Mutable user specified security marks belonging to the parent resource. + * Constraints are as follows: + * * Keys and values are treated as case insensitive + * * Keys must be between 1 - 256 characters (inclusive) + * * Keys must be letters, numbers, underscores, or dashes + * * Values have leading and trailing whitespace trimmed, remaining + * characters must be between 1 - 4096 characters (inclusive) + * + * Generated from protobuf field map marks = 2; + * @return \Google\Protobuf\Internal\MapField + */ + public function getMarks() + { + return $this->marks; + } + + /** + * Mutable user specified security marks belonging to the parent resource. + * Constraints are as follows: + * * Keys and values are treated as case insensitive + * * Keys must be between 1 - 256 characters (inclusive) + * * Keys must be letters, numbers, underscores, or dashes + * * Values have leading and trailing whitespace trimmed, remaining + * characters must be between 1 - 4096 characters (inclusive) + * + * Generated from protobuf field map marks = 2; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setMarks($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); + $this->marks = $arr; + + return $this; + } + + /** + * The canonical name of the marks. The following list shows some examples: + * + `organizations/{organization_id}/assets/{asset_id}/securityMarks` + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` + * + `folders/{folder_id}/assets/{asset_id}/securityMarks` + * + + * `folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` + * + `projects/{project_number}/assets/{asset_id}/securityMarks` + * + + * `projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks` + * + + * `projects/{project_number}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` + * + * Generated from protobuf field string canonical_name = 3; + * @return string + */ + public function getCanonicalName() + { + return $this->canonical_name; + } + + /** + * The canonical name of the marks. The following list shows some examples: + * + `organizations/{organization_id}/assets/{asset_id}/securityMarks` + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` + * + `folders/{folder_id}/assets/{asset_id}/securityMarks` + * + + * `folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` + * + `projects/{project_number}/assets/{asset_id}/securityMarks` + * + + * `projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks` + * + + * `projects/{project_number}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` + * + * Generated from protobuf field string canonical_name = 3; + * @param string $var + * @return $this + */ + public function setCanonicalName($var) + { + GPBUtil::checkString($var, True); + $this->canonical_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPolicy.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPolicy.php new file mode 100644 index 000000000000..efb0f5344f98 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPolicy.php @@ -0,0 +1,149 @@ +google.cloud.securitycenter.v2.SecurityPolicy + */ +class SecurityPolicy extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the Google Cloud Armor security policy, for example, + * "my-security-policy". + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The type of Google Cloud Armor security policy for example, 'backend + * security policy', 'edge security policy', 'network edge security policy', + * or 'always-on DDoS protection'. + * + * Generated from protobuf field string type = 2; + */ + protected $type = ''; + /** + * Whether or not the associated rule or policy is in preview mode. + * + * Generated from protobuf field bool preview = 3; + */ + protected $preview = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of the Google Cloud Armor security policy, for example, + * "my-security-policy". + * @type string $type + * The type of Google Cloud Armor security policy for example, 'backend + * security policy', 'edge security policy', 'network edge security policy', + * or 'always-on DDoS protection'. + * @type bool $preview + * Whether or not the associated rule or policy is in preview mode. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\CloudArmor::initOnce(); + parent::__construct($data); + } + + /** + * The name of the Google Cloud Armor security policy, for example, + * "my-security-policy". + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the Google Cloud Armor security policy, for example, + * "my-security-policy". + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The type of Google Cloud Armor security policy for example, 'backend + * security policy', 'edge security policy', 'network edge security policy', + * or 'always-on DDoS protection'. + * + * Generated from protobuf field string type = 2; + * @return string + */ + public function getType() + { + return $this->type; + } + + /** + * The type of Google Cloud Armor security policy for example, 'backend + * security policy', 'edge security policy', 'network edge security policy', + * or 'always-on DDoS protection'. + * + * Generated from protobuf field string type = 2; + * @param string $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkString($var, True); + $this->type = $var; + + return $this; + } + + /** + * Whether or not the associated rule or policy is in preview mode. + * + * Generated from protobuf field bool preview = 3; + * @return bool + */ + public function getPreview() + { + return $this->preview; + } + + /** + * Whether or not the associated rule or policy is in preview mode. + * + * Generated from protobuf field bool preview = 3; + * @param bool $var + * @return $this + */ + public function setPreview($var) + { + GPBUtil::checkBool($var); + $this->preview = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPosture.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPosture.php new file mode 100644 index 000000000000..04ba9a8280f7 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPosture.php @@ -0,0 +1,325 @@ +google.cloud.securitycenter.v2.SecurityPosture + */ +class SecurityPosture extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the posture, for example, `CIS-Posture`. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The version of the posture, for example, `c7cfa2a8`. + * + * Generated from protobuf field string revision_id = 2; + */ + protected $revision_id = ''; + /** + * The project, folder, or organization on which the posture is deployed, + * for example, `projects/{project_number}`. + * + * Generated from protobuf field string posture_deployment_resource = 3; + */ + protected $posture_deployment_resource = ''; + /** + * The name of the posture deployment, for example, + * `organizations/{org_id}/posturedeployments/{posture_deployment_id}`. + * + * Generated from protobuf field string posture_deployment = 4; + */ + protected $posture_deployment = ''; + /** + * The name of the updated policy, for example, + * `projects/{project_id}/policies/{constraint_name}`. + * + * Generated from protobuf field string changed_policy = 5; + */ + protected $changed_policy = ''; + /** + * The name of the updated policy set, for example, `cis-policyset`. + * + * Generated from protobuf field string policy_set = 6; + */ + protected $policy_set = ''; + /** + * The ID of the updated policy, for example, `compute-policy-1`. + * + * Generated from protobuf field string policy = 7; + */ + protected $policy = ''; + /** + * The details about a change in an updated policy that violates the deployed + * posture. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.SecurityPosture.PolicyDriftDetails policy_drift_details = 8; + */ + private $policy_drift_details; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Name of the posture, for example, `CIS-Posture`. + * @type string $revision_id + * The version of the posture, for example, `c7cfa2a8`. + * @type string $posture_deployment_resource + * The project, folder, or organization on which the posture is deployed, + * for example, `projects/{project_number}`. + * @type string $posture_deployment + * The name of the posture deployment, for example, + * `organizations/{org_id}/posturedeployments/{posture_deployment_id}`. + * @type string $changed_policy + * The name of the updated policy, for example, + * `projects/{project_id}/policies/{constraint_name}`. + * @type string $policy_set + * The name of the updated policy set, for example, `cis-policyset`. + * @type string $policy + * The ID of the updated policy, for example, `compute-policy-1`. + * @type array<\Google\Cloud\SecurityCenter\V2\SecurityPosture\PolicyDriftDetails>|\Google\Protobuf\Internal\RepeatedField $policy_drift_details + * The details about a change in an updated policy that violates the deployed + * posture. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecurityPosture::initOnce(); + parent::__construct($data); + } + + /** + * Name of the posture, for example, `CIS-Posture`. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Name of the posture, for example, `CIS-Posture`. + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The version of the posture, for example, `c7cfa2a8`. + * + * Generated from protobuf field string revision_id = 2; + * @return string + */ + public function getRevisionId() + { + return $this->revision_id; + } + + /** + * The version of the posture, for example, `c7cfa2a8`. + * + * Generated from protobuf field string revision_id = 2; + * @param string $var + * @return $this + */ + public function setRevisionId($var) + { + GPBUtil::checkString($var, True); + $this->revision_id = $var; + + return $this; + } + + /** + * The project, folder, or organization on which the posture is deployed, + * for example, `projects/{project_number}`. + * + * Generated from protobuf field string posture_deployment_resource = 3; + * @return string + */ + public function getPostureDeploymentResource() + { + return $this->posture_deployment_resource; + } + + /** + * The project, folder, or organization on which the posture is deployed, + * for example, `projects/{project_number}`. + * + * Generated from protobuf field string posture_deployment_resource = 3; + * @param string $var + * @return $this + */ + public function setPostureDeploymentResource($var) + { + GPBUtil::checkString($var, True); + $this->posture_deployment_resource = $var; + + return $this; + } + + /** + * The name of the posture deployment, for example, + * `organizations/{org_id}/posturedeployments/{posture_deployment_id}`. + * + * Generated from protobuf field string posture_deployment = 4; + * @return string + */ + public function getPostureDeployment() + { + return $this->posture_deployment; + } + + /** + * The name of the posture deployment, for example, + * `organizations/{org_id}/posturedeployments/{posture_deployment_id}`. + * + * Generated from protobuf field string posture_deployment = 4; + * @param string $var + * @return $this + */ + public function setPostureDeployment($var) + { + GPBUtil::checkString($var, True); + $this->posture_deployment = $var; + + return $this; + } + + /** + * The name of the updated policy, for example, + * `projects/{project_id}/policies/{constraint_name}`. + * + * Generated from protobuf field string changed_policy = 5; + * @return string + */ + public function getChangedPolicy() + { + return $this->changed_policy; + } + + /** + * The name of the updated policy, for example, + * `projects/{project_id}/policies/{constraint_name}`. + * + * Generated from protobuf field string changed_policy = 5; + * @param string $var + * @return $this + */ + public function setChangedPolicy($var) + { + GPBUtil::checkString($var, True); + $this->changed_policy = $var; + + return $this; + } + + /** + * The name of the updated policy set, for example, `cis-policyset`. + * + * Generated from protobuf field string policy_set = 6; + * @return string + */ + public function getPolicySet() + { + return $this->policy_set; + } + + /** + * The name of the updated policy set, for example, `cis-policyset`. + * + * Generated from protobuf field string policy_set = 6; + * @param string $var + * @return $this + */ + public function setPolicySet($var) + { + GPBUtil::checkString($var, True); + $this->policy_set = $var; + + return $this; + } + + /** + * The ID of the updated policy, for example, `compute-policy-1`. + * + * Generated from protobuf field string policy = 7; + * @return string + */ + public function getPolicy() + { + return $this->policy; + } + + /** + * The ID of the updated policy, for example, `compute-policy-1`. + * + * Generated from protobuf field string policy = 7; + * @param string $var + * @return $this + */ + public function setPolicy($var) + { + GPBUtil::checkString($var, True); + $this->policy = $var; + + return $this; + } + + /** + * The details about a change in an updated policy that violates the deployed + * posture. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.SecurityPosture.PolicyDriftDetails policy_drift_details = 8; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getPolicyDriftDetails() + { + return $this->policy_drift_details; + } + + /** + * The details about a change in an updated policy that violates the deployed + * posture. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.SecurityPosture.PolicyDriftDetails policy_drift_details = 8; + * @param array<\Google\Cloud\SecurityCenter\V2\SecurityPosture\PolicyDriftDetails>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setPolicyDriftDetails($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\SecurityPosture\PolicyDriftDetails::class); + $this->policy_drift_details = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPosture/PolicyDriftDetails.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPosture/PolicyDriftDetails.php new file mode 100644 index 000000000000..68b239c357d5 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPosture/PolicyDriftDetails.php @@ -0,0 +1,151 @@ +google.cloud.securitycenter.v2.SecurityPosture.PolicyDriftDetails + */ +class PolicyDriftDetails extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the updated field, for example + * constraint.implementation.policy_rules[0].enforce + * + * Generated from protobuf field string field = 1; + */ + protected $field = ''; + /** + * The value of this field that was configured in a posture, for example, + * `true` or `allowed_values={"projects/29831892"}`. + * + * Generated from protobuf field string expected_value = 2; + */ + protected $expected_value = ''; + /** + * The detected value that violates the deployed posture, for example, + * `false` or `allowed_values={"projects/22831892"}`. + * + * Generated from protobuf field string detected_value = 3; + */ + protected $detected_value = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $field + * The name of the updated field, for example + * constraint.implementation.policy_rules[0].enforce + * @type string $expected_value + * The value of this field that was configured in a posture, for example, + * `true` or `allowed_values={"projects/29831892"}`. + * @type string $detected_value + * The detected value that violates the deployed posture, for example, + * `false` or `allowed_values={"projects/22831892"}`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecurityPosture::initOnce(); + parent::__construct($data); + } + + /** + * The name of the updated field, for example + * constraint.implementation.policy_rules[0].enforce + * + * Generated from protobuf field string field = 1; + * @return string + */ + public function getField() + { + return $this->field; + } + + /** + * The name of the updated field, for example + * constraint.implementation.policy_rules[0].enforce + * + * Generated from protobuf field string field = 1; + * @param string $var + * @return $this + */ + public function setField($var) + { + GPBUtil::checkString($var, True); + $this->field = $var; + + return $this; + } + + /** + * The value of this field that was configured in a posture, for example, + * `true` or `allowed_values={"projects/29831892"}`. + * + * Generated from protobuf field string expected_value = 2; + * @return string + */ + public function getExpectedValue() + { + return $this->expected_value; + } + + /** + * The value of this field that was configured in a posture, for example, + * `true` or `allowed_values={"projects/29831892"}`. + * + * Generated from protobuf field string expected_value = 2; + * @param string $var + * @return $this + */ + public function setExpectedValue($var) + { + GPBUtil::checkString($var, True); + $this->expected_value = $var; + + return $this; + } + + /** + * The detected value that violates the deployed posture, for example, + * `false` or `allowed_values={"projects/22831892"}`. + * + * Generated from protobuf field string detected_value = 3; + * @return string + */ + public function getDetectedValue() + { + return $this->detected_value; + } + + /** + * The detected value that violates the deployed posture, for example, + * `false` or `allowed_values={"projects/22831892"}`. + * + * Generated from protobuf field string detected_value = 3; + * @param string $var + * @return $this + */ + public function setDetectedValue($var) + { + GPBUtil::checkString($var, True); + $this->detected_value = $var; + + return $this; + } + +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(PolicyDriftDetails::class, \Google\Cloud\SecurityCenter\V2\SecurityPosture_PolicyDriftDetails::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ServiceAccountDelegationInfo.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ServiceAccountDelegationInfo.php new file mode 100644 index 000000000000..4145baf6ef0b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ServiceAccountDelegationInfo.php @@ -0,0 +1,125 @@ +google.cloud.securitycenter.v2.ServiceAccountDelegationInfo + */ +class ServiceAccountDelegationInfo extends \Google\Protobuf\Internal\Message +{ + /** + * The email address of a Google account. + * + * Generated from protobuf field string principal_email = 1; + */ + protected $principal_email = ''; + /** + * A string representing the principal_subject associated with the identity. + * As compared to `principal_email`, supports principals that aren't + * associated with email addresses, such as third party principals. For most + * identities, the format will be `principal://iam.googleapis.com/{identity + * pool name}/subjects/{subject}` except for some GKE identities + * (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy + * format `serviceAccount:{identity pool name}[{subject}]` + * + * Generated from protobuf field string principal_subject = 2; + */ + protected $principal_subject = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $principal_email + * The email address of a Google account. + * @type string $principal_subject + * A string representing the principal_subject associated with the identity. + * As compared to `principal_email`, supports principals that aren't + * associated with email addresses, such as third party principals. For most + * identities, the format will be `principal://iam.googleapis.com/{identity + * pool name}/subjects/{subject}` except for some GKE identities + * (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy + * format `serviceAccount:{identity pool name}[{subject}]` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Access::initOnce(); + parent::__construct($data); + } + + /** + * The email address of a Google account. + * + * Generated from protobuf field string principal_email = 1; + * @return string + */ + public function getPrincipalEmail() + { + return $this->principal_email; + } + + /** + * The email address of a Google account. + * + * Generated from protobuf field string principal_email = 1; + * @param string $var + * @return $this + */ + public function setPrincipalEmail($var) + { + GPBUtil::checkString($var, True); + $this->principal_email = $var; + + return $this; + } + + /** + * A string representing the principal_subject associated with the identity. + * As compared to `principal_email`, supports principals that aren't + * associated with email addresses, such as third party principals. For most + * identities, the format will be `principal://iam.googleapis.com/{identity + * pool name}/subjects/{subject}` except for some GKE identities + * (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy + * format `serviceAccount:{identity pool name}[{subject}]` + * + * Generated from protobuf field string principal_subject = 2; + * @return string + */ + public function getPrincipalSubject() + { + return $this->principal_subject; + } + + /** + * A string representing the principal_subject associated with the identity. + * As compared to `principal_email`, supports principals that aren't + * associated with email addresses, such as third party principals. For most + * identities, the format will be `principal://iam.googleapis.com/{identity + * pool name}/subjects/{subject}` except for some GKE identities + * (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy + * format `serviceAccount:{identity pool name}[{subject}]` + * + * Generated from protobuf field string principal_subject = 2; + * @param string $var + * @return $this + */ + public function setPrincipalSubject($var) + { + GPBUtil::checkString($var, True); + $this->principal_subject = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SetFindingStateRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SetFindingStateRequest.php new file mode 100644 index 000000000000..dd5c233881f4 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SetFindingStateRequest.php @@ -0,0 +1,184 @@ +google.cloud.securitycenter.v2.SetFindingStateRequest + */ +class SetFindingStateRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. If no location is specified, finding is assumed to be in + * global. The following list shows some examples: + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` + * + + * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Required. The desired State of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.State state = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $state = 0; + + /** + * @param string $name Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. If no location is specified, finding is assumed to be in + * global. The following list shows some examples: + * + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` + * + + * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * Please see {@see SecurityCenterClient::findingName()} for help formatting this field. + * @param int $state Required. The desired State of the finding. + * For allowed values, use constants defined on {@see \Google\Cloud\SecurityCenter\V2\Finding\State} + * + * @return \Google\Cloud\SecurityCenter\V2\SetFindingStateRequest + * + * @experimental + */ + public static function build(string $name, int $state): self + { + return (new self()) + ->setName($name) + ->setState($state); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. If no location is specified, finding is assumed to be in + * global. The following list shows some examples: + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` + * + + * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * @type int $state + * Required. The desired State of the finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. If no location is specified, finding is assumed to be in + * global. The following list shows some examples: + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` + * + + * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. If no location is specified, finding is assumed to be in + * global. The following list shows some examples: + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` + * + + * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Required. The desired State of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.State state = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Required. The desired State of the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.State state = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Finding\State::class); + $this->state = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SetMuteRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SetMuteRequest.php new file mode 100644 index 000000000000..e8be7ff3aa7d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SetMuteRequest.php @@ -0,0 +1,184 @@ +google.cloud.securitycenter.v2.SetMuteRequest + */ +class SetMuteRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. If no location is specified, finding is assumed to be in + * global. The following list shows some examples: + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` + * + + * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Required. The desired state of the Mute. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.Mute mute = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $mute = 0; + + /** + * @param string $name Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. If no location is specified, finding is assumed to be in + * global. The following list shows some examples: + * + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` + * + + * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * Please see {@see SecurityCenterClient::findingName()} for help formatting this field. + * @param int $mute Required. The desired state of the Mute. + * For allowed values, use constants defined on {@see \Google\Cloud\SecurityCenter\V2\Finding\Mute} + * + * @return \Google\Cloud\SecurityCenter\V2\SetMuteRequest + * + * @experimental + */ + public static function build(string $name, int $mute): self + { + return (new self()) + ->setName($name) + ->setMute($mute); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. If no location is specified, finding is assumed to be in + * global. The following list shows some examples: + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` + * + + * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * @type int $mute + * Required. The desired state of the Mute. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. If no location is specified, finding is assumed to be in + * global. The following list shows some examples: + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` + * + + * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. The [relative resource + * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) + * of the finding. If no location is specified, finding is assumed to be in + * global. The following list shows some examples: + * + + * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` + * + + * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` + * + + * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` + * + + * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Required. The desired state of the Mute. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.Mute mute = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getMute() + { + return $this->mute; + } + + /** + * Required. The desired state of the Mute. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.Mute mute = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setMute($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Finding\Mute::class); + $this->mute = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Simulation.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Simulation.php new file mode 100644 index 000000000000..f94b7f0cface --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Simulation.php @@ -0,0 +1,187 @@ +google.cloud.securitycenter.v2.Simulation + */ +class Simulation extends \Google\Protobuf\Internal\Message +{ + /** + * Full resource name of the Simulation: + * organizations/123/simulations/456 + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Output only. Time simulation was created + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Resource value configurations' metadata used in this simulation. Maximum of + * 100. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfigMetadata resource_value_configs_metadata = 3; + */ + private $resource_value_configs_metadata; + /** + * Indicates which cloud provider was used in this simulation. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; + */ + protected $cloud_provider = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Full resource name of the Simulation: + * organizations/123/simulations/456 + * @type \Google\Protobuf\Timestamp $create_time + * Output only. Time simulation was created + * @type array<\Google\Cloud\SecurityCenter\V2\ResourceValueConfigMetadata>|\Google\Protobuf\Internal\RepeatedField $resource_value_configs_metadata + * Resource value configurations' metadata used in this simulation. Maximum of + * 100. + * @type int $cloud_provider + * Indicates which cloud provider was used in this simulation. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Simulation::initOnce(); + parent::__construct($data); + } + + /** + * Full resource name of the Simulation: + * organizations/123/simulations/456 + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Full resource name of the Simulation: + * organizations/123/simulations/456 + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Output only. Time simulation was created + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getCreateTime() + { + return $this->create_time; + } + + public function hasCreateTime() + { + return isset($this->create_time); + } + + public function clearCreateTime() + { + unset($this->create_time); + } + + /** + * Output only. Time simulation was created + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setCreateTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->create_time = $var; + + return $this; + } + + /** + * Resource value configurations' metadata used in this simulation. Maximum of + * 100. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfigMetadata resource_value_configs_metadata = 3; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getResourceValueConfigsMetadata() + { + return $this->resource_value_configs_metadata; + } + + /** + * Resource value configurations' metadata used in this simulation. Maximum of + * 100. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfigMetadata resource_value_configs_metadata = 3; + * @param array<\Google\Cloud\SecurityCenter\V2\ResourceValueConfigMetadata>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setResourceValueConfigsMetadata($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ResourceValueConfigMetadata::class); + $this->resource_value_configs_metadata = $arr; + + return $this; + } + + /** + * Indicates which cloud provider was used in this simulation. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; + * @return int + */ + public function getCloudProvider() + { + return $this->cloud_provider; + } + + /** + * Indicates which cloud provider was used in this simulation. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; + * @param int $var + * @return $this + */ + public function setCloudProvider($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\CloudProvider::class); + $this->cloud_provider = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Source.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Source.php new file mode 100644 index 000000000000..e129fd42ce1d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Source.php @@ -0,0 +1,244 @@ +google.cloud.securitycenter.v2.Source + */ +class Source extends \Google\Protobuf\Internal\Message +{ + /** + * The relative resource name of this source. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}" + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The source's display name. + * A source's display name must be unique amongst its siblings, for example, + * two sources with the same parent can't share the same display name. + * The display name must have a length between 1 and 64 characters + * (inclusive). + * + * Generated from protobuf field string display_name = 2; + */ + protected $display_name = ''; + /** + * The description of the source (max of 1024 characters). + * Example: + * "Web Security Scanner is a web security scanner for common + * vulnerabilities in App Engine applications. It can automatically + * scan and detect four common vulnerabilities, including cross-site-scripting + * (XSS), Flash injection, mixed content (HTTP in HTTPS), and + * outdated or insecure libraries." + * + * Generated from protobuf field string description = 3; + */ + protected $description = ''; + /** + * The canonical name of the finding source. It's either + * "organizations/{organization_id}/sources/{source_id}", + * "folders/{folder_id}/sources/{source_id}", or + * "projects/{project_number}/sources/{source_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * + * Generated from protobuf field string canonical_name = 4; + */ + protected $canonical_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The relative resource name of this source. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}" + * @type string $display_name + * The source's display name. + * A source's display name must be unique amongst its siblings, for example, + * two sources with the same parent can't share the same display name. + * The display name must have a length between 1 and 64 characters + * (inclusive). + * @type string $description + * The description of the source (max of 1024 characters). + * Example: + * "Web Security Scanner is a web security scanner for common + * vulnerabilities in App Engine applications. It can automatically + * scan and detect four common vulnerabilities, including cross-site-scripting + * (XSS), Flash injection, mixed content (HTTP in HTTPS), and + * outdated or insecure libraries." + * @type string $canonical_name + * The canonical name of the finding source. It's either + * "organizations/{organization_id}/sources/{source_id}", + * "folders/{folder_id}/sources/{source_id}", or + * "projects/{project_number}/sources/{source_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Source::initOnce(); + parent::__construct($data); + } + + /** + * The relative resource name of this source. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}" + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The relative resource name of this source. See: + * https://cloud.google.com/apis/design/resource_names#relative_resource_name + * Example: + * "organizations/{organization_id}/sources/{source_id}" + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The source's display name. + * A source's display name must be unique amongst its siblings, for example, + * two sources with the same parent can't share the same display name. + * The display name must have a length between 1 and 64 characters + * (inclusive). + * + * Generated from protobuf field string display_name = 2; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * The source's display name. + * A source's display name must be unique amongst its siblings, for example, + * two sources with the same parent can't share the same display name. + * The display name must have a length between 1 and 64 characters + * (inclusive). + * + * Generated from protobuf field string display_name = 2; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * The description of the source (max of 1024 characters). + * Example: + * "Web Security Scanner is a web security scanner for common + * vulnerabilities in App Engine applications. It can automatically + * scan and detect four common vulnerabilities, including cross-site-scripting + * (XSS), Flash injection, mixed content (HTTP in HTTPS), and + * outdated or insecure libraries." + * + * Generated from protobuf field string description = 3; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * The description of the source (max of 1024 characters). + * Example: + * "Web Security Scanner is a web security scanner for common + * vulnerabilities in App Engine applications. It can automatically + * scan and detect four common vulnerabilities, including cross-site-scripting + * (XSS), Flash injection, mixed content (HTTP in HTTPS), and + * outdated or insecure libraries." + * + * Generated from protobuf field string description = 3; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * The canonical name of the finding source. It's either + * "organizations/{organization_id}/sources/{source_id}", + * "folders/{folder_id}/sources/{source_id}", or + * "projects/{project_number}/sources/{source_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * + * Generated from protobuf field string canonical_name = 4; + * @return string + */ + public function getCanonicalName() + { + return $this->canonical_name; + } + + /** + * The canonical name of the finding source. It's either + * "organizations/{organization_id}/sources/{source_id}", + * "folders/{folder_id}/sources/{source_id}", or + * "projects/{project_number}/sources/{source_id}", + * depending on the closest CRM ancestor of the resource associated with the + * finding. + * + * Generated from protobuf field string canonical_name = 4; + * @param string $var + * @return $this + */ + public function setCanonicalName($var) + { + GPBUtil::checkString($var, True); + $this->canonical_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ToxicCombination.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ToxicCombination.php new file mode 100644 index 000000000000..28c16fe8e41e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ToxicCombination.php @@ -0,0 +1,124 @@ +google.cloud.securitycenter.v2.ToxicCombination + */ +class ToxicCombination extends \Google\Protobuf\Internal\Message +{ + /** + * The + * [Attack exposure + * score](https://cloud.google.com/security-command-center/docs/attack-exposure-learn#attack_exposure_scores) + * of this toxic combination. The score is a measure of how much this toxic + * combination exposes one or more high-value resources to potential attack. + * + * Generated from protobuf field double attack_exposure_score = 1; + */ + protected $attack_exposure_score = 0.0; + /** + * List of resource names of findings associated with this toxic combination. + * For example, `organizations/123/sources/456/findings/789`. + * + * Generated from protobuf field repeated string related_findings = 2; + */ + private $related_findings; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type float $attack_exposure_score + * The + * [Attack exposure + * score](https://cloud.google.com/security-command-center/docs/attack-exposure-learn#attack_exposure_scores) + * of this toxic combination. The score is a measure of how much this toxic + * combination exposes one or more high-value resources to potential attack. + * @type array|\Google\Protobuf\Internal\RepeatedField $related_findings + * List of resource names of findings associated with this toxic combination. + * For example, `organizations/123/sources/456/findings/789`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\ToxicCombination::initOnce(); + parent::__construct($data); + } + + /** + * The + * [Attack exposure + * score](https://cloud.google.com/security-command-center/docs/attack-exposure-learn#attack_exposure_scores) + * of this toxic combination. The score is a measure of how much this toxic + * combination exposes one or more high-value resources to potential attack. + * + * Generated from protobuf field double attack_exposure_score = 1; + * @return float + */ + public function getAttackExposureScore() + { + return $this->attack_exposure_score; + } + + /** + * The + * [Attack exposure + * score](https://cloud.google.com/security-command-center/docs/attack-exposure-learn#attack_exposure_scores) + * of this toxic combination. The score is a measure of how much this toxic + * combination exposes one or more high-value resources to potential attack. + * + * Generated from protobuf field double attack_exposure_score = 1; + * @param float $var + * @return $this + */ + public function setAttackExposureScore($var) + { + GPBUtil::checkDouble($var); + $this->attack_exposure_score = $var; + + return $this; + } + + /** + * List of resource names of findings associated with this toxic combination. + * For example, `organizations/123/sources/456/findings/789`. + * + * Generated from protobuf field repeated string related_findings = 2; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getRelatedFindings() + { + return $this->related_findings; + } + + /** + * List of resource names of findings associated with this toxic combination. + * For example, `organizations/123/sources/456/findings/789`. + * + * Generated from protobuf field repeated string related_findings = 2; + * @param array|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setRelatedFindings($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->related_findings = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateBigQueryExportRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateBigQueryExportRequest.php new file mode 100644 index 000000000000..7d92466628b3 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateBigQueryExportRequest.php @@ -0,0 +1,141 @@ +google.cloud.securitycenter.v2.UpdateBigQueryExportRequest + */ +class UpdateBigQueryExportRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The BigQuery export being updated. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.BigQueryExport big_query_export = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $big_query_export = null; + /** + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * @param \Google\Cloud\SecurityCenter\V2\BigQueryExport $bigQueryExport Required. The BigQuery export being updated. + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. + * If empty all mutable fields will be updated. + * + * @return \Google\Cloud\SecurityCenter\V2\UpdateBigQueryExportRequest + * + * @experimental + */ + public static function build(\Google\Cloud\SecurityCenter\V2\BigQueryExport $bigQueryExport, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setBigQueryExport($bigQueryExport) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V2\BigQueryExport $big_query_export + * Required. The BigQuery export being updated. + * @type \Google\Protobuf\FieldMask $update_mask + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The BigQuery export being updated. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.BigQueryExport big_query_export = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V2\BigQueryExport|null + */ + public function getBigQueryExport() + { + return $this->big_query_export; + } + + public function hasBigQueryExport() + { + return isset($this->big_query_export); + } + + public function clearBigQueryExport() + { + unset($this->big_query_export); + } + + /** + * Required. The BigQuery export being updated. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.BigQueryExport big_query_export = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V2\BigQueryExport $var + * @return $this + */ + public function setBigQueryExport($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\BigQueryExport::class); + $this->big_query_export = $var; + + return $this; + } + + /** + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateExternalSystemRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateExternalSystemRequest.php new file mode 100644 index 000000000000..ad459bb1e223 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateExternalSystemRequest.php @@ -0,0 +1,142 @@ +google.cloud.securitycenter.v2.UpdateExternalSystemRequest + */ +class UpdateExternalSystemRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The external system resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ExternalSystem external_system = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $external_system = null; + /** + * The FieldMask to use when updating the external system resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * @param \Google\Cloud\SecurityCenter\V2\ExternalSystem $externalSystem Required. The external system resource to update. + * @param \Google\Protobuf\FieldMask $updateMask The FieldMask to use when updating the external system resource. + * + * If empty all mutable fields will be updated. + * + * @return \Google\Cloud\SecurityCenter\V2\UpdateExternalSystemRequest + * + * @experimental + */ + public static function build(\Google\Cloud\SecurityCenter\V2\ExternalSystem $externalSystem, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setExternalSystem($externalSystem) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V2\ExternalSystem $external_system + * Required. The external system resource to update. + * @type \Google\Protobuf\FieldMask $update_mask + * The FieldMask to use when updating the external system resource. + * If empty all mutable fields will be updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The external system resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ExternalSystem external_system = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V2\ExternalSystem|null + */ + public function getExternalSystem() + { + return $this->external_system; + } + + public function hasExternalSystem() + { + return isset($this->external_system); + } + + public function clearExternalSystem() + { + unset($this->external_system); + } + + /** + * Required. The external system resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ExternalSystem external_system = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V2\ExternalSystem $var + * @return $this + */ + public function setExternalSystem($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ExternalSystem::class); + $this->external_system = $var; + + return $this; + } + + /** + * The FieldMask to use when updating the external system resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The FieldMask to use when updating the external system resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateFindingRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateFindingRequest.php new file mode 100644 index 000000000000..7f09a9ce90f0 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateFindingRequest.php @@ -0,0 +1,183 @@ +google.cloud.securitycenter.v2.UpdateFindingRequest + */ +class UpdateFindingRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The finding resource to update or create if it does not already + * exist. parent, security_marks, and update_time will be ignored. + * In the case of creation, the finding id portion of the name must be + * alphanumeric and less than or equal to 32 characters and greater than 0 + * characters in length. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $finding = null; + /** + * The FieldMask to use when updating the finding resource. This field should + * not be specified when creating a finding. + * When updating a finding, an empty mask is treated as updating all mutable + * fields and replacing source_properties. Individual source_properties can + * be added/updated by using "source_properties." in the field + * mask. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * @param \Google\Cloud\SecurityCenter\V2\Finding $finding Required. The finding resource to update or create if it does not already + * exist. parent, security_marks, and update_time will be ignored. + * + * In the case of creation, the finding id portion of the name must be + * alphanumeric and less than or equal to 32 characters and greater than 0 + * characters in length. + * @param \Google\Protobuf\FieldMask $updateMask The FieldMask to use when updating the finding resource. This field should + * not be specified when creating a finding. + * + * When updating a finding, an empty mask is treated as updating all mutable + * fields and replacing source_properties. Individual source_properties can + * be added/updated by using "source_properties." in the field + * mask. + * + * @return \Google\Cloud\SecurityCenter\V2\UpdateFindingRequest + * + * @experimental + */ + public static function build(\Google\Cloud\SecurityCenter\V2\Finding $finding, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setFinding($finding) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V2\Finding $finding + * Required. The finding resource to update or create if it does not already + * exist. parent, security_marks, and update_time will be ignored. + * In the case of creation, the finding id portion of the name must be + * alphanumeric and less than or equal to 32 characters and greater than 0 + * characters in length. + * @type \Google\Protobuf\FieldMask $update_mask + * The FieldMask to use when updating the finding resource. This field should + * not be specified when creating a finding. + * When updating a finding, an empty mask is treated as updating all mutable + * fields and replacing source_properties. Individual source_properties can + * be added/updated by using "source_properties." in the field + * mask. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The finding resource to update or create if it does not already + * exist. parent, security_marks, and update_time will be ignored. + * In the case of creation, the finding id portion of the name must be + * alphanumeric and less than or equal to 32 characters and greater than 0 + * characters in length. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V2\Finding|null + */ + public function getFinding() + { + return $this->finding; + } + + public function hasFinding() + { + return isset($this->finding); + } + + public function clearFinding() + { + unset($this->finding); + } + + /** + * Required. The finding resource to update or create if it does not already + * exist. parent, security_marks, and update_time will be ignored. + * In the case of creation, the finding id portion of the name must be + * alphanumeric and less than or equal to 32 characters and greater than 0 + * characters in length. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V2\Finding $var + * @return $this + */ + public function setFinding($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Finding::class); + $this->finding = $var; + + return $this; + } + + /** + * The FieldMask to use when updating the finding resource. This field should + * not be specified when creating a finding. + * When updating a finding, an empty mask is treated as updating all mutable + * fields and replacing source_properties. Individual source_properties can + * be added/updated by using "source_properties." in the field + * mask. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The FieldMask to use when updating the finding resource. This field should + * not be specified when creating a finding. + * When updating a finding, an empty mask is treated as updating all mutable + * fields and replacing source_properties. Individual source_properties can + * be added/updated by using "source_properties." in the field + * mask. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateMuteConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateMuteConfigRequest.php new file mode 100644 index 000000000000..a8d7e9e90164 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateMuteConfigRequest.php @@ -0,0 +1,141 @@ +google.cloud.securitycenter.v2.UpdateMuteConfigRequest + */ +class UpdateMuteConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The mute config being updated. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.MuteConfig mute_config = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $mute_config = null; + /** + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * @param \Google\Cloud\SecurityCenter\V2\MuteConfig $muteConfig Required. The mute config being updated. + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. + * If empty all mutable fields will be updated. + * + * @return \Google\Cloud\SecurityCenter\V2\UpdateMuteConfigRequest + * + * @experimental + */ + public static function build(\Google\Cloud\SecurityCenter\V2\MuteConfig $muteConfig, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setMuteConfig($muteConfig) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V2\MuteConfig $mute_config + * Required. The mute config being updated. + * @type \Google\Protobuf\FieldMask $update_mask + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The mute config being updated. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.MuteConfig mute_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V2\MuteConfig|null + */ + public function getMuteConfig() + { + return $this->mute_config; + } + + public function hasMuteConfig() + { + return isset($this->mute_config); + } + + public function clearMuteConfig() + { + unset($this->mute_config); + } + + /** + * Required. The mute config being updated. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.MuteConfig mute_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V2\MuteConfig $var + * @return $this + */ + public function setMuteConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\MuteConfig::class); + $this->mute_config = $var; + + return $this; + } + + /** + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateNotificationConfigRequest.php new file mode 100644 index 000000000000..f64cf1a15c06 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateNotificationConfigRequest.php @@ -0,0 +1,142 @@ +google.cloud.securitycenter.v2.UpdateNotificationConfigRequest + */ +class UpdateNotificationConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The notification config to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.NotificationConfig notification_config = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $notification_config = null; + /** + * The FieldMask to use when updating the notification config. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * @param \Google\Cloud\SecurityCenter\V2\NotificationConfig $notificationConfig Required. The notification config to update. + * @param \Google\Protobuf\FieldMask $updateMask The FieldMask to use when updating the notification config. + * + * If empty all mutable fields will be updated. + * + * @return \Google\Cloud\SecurityCenter\V2\UpdateNotificationConfigRequest + * + * @experimental + */ + public static function build(\Google\Cloud\SecurityCenter\V2\NotificationConfig $notificationConfig, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setNotificationConfig($notificationConfig) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V2\NotificationConfig $notification_config + * Required. The notification config to update. + * @type \Google\Protobuf\FieldMask $update_mask + * The FieldMask to use when updating the notification config. + * If empty all mutable fields will be updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The notification config to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.NotificationConfig notification_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V2\NotificationConfig|null + */ + public function getNotificationConfig() + { + return $this->notification_config; + } + + public function hasNotificationConfig() + { + return isset($this->notification_config); + } + + public function clearNotificationConfig() + { + unset($this->notification_config); + } + + /** + * Required. The notification config to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.NotificationConfig notification_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V2\NotificationConfig $var + * @return $this + */ + public function setNotificationConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\NotificationConfig::class); + $this->notification_config = $var; + + return $this; + } + + /** + * The FieldMask to use when updating the notification config. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The FieldMask to use when updating the notification config. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateResourceValueConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateResourceValueConfigRequest.php new file mode 100644 index 000000000000..95920b7f008d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateResourceValueConfigRequest.php @@ -0,0 +1,157 @@ +google.cloud.securitycenter.v2.UpdateResourceValueConfigRequest + */ +class UpdateResourceValueConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource value config being updated. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_config = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $resource_value_config = null; + /** + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * To update nested fields, include the top level field in the mask + * For example, to update gcp_metadata.resource_type, include the + * "gcp_metadata" field mask + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * @param \Google\Cloud\SecurityCenter\V2\ResourceValueConfig $resourceValueConfig Required. The resource value config being updated. + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. + * If empty all mutable fields will be updated. + * + * To update nested fields, include the top level field in the mask + * For example, to update gcp_metadata.resource_type, include the + * "gcp_metadata" field mask + * + * @return \Google\Cloud\SecurityCenter\V2\UpdateResourceValueConfigRequest + * + * @experimental + */ + public static function build(\Google\Cloud\SecurityCenter\V2\ResourceValueConfig $resourceValueConfig, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setResourceValueConfig($resourceValueConfig) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V2\ResourceValueConfig $resource_value_config + * Required. The resource value config being updated. + * @type \Google\Protobuf\FieldMask $update_mask + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * To update nested fields, include the top level field in the mask + * For example, to update gcp_metadata.resource_type, include the + * "gcp_metadata" field mask + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource value config being updated. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V2\ResourceValueConfig|null + */ + public function getResourceValueConfig() + { + return $this->resource_value_config; + } + + public function hasResourceValueConfig() + { + return isset($this->resource_value_config); + } + + public function clearResourceValueConfig() + { + unset($this->resource_value_config); + } + + /** + * Required. The resource value config being updated. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V2\ResourceValueConfig $var + * @return $this + */ + public function setResourceValueConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ResourceValueConfig::class); + $this->resource_value_config = $var; + + return $this; + } + + /** + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * To update nested fields, include the top level field in the mask + * For example, to update gcp_metadata.resource_type, include the + * "gcp_metadata" field mask + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The list of fields to be updated. + * If empty all mutable fields will be updated. + * To update nested fields, include the top level field in the mask + * For example, to update gcp_metadata.resource_type, include the + * "gcp_metadata" field mask + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateSecurityMarksRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateSecurityMarksRequest.php new file mode 100644 index 000000000000..14b3382b251b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateSecurityMarksRequest.php @@ -0,0 +1,152 @@ +google.cloud.securitycenter.v2.UpdateSecurityMarksRequest + */ +class UpdateSecurityMarksRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The security marks resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityMarks security_marks = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $security_marks = null; + /** + * The FieldMask to use when updating the security marks resource. + * The field mask must not contain duplicate fields. + * If empty or set to "marks", all marks will be replaced. Individual + * marks can be updated using "marks.". + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * @param \Google\Cloud\SecurityCenter\V2\SecurityMarks $securityMarks Required. The security marks resource to update. + * @param \Google\Protobuf\FieldMask $updateMask The FieldMask to use when updating the security marks resource. + * + * The field mask must not contain duplicate fields. + * If empty or set to "marks", all marks will be replaced. Individual + * marks can be updated using "marks.". + * + * @return \Google\Cloud\SecurityCenter\V2\UpdateSecurityMarksRequest + * + * @experimental + */ + public static function build(\Google\Cloud\SecurityCenter\V2\SecurityMarks $securityMarks, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setSecurityMarks($securityMarks) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V2\SecurityMarks $security_marks + * Required. The security marks resource to update. + * @type \Google\Protobuf\FieldMask $update_mask + * The FieldMask to use when updating the security marks resource. + * The field mask must not contain duplicate fields. + * If empty or set to "marks", all marks will be replaced. Individual + * marks can be updated using "marks.". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The security marks resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityMarks security_marks = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V2\SecurityMarks|null + */ + public function getSecurityMarks() + { + return $this->security_marks; + } + + public function hasSecurityMarks() + { + return isset($this->security_marks); + } + + public function clearSecurityMarks() + { + unset($this->security_marks); + } + + /** + * Required. The security marks resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityMarks security_marks = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V2\SecurityMarks $var + * @return $this + */ + public function setSecurityMarks($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\SecurityMarks::class); + $this->security_marks = $var; + + return $this; + } + + /** + * The FieldMask to use when updating the security marks resource. + * The field mask must not contain duplicate fields. + * If empty or set to "marks", all marks will be replaced. Individual + * marks can be updated using "marks.". + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The FieldMask to use when updating the security marks resource. + * The field mask must not contain duplicate fields. + * If empty or set to "marks", all marks will be replaced. Individual + * marks can be updated using "marks.". + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateSourceRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateSourceRequest.php new file mode 100644 index 000000000000..f4802b6d3c2c --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateSourceRequest.php @@ -0,0 +1,142 @@ +google.cloud.securitycenter.v2.UpdateSourceRequest + */ +class UpdateSourceRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The source resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Source source = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $source = null; + /** + * The FieldMask to use when updating the source resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * @param \Google\Cloud\SecurityCenter\V2\Source $source Required. The source resource to update. + * @param \Google\Protobuf\FieldMask $updateMask The FieldMask to use when updating the source resource. + * + * If empty all mutable fields will be updated. + * + * @return \Google\Cloud\SecurityCenter\V2\UpdateSourceRequest + * + * @experimental + */ + public static function build(\Google\Cloud\SecurityCenter\V2\Source $source, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setSource($source) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V2\Source $source + * Required. The source resource to update. + * @type \Google\Protobuf\FieldMask $update_mask + * The FieldMask to use when updating the source resource. + * If empty all mutable fields will be updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The source resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Source source = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\SecurityCenter\V2\Source|null + */ + public function getSource() + { + return $this->source; + } + + public function hasSource() + { + return isset($this->source); + } + + public function clearSource() + { + unset($this->source); + } + + /** + * Required. The source resource to update. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Source source = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\SecurityCenter\V2\Source $var + * @return $this + */ + public function setSource($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Source::class); + $this->source = $var; + + return $this; + } + + /** + * The FieldMask to use when updating the source resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @return \Google\Protobuf\FieldMask|null + */ + public function getUpdateMask() + { + return $this->update_mask; + } + + public function hasUpdateMask() + { + return isset($this->update_mask); + } + + public function clearUpdateMask() + { + unset($this->update_mask); + } + + /** + * The FieldMask to use when updating the source resource. + * If empty all mutable fields will be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ValuedResource.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ValuedResource.php new file mode 100644 index 000000000000..41aede0ba23d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ValuedResource.php @@ -0,0 +1,307 @@ +google.cloud.securitycenter.v2.ValuedResource + */ +class ValuedResource extends \Google\Protobuf\Internal\Message +{ + /** + * Valued resource name, for example, + * e.g.: + * `organizations/123/simulations/456/valuedResources/789` + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * The + * [full resource + * name](https://cloud.google.com/apis/design/resource_names#full_resource_name) + * of the valued resource. + * + * Generated from protobuf field string resource = 2; + */ + protected $resource = ''; + /** + * The [resource + * type](https://cloud.google.com/asset-inventory/docs/supported-asset-types) + * of the valued resource. + * + * Generated from protobuf field string resource_type = 3; + */ + protected $resource_type = ''; + /** + * Human-readable name of the valued resource. + * + * Generated from protobuf field string display_name = 4; + */ + protected $display_name = ''; + /** + * How valuable this resource is. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ValuedResource.ResourceValue resource_value = 5; + */ + protected $resource_value = 0; + /** + * Exposed score for this valued resource. A value of 0 means no exposure was + * detected exposure. + * + * Generated from protobuf field double exposed_score = 6; + */ + protected $exposed_score = 0.0; + /** + * List of resource value configurations' metadata used to determine the value + * of this resource. Maximum of 100. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfigMetadata resource_value_configs_used = 7; + */ + private $resource_value_configs_used; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Valued resource name, for example, + * e.g.: + * `organizations/123/simulations/456/valuedResources/789` + * @type string $resource + * The + * [full resource + * name](https://cloud.google.com/apis/design/resource_names#full_resource_name) + * of the valued resource. + * @type string $resource_type + * The [resource + * type](https://cloud.google.com/asset-inventory/docs/supported-asset-types) + * of the valued resource. + * @type string $display_name + * Human-readable name of the valued resource. + * @type int $resource_value + * How valuable this resource is. + * @type float $exposed_score + * Exposed score for this valued resource. A value of 0 means no exposure was + * detected exposure. + * @type array<\Google\Cloud\SecurityCenter\V2\ResourceValueConfigMetadata>|\Google\Protobuf\Internal\RepeatedField $resource_value_configs_used + * List of resource value configurations' metadata used to determine the value + * of this resource. Maximum of 100. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\ValuedResource::initOnce(); + parent::__construct($data); + } + + /** + * Valued resource name, for example, + * e.g.: + * `organizations/123/simulations/456/valuedResources/789` + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Valued resource name, for example, + * e.g.: + * `organizations/123/simulations/456/valuedResources/789` + * + * Generated from protobuf field string name = 1; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * The + * [full resource + * name](https://cloud.google.com/apis/design/resource_names#full_resource_name) + * of the valued resource. + * + * Generated from protobuf field string resource = 2; + * @return string + */ + public function getResource() + { + return $this->resource; + } + + /** + * The + * [full resource + * name](https://cloud.google.com/apis/design/resource_names#full_resource_name) + * of the valued resource. + * + * Generated from protobuf field string resource = 2; + * @param string $var + * @return $this + */ + public function setResource($var) + { + GPBUtil::checkString($var, True); + $this->resource = $var; + + return $this; + } + + /** + * The [resource + * type](https://cloud.google.com/asset-inventory/docs/supported-asset-types) + * of the valued resource. + * + * Generated from protobuf field string resource_type = 3; + * @return string + */ + public function getResourceType() + { + return $this->resource_type; + } + + /** + * The [resource + * type](https://cloud.google.com/asset-inventory/docs/supported-asset-types) + * of the valued resource. + * + * Generated from protobuf field string resource_type = 3; + * @param string $var + * @return $this + */ + public function setResourceType($var) + { + GPBUtil::checkString($var, True); + $this->resource_type = $var; + + return $this; + } + + /** + * Human-readable name of the valued resource. + * + * Generated from protobuf field string display_name = 4; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * Human-readable name of the valued resource. + * + * Generated from protobuf field string display_name = 4; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * How valuable this resource is. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ValuedResource.ResourceValue resource_value = 5; + * @return int + */ + public function getResourceValue() + { + return $this->resource_value; + } + + /** + * How valuable this resource is. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ValuedResource.ResourceValue resource_value = 5; + * @param int $var + * @return $this + */ + public function setResourceValue($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\ValuedResource\ResourceValue::class); + $this->resource_value = $var; + + return $this; + } + + /** + * Exposed score for this valued resource. A value of 0 means no exposure was + * detected exposure. + * + * Generated from protobuf field double exposed_score = 6; + * @return float + */ + public function getExposedScore() + { + return $this->exposed_score; + } + + /** + * Exposed score for this valued resource. A value of 0 means no exposure was + * detected exposure. + * + * Generated from protobuf field double exposed_score = 6; + * @param float $var + * @return $this + */ + public function setExposedScore($var) + { + GPBUtil::checkDouble($var); + $this->exposed_score = $var; + + return $this; + } + + /** + * List of resource value configurations' metadata used to determine the value + * of this resource. Maximum of 100. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfigMetadata resource_value_configs_used = 7; + * @return \Google\Protobuf\Internal\RepeatedField + */ + public function getResourceValueConfigsUsed() + { + return $this->resource_value_configs_used; + } + + /** + * List of resource value configurations' metadata used to determine the value + * of this resource. Maximum of 100. + * + * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfigMetadata resource_value_configs_used = 7; + * @param array<\Google\Cloud\SecurityCenter\V2\ResourceValueConfigMetadata>|\Google\Protobuf\Internal\RepeatedField $var + * @return $this + */ + public function setResourceValueConfigsUsed($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ResourceValueConfigMetadata::class); + $this->resource_value_configs_used = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ValuedResource/ResourceValue.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ValuedResource/ResourceValue.php new file mode 100644 index 000000000000..d6b2831a2751 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ValuedResource/ResourceValue.php @@ -0,0 +1,71 @@ +google.cloud.securitycenter.v2.ValuedResource.ResourceValue + */ +class ResourceValue +{ + /** + * The resource value isn't specified. + * + * Generated from protobuf enum RESOURCE_VALUE_UNSPECIFIED = 0; + */ + const RESOURCE_VALUE_UNSPECIFIED = 0; + /** + * This is a low-value resource. + * + * Generated from protobuf enum RESOURCE_VALUE_LOW = 1; + */ + const RESOURCE_VALUE_LOW = 1; + /** + * This is a medium-value resource. + * + * Generated from protobuf enum RESOURCE_VALUE_MEDIUM = 2; + */ + const RESOURCE_VALUE_MEDIUM = 2; + /** + * This is a high-value resource. + * + * Generated from protobuf enum RESOURCE_VALUE_HIGH = 3; + */ + const RESOURCE_VALUE_HIGH = 3; + + private static $valueToName = [ + self::RESOURCE_VALUE_UNSPECIFIED => 'RESOURCE_VALUE_UNSPECIFIED', + self::RESOURCE_VALUE_LOW => 'RESOURCE_VALUE_LOW', + self::RESOURCE_VALUE_MEDIUM => 'RESOURCE_VALUE_MEDIUM', + self::RESOURCE_VALUE_HIGH => 'RESOURCE_VALUE_HIGH', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + +// Adding a class alias for backwards compatibility with the previous class name. +class_alias(ResourceValue::class, \Google\Cloud\SecurityCenter\V2\ValuedResource_ResourceValue::class); + diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Vulnerability.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Vulnerability.php new file mode 100644 index 000000000000..780743966879 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Vulnerability.php @@ -0,0 +1,213 @@ +google.cloud.securitycenter.v2.Vulnerability + */ +class Vulnerability extends \Google\Protobuf\Internal\Message +{ + /** + * CVE stands for Common Vulnerabilities and Exposures + * (https://cve.mitre.org/about/) + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cve cve = 1; + */ + protected $cve = null; + /** + * The offending package is relevant to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Package offending_package = 2; + */ + protected $offending_package = null; + /** + * The fixed package is relevant to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Package fixed_package = 3; + */ + protected $fixed_package = null; + /** + * The security bulletin is relevant to this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityBulletin security_bulletin = 4; + */ + protected $security_bulletin = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\SecurityCenter\V2\Cve $cve + * CVE stands for Common Vulnerabilities and Exposures + * (https://cve.mitre.org/about/) + * @type \Google\Cloud\SecurityCenter\V2\Package $offending_package + * The offending package is relevant to the finding. + * @type \Google\Cloud\SecurityCenter\V2\Package $fixed_package + * The fixed package is relevant to the finding. + * @type \Google\Cloud\SecurityCenter\V2\SecurityBulletin $security_bulletin + * The security bulletin is relevant to this finding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Securitycenter\V2\Vulnerability::initOnce(); + parent::__construct($data); + } + + /** + * CVE stands for Common Vulnerabilities and Exposures + * (https://cve.mitre.org/about/) + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cve cve = 1; + * @return \Google\Cloud\SecurityCenter\V2\Cve|null + */ + public function getCve() + { + return $this->cve; + } + + public function hasCve() + { + return isset($this->cve); + } + + public function clearCve() + { + unset($this->cve); + } + + /** + * CVE stands for Common Vulnerabilities and Exposures + * (https://cve.mitre.org/about/) + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Cve cve = 1; + * @param \Google\Cloud\SecurityCenter\V2\Cve $var + * @return $this + */ + public function setCve($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Cve::class); + $this->cve = $var; + + return $this; + } + + /** + * The offending package is relevant to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Package offending_package = 2; + * @return \Google\Cloud\SecurityCenter\V2\Package|null + */ + public function getOffendingPackage() + { + return $this->offending_package; + } + + public function hasOffendingPackage() + { + return isset($this->offending_package); + } + + public function clearOffendingPackage() + { + unset($this->offending_package); + } + + /** + * The offending package is relevant to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Package offending_package = 2; + * @param \Google\Cloud\SecurityCenter\V2\Package $var + * @return $this + */ + public function setOffendingPackage($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Package::class); + $this->offending_package = $var; + + return $this; + } + + /** + * The fixed package is relevant to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Package fixed_package = 3; + * @return \Google\Cloud\SecurityCenter\V2\Package|null + */ + public function getFixedPackage() + { + return $this->fixed_package; + } + + public function hasFixedPackage() + { + return isset($this->fixed_package); + } + + public function clearFixedPackage() + { + unset($this->fixed_package); + } + + /** + * The fixed package is relevant to the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Package fixed_package = 3; + * @param \Google\Cloud\SecurityCenter\V2\Package $var + * @return $this + */ + public function setFixedPackage($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Package::class); + $this->fixed_package = $var; + + return $this; + } + + /** + * The security bulletin is relevant to this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityBulletin security_bulletin = 4; + * @return \Google\Cloud\SecurityCenter\V2\SecurityBulletin|null + */ + public function getSecurityBulletin() + { + return $this->security_bulletin; + } + + public function hasSecurityBulletin() + { + return isset($this->security_bulletin); + } + + public function clearSecurityBulletin() + { + unset($this->security_bulletin); + } + + /** + * The security bulletin is relevant to this finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityBulletin security_bulletin = 4; + * @param \Google\Cloud\SecurityCenter\V2\SecurityBulletin $var + * @return $this + */ + public function setSecurityBulletin($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\SecurityBulletin::class); + $this->security_bulletin = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/batch_create_resource_value_configs.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/batch_create_resource_value_configs.php new file mode 100644 index 000000000000..f2258fa62849 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/batch_create_resource_value_configs.php @@ -0,0 +1,102 @@ +AND to check against. + * Values in the form "tagValues/123" + * Example: [ "tagValues/123", "tagValues/456", "tagValues/789" ] + * https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing + */ +function batch_create_resource_value_configs_sample( + string $formattedParent, + string $formattedRequestsParent, + string $requestsResourceValueConfigTagValuesElement +): void { + // Create a client. + $securityCenterClient = new SecurityCenterClient(); + + // Prepare the request message. + $requestsResourceValueConfigTagValues = [$requestsResourceValueConfigTagValuesElement,]; + $requestsResourceValueConfig = (new ResourceValueConfig()) + ->setTagValues($requestsResourceValueConfigTagValues); + $createResourceValueConfigRequest = (new CreateResourceValueConfigRequest()) + ->setParent($formattedRequestsParent) + ->setResourceValueConfig($requestsResourceValueConfig); + $requests = [$createResourceValueConfigRequest,]; + $request = (new BatchCreateResourceValueConfigsRequest()) + ->setParent($formattedParent) + ->setRequests($requests); + + // Call the API and handle any network failures. + try { + /** @var BatchCreateResourceValueConfigsResponse $response */ + $response = $securityCenterClient->batchCreateResourceValueConfigs($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $formattedRequestsParent = SecurityCenterClient::organizationLocationName( + '[ORGANIZATION]', + '[LOCATION]' + ); + $requestsResourceValueConfigTagValuesElement = '[TAG_VALUES]'; + + batch_create_resource_value_configs_sample( + $formattedParent, + $formattedRequestsParent, + $requestsResourceValueConfigTagValuesElement + ); +} +// [END securitycenter_v2_generated_SecurityCenter_BatchCreateResourceValueConfigs_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/bulk_mute_findings.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/bulk_mute_findings.php new file mode 100644 index 000000000000..0300825d282f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/bulk_mute_findings.php @@ -0,0 +1,94 @@ +setParent($parent); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $securityCenterClient->bulkMuteFindings($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var BulkMuteFindingsResponse $result */ + $result = $response->getResult(); + printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString()); + } else { + /** @var Status $error */ + $error = $response->getError(); + printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $parent = '[PARENT]'; + + bulk_mute_findings_sample($parent); +} +// [END securitycenter_v2_generated_SecurityCenter_BulkMuteFindings_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_big_query_export.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_big_query_export.php new file mode 100644 index 000000000000..deac9b2687cd --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_big_query_export.php @@ -0,0 +1,82 @@ +setParent($formattedParent) + ->setBigQueryExport($bigQueryExport) + ->setBigQueryExportId($bigQueryExportId); + + // Call the API and handle any network failures. + try { + /** @var BigQueryExport $response */ + $response = $securityCenterClient->createBigQueryExport($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $bigQueryExportId = '[BIG_QUERY_EXPORT_ID]'; + + create_big_query_export_sample($formattedParent, $bigQueryExportId); +} +// [END securitycenter_v2_generated_SecurityCenter_CreateBigQueryExport_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_finding.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_finding.php new file mode 100644 index 000000000000..bbc174b8fc52 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_finding.php @@ -0,0 +1,84 @@ +setParent($formattedParent) + ->setFindingId($findingId) + ->setFinding($finding); + + // Call the API and handle any network failures. + try { + /** @var Finding $response */ + $response = $securityCenterClient->createFinding($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); + $findingId = '[FINDING_ID]'; + + create_finding_sample($formattedParent, $findingId); +} +// [END securitycenter_v2_generated_SecurityCenter_CreateFinding_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_mute_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_mute_config.php new file mode 100644 index 000000000000..397847206476 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_mute_config.php @@ -0,0 +1,113 @@ +setFilter($muteConfigFilter) + ->setType($muteConfigType); + $request = (new CreateMuteConfigRequest()) + ->setParent($formattedParent) + ->setMuteConfig($muteConfig) + ->setMuteConfigId($muteConfigId); + + // Call the API and handle any network failures. + try { + /** @var MuteConfig $response */ + $response = $securityCenterClient->createMuteConfig($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $muteConfigFilter = '[FILTER]'; + $muteConfigType = MuteConfigType::MUTE_CONFIG_TYPE_UNSPECIFIED; + $muteConfigId = '[MUTE_CONFIG_ID]'; + + create_mute_config_sample($formattedParent, $muteConfigFilter, $muteConfigType, $muteConfigId); +} +// [END securitycenter_v2_generated_SecurityCenter_CreateMuteConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_notification_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_notification_config.php new file mode 100644 index 000000000000..773db97e5540 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_notification_config.php @@ -0,0 +1,82 @@ +setParent($formattedParent) + ->setConfigId($configId) + ->setNotificationConfig($notificationConfig); + + // Call the API and handle any network failures. + try { + /** @var NotificationConfig $response */ + $response = $securityCenterClient->createNotificationConfig($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $configId = '[CONFIG_ID]'; + + create_notification_config_sample($formattedParent, $configId); +} +// [END securitycenter_v2_generated_SecurityCenter_CreateNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_source.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_source.php new file mode 100644 index 000000000000..5bf33ef01ff3 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_source.php @@ -0,0 +1,74 @@ +setParent($formattedParent) + ->setSource($source); + + // Call the API and handle any network failures. + try { + /** @var Source $response */ + $response = $securityCenterClient->createSource($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::organizationName('[ORGANIZATION]'); + + create_source_sample($formattedParent); +} +// [END securitycenter_v2_generated_SecurityCenter_CreateSource_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_big_query_export.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_big_query_export.php new file mode 100644 index 000000000000..d7c566a4f58d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_big_query_export.php @@ -0,0 +1,79 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + $securityCenterClient->deleteBigQueryExport($request); + printf('Call completed successfully.' . PHP_EOL); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::bigQueryExportName( + '[ORGANIZATION]', + '[LOCATION]', + '[EXPORT]' + ); + + delete_big_query_export_sample($formattedName); +} +// [END securitycenter_v2_generated_SecurityCenter_DeleteBigQueryExport_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_mute_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_mute_config.php new file mode 100644 index 000000000000..fce07f47bcbd --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_mute_config.php @@ -0,0 +1,79 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + $securityCenterClient->deleteMuteConfig($request); + printf('Call completed successfully.' . PHP_EOL); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); + + delete_mute_config_sample($formattedName); +} +// [END securitycenter_v2_generated_SecurityCenter_DeleteMuteConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_notification_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_notification_config.php new file mode 100644 index 000000000000..6a96dd10f38f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_notification_config.php @@ -0,0 +1,81 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + $securityCenterClient->deleteNotificationConfig($request); + printf('Call completed successfully.' . PHP_EOL); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::notificationConfigName( + '[ORGANIZATION]', + '[LOCATION]', + '[NOTIFICATION_CONFIG]' + ); + + delete_notification_config_sample($formattedName); +} +// [END securitycenter_v2_generated_SecurityCenter_DeleteNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_resource_value_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_resource_value_config.php new file mode 100644 index 000000000000..28fbd37e6393 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_resource_value_config.php @@ -0,0 +1,72 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + $securityCenterClient->deleteResourceValueConfig($request); + printf('Call completed successfully.' . PHP_EOL); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::resourceValueConfigName( + '[ORGANIZATION]', + '[RESOURCE_VALUE_CONFIG]' + ); + + delete_resource_value_config_sample($formattedName); +} +// [END securitycenter_v2_generated_SecurityCenter_DeleteResourceValueConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_big_query_export.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_big_query_export.php new file mode 100644 index 000000000000..220e37216f30 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_big_query_export.php @@ -0,0 +1,81 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var BigQueryExport $response */ + $response = $securityCenterClient->getBigQueryExport($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::bigQueryExportName( + '[ORGANIZATION]', + '[LOCATION]', + '[EXPORT]' + ); + + get_big_query_export_sample($formattedName); +} +// [END securitycenter_v2_generated_SecurityCenter_GetBigQueryExport_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_iam_policy.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_iam_policy.php new file mode 100644 index 000000000000..bc5da467b950 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_iam_policy.php @@ -0,0 +1,71 @@ +setResource($resource); + + // Call the API and handle any network failures. + try { + /** @var Policy $response */ + $response = $securityCenterClient->getIamPolicy($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $resource = '[RESOURCE]'; + + get_iam_policy_sample($resource); +} +// [END securitycenter_v2_generated_SecurityCenter_GetIamPolicy_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_mute_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_mute_config.php new file mode 100644 index 000000000000..c8770040f68e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_mute_config.php @@ -0,0 +1,81 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var MuteConfig $response */ + $response = $securityCenterClient->getMuteConfig($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); + + get_mute_config_sample($formattedName); +} +// [END securitycenter_v2_generated_SecurityCenter_GetMuteConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_notification_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_notification_config.php new file mode 100644 index 000000000000..975ee2350a5e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_notification_config.php @@ -0,0 +1,83 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var NotificationConfig $response */ + $response = $securityCenterClient->getNotificationConfig($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::notificationConfigName( + '[ORGANIZATION]', + '[LOCATION]', + '[NOTIFICATION_CONFIG]' + ); + + get_notification_config_sample($formattedName); +} +// [END securitycenter_v2_generated_SecurityCenter_GetNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_resource_value_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_resource_value_config.php new file mode 100644 index 000000000000..0412e23f52a6 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_resource_value_config.php @@ -0,0 +1,75 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var ResourceValueConfig $response */ + $response = $securityCenterClient->getResourceValueConfig($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::resourceValueConfigName( + '[ORGANIZATION]', + '[RESOURCE_VALUE_CONFIG]' + ); + + get_resource_value_config_sample($formattedName); +} +// [END securitycenter_v2_generated_SecurityCenter_GetResourceValueConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_simulation.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_simulation.php new file mode 100644 index 000000000000..323b8e239677 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_simulation.php @@ -0,0 +1,76 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var Simulation $response */ + $response = $securityCenterClient->getSimulation($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::simulationName('[ORGANIZATION]', '[SIMULATION]'); + + get_simulation_sample($formattedName); +} +// [END securitycenter_v2_generated_SecurityCenter_GetSimulation_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_source.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_source.php new file mode 100644 index 000000000000..d9edaa9e9ff7 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_source.php @@ -0,0 +1,72 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var Source $response */ + $response = $securityCenterClient->getSource($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); + + get_source_sample($formattedName); +} +// [END securitycenter_v2_generated_SecurityCenter_GetSource_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_valued_resource.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_valued_resource.php new file mode 100644 index 000000000000..56b54dd0da66 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_valued_resource.php @@ -0,0 +1,78 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var ValuedResource $response */ + $response = $securityCenterClient->getValuedResource($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::valuedResourceName( + '[ORGANIZATION]', + '[SIMULATION]', + '[VALUED_RESOURCE]' + ); + + get_valued_resource_sample($formattedName); +} +// [END securitycenter_v2_generated_SecurityCenter_GetValuedResource_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/group_findings.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/group_findings.php new file mode 100644 index 000000000000..17c770cff8f4 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/group_findings.php @@ -0,0 +1,114 @@ +setParent($formattedParent) + ->setGroupBy($groupBy); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->groupFindings($request); + + /** @var GroupResult $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); + $groupBy = '[GROUP_BY]'; + + group_findings_sample($formattedParent, $groupBy); +} +// [END securitycenter_v2_generated_SecurityCenter_GroupFindings_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_attack_paths.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_attack_paths.php new file mode 100644 index 000000000000..c73ae4482d56 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_attack_paths.php @@ -0,0 +1,88 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->listAttackPaths($request); + + /** @var AttackPath $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::organizationValuedResourceName( + '[ORGANIZATION]', + '[LOCATION]', + '[SIMULATION]', + '[VALUED_RESOURCE]' + ); + + list_attack_paths_sample($formattedParent); +} +// [END securitycenter_v2_generated_SecurityCenter_ListAttackPaths_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_big_query_exports.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_big_query_exports.php new file mode 100644 index 000000000000..98209ecb6106 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_big_query_exports.php @@ -0,0 +1,83 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->listBigQueryExports($request); + + /** @var BigQueryExport $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + + list_big_query_exports_sample($formattedParent); +} +// [END securitycenter_v2_generated_SecurityCenter_ListBigQueryExports_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_findings.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_findings.php new file mode 100644 index 000000000000..f1a611b5f476 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_findings.php @@ -0,0 +1,103 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->listFindings($request); + + /** @var ListFindingsResult $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); + + list_findings_sample($formattedParent); +} +// [END securitycenter_v2_generated_SecurityCenter_ListFindings_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_mute_configs.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_mute_configs.php new file mode 100644 index 000000000000..c9f315f496ee --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_mute_configs.php @@ -0,0 +1,82 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->listMuteConfigs($request); + + /** @var MuteConfig $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + + list_mute_configs_sample($formattedParent); +} +// [END securitycenter_v2_generated_SecurityCenter_ListMuteConfigs_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_notification_configs.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_notification_configs.php new file mode 100644 index 000000000000..185c3518d48f --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_notification_configs.php @@ -0,0 +1,80 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->listNotificationConfigs($request); + + /** @var NotificationConfig $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + + list_notification_configs_sample($formattedParent); +} +// [END securitycenter_v2_generated_SecurityCenter_ListNotificationConfigs_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_resource_value_configs.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_resource_value_configs.php new file mode 100644 index 000000000000..63ea9e8e6697 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_resource_value_configs.php @@ -0,0 +1,78 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->listResourceValueConfigs($request); + + /** @var ResourceValueConfig $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + + list_resource_value_configs_sample($formattedParent); +} +// [END securitycenter_v2_generated_SecurityCenter_ListResourceValueConfigs_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_sources.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_sources.php new file mode 100644 index 000000000000..47b9882c05dd --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_sources.php @@ -0,0 +1,78 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->listSources($request); + + /** @var Source $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); + + list_sources_sample($formattedParent); +} +// [END securitycenter_v2_generated_SecurityCenter_ListSources_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_valued_resources.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_valued_resources.php new file mode 100644 index 000000000000..b3732d2b7a53 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_valued_resources.php @@ -0,0 +1,81 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $securityCenterClient->listValuedResources($request); + + /** @var ValuedResource $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedParent = SecurityCenterClient::simulationName('[ORGANIZATION]', '[SIMULATION]'); + + list_valued_resources_sample($formattedParent); +} +// [END securitycenter_v2_generated_SecurityCenter_ListValuedResources_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_finding_state.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_finding_state.php new file mode 100644 index 000000000000..51e2901ef3cc --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_finding_state.php @@ -0,0 +1,90 @@ +setName($formattedName) + ->setState($state); + + // Call the API and handle any network failures. + try { + /** @var Finding $response */ + $response = $securityCenterClient->setFindingState($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + $state = State::STATE_UNSPECIFIED; + + set_finding_state_sample($formattedName, $state); +} +// [END securitycenter_v2_generated_SecurityCenter_SetFindingState_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_iam_policy.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_iam_policy.php new file mode 100644 index 000000000000..994eae7c0930 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_iam_policy.php @@ -0,0 +1,73 @@ +setResource($resource) + ->setPolicy($policy); + + // Call the API and handle any network failures. + try { + /** @var Policy $response */ + $response = $securityCenterClient->setIamPolicy($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $resource = '[RESOURCE]'; + + set_iam_policy_sample($resource); +} +// [END securitycenter_v2_generated_SecurityCenter_SetIamPolicy_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_mute.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_mute.php new file mode 100644 index 000000000000..46e7f2382bdc --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_mute.php @@ -0,0 +1,90 @@ +setName($formattedName) + ->setMute($mute); + + // Call the API and handle any network failures. + try { + /** @var Finding $response */ + $response = $securityCenterClient->setMute($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $formattedName = SecurityCenterClient::findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + $mute = Mute::MUTE_UNSPECIFIED; + + set_mute_sample($formattedName, $mute); +} +// [END securitycenter_v2_generated_SecurityCenter_SetMute_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/test_iam_permissions.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/test_iam_permissions.php new file mode 100644 index 000000000000..8b4e4297173e --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/test_iam_permissions.php @@ -0,0 +1,78 @@ +setResource($resource) + ->setPermissions($permissions); + + // Call the API and handle any network failures. + try { + /** @var TestIamPermissionsResponse $response */ + $response = $securityCenterClient->testIamPermissions($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $resource = '[RESOURCE]'; + $permissionsElement = '[PERMISSIONS]'; + + test_iam_permissions_sample($resource, $permissionsElement); +} +// [END securitycenter_v2_generated_SecurityCenter_TestIamPermissions_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_big_query_export.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_big_query_export.php new file mode 100644 index 000000000000..3701cd360e27 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_big_query_export.php @@ -0,0 +1,59 @@ +setBigQueryExport($bigQueryExport); + + // Call the API and handle any network failures. + try { + /** @var BigQueryExport $response */ + $response = $securityCenterClient->updateBigQueryExport($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END securitycenter_v2_generated_SecurityCenter_UpdateBigQueryExport_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_external_system.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_external_system.php new file mode 100644 index 000000000000..3036bdbefd69 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_external_system.php @@ -0,0 +1,60 @@ +setExternalSystem($externalSystem); + + // Call the API and handle any network failures. + try { + /** @var ExternalSystem $response */ + $response = $securityCenterClient->updateExternalSystem($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END securitycenter_v2_generated_SecurityCenter_UpdateExternalSystem_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_finding.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_finding.php new file mode 100644 index 000000000000..06fd8eb4aac9 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_finding.php @@ -0,0 +1,61 @@ +setFinding($finding); + + // Call the API and handle any network failures. + try { + /** @var Finding $response */ + $response = $securityCenterClient->updateFinding($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END securitycenter_v2_generated_SecurityCenter_UpdateFinding_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_mute_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_mute_config.php new file mode 100644 index 000000000000..88891aa5a60a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_mute_config.php @@ -0,0 +1,97 @@ +setFilter($muteConfigFilter) + ->setType($muteConfigType); + $request = (new UpdateMuteConfigRequest()) + ->setMuteConfig($muteConfig); + + // Call the API and handle any network failures. + try { + /** @var MuteConfig $response */ + $response = $securityCenterClient->updateMuteConfig($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $muteConfigFilter = '[FILTER]'; + $muteConfigType = MuteConfigType::MUTE_CONFIG_TYPE_UNSPECIFIED; + + update_mute_config_sample($muteConfigFilter, $muteConfigType); +} +// [END securitycenter_v2_generated_SecurityCenter_UpdateMuteConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_notification_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_notification_config.php new file mode 100644 index 000000000000..1bed33b59408 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_notification_config.php @@ -0,0 +1,60 @@ +setNotificationConfig($notificationConfig); + + // Call the API and handle any network failures. + try { + /** @var NotificationConfig $response */ + $response = $securityCenterClient->updateNotificationConfig($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END securitycenter_v2_generated_SecurityCenter_UpdateNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_resource_value_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_resource_value_config.php new file mode 100644 index 000000000000..88655d00e356 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_resource_value_config.php @@ -0,0 +1,76 @@ +AND to check against. + * Values in the form "tagValues/123" + * Example: [ "tagValues/123", "tagValues/456", "tagValues/789" ] + * https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing + */ +function update_resource_value_config_sample(string $resourceValueConfigTagValuesElement): void +{ + // Create a client. + $securityCenterClient = new SecurityCenterClient(); + + // Prepare the request message. + $resourceValueConfigTagValues = [$resourceValueConfigTagValuesElement,]; + $resourceValueConfig = (new ResourceValueConfig()) + ->setTagValues($resourceValueConfigTagValues); + $request = (new UpdateResourceValueConfigRequest()) + ->setResourceValueConfig($resourceValueConfig); + + // Call the API and handle any network failures. + try { + /** @var ResourceValueConfig $response */ + $response = $securityCenterClient->updateResourceValueConfig($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $resourceValueConfigTagValuesElement = '[TAG_VALUES]'; + + update_resource_value_config_sample($resourceValueConfigTagValuesElement); +} +// [END securitycenter_v2_generated_SecurityCenter_UpdateResourceValueConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_security_marks.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_security_marks.php new file mode 100644 index 000000000000..faac811ad4a6 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_security_marks.php @@ -0,0 +1,61 @@ +setSecurityMarks($securityMarks); + + // Call the API and handle any network failures. + try { + /** @var SecurityMarks $response */ + $response = $securityCenterClient->updateSecurityMarks($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END securitycenter_v2_generated_SecurityCenter_UpdateSecurityMarks_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_source.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_source.php new file mode 100644 index 000000000000..0cd0c337c75a --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_source.php @@ -0,0 +1,59 @@ +setSource($source); + + // Call the API and handle any network failures. + try { + /** @var Source $response */ + $response = $securityCenterClient->updateSource($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END securitycenter_v2_generated_SecurityCenter_UpdateSource_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/src/V2/Client/SecurityCenterClient.php b/owl-bot-staging/SecurityCenter/v2/src/V2/Client/SecurityCenterClient.php new file mode 100644 index 000000000000..07df517a9ec6 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/src/V2/Client/SecurityCenterClient.php @@ -0,0 +1,2791 @@ + self::SERVICE_NAME, + 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, + 'clientConfig' => __DIR__ . '/../resources/security_center_client_config.json', + 'descriptorsConfigPath' => __DIR__ . '/../resources/security_center_descriptor_config.php', + 'gcpApiConfigPath' => __DIR__ . '/../resources/security_center_grpc_config.json', + 'credentialsConfig' => [ + 'defaultScopes' => self::$serviceScopes, + ], + 'transportConfig' => [ + 'rest' => [ + 'restClientConfigPath' => __DIR__ . '/../resources/security_center_rest_client_config.php', + ], + ], + ]; + } + + /** + * Return an OperationsClient object with the same endpoint as $this. + * + * @return OperationsClient + */ + public function getOperationsClient() + { + return $this->operationsClient; + } + + /** + * Resume an existing long running operation that was previously started by a long + * running API method. If $methodName is not provided, or does not match a long + * running API method, then the operation can still be resumed, but the + * OperationResponse object will not deserialize the final response. + * + * @param string $operationName The name of the long running operation + * @param string $methodName The name of the method used to start the operation + * + * @return OperationResponse + */ + public function resumeOperation($operationName, $methodName = null) + { + $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; + $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); + $operation->reload(); + return $operation; + } + + /** + * Create the default operation client for the service. + * + * @param array $options ClientOptions for the client. + * + * @return OperationsClient + */ + private function createOperationsClient(array $options) + { + // Unset client-specific configuration options + unset($options['serviceName'], $options['clientConfig'], $options['descriptorsConfigPath']); + + if (isset($options['operationsClient'])) { + return $options['operationsClient']; + } + + return new OperationsClient($options); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * big_query_export resource. + * + * @param string $organization + * @param string $location + * @param string $export + * + * @return string The formatted big_query_export resource. + */ + public static function bigQueryExportName(string $organization, string $location, string $export): string + { + return self::getPathTemplate('bigQueryExport')->render([ + 'organization' => $organization, + 'location' => $location, + 'export' => $export, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a dlp_job + * resource. + * + * @param string $project + * @param string $dlpJob + * + * @return string The formatted dlp_job resource. + */ + public static function dlpJobName(string $project, string $dlpJob): string + { + return self::getPathTemplate('dlpJob')->render([ + 'project' => $project, + 'dlp_job' => $dlpJob, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * external_system resource. + * + * @param string $organization + * @param string $source + * @param string $finding + * @param string $externalsystem + * + * @return string The formatted external_system resource. + */ + public static function externalSystemName(string $organization, string $source, string $finding, string $externalsystem): string + { + return self::getPathTemplate('externalSystem')->render([ + 'organization' => $organization, + 'source' => $source, + 'finding' => $finding, + 'externalsystem' => $externalsystem, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a finding + * resource. + * + * @param string $organization + * @param string $source + * @param string $finding + * + * @return string The formatted finding resource. + */ + public static function findingName(string $organization, string $source, string $finding): string + { + return self::getPathTemplate('finding')->render([ + 'organization' => $organization, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a folder + * resource. + * + * @param string $folder + * + * @return string The formatted folder resource. + */ + public static function folderName(string $folder): string + { + return self::getPathTemplate('folder')->render([ + 'folder' => $folder, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_asset_securityMarks resource. + * + * @param string $folder + * @param string $asset + * + * @return string The formatted folder_asset_securityMarks resource. + */ + public static function folderAssetSecurityMarksName(string $folder, string $asset): string + { + return self::getPathTemplate('folderAssetSecurityMarks')->render([ + 'folder' => $folder, + 'asset' => $asset, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_constraint_name resource. + * + * @param string $folder + * @param string $constraintName + * + * @return string The formatted folder_constraint_name resource. + */ + public static function folderConstraintNameName(string $folder, string $constraintName): string + { + return self::getPathTemplate('folderConstraintName')->render([ + 'folder' => $folder, + 'constraint_name' => $constraintName, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_location resource. + * + * @param string $folder + * @param string $location + * + * @return string The formatted folder_location resource. + */ + public static function folderLocationName(string $folder, string $location): string + { + return self::getPathTemplate('folderLocation')->render([ + 'folder' => $folder, + 'location' => $location, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_location_export resource. + * + * @param string $folder + * @param string $location + * @param string $export + * + * @return string The formatted folder_location_export resource. + */ + public static function folderLocationExportName(string $folder, string $location, string $export): string + { + return self::getPathTemplate('folderLocationExport')->render([ + 'folder' => $folder, + 'location' => $location, + 'export' => $export, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_location_mute_config resource. + * + * @param string $folder + * @param string $location + * @param string $muteConfig + * + * @return string The formatted folder_location_mute_config resource. + */ + public static function folderLocationMuteConfigName(string $folder, string $location, string $muteConfig): string + { + return self::getPathTemplate('folderLocationMuteConfig')->render([ + 'folder' => $folder, + 'location' => $location, + 'mute_config' => $muteConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_location_notification_config resource. + * + * @param string $folder + * @param string $location + * @param string $notificationConfig + * + * @return string The formatted folder_location_notification_config resource. + */ + public static function folderLocationNotificationConfigName(string $folder, string $location, string $notificationConfig): string + { + return self::getPathTemplate('folderLocationNotificationConfig')->render([ + 'folder' => $folder, + 'location' => $location, + 'notification_config' => $notificationConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_mute_config resource. + * + * @param string $folder + * @param string $muteConfig + * + * @return string The formatted folder_mute_config resource. + */ + public static function folderMuteConfigName(string $folder, string $muteConfig): string + { + return self::getPathTemplate('folderMuteConfig')->render([ + 'folder' => $folder, + 'mute_config' => $muteConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_source resource. + * + * @param string $folder + * @param string $source + * + * @return string The formatted folder_source resource. + */ + public static function folderSourceName(string $folder, string $source): string + { + return self::getPathTemplate('folderSource')->render([ + 'folder' => $folder, + 'source' => $source, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_source_finding resource. + * + * @param string $folder + * @param string $source + * @param string $finding + * + * @return string The formatted folder_source_finding resource. + */ + public static function folderSourceFindingName(string $folder, string $source, string $finding): string + { + return self::getPathTemplate('folderSourceFinding')->render([ + 'folder' => $folder, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_source_finding_externalsystem resource. + * + * @param string $folder + * @param string $source + * @param string $finding + * @param string $externalsystem + * + * @return string The formatted folder_source_finding_externalsystem resource. + */ + public static function folderSourceFindingExternalsystemName(string $folder, string $source, string $finding, string $externalsystem): string + { + return self::getPathTemplate('folderSourceFindingExternalsystem')->render([ + 'folder' => $folder, + 'source' => $source, + 'finding' => $finding, + 'externalsystem' => $externalsystem, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_source_finding_securityMarks resource. + * + * @param string $folder + * @param string $source + * @param string $finding + * + * @return string The formatted folder_source_finding_securityMarks resource. + */ + public static function folderSourceFindingSecurityMarksName(string $folder, string $source, string $finding): string + { + return self::getPathTemplate('folderSourceFindingSecurityMarks')->render([ + 'folder' => $folder, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_source_location_finding resource. + * + * @param string $folder + * @param string $source + * @param string $location + * @param string $finding + * + * @return string The formatted folder_source_location_finding resource. + */ + public static function folderSourceLocationFindingName(string $folder, string $source, string $location, string $finding): string + { + return self::getPathTemplate('folderSourceLocationFinding')->render([ + 'folder' => $folder, + 'source' => $source, + 'location' => $location, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_source_location_finding_externalsystem resource. + * + * @param string $folder + * @param string $source + * @param string $location + * @param string $finding + * @param string $externalsystem + * + * @return string The formatted folder_source_location_finding_externalsystem resource. + */ + public static function folderSourceLocationFindingExternalsystemName(string $folder, string $source, string $location, string $finding, string $externalsystem): string + { + return self::getPathTemplate('folderSourceLocationFindingExternalsystem')->render([ + 'folder' => $folder, + 'source' => $source, + 'location' => $location, + 'finding' => $finding, + 'externalsystem' => $externalsystem, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * folder_source_location_finding_securityMarks resource. + * + * @param string $folder + * @param string $source + * @param string $location + * @param string $finding + * + * @return string The formatted folder_source_location_finding_securityMarks resource. + */ + public static function folderSourceLocationFindingSecurityMarksName(string $folder, string $source, string $location, string $finding): string + { + return self::getPathTemplate('folderSourceLocationFindingSecurityMarks')->render([ + 'folder' => $folder, + 'source' => $source, + 'location' => $location, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a location + * resource. + * + * @param string $project + * @param string $location + * + * @return string The formatted location resource. + */ + public static function locationName(string $project, string $location): string + { + return self::getPathTemplate('location')->render([ + 'project' => $project, + 'location' => $location, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a mute_config + * resource. + * + * @param string $organization + * @param string $muteConfig + * + * @return string The formatted mute_config resource. + */ + public static function muteConfigName(string $organization, string $muteConfig): string + { + return self::getPathTemplate('muteConfig')->render([ + 'organization' => $organization, + 'mute_config' => $muteConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * notification_config resource. + * + * @param string $organization + * @param string $location + * @param string $notificationConfig + * + * @return string The formatted notification_config resource. + */ + public static function notificationConfigName(string $organization, string $location, string $notificationConfig): string + { + return self::getPathTemplate('notificationConfig')->render([ + 'organization' => $organization, + 'location' => $location, + 'notification_config' => $notificationConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a organization + * resource. + * + * @param string $organization + * + * @return string The formatted organization resource. + */ + public static function organizationName(string $organization): string + { + return self::getPathTemplate('organization')->render([ + 'organization' => $organization, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_asset_securityMarks resource. + * + * @param string $organization + * @param string $asset + * + * @return string The formatted organization_asset_securityMarks resource. + */ + public static function organizationAssetSecurityMarksName(string $organization, string $asset): string + { + return self::getPathTemplate('organizationAssetSecurityMarks')->render([ + 'organization' => $organization, + 'asset' => $asset, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_constraint_name resource. + * + * @param string $organization + * @param string $constraintName + * + * @return string The formatted organization_constraint_name resource. + */ + public static function organizationConstraintNameName(string $organization, string $constraintName): string + { + return self::getPathTemplate('organizationConstraintName')->render([ + 'organization' => $organization, + 'constraint_name' => $constraintName, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location resource. + * + * @param string $organization + * @param string $location + * + * @return string The formatted organization_location resource. + */ + public static function organizationLocationName(string $organization, string $location): string + { + return self::getPathTemplate('organizationLocation')->render([ + 'organization' => $organization, + 'location' => $location, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_export resource. + * + * @param string $organization + * @param string $location + * @param string $export + * + * @return string The formatted organization_location_export resource. + */ + public static function organizationLocationExportName(string $organization, string $location, string $export): string + { + return self::getPathTemplate('organizationLocationExport')->render([ + 'organization' => $organization, + 'location' => $location, + 'export' => $export, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_mute_config resource. + * + * @param string $organization + * @param string $location + * @param string $muteConfig + * + * @return string The formatted organization_location_mute_config resource. + */ + public static function organizationLocationMuteConfigName(string $organization, string $location, string $muteConfig): string + { + return self::getPathTemplate('organizationLocationMuteConfig')->render([ + 'organization' => $organization, + 'location' => $location, + 'mute_config' => $muteConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_notification_config resource. + * + * @param string $organization + * @param string $location + * @param string $notificationConfig + * + * @return string The formatted organization_location_notification_config resource. + */ + public static function organizationLocationNotificationConfigName(string $organization, string $location, string $notificationConfig): string + { + return self::getPathTemplate('organizationLocationNotificationConfig')->render([ + 'organization' => $organization, + 'location' => $location, + 'notification_config' => $notificationConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_resource_value_config resource. + * + * @param string $organization + * @param string $location + * @param string $resourceValueConfig + * + * @return string The formatted organization_location_resource_value_config resource. + */ + public static function organizationLocationResourceValueConfigName(string $organization, string $location, string $resourceValueConfig): string + { + return self::getPathTemplate('organizationLocationResourceValueConfig')->render([ + 'organization' => $organization, + 'location' => $location, + 'resource_value_config' => $resourceValueConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_simluation resource. + * + * @param string $organization + * @param string $location + * @param string $simluation + * + * @return string The formatted organization_location_simluation resource. + */ + public static function organizationLocationSimluationName(string $organization, string $location, string $simluation): string + { + return self::getPathTemplate('organizationLocationSimluation')->render([ + 'organization' => $organization, + 'location' => $location, + 'simluation' => $simluation, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_simluation_valued_resource resource. + * + * @param string $organization + * @param string $location + * @param string $simluation + * @param string $valuedResource + * + * @return string The formatted organization_location_simluation_valued_resource resource. + */ + public static function organizationLocationSimluationValuedResourceName(string $organization, string $location, string $simluation, string $valuedResource): string + { + return self::getPathTemplate('organizationLocationSimluationValuedResource')->render([ + 'organization' => $organization, + 'location' => $location, + 'simluation' => $simluation, + 'valued_resource' => $valuedResource, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_mute_config resource. + * + * @param string $organization + * @param string $muteConfig + * + * @return string The formatted organization_mute_config resource. + */ + public static function organizationMuteConfigName(string $organization, string $muteConfig): string + { + return self::getPathTemplate('organizationMuteConfig')->render([ + 'organization' => $organization, + 'mute_config' => $muteConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_resource_value_config resource. + * + * @param string $organization + * @param string $resourceValueConfig + * + * @return string The formatted organization_resource_value_config resource. + */ + public static function organizationResourceValueConfigName(string $organization, string $resourceValueConfig): string + { + return self::getPathTemplate('organizationResourceValueConfig')->render([ + 'organization' => $organization, + 'resource_value_config' => $resourceValueConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_simulation resource. + * + * @param string $organization + * @param string $simulation + * + * @return string The formatted organization_simulation resource. + */ + public static function organizationSimulationName(string $organization, string $simulation): string + { + return self::getPathTemplate('organizationSimulation')->render([ + 'organization' => $organization, + 'simulation' => $simulation, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_simulation_valued_resource resource. + * + * @param string $organization + * @param string $simulation + * @param string $valuedResource + * + * @return string The formatted organization_simulation_valued_resource resource. + */ + public static function organizationSimulationValuedResourceName(string $organization, string $simulation, string $valuedResource): string + { + return self::getPathTemplate('organizationSimulationValuedResource')->render([ + 'organization' => $organization, + 'simulation' => $simulation, + 'valued_resource' => $valuedResource, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_source resource. + * + * @param string $organization + * @param string $source + * + * @return string The formatted organization_source resource. + */ + public static function organizationSourceName(string $organization, string $source): string + { + return self::getPathTemplate('organizationSource')->render([ + 'organization' => $organization, + 'source' => $source, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_source_finding resource. + * + * @param string $organization + * @param string $source + * @param string $finding + * + * @return string The formatted organization_source_finding resource. + */ + public static function organizationSourceFindingName(string $organization, string $source, string $finding): string + { + return self::getPathTemplate('organizationSourceFinding')->render([ + 'organization' => $organization, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_source_finding_externalsystem resource. + * + * @param string $organization + * @param string $source + * @param string $finding + * @param string $externalsystem + * + * @return string The formatted organization_source_finding_externalsystem resource. + */ + public static function organizationSourceFindingExternalsystemName(string $organization, string $source, string $finding, string $externalsystem): string + { + return self::getPathTemplate('organizationSourceFindingExternalsystem')->render([ + 'organization' => $organization, + 'source' => $source, + 'finding' => $finding, + 'externalsystem' => $externalsystem, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_source_finding_securityMarks resource. + * + * @param string $organization + * @param string $source + * @param string $finding + * + * @return string The formatted organization_source_finding_securityMarks resource. + */ + public static function organizationSourceFindingSecurityMarksName(string $organization, string $source, string $finding): string + { + return self::getPathTemplate('organizationSourceFindingSecurityMarks')->render([ + 'organization' => $organization, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_source_location_finding resource. + * + * @param string $organization + * @param string $source + * @param string $location + * @param string $finding + * + * @return string The formatted organization_source_location_finding resource. + */ + public static function organizationSourceLocationFindingName(string $organization, string $source, string $location, string $finding): string + { + return self::getPathTemplate('organizationSourceLocationFinding')->render([ + 'organization' => $organization, + 'source' => $source, + 'location' => $location, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_source_location_finding_externalsystem resource. + * + * @param string $organization + * @param string $source + * @param string $location + * @param string $finding + * @param string $externalsystem + * + * @return string The formatted organization_source_location_finding_externalsystem resource. + */ + public static function organizationSourceLocationFindingExternalsystemName(string $organization, string $source, string $location, string $finding, string $externalsystem): string + { + return self::getPathTemplate('organizationSourceLocationFindingExternalsystem')->render([ + 'organization' => $organization, + 'source' => $source, + 'location' => $location, + 'finding' => $finding, + 'externalsystem' => $externalsystem, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_source_location_finding_securityMarks resource. + * + * @param string $organization + * @param string $source + * @param string $location + * @param string $finding + * + * @return string The formatted organization_source_location_finding_securityMarks resource. + */ + public static function organizationSourceLocationFindingSecurityMarksName(string $organization, string $source, string $location, string $finding): string + { + return self::getPathTemplate('organizationSourceLocationFindingSecurityMarks')->render([ + 'organization' => $organization, + 'source' => $source, + 'location' => $location, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_valued_resource resource. + * + * @param string $organization + * @param string $location + * @param string $simulation + * @param string $valuedResource + * + * @return string The formatted organization_valued_resource resource. + */ + public static function organizationValuedResourceName(string $organization, string $location, string $simulation, string $valuedResource): string + { + return self::getPathTemplate('organizationValuedResource')->render([ + 'organization' => $organization, + 'location' => $location, + 'simulation' => $simulation, + 'valued_resource' => $valuedResource, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a policy + * resource. + * + * @param string $organization + * @param string $constraintName + * + * @return string The formatted policy resource. + */ + public static function policyName(string $organization, string $constraintName): string + { + return self::getPathTemplate('policy')->render([ + 'organization' => $organization, + 'constraint_name' => $constraintName, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a project + * resource. + * + * @param string $project + * + * @return string The formatted project resource. + */ + public static function projectName(string $project): string + { + return self::getPathTemplate('project')->render([ + 'project' => $project, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_asset_securityMarks resource. + * + * @param string $project + * @param string $asset + * + * @return string The formatted project_asset_securityMarks resource. + */ + public static function projectAssetSecurityMarksName(string $project, string $asset): string + { + return self::getPathTemplate('projectAssetSecurityMarks')->render([ + 'project' => $project, + 'asset' => $asset, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_constraint_name resource. + * + * @param string $project + * @param string $constraintName + * + * @return string The formatted project_constraint_name resource. + */ + public static function projectConstraintNameName(string $project, string $constraintName): string + { + return self::getPathTemplate('projectConstraintName')->render([ + 'project' => $project, + 'constraint_name' => $constraintName, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_dlp_job resource. + * + * @param string $project + * @param string $dlpJob + * + * @return string The formatted project_dlp_job resource. + */ + public static function projectDlpJobName(string $project, string $dlpJob): string + { + return self::getPathTemplate('projectDlpJob')->render([ + 'project' => $project, + 'dlp_job' => $dlpJob, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_dlp_job resource. + * + * @param string $project + * @param string $location + * @param string $dlpJob + * + * @return string The formatted project_location_dlp_job resource. + */ + public static function projectLocationDlpJobName(string $project, string $location, string $dlpJob): string + { + return self::getPathTemplate('projectLocationDlpJob')->render([ + 'project' => $project, + 'location' => $location, + 'dlp_job' => $dlpJob, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_export resource. + * + * @param string $project + * @param string $location + * @param string $export + * + * @return string The formatted project_location_export resource. + */ + public static function projectLocationExportName(string $project, string $location, string $export): string + { + return self::getPathTemplate('projectLocationExport')->render([ + 'project' => $project, + 'location' => $location, + 'export' => $export, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_mute_config resource. + * + * @param string $project + * @param string $location + * @param string $muteConfig + * + * @return string The formatted project_location_mute_config resource. + */ + public static function projectLocationMuteConfigName(string $project, string $location, string $muteConfig): string + { + return self::getPathTemplate('projectLocationMuteConfig')->render([ + 'project' => $project, + 'location' => $location, + 'mute_config' => $muteConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_notification_config resource. + * + * @param string $project + * @param string $location + * @param string $notificationConfig + * + * @return string The formatted project_location_notification_config resource. + */ + public static function projectLocationNotificationConfigName(string $project, string $location, string $notificationConfig): string + { + return self::getPathTemplate('projectLocationNotificationConfig')->render([ + 'project' => $project, + 'location' => $location, + 'notification_config' => $notificationConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_location_table_profile resource. + * + * @param string $project + * @param string $location + * @param string $tableProfile + * + * @return string The formatted project_location_table_profile resource. + */ + public static function projectLocationTableProfileName(string $project, string $location, string $tableProfile): string + { + return self::getPathTemplate('projectLocationTableProfile')->render([ + 'project' => $project, + 'location' => $location, + 'table_profile' => $tableProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_mute_config resource. + * + * @param string $project + * @param string $muteConfig + * + * @return string The formatted project_mute_config resource. + */ + public static function projectMuteConfigName(string $project, string $muteConfig): string + { + return self::getPathTemplate('projectMuteConfig')->render([ + 'project' => $project, + 'mute_config' => $muteConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_source resource. + * + * @param string $project + * @param string $source + * + * @return string The formatted project_source resource. + */ + public static function projectSourceName(string $project, string $source): string + { + return self::getPathTemplate('projectSource')->render([ + 'project' => $project, + 'source' => $source, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_source_finding resource. + * + * @param string $project + * @param string $source + * @param string $finding + * + * @return string The formatted project_source_finding resource. + */ + public static function projectSourceFindingName(string $project, string $source, string $finding): string + { + return self::getPathTemplate('projectSourceFinding')->render([ + 'project' => $project, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_source_finding_externalsystem resource. + * + * @param string $project + * @param string $source + * @param string $finding + * @param string $externalsystem + * + * @return string The formatted project_source_finding_externalsystem resource. + */ + public static function projectSourceFindingExternalsystemName(string $project, string $source, string $finding, string $externalsystem): string + { + return self::getPathTemplate('projectSourceFindingExternalsystem')->render([ + 'project' => $project, + 'source' => $source, + 'finding' => $finding, + 'externalsystem' => $externalsystem, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_source_finding_securityMarks resource. + * + * @param string $project + * @param string $source + * @param string $finding + * + * @return string The formatted project_source_finding_securityMarks resource. + */ + public static function projectSourceFindingSecurityMarksName(string $project, string $source, string $finding): string + { + return self::getPathTemplate('projectSourceFindingSecurityMarks')->render([ + 'project' => $project, + 'source' => $source, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_source_location_finding resource. + * + * @param string $project + * @param string $source + * @param string $location + * @param string $finding + * + * @return string The formatted project_source_location_finding resource. + */ + public static function projectSourceLocationFindingName(string $project, string $source, string $location, string $finding): string + { + return self::getPathTemplate('projectSourceLocationFinding')->render([ + 'project' => $project, + 'source' => $source, + 'location' => $location, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_source_location_finding_externalsystem resource. + * + * @param string $project + * @param string $source + * @param string $location + * @param string $finding + * @param string $externalsystem + * + * @return string The formatted project_source_location_finding_externalsystem resource. + */ + public static function projectSourceLocationFindingExternalsystemName(string $project, string $source, string $location, string $finding, string $externalsystem): string + { + return self::getPathTemplate('projectSourceLocationFindingExternalsystem')->render([ + 'project' => $project, + 'source' => $source, + 'location' => $location, + 'finding' => $finding, + 'externalsystem' => $externalsystem, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_source_location_finding_securityMarks resource. + * + * @param string $project + * @param string $source + * @param string $location + * @param string $finding + * + * @return string The formatted project_source_location_finding_securityMarks resource. + */ + public static function projectSourceLocationFindingSecurityMarksName(string $project, string $source, string $location, string $finding): string + { + return self::getPathTemplate('projectSourceLocationFindingSecurityMarks')->render([ + 'project' => $project, + 'source' => $source, + 'location' => $location, + 'finding' => $finding, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * project_table_profile resource. + * + * @param string $project + * @param string $tableProfile + * + * @return string The formatted project_table_profile resource. + */ + public static function projectTableProfileName(string $project, string $tableProfile): string + { + return self::getPathTemplate('projectTableProfile')->render([ + 'project' => $project, + 'table_profile' => $tableProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * resource_value_config resource. + * + * @param string $organization + * @param string $resourceValueConfig + * + * @return string The formatted resource_value_config resource. + */ + public static function resourceValueConfigName(string $organization, string $resourceValueConfig): string + { + return self::getPathTemplate('resourceValueConfig')->render([ + 'organization' => $organization, + 'resource_value_config' => $resourceValueConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * security_marks resource. + * + * @param string $organization + * @param string $asset + * + * @return string The formatted security_marks resource. + */ + public static function securityMarksName(string $organization, string $asset): string + { + return self::getPathTemplate('securityMarks')->render([ + 'organization' => $organization, + 'asset' => $asset, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a simulation + * resource. + * + * @param string $organization + * @param string $simulation + * + * @return string The formatted simulation resource. + */ + public static function simulationName(string $organization, string $simulation): string + { + return self::getPathTemplate('simulation')->render([ + 'organization' => $organization, + 'simulation' => $simulation, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a source + * resource. + * + * @param string $organization + * @param string $source + * + * @return string The formatted source resource. + */ + public static function sourceName(string $organization, string $source): string + { + return self::getPathTemplate('source')->render([ + 'organization' => $organization, + 'source' => $source, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * table_data_profile resource. + * + * @param string $project + * @param string $tableProfile + * + * @return string The formatted table_data_profile resource. + */ + public static function tableDataProfileName(string $project, string $tableProfile): string + { + return self::getPathTemplate('tableDataProfile')->render([ + 'project' => $project, + 'table_profile' => $tableProfile, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a topic + * resource. + * + * @param string $project + * @param string $topic + * + * @return string The formatted topic resource. + */ + public static function topicName(string $project, string $topic): string + { + return self::getPathTemplate('topic')->render([ + 'project' => $project, + 'topic' => $topic, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * valued_resource resource. + * + * @param string $organization + * @param string $simulation + * @param string $valuedResource + * + * @return string The formatted valued_resource resource. + */ + public static function valuedResourceName(string $organization, string $simulation, string $valuedResource): string + { + return self::getPathTemplate('valuedResource')->render([ + 'organization' => $organization, + 'simulation' => $simulation, + 'valued_resource' => $valuedResource, + ]); + } + + /** + * Parses a formatted name string and returns an associative array of the components in the name. + * The following name formats are supported: + * Template: Pattern + * - bigQueryExport: organizations/{organization}/locations/{location}/bigQueryExports/{export} + * - dlpJob: projects/{project}/dlpJobs/{dlp_job} + * - externalSystem: organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} + * - finding: organizations/{organization}/sources/{source}/findings/{finding} + * - folder: folders/{folder} + * - folderAssetSecurityMarks: folders/{folder}/assets/{asset}/securityMarks + * - folderConstraintName: folders/{folder}/policies/{constraint_name} + * - folderLocation: folders/{folder}/locations/{location} + * - folderLocationExport: folders/{folder}/locations/{location}/bigQueryExports/{export} + * - folderLocationMuteConfig: folders/{folder}/locations/{location}/muteConfigs/{mute_config} + * - folderLocationNotificationConfig: folders/{folder}/locations/{location}/notificationConfigs/{notification_config} + * - folderMuteConfig: folders/{folder}/muteConfigs/{mute_config} + * - folderSource: folders/{folder}/sources/{source} + * - folderSourceFinding: folders/{folder}/sources/{source}/findings/{finding} + * - folderSourceFindingExternalsystem: folders/{folder}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} + * - folderSourceFindingSecurityMarks: folders/{folder}/sources/{source}/findings/{finding}/securityMarks + * - folderSourceLocationFinding: folders/{folder}/sources/{source}/locations/{location}/findings/{finding} + * - folderSourceLocationFindingExternalsystem: folders/{folder}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem} + * - folderSourceLocationFindingSecurityMarks: folders/{folder}/sources/{source}/locations/{location}/findings/{finding}/securityMarks + * - location: projects/{project}/locations/{location} + * - muteConfig: organizations/{organization}/muteConfigs/{mute_config} + * - notificationConfig: organizations/{organization}/locations/{location}/notificationConfigs/{notification_config} + * - organization: organizations/{organization} + * - organizationAssetSecurityMarks: organizations/{organization}/assets/{asset}/securityMarks + * - organizationConstraintName: organizations/{organization}/policies/{constraint_name} + * - organizationLocation: organizations/{organization}/locations/{location} + * - organizationLocationExport: organizations/{organization}/locations/{location}/bigQueryExports/{export} + * - organizationLocationMuteConfig: organizations/{organization}/locations/{location}/muteConfigs/{mute_config} + * - organizationLocationNotificationConfig: organizations/{organization}/locations/{location}/notificationConfigs/{notification_config} + * - organizationLocationResourceValueConfig: organizations/{organization}/locations/{location}/resourceValueConfigs/{resource_value_config} + * - organizationLocationSimluation: organizations/{organization}/locations/{location}/simulations/{simluation} + * - organizationLocationSimluationValuedResource: organizations/{organization}/locations/{location}/simulations/{simluation}/valuedResources/{valued_resource} + * - organizationMuteConfig: organizations/{organization}/muteConfigs/{mute_config} + * - organizationResourceValueConfig: organizations/{organization}/resourceValueConfigs/{resource_value_config} + * - organizationSimulation: organizations/{organization}/simulations/{simulation} + * - organizationSimulationValuedResource: organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource} + * - organizationSource: organizations/{organization}/sources/{source} + * - organizationSourceFinding: organizations/{organization}/sources/{source}/findings/{finding} + * - organizationSourceFindingExternalsystem: organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} + * - organizationSourceFindingSecurityMarks: organizations/{organization}/sources/{source}/findings/{finding}/securityMarks + * - organizationSourceLocationFinding: organizations/{organization}/sources/{source}/locations/{location}/findings/{finding} + * - organizationSourceLocationFindingExternalsystem: organizations/{organization}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem} + * - organizationSourceLocationFindingSecurityMarks: organizations/{organization}/sources/{source}/locations/{location}/findings/{finding}/securityMarks + * - organizationValuedResource: organizations/{organization}/locations/{location}/simulations/{simulation}/valuedResources/{valued_resource} + * - policy: organizations/{organization}/policies/{constraint_name} + * - project: projects/{project} + * - projectAssetSecurityMarks: projects/{project}/assets/{asset}/securityMarks + * - projectConstraintName: projects/{project}/policies/{constraint_name} + * - projectDlpJob: projects/{project}/dlpJobs/{dlp_job} + * - projectLocationDlpJob: projects/{project}/locations/{location}/dlpJobs/{dlp_job} + * - projectLocationExport: projects/{project}/locations/{location}/bigQueryExports/{export} + * - projectLocationMuteConfig: projects/{project}/locations/{location}/muteConfigs/{mute_config} + * - projectLocationNotificationConfig: projects/{project}/locations/{location}/notificationConfigs/{notification_config} + * - projectLocationTableProfile: projects/{project}/locations/{location}/tableProfiles/{table_profile} + * - projectMuteConfig: projects/{project}/muteConfigs/{mute_config} + * - projectSource: projects/{project}/sources/{source} + * - projectSourceFinding: projects/{project}/sources/{source}/findings/{finding} + * - projectSourceFindingExternalsystem: projects/{project}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} + * - projectSourceFindingSecurityMarks: projects/{project}/sources/{source}/findings/{finding}/securityMarks + * - projectSourceLocationFinding: projects/{project}/sources/{source}/locations/{location}/findings/{finding} + * - projectSourceLocationFindingExternalsystem: projects/{project}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem} + * - projectSourceLocationFindingSecurityMarks: projects/{project}/sources/{source}/locations/{location}/findings/{finding}/securityMarks + * - projectTableProfile: projects/{project}/tableProfiles/{table_profile} + * - resourceValueConfig: organizations/{organization}/resourceValueConfigs/{resource_value_config} + * - securityMarks: organizations/{organization}/assets/{asset}/securityMarks + * - simulation: organizations/{organization}/simulations/{simulation} + * - source: organizations/{organization}/sources/{source} + * - tableDataProfile: projects/{project}/tableProfiles/{table_profile} + * - topic: projects/{project}/topics/{topic} + * - valuedResource: organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource} + * + * The optional $template argument can be supplied to specify a particular pattern, + * and must match one of the templates listed above. If no $template argument is + * provided, or if the $template argument does not match one of the templates + * listed, then parseName will check each of the supported templates, and return + * the first match. + * + * @param string $formattedName The formatted name string + * @param string $template Optional name of template to match + * + * @return array An associative array from name component IDs to component values. + * + * @throws ValidationException If $formattedName could not be matched. + */ + public static function parseName(string $formattedName, string $template = null): array + { + return self::parseFormattedName($formattedName, $template); + } + + /** + * Constructor. + * + * @param array $options { + * Optional. Options for configuring the service API wrapper. + * + * @type string $apiEndpoint + * The address of the API remote host. May optionally include the port, formatted + * as ":". Default 'securitycenter.googleapis.com:443'. + * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials + * The credentials to be used by the client to authorize API calls. This option + * accepts either a path to a credentials file, or a decoded credentials file as a + * PHP array. + * *Advanced usage*: In addition, this option can also accept a pre-constructed + * {@see \Google\Auth\FetchAuthTokenInterface} object or + * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these + * objects are provided, any settings in $credentialsConfig will be ignored. + * @type array $credentialsConfig + * Options used to configure credentials, including auth token caching, for the + * client. For a full list of supporting configuration options, see + * {@see \Google\ApiCore\CredentialsWrapper::build()} . + * @type bool $disableRetries + * Determines whether or not retries defined by the client configuration should be + * disabled. Defaults to `false`. + * @type string|array $clientConfig + * Client method configuration, including retry settings. This option can be either + * a path to a JSON file, or a PHP array containing the decoded JSON data. By + * default this settings points to the default client config file, which is + * provided in the resources folder. + * @type string|TransportInterface $transport + * The transport used for executing network requests. May be either the string + * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. + * *Advanced usage*: Additionally, it is possible to pass in an already + * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note + * that when this object is provided, any settings in $transportConfig, and any + * $apiEndpoint setting, will be ignored. + * @type array $transportConfig + * Configuration options that will be used to construct the transport. Options for + * each supported transport type should be passed in a key for that transport. For + * example: + * $transportConfig = [ + * 'grpc' => [...], + * 'rest' => [...], + * ]; + * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and + * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the + * supported options. + * @type callable $clientCertSource + * A callable which returns the client cert as a string. This can be used to + * provide a certificate and private key to the transport layer for mTLS. + * } + * + * @throws ValidationException + */ + public function __construct(array $options = []) + { + $clientOptions = $this->buildClientOptions($options); + $this->setClientOptions($clientOptions); + $this->operationsClient = $this->createOperationsClient($clientOptions); + } + + /** Handles execution of the async variants for each documented method. */ + public function __call($method, $args) + { + if (substr($method, -5) !== 'Async') { + trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); + } + + array_unshift($args, substr($method, 0, -5)); + return call_user_func_array([$this, 'startAsyncCall'], $args); + } + + /** + * Creates a ResourceValueConfig for an organization. Maps user's tags to + * difference resource values for use by the attack path simulation. + * + * The async variant is + * {@see SecurityCenterClient::batchCreateResourceValueConfigsAsync()} . + * + * @example samples/V2/SecurityCenterClient/batch_create_resource_value_configs.php + * + * @param BatchCreateResourceValueConfigsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return BatchCreateResourceValueConfigsResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function batchCreateResourceValueConfigs(BatchCreateResourceValueConfigsRequest $request, array $callOptions = []): BatchCreateResourceValueConfigsResponse + { + return $this->startApiCall('BatchCreateResourceValueConfigs', $request, $callOptions)->wait(); + } + + /** + * Kicks off an LRO to bulk mute findings for a parent based on a filter. If + * no location is specified, findings are muted in global. The parent + * can be either an organization, folder, or project. The findings matched by + * the filter will be muted after the LRO is done. + * + * The async variant is {@see SecurityCenterClient::bulkMuteFindingsAsync()} . + * + * @example samples/V2/SecurityCenterClient/bulk_mute_findings.php + * + * @param BulkMuteFindingsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function bulkMuteFindings(BulkMuteFindingsRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('BulkMuteFindings', $request, $callOptions)->wait(); + } + + /** + * Creates a BigQuery export. + * + * The async variant is {@see SecurityCenterClient::createBigQueryExportAsync()} . + * + * @example samples/V2/SecurityCenterClient/create_big_query_export.php + * + * @param CreateBigQueryExportRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return BigQueryExport + * + * @throws ApiException Thrown if the API call fails. + */ + public function createBigQueryExport(CreateBigQueryExportRequest $request, array $callOptions = []): BigQueryExport + { + return $this->startApiCall('CreateBigQueryExport', $request, $callOptions)->wait(); + } + + /** + * Creates a finding in a location. The corresponding source must exist for + * finding creation to succeed. + * + * The async variant is {@see SecurityCenterClient::createFindingAsync()} . + * + * @example samples/V2/SecurityCenterClient/create_finding.php + * + * @param CreateFindingRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Finding + * + * @throws ApiException Thrown if the API call fails. + */ + public function createFinding(CreateFindingRequest $request, array $callOptions = []): Finding + { + return $this->startApiCall('CreateFinding', $request, $callOptions)->wait(); + } + + /** + * Creates a mute config. + * + * The async variant is {@see SecurityCenterClient::createMuteConfigAsync()} . + * + * @example samples/V2/SecurityCenterClient/create_mute_config.php + * + * @param CreateMuteConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return MuteConfig + * + * @throws ApiException Thrown if the API call fails. + */ + public function createMuteConfig(CreateMuteConfigRequest $request, array $callOptions = []): MuteConfig + { + return $this->startApiCall('CreateMuteConfig', $request, $callOptions)->wait(); + } + + /** + * Creates a notification config. + * + * The async variant is + * {@see SecurityCenterClient::createNotificationConfigAsync()} . + * + * @example samples/V2/SecurityCenterClient/create_notification_config.php + * + * @param CreateNotificationConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return NotificationConfig + * + * @throws ApiException Thrown if the API call fails. + */ + public function createNotificationConfig(CreateNotificationConfigRequest $request, array $callOptions = []): NotificationConfig + { + return $this->startApiCall('CreateNotificationConfig', $request, $callOptions)->wait(); + } + + /** + * Creates a source. + * + * The async variant is {@see SecurityCenterClient::createSourceAsync()} . + * + * @example samples/V2/SecurityCenterClient/create_source.php + * + * @param CreateSourceRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Source + * + * @throws ApiException Thrown if the API call fails. + */ + public function createSource(CreateSourceRequest $request, array $callOptions = []): Source + { + return $this->startApiCall('CreateSource', $request, $callOptions)->wait(); + } + + /** + * Deletes an existing BigQuery export. + * + * The async variant is {@see SecurityCenterClient::deleteBigQueryExportAsync()} . + * + * @example samples/V2/SecurityCenterClient/delete_big_query_export.php + * + * @param DeleteBigQueryExportRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteBigQueryExport(DeleteBigQueryExportRequest $request, array $callOptions = []): void + { + $this->startApiCall('DeleteBigQueryExport', $request, $callOptions)->wait(); + } + + /** + * Deletes an existing mute config. If no location is specified, default is + * global. + * + * The async variant is {@see SecurityCenterClient::deleteMuteConfigAsync()} . + * + * @example samples/V2/SecurityCenterClient/delete_mute_config.php + * + * @param DeleteMuteConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteMuteConfig(DeleteMuteConfigRequest $request, array $callOptions = []): void + { + $this->startApiCall('DeleteMuteConfig', $request, $callOptions)->wait(); + } + + /** + * Deletes a notification config. + * + * The async variant is + * {@see SecurityCenterClient::deleteNotificationConfigAsync()} . + * + * @example samples/V2/SecurityCenterClient/delete_notification_config.php + * + * @param DeleteNotificationConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteNotificationConfig(DeleteNotificationConfigRequest $request, array $callOptions = []): void + { + $this->startApiCall('DeleteNotificationConfig', $request, $callOptions)->wait(); + } + + /** + * Deletes a ResourceValueConfig. + * + * The async variant is + * {@see SecurityCenterClient::deleteResourceValueConfigAsync()} . + * + * @example samples/V2/SecurityCenterClient/delete_resource_value_config.php + * + * @param DeleteResourceValueConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteResourceValueConfig(DeleteResourceValueConfigRequest $request, array $callOptions = []): void + { + $this->startApiCall('DeleteResourceValueConfig', $request, $callOptions)->wait(); + } + + /** + * Gets a BigQuery export. + * + * The async variant is {@see SecurityCenterClient::getBigQueryExportAsync()} . + * + * @example samples/V2/SecurityCenterClient/get_big_query_export.php + * + * @param GetBigQueryExportRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return BigQueryExport + * + * @throws ApiException Thrown if the API call fails. + */ + public function getBigQueryExport(GetBigQueryExportRequest $request, array $callOptions = []): BigQueryExport + { + return $this->startApiCall('GetBigQueryExport', $request, $callOptions)->wait(); + } + + /** + * Gets the access control policy on the specified Source. + * + * The async variant is {@see SecurityCenterClient::getIamPolicyAsync()} . + * + * @example samples/V2/SecurityCenterClient/get_iam_policy.php + * + * @param GetIamPolicyRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Policy + * + * @throws ApiException Thrown if the API call fails. + */ + public function getIamPolicy(GetIamPolicyRequest $request, array $callOptions = []): Policy + { + return $this->startApiCall('GetIamPolicy', $request, $callOptions)->wait(); + } + + /** + * Gets a mute config. If no location is specified, default is + * global. + * + * The async variant is {@see SecurityCenterClient::getMuteConfigAsync()} . + * + * @example samples/V2/SecurityCenterClient/get_mute_config.php + * + * @param GetMuteConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return MuteConfig + * + * @throws ApiException Thrown if the API call fails. + */ + public function getMuteConfig(GetMuteConfigRequest $request, array $callOptions = []): MuteConfig + { + return $this->startApiCall('GetMuteConfig', $request, $callOptions)->wait(); + } + + /** + * Gets a notification config. + * + * The async variant is {@see SecurityCenterClient::getNotificationConfigAsync()} . + * + * @example samples/V2/SecurityCenterClient/get_notification_config.php + * + * @param GetNotificationConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return NotificationConfig + * + * @throws ApiException Thrown if the API call fails. + */ + public function getNotificationConfig(GetNotificationConfigRequest $request, array $callOptions = []): NotificationConfig + { + return $this->startApiCall('GetNotificationConfig', $request, $callOptions)->wait(); + } + + /** + * Gets a ResourceValueConfig. + * + * The async variant is {@see SecurityCenterClient::getResourceValueConfigAsync()} + * . + * + * @example samples/V2/SecurityCenterClient/get_resource_value_config.php + * + * @param GetResourceValueConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return ResourceValueConfig + * + * @throws ApiException Thrown if the API call fails. + */ + public function getResourceValueConfig(GetResourceValueConfigRequest $request, array $callOptions = []): ResourceValueConfig + { + return $this->startApiCall('GetResourceValueConfig', $request, $callOptions)->wait(); + } + + /** + * Get the simulation by name or the latest simulation for the given + * organization. + * + * The async variant is {@see SecurityCenterClient::getSimulationAsync()} . + * + * @example samples/V2/SecurityCenterClient/get_simulation.php + * + * @param GetSimulationRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Simulation + * + * @throws ApiException Thrown if the API call fails. + */ + public function getSimulation(GetSimulationRequest $request, array $callOptions = []): Simulation + { + return $this->startApiCall('GetSimulation', $request, $callOptions)->wait(); + } + + /** + * Gets a source. + * + * The async variant is {@see SecurityCenterClient::getSourceAsync()} . + * + * @example samples/V2/SecurityCenterClient/get_source.php + * + * @param GetSourceRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Source + * + * @throws ApiException Thrown if the API call fails. + */ + public function getSource(GetSourceRequest $request, array $callOptions = []): Source + { + return $this->startApiCall('GetSource', $request, $callOptions)->wait(); + } + + /** + * Get the valued resource by name + * + * The async variant is {@see SecurityCenterClient::getValuedResourceAsync()} . + * + * @example samples/V2/SecurityCenterClient/get_valued_resource.php + * + * @param GetValuedResourceRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return ValuedResource + * + * @throws ApiException Thrown if the API call fails. + */ + public function getValuedResource(GetValuedResourceRequest $request, array $callOptions = []): ValuedResource + { + return $this->startApiCall('GetValuedResource', $request, $callOptions)->wait(); + } + + /** + * Filters an organization or source's findings and groups them by their + * specified properties in a location. If no location is specified, findings + * are assumed to be in global + * + * To group across all sources provide a `-` as the source id. + * The following list shows some examples: + * + * + `/v2/organizations/{organization_id}/sources/-/findings` + * + + * `/v2/organizations/{organization_id}/sources/-/locations/{location_id}/findings` + * + `/v2/folders/{folder_id}/sources/-/findings` + * + `/v2/folders/{folder_id}/sources/-/locations/{location_id}/findings` + * + `/v2/projects/{project_id}/sources/-/findings` + * + `/v2/projects/{project_id}/sources/-/locations/{location_id}/findings` + * + * The async variant is {@see SecurityCenterClient::groupFindingsAsync()} . + * + * @example samples/V2/SecurityCenterClient/group_findings.php + * + * @param GroupFindingsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function groupFindings(GroupFindingsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('GroupFindings', $request, $callOptions); + } + + /** + * Lists the attack paths for a set of simulation results or valued resources + * and filter. + * + * The async variant is {@see SecurityCenterClient::listAttackPathsAsync()} . + * + * @example samples/V2/SecurityCenterClient/list_attack_paths.php + * + * @param ListAttackPathsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listAttackPaths(ListAttackPathsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListAttackPaths', $request, $callOptions); + } + + /** + * Lists BigQuery exports. Note that when requesting BigQuery exports at a + * given level all exports under that level are also returned e.g. if + * requesting BigQuery exports under a folder, then all BigQuery exports + * immediately under the folder plus the ones created under the projects + * within the folder are returned. + * + * The async variant is {@see SecurityCenterClient::listBigQueryExportsAsync()} . + * + * @example samples/V2/SecurityCenterClient/list_big_query_exports.php + * + * @param ListBigQueryExportsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listBigQueryExports(ListBigQueryExportsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListBigQueryExports', $request, $callOptions); + } + + /** + * Lists an organization or source's findings. + * + * To list across all sources for a given location provide a `-` as the source + * id. If no location is specified, finding are assumed to be in global. + * The following list shows some examples: + * + * + `/v2/organizations/{organization_id}/sources/-/findings` + * + + * `/v2/organizations/{organization_id}/sources/-/locations/{location_id}/findings` + * + * The async variant is {@see SecurityCenterClient::listFindingsAsync()} . + * + * @example samples/V2/SecurityCenterClient/list_findings.php + * + * @param ListFindingsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listFindings(ListFindingsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListFindings', $request, $callOptions); + } + + /** + * Lists mute configs. If no location is specified, default is + * global. + * + * The async variant is {@see SecurityCenterClient::listMuteConfigsAsync()} . + * + * @example samples/V2/SecurityCenterClient/list_mute_configs.php + * + * @param ListMuteConfigsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listMuteConfigs(ListMuteConfigsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListMuteConfigs', $request, $callOptions); + } + + /** + * Lists notification configs. + * + * The async variant is {@see SecurityCenterClient::listNotificationConfigsAsync()} + * . + * + * @example samples/V2/SecurityCenterClient/list_notification_configs.php + * + * @param ListNotificationConfigsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listNotificationConfigs(ListNotificationConfigsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListNotificationConfigs', $request, $callOptions); + } + + /** + * Lists all ResourceValueConfigs. + * + * The async variant is + * {@see SecurityCenterClient::listResourceValueConfigsAsync()} . + * + * @example samples/V2/SecurityCenterClient/list_resource_value_configs.php + * + * @param ListResourceValueConfigsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listResourceValueConfigs(ListResourceValueConfigsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListResourceValueConfigs', $request, $callOptions); + } + + /** + * Lists all sources belonging to an organization. + * + * The async variant is {@see SecurityCenterClient::listSourcesAsync()} . + * + * @example samples/V2/SecurityCenterClient/list_sources.php + * + * @param ListSourcesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listSources(ListSourcesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListSources', $request, $callOptions); + } + + /** + * Lists the valued resources for a set of simulation results and filter. + * + * The async variant is {@see SecurityCenterClient::listValuedResourcesAsync()} . + * + * @example samples/V2/SecurityCenterClient/list_valued_resources.php + * + * @param ListValuedResourcesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listValuedResources(ListValuedResourcesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListValuedResources', $request, $callOptions); + } + + /** + * Updates the state of a finding. If no location is specified, finding is + * assumed to be in global + * + * The async variant is {@see SecurityCenterClient::setFindingStateAsync()} . + * + * @example samples/V2/SecurityCenterClient/set_finding_state.php + * + * @param SetFindingStateRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Finding + * + * @throws ApiException Thrown if the API call fails. + */ + public function setFindingState(SetFindingStateRequest $request, array $callOptions = []): Finding + { + return $this->startApiCall('SetFindingState', $request, $callOptions)->wait(); + } + + /** + * Sets the access control policy on the specified Source. + * + * The async variant is {@see SecurityCenterClient::setIamPolicyAsync()} . + * + * @example samples/V2/SecurityCenterClient/set_iam_policy.php + * + * @param SetIamPolicyRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Policy + * + * @throws ApiException Thrown if the API call fails. + */ + public function setIamPolicy(SetIamPolicyRequest $request, array $callOptions = []): Policy + { + return $this->startApiCall('SetIamPolicy', $request, $callOptions)->wait(); + } + + /** + * Updates the mute state of a finding. If no location is specified, finding + * is assumed to be in global + * + * The async variant is {@see SecurityCenterClient::setMuteAsync()} . + * + * @example samples/V2/SecurityCenterClient/set_mute.php + * + * @param SetMuteRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Finding + * + * @throws ApiException Thrown if the API call fails. + */ + public function setMute(SetMuteRequest $request, array $callOptions = []): Finding + { + return $this->startApiCall('SetMute', $request, $callOptions)->wait(); + } + + /** + * Returns the permissions that a caller has on the specified source. + * + * The async variant is {@see SecurityCenterClient::testIamPermissionsAsync()} . + * + * @example samples/V2/SecurityCenterClient/test_iam_permissions.php + * + * @param TestIamPermissionsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return TestIamPermissionsResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function testIamPermissions(TestIamPermissionsRequest $request, array $callOptions = []): TestIamPermissionsResponse + { + return $this->startApiCall('TestIamPermissions', $request, $callOptions)->wait(); + } + + /** + * Updates a BigQuery export. + * + * The async variant is {@see SecurityCenterClient::updateBigQueryExportAsync()} . + * + * @example samples/V2/SecurityCenterClient/update_big_query_export.php + * + * @param UpdateBigQueryExportRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return BigQueryExport + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateBigQueryExport(UpdateBigQueryExportRequest $request, array $callOptions = []): BigQueryExport + { + return $this->startApiCall('UpdateBigQueryExport', $request, $callOptions)->wait(); + } + + /** + * Updates external system. This is for a given finding. If no location is + * specified, finding is assumed to be in global + * + * The async variant is {@see SecurityCenterClient::updateExternalSystemAsync()} . + * + * @example samples/V2/SecurityCenterClient/update_external_system.php + * + * @param UpdateExternalSystemRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return ExternalSystem + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateExternalSystem(UpdateExternalSystemRequest $request, array $callOptions = []): ExternalSystem + { + return $this->startApiCall('UpdateExternalSystem', $request, $callOptions)->wait(); + } + + /** + * Creates or updates a finding. If no location is specified, finding is + * assumed to be in global. The corresponding source must exist for a finding + * creation to succeed. + * + * The async variant is {@see SecurityCenterClient::updateFindingAsync()} . + * + * @example samples/V2/SecurityCenterClient/update_finding.php + * + * @param UpdateFindingRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Finding + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateFinding(UpdateFindingRequest $request, array $callOptions = []): Finding + { + return $this->startApiCall('UpdateFinding', $request, $callOptions)->wait(); + } + + /** + * Updates a mute config. If no location is specified, default is + * global. + * + * The async variant is {@see SecurityCenterClient::updateMuteConfigAsync()} . + * + * @example samples/V2/SecurityCenterClient/update_mute_config.php + * + * @param UpdateMuteConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return MuteConfig + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateMuteConfig(UpdateMuteConfigRequest $request, array $callOptions = []): MuteConfig + { + return $this->startApiCall('UpdateMuteConfig', $request, $callOptions)->wait(); + } + + /** + * Updates a notification config. The following update + * fields are allowed: description, pubsub_topic, streaming_config.filter + * + * The async variant is + * {@see SecurityCenterClient::updateNotificationConfigAsync()} . + * + * @example samples/V2/SecurityCenterClient/update_notification_config.php + * + * @param UpdateNotificationConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return NotificationConfig + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateNotificationConfig(UpdateNotificationConfigRequest $request, array $callOptions = []): NotificationConfig + { + return $this->startApiCall('UpdateNotificationConfig', $request, $callOptions)->wait(); + } + + /** + * Updates an existing ResourceValueConfigs with new rules. + * + * The async variant is + * {@see SecurityCenterClient::updateResourceValueConfigAsync()} . + * + * @example samples/V2/SecurityCenterClient/update_resource_value_config.php + * + * @param UpdateResourceValueConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return ResourceValueConfig + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateResourceValueConfig(UpdateResourceValueConfigRequest $request, array $callOptions = []): ResourceValueConfig + { + return $this->startApiCall('UpdateResourceValueConfig', $request, $callOptions)->wait(); + } + + /** + * Updates security marks. For Finding Security marks, if no location is + * specified, finding is assumed to be in global. Assets Security Marks can + * only be accessed through global endpoint. + * + * The async variant is {@see SecurityCenterClient::updateSecurityMarksAsync()} . + * + * @example samples/V2/SecurityCenterClient/update_security_marks.php + * + * @param UpdateSecurityMarksRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return SecurityMarks + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateSecurityMarks(UpdateSecurityMarksRequest $request, array $callOptions = []): SecurityMarks + { + return $this->startApiCall('UpdateSecurityMarks', $request, $callOptions)->wait(); + } + + /** + * Updates a source. + * + * The async variant is {@see SecurityCenterClient::updateSourceAsync()} . + * + * @example samples/V2/SecurityCenterClient/update_source.php + * + * @param UpdateSourceRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * Optional. + * + * @type RetrySettings|array $retrySettings + * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an + * associative array of retry settings parameters. See the documentation on + * {@see RetrySettings} for example usage. + * } + * + * @return Source + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateSource(UpdateSourceRequest $request, array $callOptions = []): Source + { + return $this->startApiCall('UpdateSource', $request, $callOptions)->wait(); + } +} diff --git a/owl-bot-staging/SecurityCenter/v2/src/V2/gapic_metadata.json b/owl-bot-staging/SecurityCenter/v2/src/V2/gapic_metadata.json new file mode 100644 index 000000000000..375a86c17fe7 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/src/V2/gapic_metadata.json @@ -0,0 +1,218 @@ +{ + "schema": "1.0", + "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", + "language": "php", + "protoPackage": "google.cloud.securitycenter.v2", + "libraryPackage": "Google\\Cloud\\SecurityCenter\\V2", + "services": { + "SecurityCenter": { + "clients": { + "grpc": { + "libraryClient": "SecurityCenterGapicClient", + "rpcs": { + "BatchCreateResourceValueConfigs": { + "methods": [ + "batchCreateResourceValueConfigs" + ] + }, + "BulkMuteFindings": { + "methods": [ + "bulkMuteFindings" + ] + }, + "CreateBigQueryExport": { + "methods": [ + "createBigQueryExport" + ] + }, + "CreateFinding": { + "methods": [ + "createFinding" + ] + }, + "CreateMuteConfig": { + "methods": [ + "createMuteConfig" + ] + }, + "CreateNotificationConfig": { + "methods": [ + "createNotificationConfig" + ] + }, + "CreateSource": { + "methods": [ + "createSource" + ] + }, + "DeleteBigQueryExport": { + "methods": [ + "deleteBigQueryExport" + ] + }, + "DeleteMuteConfig": { + "methods": [ + "deleteMuteConfig" + ] + }, + "DeleteNotificationConfig": { + "methods": [ + "deleteNotificationConfig" + ] + }, + "DeleteResourceValueConfig": { + "methods": [ + "deleteResourceValueConfig" + ] + }, + "GetBigQueryExport": { + "methods": [ + "getBigQueryExport" + ] + }, + "GetIamPolicy": { + "methods": [ + "getIamPolicy" + ] + }, + "GetMuteConfig": { + "methods": [ + "getMuteConfig" + ] + }, + "GetNotificationConfig": { + "methods": [ + "getNotificationConfig" + ] + }, + "GetResourceValueConfig": { + "methods": [ + "getResourceValueConfig" + ] + }, + "GetSimulation": { + "methods": [ + "getSimulation" + ] + }, + "GetSource": { + "methods": [ + "getSource" + ] + }, + "GetValuedResource": { + "methods": [ + "getValuedResource" + ] + }, + "GroupFindings": { + "methods": [ + "groupFindings" + ] + }, + "ListAttackPaths": { + "methods": [ + "listAttackPaths" + ] + }, + "ListBigQueryExports": { + "methods": [ + "listBigQueryExports" + ] + }, + "ListFindings": { + "methods": [ + "listFindings" + ] + }, + "ListMuteConfigs": { + "methods": [ + "listMuteConfigs" + ] + }, + "ListNotificationConfigs": { + "methods": [ + "listNotificationConfigs" + ] + }, + "ListResourceValueConfigs": { + "methods": [ + "listResourceValueConfigs" + ] + }, + "ListSources": { + "methods": [ + "listSources" + ] + }, + "ListValuedResources": { + "methods": [ + "listValuedResources" + ] + }, + "SetFindingState": { + "methods": [ + "setFindingState" + ] + }, + "SetIamPolicy": { + "methods": [ + "setIamPolicy" + ] + }, + "SetMute": { + "methods": [ + "setMute" + ] + }, + "TestIamPermissions": { + "methods": [ + "testIamPermissions" + ] + }, + "UpdateBigQueryExport": { + "methods": [ + "updateBigQueryExport" + ] + }, + "UpdateExternalSystem": { + "methods": [ + "updateExternalSystem" + ] + }, + "UpdateFinding": { + "methods": [ + "updateFinding" + ] + }, + "UpdateMuteConfig": { + "methods": [ + "updateMuteConfig" + ] + }, + "UpdateNotificationConfig": { + "methods": [ + "updateNotificationConfig" + ] + }, + "UpdateResourceValueConfig": { + "methods": [ + "updateResourceValueConfig" + ] + }, + "UpdateSecurityMarks": { + "methods": [ + "updateSecurityMarks" + ] + }, + "UpdateSource": { + "methods": [ + "updateSource" + ] + } + } + } + } + } + } +} \ No newline at end of file diff --git a/owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_client_config.json b/owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_client_config.json new file mode 100644 index 000000000000..93f35a4efd54 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_client_config.json @@ -0,0 +1,226 @@ +{ + "interfaces": { + "google.cloud.securitycenter.v2.SecurityCenter": { + "retry_codes": { + "idempotent": [ + "DEADLINE_EXCEEDED", + "UNAVAILABLE" + ], + "non_idempotent": [] + }, + "retry_params": { + "default": { + "initial_retry_delay_millis": 100, + "retry_delay_multiplier": 1.3, + "max_retry_delay_millis": 60000, + "initial_rpc_timeout_millis": 20000, + "rpc_timeout_multiplier": 1.0, + "max_rpc_timeout_millis": 20000, + "total_timeout_millis": 600000 + } + }, + "methods": { + "BatchCreateResourceValueConfigs": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "BulkMuteFindings": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "CreateBigQueryExport": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "CreateFinding": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "CreateMuteConfig": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "CreateNotificationConfig": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "CreateSource": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "DeleteBigQueryExport": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "DeleteMuteConfig": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "DeleteNotificationConfig": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "DeleteResourceValueConfig": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "GetBigQueryExport": { + "timeout_millis": 60000, + "retry_codes_name": "idempotent", + "retry_params_name": "default" + }, + "GetIamPolicy": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "GetMuteConfig": { + "timeout_millis": 60000, + "retry_codes_name": "idempotent", + "retry_params_name": "default" + }, + "GetNotificationConfig": { + "timeout_millis": 60000, + "retry_codes_name": "idempotent", + "retry_params_name": "default" + }, + "GetResourceValueConfig": { + "timeout_millis": 60000, + "retry_codes_name": "idempotent", + "retry_params_name": "default" + }, + "GetSimulation": { + "timeout_millis": 60000, + "retry_codes_name": "idempotent", + "retry_params_name": "default" + }, + "GetSource": { + "timeout_millis": 60000, + "retry_codes_name": "idempotent", + "retry_params_name": "default" + }, + "GetValuedResource": { + "timeout_millis": 60000, + "retry_codes_name": "idempotent", + "retry_params_name": "default" + }, + "GroupFindings": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "ListAttackPaths": { + "timeout_millis": 60000, + "retry_codes_name": "idempotent", + "retry_params_name": "default" + }, + "ListBigQueryExports": { + "timeout_millis": 60000, + "retry_codes_name": "idempotent", + "retry_params_name": "default" + }, + "ListFindings": { + "timeout_millis": 60000, + "retry_codes_name": "idempotent", + "retry_params_name": "default" + }, + "ListMuteConfigs": { + "timeout_millis": 60000, + "retry_codes_name": "idempotent", + "retry_params_name": "default" + }, + "ListNotificationConfigs": { + "timeout_millis": 60000, + "retry_codes_name": "idempotent", + "retry_params_name": "default" + }, + "ListResourceValueConfigs": { + "timeout_millis": 60000, + "retry_codes_name": "idempotent", + "retry_params_name": "default" + }, + "ListSources": { + "timeout_millis": 60000, + "retry_codes_name": "idempotent", + "retry_params_name": "default" + }, + "ListValuedResources": { + "timeout_millis": 60000, + "retry_codes_name": "idempotent", + "retry_params_name": "default" + }, + "SetFindingState": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "SetIamPolicy": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "SetMute": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "TestIamPermissions": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "UpdateBigQueryExport": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "UpdateExternalSystem": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "UpdateFinding": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "UpdateMuteConfig": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "UpdateNotificationConfig": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "UpdateResourceValueConfig": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "UpdateSecurityMarks": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + }, + "UpdateSource": { + "timeout_millis": 60000, + "retry_codes_name": "non_idempotent", + "retry_params_name": "default" + } + } + } + } +} diff --git a/owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_descriptor_config.php b/owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_descriptor_config.php new file mode 100644 index 000000000000..c8e952422ea3 --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_descriptor_config.php @@ -0,0 +1,672 @@ + [ + 'google.cloud.securitycenter.v2.SecurityCenter' => [ + 'BulkMuteFindings' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\SecurityCenter\V2\BulkMuteFindingsResponse', + 'metadataReturnType' => '\Google\Protobuf\GPBEmpty', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'BatchCreateResourceValueConfigs' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\BatchCreateResourceValueConfigsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateBigQueryExport' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\BigQueryExport', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateFinding' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\Finding', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateMuteConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\MuteConfig', + 'headerParams' => [ + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getParent', + ], + 'matchers' => [], + ], + ], + ], + 'CreateNotificationConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\NotificationConfig', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateSource' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\Source', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteBigQueryExport' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteMuteConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getName', + ], + 'matchers' => [], + ], + ], + ], + 'DeleteNotificationConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteResourceValueConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetBigQueryExport' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\BigQueryExport', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], + ], + 'GetMuteConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\MuteConfig', + 'headerParams' => [ + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getName', + ], + 'matchers' => [], + ], + ], + ], + 'GetNotificationConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\NotificationConfig', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetResourceValueConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\ResourceValueConfig', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetSimulation' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\Simulation', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetSource' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\Source', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetValuedResource' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\ValuedResource', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GroupFindings' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getGroupByResults', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\GroupFindingsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListAttackPaths' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getAttackPaths', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\ListAttackPathsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListBigQueryExports' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getBigQueryExports', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\ListBigQueryExportsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListFindings' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getListFindingsResults', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\ListFindingsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListMuteConfigs' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getMuteConfigs', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\ListMuteConfigsResponse', + 'headerParams' => [ + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getParent', + ], + 'matchers' => [], + ], + ], + ], + 'ListNotificationConfigs' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getNotificationConfigs', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\ListNotificationConfigsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListResourceValueConfigs' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getResourceValueConfigs', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\ListResourceValueConfigsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListSources' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getSources', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\ListSourcesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListValuedResources' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getValuedResources', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\ListValuedResourcesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'SetFindingState' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\Finding', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'SetIamPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\Policy', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], + ], + 'SetMute' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\Finding', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'TestIamPermissions' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'resource', + 'fieldAccessors' => [ + 'getResource', + ], + ], + ], + ], + 'UpdateBigQueryExport' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\BigQueryExport', + 'headerParams' => [ + [ + 'keyName' => 'big_query_export.name', + 'fieldAccessors' => [ + 'getBigQueryExport', + 'getName', + ], + ], + ], + ], + 'UpdateExternalSystem' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\ExternalSystem', + 'headerParams' => [ + [ + 'keyName' => 'external_system.name', + 'fieldAccessors' => [ + 'getExternalSystem', + 'getName', + ], + ], + ], + ], + 'UpdateFinding' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\Finding', + 'headerParams' => [ + [ + 'keyName' => 'finding.name', + 'fieldAccessors' => [ + 'getFinding', + 'getName', + ], + ], + ], + ], + 'UpdateMuteConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\MuteConfig', + 'headerParams' => [ + [ + 'keyName' => 'location', + 'fieldAccessors' => [ + 'getMuteConfig', + 'getName', + ], + 'matchers' => [], + ], + ], + ], + 'UpdateNotificationConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\NotificationConfig', + 'headerParams' => [ + [ + 'keyName' => 'notification_config.name', + 'fieldAccessors' => [ + 'getNotificationConfig', + 'getName', + ], + ], + ], + ], + 'UpdateResourceValueConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\ResourceValueConfig', + 'headerParams' => [ + [ + 'keyName' => 'resource_value_config.name', + 'fieldAccessors' => [ + 'getResourceValueConfig', + 'getName', + ], + ], + ], + ], + 'UpdateSecurityMarks' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\SecurityMarks', + 'headerParams' => [ + [ + 'keyName' => 'security_marks.name', + 'fieldAccessors' => [ + 'getSecurityMarks', + 'getName', + ], + ], + ], + ], + 'UpdateSource' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\SecurityCenter\V2\Source', + 'headerParams' => [ + [ + 'keyName' => 'source.name', + 'fieldAccessors' => [ + 'getSource', + 'getName', + ], + ], + ], + ], + 'templateMap' => [ + 'bigQueryExport' => 'organizations/{organization}/locations/{location}/bigQueryExports/{export}', + 'dlpJob' => 'projects/{project}/dlpJobs/{dlp_job}', + 'externalSystem' => 'organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}', + 'finding' => 'organizations/{organization}/sources/{source}/findings/{finding}', + 'folder' => 'folders/{folder}', + 'folderAssetSecurityMarks' => 'folders/{folder}/assets/{asset}/securityMarks', + 'folderConstraintName' => 'folders/{folder}/policies/{constraint_name}', + 'folderLocation' => 'folders/{folder}/locations/{location}', + 'folderLocationExport' => 'folders/{folder}/locations/{location}/bigQueryExports/{export}', + 'folderLocationMuteConfig' => 'folders/{folder}/locations/{location}/muteConfigs/{mute_config}', + 'folderLocationNotificationConfig' => 'folders/{folder}/locations/{location}/notificationConfigs/{notification_config}', + 'folderMuteConfig' => 'folders/{folder}/muteConfigs/{mute_config}', + 'folderSource' => 'folders/{folder}/sources/{source}', + 'folderSourceFinding' => 'folders/{folder}/sources/{source}/findings/{finding}', + 'folderSourceFindingExternalsystem' => 'folders/{folder}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}', + 'folderSourceFindingSecurityMarks' => 'folders/{folder}/sources/{source}/findings/{finding}/securityMarks', + 'folderSourceLocationFinding' => 'folders/{folder}/sources/{source}/locations/{location}/findings/{finding}', + 'folderSourceLocationFindingExternalsystem' => 'folders/{folder}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem}', + 'folderSourceLocationFindingSecurityMarks' => 'folders/{folder}/sources/{source}/locations/{location}/findings/{finding}/securityMarks', + 'location' => 'projects/{project}/locations/{location}', + 'muteConfig' => 'organizations/{organization}/muteConfigs/{mute_config}', + 'notificationConfig' => 'organizations/{organization}/locations/{location}/notificationConfigs/{notification_config}', + 'organization' => 'organizations/{organization}', + 'organizationAssetSecurityMarks' => 'organizations/{organization}/assets/{asset}/securityMarks', + 'organizationConstraintName' => 'organizations/{organization}/policies/{constraint_name}', + 'organizationLocation' => 'organizations/{organization}/locations/{location}', + 'organizationLocationExport' => 'organizations/{organization}/locations/{location}/bigQueryExports/{export}', + 'organizationLocationMuteConfig' => 'organizations/{organization}/locations/{location}/muteConfigs/{mute_config}', + 'organizationLocationNotificationConfig' => 'organizations/{organization}/locations/{location}/notificationConfigs/{notification_config}', + 'organizationLocationResourceValueConfig' => 'organizations/{organization}/locations/{location}/resourceValueConfigs/{resource_value_config}', + 'organizationLocationSimluation' => 'organizations/{organization}/locations/{location}/simulations/{simluation}', + 'organizationLocationSimluationValuedResource' => 'organizations/{organization}/locations/{location}/simulations/{simluation}/valuedResources/{valued_resource}', + 'organizationMuteConfig' => 'organizations/{organization}/muteConfigs/{mute_config}', + 'organizationResourceValueConfig' => 'organizations/{organization}/resourceValueConfigs/{resource_value_config}', + 'organizationSimulation' => 'organizations/{organization}/simulations/{simulation}', + 'organizationSimulationValuedResource' => 'organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}', + 'organizationSource' => 'organizations/{organization}/sources/{source}', + 'organizationSourceFinding' => 'organizations/{organization}/sources/{source}/findings/{finding}', + 'organizationSourceFindingExternalsystem' => 'organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}', + 'organizationSourceFindingSecurityMarks' => 'organizations/{organization}/sources/{source}/findings/{finding}/securityMarks', + 'organizationSourceLocationFinding' => 'organizations/{organization}/sources/{source}/locations/{location}/findings/{finding}', + 'organizationSourceLocationFindingExternalsystem' => 'organizations/{organization}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem}', + 'organizationSourceLocationFindingSecurityMarks' => 'organizations/{organization}/sources/{source}/locations/{location}/findings/{finding}/securityMarks', + 'organizationValuedResource' => 'organizations/{organization}/locations/{location}/simulations/{simulation}/valuedResources/{valued_resource}', + 'policy' => 'organizations/{organization}/policies/{constraint_name}', + 'project' => 'projects/{project}', + 'projectAssetSecurityMarks' => 'projects/{project}/assets/{asset}/securityMarks', + 'projectConstraintName' => 'projects/{project}/policies/{constraint_name}', + 'projectDlpJob' => 'projects/{project}/dlpJobs/{dlp_job}', + 'projectLocationDlpJob' => 'projects/{project}/locations/{location}/dlpJobs/{dlp_job}', + 'projectLocationExport' => 'projects/{project}/locations/{location}/bigQueryExports/{export}', + 'projectLocationMuteConfig' => 'projects/{project}/locations/{location}/muteConfigs/{mute_config}', + 'projectLocationNotificationConfig' => 'projects/{project}/locations/{location}/notificationConfigs/{notification_config}', + 'projectLocationTableProfile' => 'projects/{project}/locations/{location}/tableProfiles/{table_profile}', + 'projectMuteConfig' => 'projects/{project}/muteConfigs/{mute_config}', + 'projectSource' => 'projects/{project}/sources/{source}', + 'projectSourceFinding' => 'projects/{project}/sources/{source}/findings/{finding}', + 'projectSourceFindingExternalsystem' => 'projects/{project}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}', + 'projectSourceFindingSecurityMarks' => 'projects/{project}/sources/{source}/findings/{finding}/securityMarks', + 'projectSourceLocationFinding' => 'projects/{project}/sources/{source}/locations/{location}/findings/{finding}', + 'projectSourceLocationFindingExternalsystem' => 'projects/{project}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem}', + 'projectSourceLocationFindingSecurityMarks' => 'projects/{project}/sources/{source}/locations/{location}/findings/{finding}/securityMarks', + 'projectTableProfile' => 'projects/{project}/tableProfiles/{table_profile}', + 'resourceValueConfig' => 'organizations/{organization}/resourceValueConfigs/{resource_value_config}', + 'securityMarks' => 'organizations/{organization}/assets/{asset}/securityMarks', + 'simulation' => 'organizations/{organization}/simulations/{simulation}', + 'source' => 'organizations/{organization}/sources/{source}', + 'tableDataProfile' => 'projects/{project}/tableProfiles/{table_profile}', + 'topic' => 'projects/{project}/topics/{topic}', + 'valuedResource' => 'organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}', + ], + ], + ], +]; diff --git a/owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_rest_client_config.php b/owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_rest_client_config.php new file mode 100644 index 000000000000..ae5110e7ac2d --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_rest_client_config.php @@ -0,0 +1,1125 @@ + [ + 'google.cloud.securitycenter.v2.SecurityCenter' => [ + 'BatchCreateResourceValueConfigs' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*}/resourceValueConfigs:batchCreate', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/resourceValueConfigs:batchCreate', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'BulkMuteFindings' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*}/findings:bulkMute', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/findings:bulkMute', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=folders/*}/findings:bulkMute', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=folders/*/locations/*}/findings:bulkMute', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*}/findings:bulkMute', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/findings:bulkMute', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'CreateBigQueryExport' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/bigQueryExports', + 'body' => 'big_query_export', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=folders/*/locations/*}/bigQueryExports', + 'body' => 'big_query_export', + 'queryParams' => [ + 'big_query_export_id', + ], + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/bigQueryExports', + 'body' => 'big_query_export', + 'queryParams' => [ + 'big_query_export_id', + ], + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'big_query_export_id', + ], + ], + 'CreateFinding' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*/sources/*/locations/*}/findings', + 'body' => 'finding', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*/sources/*}/findings', + 'body' => 'finding', + 'queryParams' => [ + 'finding_id', + ], + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'finding_id', + ], + ], + 'CreateMuteConfig' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/muteConfigs', + 'body' => 'mute_config', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=folders/*/locations/*}/muteConfigs', + 'body' => 'mute_config', + 'queryParams' => [ + 'mute_config_id', + ], + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/muteConfigs', + 'body' => 'mute_config', + 'queryParams' => [ + 'mute_config_id', + ], + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*}/muteConfigs', + 'body' => 'mute_config', + 'queryParams' => [ + 'mute_config_id', + ], + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=folders/*}/muteConfigs', + 'body' => 'mute_config', + 'queryParams' => [ + 'mute_config_id', + ], + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*}/muteConfigs', + 'body' => 'mute_config', + 'queryParams' => [ + 'mute_config_id', + ], + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'mute_config_id', + ], + ], + 'CreateNotificationConfig' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/notificationConfigs', + 'body' => 'notification_config', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=folders/*/locations/*}/notificationConfigs', + 'body' => 'notification_config', + 'queryParams' => [ + 'config_id', + ], + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/notificationConfigs', + 'body' => 'notification_config', + 'queryParams' => [ + 'config_id', + ], + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'config_id', + ], + ], + 'CreateSource' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*}/sources', + 'body' => 'source', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteBigQueryExport' => [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/bigQueryExports/*}', + 'additionalBindings' => [ + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=folders/*/locations/*/bigQueryExports/*}', + ], + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/bigQueryExports/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteMuteConfig' => [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=organizations/*/muteConfigs/*}', + 'additionalBindings' => [ + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/muteConfigs/*}', + ], + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=folders/*/muteConfigs/*}', + ], + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=folders/*/locations/*/muteConfigs/*}', + ], + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/muteConfigs/*}', + ], + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/muteConfigs/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteNotificationConfig' => [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/notificationConfigs/*}', + 'additionalBindings' => [ + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=folders/*/locations/*/notificationConfigs/*}', + ], + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/notificationConfigs/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteResourceValueConfig' => [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=organizations/*/resourceValueConfigs/*}', + 'additionalBindings' => [ + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/resourceValueConfigs/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetBigQueryExport' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/bigQueryExports/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=folders/*/locations/*/bigQueryExports/*}', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/bigQueryExports/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetIamPolicy' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{resource=organizations/*/sources/*}:getIamPolicy', + 'body' => '*', + 'placeholders' => [ + 'resource' => [ + 'getters' => [ + 'getResource', + ], + ], + ], + ], + 'GetMuteConfig' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/muteConfigs/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/muteConfigs/*}', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=folders/*/muteConfigs/*}', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=folders/*/locations/*/muteConfigs/*}', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/muteConfigs/*}', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/muteConfigs/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetNotificationConfig' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/notificationConfigs/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=folders/*/locations/*/notificationConfigs/*}', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/notificationConfigs/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetResourceValueConfig' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/resourceValueConfigs/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/resourceValueConfigs/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetSimulation' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/simulations/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/simulations/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetSource' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/sources/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetValuedResource' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/simulations/*/valuedResources/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/simulations/*/valuedResources/*}', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GroupFindings' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*/sources/*}/findings:group', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*/sources/*/locations/*}/findings:group', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=folders/*/sources/*}/findings:group', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=folders/*/sources/*/locations/*}/findings:group', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/sources/*}/findings:group', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/sources/*/locations/*}/findings:group', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListAttackPaths' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/simulations/*}/attackPaths', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/simulations/*/valuedResources/*}/attackPaths', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*/simulations/*/valuedResources/*}/attackPaths', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/simulations/*/attackExposureResults/*}/attackPaths', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*/simulations/*/attackExposureResults/*}/attackPaths', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListBigQueryExports' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/bigQueryExports', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=folders/*/locations/*}/bigQueryExports', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/bigQueryExports', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListFindings' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/sources/*}/findings', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/sources/*/locations/*}/findings', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=folders/*/sources/*}/findings', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=folders/*/sources/*/locations/*}/findings', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*/sources/*}/findings', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*/sources/*/locations/*}/findings', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListMuteConfigs' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*}/muteConfigs', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/muteConfigs', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=folders/*}/muteConfigs', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=folders/*/locations/*}/muteConfigs', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*}/muteConfigs', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/muteConfigs', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListNotificationConfigs' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/notificationConfigs', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=folders/*/locations/*}/notificationConfigs', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/notificationConfigs', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListResourceValueConfigs' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*}/resourceValueConfigs', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/resourceValueConfigs', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListSources' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*}/sources', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=folders/*}/sources', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*}/sources', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListValuedResources' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/simulations/*}/valuedResources', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/simulations/*/attackExposureResults/*}/valuedResources', + ], + ], + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'SetFindingState' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=organizations/*/sources/*/findings/*}:setState', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=organizations/*/sources/*/locations/*/findings/*}:setState', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=folders/*/sources/*/findings/*}:setState', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=folders/*/sources/*/locations/*/findings/*}:setState', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=projects/*/sources/*/findings/*}:setState', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=projects/*/sources/*/locations/*/findings/*}:setState', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'SetIamPolicy' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{resource=organizations/*/sources/*}:setIamPolicy', + 'body' => '*', + 'placeholders' => [ + 'resource' => [ + 'getters' => [ + 'getResource', + ], + ], + ], + ], + 'SetMute' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=organizations/*/sources/*/findings/*}:setMute', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=organizations/*/sources/*/locations/*/findings/*}:setMute', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=folders/*/sources/*/findings/*}:setMute', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=folders/*/sources/*/locations/*/findings/*}:setMute', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=projects/*/sources/*/findings/*}:setMute', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=projects/*/sources/*/locations/*/findings/*}:setMute', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'TestIamPermissions' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{resource=organizations/*/sources/*}:testIamPermissions', + 'body' => '*', + 'placeholders' => [ + 'resource' => [ + 'getters' => [ + 'getResource', + ], + ], + ], + ], + 'UpdateBigQueryExport' => [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{big_query_export.name=organizations/*/locations/*/bigQueryExports/*}', + 'body' => 'big_query_export', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{big_query_export.name=folders/*/locations/*/bigQueryExports/*}', + 'body' => 'big_query_export', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{big_query_export.name=projects/*/locations/*/bigQueryExports/*}', + 'body' => 'big_query_export', + ], + ], + 'placeholders' => [ + 'big_query_export.name' => [ + 'getters' => [ + 'getBigQueryExport', + 'getName', + ], + ], + ], + ], + 'UpdateExternalSystem' => [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{external_system.name=organizations/*/sources/*/findings/*/externalSystems/*}', + 'body' => 'external_system', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{external_system.name=organizations/*/sources/*/locations/*/findings/*/externalSystems/*}', + 'body' => 'external_system', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{external_system.name=folders/*/sources/*/findings/*/externalSystems/*}', + 'body' => 'external_system', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{external_system.name=folders/*/sources/*/locations/*/findings/*/externalSystems/*}', + 'body' => 'external_system', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{external_system.name=projects/*/sources/*/findings/*/externalSystems/*}', + 'body' => 'external_system', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{external_system.name=projects/*/sources/*/locations/*/findings/*/externalSystems/*}', + 'body' => 'external_system', + ], + ], + 'placeholders' => [ + 'external_system.name' => [ + 'getters' => [ + 'getExternalSystem', + 'getName', + ], + ], + ], + ], + 'UpdateFinding' => [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{finding.name=organizations/*/sources/*/findings/*}', + 'body' => 'finding', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{finding.name=organizations/*/sources/*/locations/*/findings/*}', + 'body' => 'finding', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{finding.name=folders/*/sources/*/findings/*}', + 'body' => 'finding', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{finding.name=folders/*/sources/*/locations/*/findings/*}', + 'body' => 'finding', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{finding.name=projects/*/sources/*/findings/*}', + 'body' => 'finding', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{finding.name=projects/*/sources/*/locations/*/findings/*}', + 'body' => 'finding', + ], + ], + 'placeholders' => [ + 'finding.name' => [ + 'getters' => [ + 'getFinding', + 'getName', + ], + ], + ], + ], + 'UpdateMuteConfig' => [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{mute_config.name=organizations/*/muteConfigs/*}', + 'body' => 'mute_config', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{mute_config.name=organizations/*/locations/*/muteConfigs/*}', + 'body' => 'mute_config', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{mute_config.name=folders/*/muteConfigs/*}', + 'body' => 'mute_config', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{mute_config.name=folders/*/locations/*/muteConfigs/*}', + 'body' => 'mute_config', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{mute_config.name=projects/*/muteConfigs/*}', + 'body' => 'mute_config', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{mute_config.name=projects/*/locations/*/muteConfigs/*}', + 'body' => 'mute_config', + ], + ], + 'placeholders' => [ + 'mute_config.name' => [ + 'getters' => [ + 'getMuteConfig', + 'getName', + ], + ], + ], + ], + 'UpdateNotificationConfig' => [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{notification_config.name=organizations/*/locations/*/notificationConfigs/*}', + 'body' => 'notification_config', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{notification_config.name=folders/*/locations/*/notificationConfigs/*}', + 'body' => 'notification_config', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{notification_config.name=projects/*/locations/*/notificationConfigs/*}', + 'body' => 'notification_config', + ], + ], + 'placeholders' => [ + 'notification_config.name' => [ + 'getters' => [ + 'getNotificationConfig', + 'getName', + ], + ], + ], + ], + 'UpdateResourceValueConfig' => [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{resource_value_config.name=organizations/*/resourceValueConfigs/*}', + 'body' => 'resource_value_config', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{resource_value_config.name=organizations/*/locations/*/resourceValueConfigs/*}', + 'body' => 'resource_value_config', + ], + ], + 'placeholders' => [ + 'resource_value_config.name' => [ + 'getters' => [ + 'getResourceValueConfig', + 'getName', + ], + ], + ], + ], + 'UpdateSecurityMarks' => [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{security_marks.name=organizations/*/sources/*/findings/*/securityMarks}', + 'body' => 'security_marks', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{security_marks.name=organizations/*/assets/*/securityMarks}', + 'body' => 'security_marks', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{security_marks.name=organizations/*/sources/*/locations/*/findings/*/securityMarks}', + 'body' => 'security_marks', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{security_marks.name=folders/*/sources/*/findings/*/securityMarks}', + 'body' => 'security_marks', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{security_marks.name=folders/*/assets/*/securityMarks}', + 'body' => 'security_marks', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{security_marks.name=folders/*/sources/*/locations/*/findings/*/securityMarks}', + 'body' => 'security_marks', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{security_marks.name=projects/*/sources/*/findings/*/securityMarks}', + 'body' => 'security_marks', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{security_marks.name=projects/*/assets/*/securityMarks}', + 'body' => 'security_marks', + ], + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{security_marks.name=projects/*/sources/*/locations/*/findings/*/securityMarks}', + 'body' => 'security_marks', + ], + ], + 'placeholders' => [ + 'security_marks.name' => [ + 'getters' => [ + 'getSecurityMarks', + 'getName', + ], + ], + ], + ], + 'UpdateSource' => [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{source.name=organizations/*/sources/*}', + 'body' => 'source', + 'placeholders' => [ + 'source.name' => [ + 'getters' => [ + 'getSource', + 'getName', + ], + ], + ], + ], + ], + 'google.longrunning.Operations' => [ + 'CancelOperation' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=organizations/*/operations/*}:cancel', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteOperation' => [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=organizations/*/operations/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetOperation' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/operations/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'ListOperations' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/operations}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + ], + ], + 'numericEnums' => true, +]; diff --git a/owl-bot-staging/SecurityCenter/v2/tests/Unit/V2/Client/SecurityCenterClientTest.php b/owl-bot-staging/SecurityCenter/v2/tests/Unit/V2/Client/SecurityCenterClientTest.php new file mode 100644 index 000000000000..b3717581d42b --- /dev/null +++ b/owl-bot-staging/SecurityCenter/v2/tests/Unit/V2/Client/SecurityCenterClientTest.php @@ -0,0 +1,3152 @@ +getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); + } + + /** @return SecurityCenterClient */ + private function createClient(array $options = []) + { + $options += [ + 'credentials' => $this->createCredentials(), + ]; + return new SecurityCenterClient($options); + } + + /** @test */ + public function batchCreateResourceValueConfigsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new BatchCreateResourceValueConfigsResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $requests = []; + $request = (new BatchCreateResourceValueConfigsRequest()) + ->setParent($formattedParent) + ->setRequests($requests); + $response = $gapicClient->batchCreateResourceValueConfigs($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/BatchCreateResourceValueConfigs', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getRequests(); + $this->assertProtobufEquals($requests, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function batchCreateResourceValueConfigsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $requests = []; + $request = (new BatchCreateResourceValueConfigsRequest()) + ->setParent($formattedParent) + ->setRequests($requests); + try { + $gapicClient->batchCreateResourceValueConfigs($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function bulkMuteFindingsTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/bulkMuteFindingsTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new BulkMuteFindingsResponse(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/bulkMuteFindingsTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $parent = 'parent-995424086'; + $request = (new BulkMuteFindingsRequest()) + ->setParent($parent); + $response = $gapicClient->bulkMuteFindings($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $apiRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($apiRequests)); + $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); + $this->assertSame(0, count($operationsRequestsEmpty)); + $actualApiFuncCall = $apiRequests[0]->getFuncCall(); + $actualApiRequestObject = $apiRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/BulkMuteFindings', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($parent, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/bulkMuteFindingsTest'); + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + $this->assertTrue($response->isDone()); + $this->assertEquals($expectedResponse, $response->getResult()); + $apiRequestsEmpty = $transport->popReceivedCalls(); + $this->assertSame(0, count($apiRequestsEmpty)); + $operationsRequests = $operationsTransport->popReceivedCalls(); + $this->assertSame(1, count($operationsRequests)); + $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); + $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); + $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); + $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function bulkMuteFindingsExceptionTest() + { + $operationsTransport = $this->createTransport(); + $operationsClient = new OperationsClient([ + 'apiEndpoint' => '', + 'transport' => $operationsTransport, + 'credentials' => $this->createCredentials(), + ]); + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + 'operationsClient' => $operationsClient, + ]); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + // Mock response + $incompleteOperation = new Operation(); + $incompleteOperation->setName('operations/bulkMuteFindingsTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $operationsTransport->addResponse(null, $status); + // Mock request + $parent = 'parent-995424086'; + $request = (new BulkMuteFindingsRequest()) + ->setParent($parent); + $response = $gapicClient->bulkMuteFindings($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/bulkMuteFindingsTest'); + try { + $response->pollUntilComplete([ + 'initialPollDelayMillis' => 1, + ]); + // If the pollUntilComplete() method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stubs are exhausted + $transport->popReceivedCalls(); + $operationsTransport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + $this->assertTrue($operationsTransport->isExhausted()); + } + + /** @test */ + public function createBigQueryExportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $description = 'description-1724546052'; + $filter = 'filter-1274492040'; + $dataset = 'dataset1443214456'; + $mostRecentEditor = 'mostRecentEditor-657770475'; + $principal = 'principal-1812041682'; + $expectedResponse = new BigQueryExport(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setFilter($filter); + $expectedResponse->setDataset($dataset); + $expectedResponse->setMostRecentEditor($mostRecentEditor); + $expectedResponse->setPrincipal($principal); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $bigQueryExport = new BigQueryExport(); + $bigQueryExportId = 'bigQueryExportId269737360'; + $request = (new CreateBigQueryExportRequest()) + ->setParent($formattedParent) + ->setBigQueryExport($bigQueryExport) + ->setBigQueryExportId($bigQueryExportId); + $response = $gapicClient->createBigQueryExport($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/CreateBigQueryExport', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getBigQueryExport(); + $this->assertProtobufEquals($bigQueryExport, $actualValue); + $actualValue = $actualRequestObject->getBigQueryExportId(); + $this->assertProtobufEquals($bigQueryExportId, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createBigQueryExportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $bigQueryExport = new BigQueryExport(); + $bigQueryExportId = 'bigQueryExportId269737360'; + $request = (new CreateBigQueryExportRequest()) + ->setParent($formattedParent) + ->setBigQueryExport($bigQueryExport) + ->setBigQueryExportId($bigQueryExportId); + try { + $gapicClient->createBigQueryExport($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createFindingTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $canonicalName = 'canonicalName1385400054'; + $parent2 = 'parent21175163357'; + $resourceName = 'resourceName979421212'; + $category = 'category50511102'; + $externalUri = 'externalUri-1385596168'; + $muteInitiator = 'muteInitiator7603081'; + $parentDisplayName = 'parentDisplayName934119773'; + $description = 'description-1724546052'; + $nextSteps = 'nextSteps-921338149'; + $moduleName = 'moduleName-1195003778'; + $expectedResponse = new Finding(); + $expectedResponse->setName($name); + $expectedResponse->setCanonicalName($canonicalName); + $expectedResponse->setParent($parent2); + $expectedResponse->setResourceName($resourceName); + $expectedResponse->setCategory($category); + $expectedResponse->setExternalUri($externalUri); + $expectedResponse->setMuteInitiator($muteInitiator); + $expectedResponse->setParentDisplayName($parentDisplayName); + $expectedResponse->setDescription($description); + $expectedResponse->setNextSteps($nextSteps); + $expectedResponse->setModuleName($moduleName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $findingId = 'findingId728776081'; + $finding = new Finding(); + $request = (new CreateFindingRequest()) + ->setParent($formattedParent) + ->setFindingId($findingId) + ->setFinding($finding); + $response = $gapicClient->createFinding($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/CreateFinding', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getFindingId(); + $this->assertProtobufEquals($findingId, $actualValue); + $actualValue = $actualRequestObject->getFinding(); + $this->assertProtobufEquals($finding, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createFindingExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $findingId = 'findingId728776081'; + $finding = new Finding(); + $request = (new CreateFindingRequest()) + ->setParent($formattedParent) + ->setFindingId($findingId) + ->setFinding($finding); + try { + $gapicClient->createFinding($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createMuteConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $description = 'description-1724546052'; + $filter = 'filter-1274492040'; + $mostRecentEditor = 'mostRecentEditor-657770475'; + $expectedResponse = new MuteConfig(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setFilter($filter); + $expectedResponse->setMostRecentEditor($mostRecentEditor); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $muteConfig = new MuteConfig(); + $muteConfigFilter = 'muteConfigFilter-1921414637'; + $muteConfig->setFilter($muteConfigFilter); + $muteConfigType = MuteConfigType::MUTE_CONFIG_TYPE_UNSPECIFIED; + $muteConfig->setType($muteConfigType); + $muteConfigId = 'muteConfigId-547860334'; + $request = (new CreateMuteConfigRequest()) + ->setParent($formattedParent) + ->setMuteConfig($muteConfig) + ->setMuteConfigId($muteConfigId); + $response = $gapicClient->createMuteConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/CreateMuteConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getMuteConfig(); + $this->assertProtobufEquals($muteConfig, $actualValue); + $actualValue = $actualRequestObject->getMuteConfigId(); + $this->assertProtobufEquals($muteConfigId, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createMuteConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $muteConfig = new MuteConfig(); + $muteConfigFilter = 'muteConfigFilter-1921414637'; + $muteConfig->setFilter($muteConfigFilter); + $muteConfigType = MuteConfigType::MUTE_CONFIG_TYPE_UNSPECIFIED; + $muteConfig->setType($muteConfigType); + $muteConfigId = 'muteConfigId-547860334'; + $request = (new CreateMuteConfigRequest()) + ->setParent($formattedParent) + ->setMuteConfig($muteConfig) + ->setMuteConfigId($muteConfigId); + try { + $gapicClient->createMuteConfig($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createNotificationConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $description = 'description-1724546052'; + $pubsubTopic = 'pubsubTopic-338126829'; + $serviceAccount = 'serviceAccount-1948028253'; + $expectedResponse = new NotificationConfig(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setPubsubTopic($pubsubTopic); + $expectedResponse->setServiceAccount($serviceAccount); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $configId = 'configId-804450504'; + $notificationConfig = new NotificationConfig(); + $request = (new CreateNotificationConfigRequest()) + ->setParent($formattedParent) + ->setConfigId($configId) + ->setNotificationConfig($notificationConfig); + $response = $gapicClient->createNotificationConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/CreateNotificationConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getConfigId(); + $this->assertProtobufEquals($configId, $actualValue); + $actualValue = $actualRequestObject->getNotificationConfig(); + $this->assertProtobufEquals($notificationConfig, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createNotificationConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $configId = 'configId-804450504'; + $notificationConfig = new NotificationConfig(); + $request = (new CreateNotificationConfigRequest()) + ->setParent($formattedParent) + ->setConfigId($configId) + ->setNotificationConfig($notificationConfig); + try { + $gapicClient->createNotificationConfig($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createSourceTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $canonicalName = 'canonicalName1385400054'; + $expectedResponse = new Source(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setCanonicalName($canonicalName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $source = new Source(); + $request = (new CreateSourceRequest()) + ->setParent($formattedParent) + ->setSource($source); + $response = $gapicClient->createSource($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/CreateSource', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getSource(); + $this->assertProtobufEquals($source, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createSourceExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $source = new Source(); + $request = (new CreateSourceRequest()) + ->setParent($formattedParent) + ->setSource($source); + try { + $gapicClient->createSource($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteBigQueryExportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[LOCATION]', '[EXPORT]'); + $request = (new DeleteBigQueryExportRequest()) + ->setName($formattedName); + $gapicClient->deleteBigQueryExport($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/DeleteBigQueryExport', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteBigQueryExportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[LOCATION]', '[EXPORT]'); + $request = (new DeleteBigQueryExportRequest()) + ->setName($formattedName); + try { + $gapicClient->deleteBigQueryExport($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteMuteConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); + $request = (new DeleteMuteConfigRequest()) + ->setName($formattedName); + $gapicClient->deleteMuteConfig($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/DeleteMuteConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteMuteConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); + $request = (new DeleteMuteConfigRequest()) + ->setName($formattedName); + try { + $gapicClient->deleteMuteConfig($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteNotificationConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[LOCATION]', '[NOTIFICATION_CONFIG]'); + $request = (new DeleteNotificationConfigRequest()) + ->setName($formattedName); + $gapicClient->deleteNotificationConfig($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/DeleteNotificationConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteNotificationConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[LOCATION]', '[NOTIFICATION_CONFIG]'); + $request = (new DeleteNotificationConfigRequest()) + ->setName($formattedName); + try { + $gapicClient->deleteNotificationConfig($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteResourceValueConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->resourceValueConfigName('[ORGANIZATION]', '[RESOURCE_VALUE_CONFIG]'); + $request = (new DeleteResourceValueConfigRequest()) + ->setName($formattedName); + $gapicClient->deleteResourceValueConfig($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/DeleteResourceValueConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteResourceValueConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->resourceValueConfigName('[ORGANIZATION]', '[RESOURCE_VALUE_CONFIG]'); + $request = (new DeleteResourceValueConfigRequest()) + ->setName($formattedName); + try { + $gapicClient->deleteResourceValueConfig($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getBigQueryExportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $description = 'description-1724546052'; + $filter = 'filter-1274492040'; + $dataset = 'dataset1443214456'; + $mostRecentEditor = 'mostRecentEditor-657770475'; + $principal = 'principal-1812041682'; + $expectedResponse = new BigQueryExport(); + $expectedResponse->setName($name2); + $expectedResponse->setDescription($description); + $expectedResponse->setFilter($filter); + $expectedResponse->setDataset($dataset); + $expectedResponse->setMostRecentEditor($mostRecentEditor); + $expectedResponse->setPrincipal($principal); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[LOCATION]', '[EXPORT]'); + $request = (new GetBigQueryExportRequest()) + ->setName($formattedName); + $response = $gapicClient->getBigQueryExport($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/GetBigQueryExport', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getBigQueryExportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[LOCATION]', '[EXPORT]'); + $request = (new GetBigQueryExportRequest()) + ->setName($formattedName); + try { + $gapicClient->getBigQueryExport($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getIamPolicyTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $version = 351608024; + $etag = '21'; + $expectedResponse = new Policy(); + $expectedResponse->setVersion($version); + $expectedResponse->setEtag($etag); + $transport->addResponse($expectedResponse); + // Mock request + $resource = 'resource-341064690'; + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + $response = $gapicClient->getIamPolicy($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/GetIamPolicy', $actualFuncCall); + $actualValue = $actualRequestObject->getResource(); + $this->assertProtobufEquals($resource, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getIamPolicyExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $resource = 'resource-341064690'; + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + try { + $gapicClient->getIamPolicy($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getMuteConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $description = 'description-1724546052'; + $filter = 'filter-1274492040'; + $mostRecentEditor = 'mostRecentEditor-657770475'; + $expectedResponse = new MuteConfig(); + $expectedResponse->setName($name2); + $expectedResponse->setDescription($description); + $expectedResponse->setFilter($filter); + $expectedResponse->setMostRecentEditor($mostRecentEditor); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); + $request = (new GetMuteConfigRequest()) + ->setName($formattedName); + $response = $gapicClient->getMuteConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/GetMuteConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getMuteConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); + $request = (new GetMuteConfigRequest()) + ->setName($formattedName); + try { + $gapicClient->getMuteConfig($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getNotificationConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $description = 'description-1724546052'; + $pubsubTopic = 'pubsubTopic-338126829'; + $serviceAccount = 'serviceAccount-1948028253'; + $expectedResponse = new NotificationConfig(); + $expectedResponse->setName($name2); + $expectedResponse->setDescription($description); + $expectedResponse->setPubsubTopic($pubsubTopic); + $expectedResponse->setServiceAccount($serviceAccount); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[LOCATION]', '[NOTIFICATION_CONFIG]'); + $request = (new GetNotificationConfigRequest()) + ->setName($formattedName); + $response = $gapicClient->getNotificationConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/GetNotificationConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getNotificationConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[LOCATION]', '[NOTIFICATION_CONFIG]'); + $request = (new GetNotificationConfigRequest()) + ->setName($formattedName); + try { + $gapicClient->getNotificationConfig($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getResourceValueConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $resourceType = 'resourceType979623115'; + $scope = 'scope109264468'; + $description = 'description-1724546052'; + $expectedResponse = new ResourceValueConfig(); + $expectedResponse->setName($name2); + $expectedResponse->setResourceType($resourceType); + $expectedResponse->setScope($scope); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->resourceValueConfigName('[ORGANIZATION]', '[RESOURCE_VALUE_CONFIG]'); + $request = (new GetResourceValueConfigRequest()) + ->setName($formattedName); + $response = $gapicClient->getResourceValueConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/GetResourceValueConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getResourceValueConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->resourceValueConfigName('[ORGANIZATION]', '[RESOURCE_VALUE_CONFIG]'); + $request = (new GetResourceValueConfigRequest()) + ->setName($formattedName); + try { + $gapicClient->getResourceValueConfig($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getSimulationTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $expectedResponse = new Simulation(); + $expectedResponse->setName($name2); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->simulationName('[ORGANIZATION]', '[SIMULATION]'); + $request = (new GetSimulationRequest()) + ->setName($formattedName); + $response = $gapicClient->getSimulation($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/GetSimulation', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getSimulationExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->simulationName('[ORGANIZATION]', '[SIMULATION]'); + $request = (new GetSimulationRequest()) + ->setName($formattedName); + try { + $gapicClient->getSimulation($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getSourceTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $canonicalName = 'canonicalName1385400054'; + $expectedResponse = new Source(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setCanonicalName($canonicalName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $request = (new GetSourceRequest()) + ->setName($formattedName); + $response = $gapicClient->getSource($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/GetSource', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getSourceExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $request = (new GetSourceRequest()) + ->setName($formattedName); + try { + $gapicClient->getSource($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getValuedResourceTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $resource = 'resource-341064690'; + $resourceType = 'resourceType979623115'; + $displayName = 'displayName1615086568'; + $exposedScore = -1.37568698E8; + $expectedResponse = new ValuedResource(); + $expectedResponse->setName($name2); + $expectedResponse->setResource($resource); + $expectedResponse->setResourceType($resourceType); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setExposedScore($exposedScore); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->valuedResourceName('[ORGANIZATION]', '[SIMULATION]', '[VALUED_RESOURCE]'); + $request = (new GetValuedResourceRequest()) + ->setName($formattedName); + $response = $gapicClient->getValuedResource($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/GetValuedResource', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getValuedResourceExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->valuedResourceName('[ORGANIZATION]', '[SIMULATION]', '[VALUED_RESOURCE]'); + $request = (new GetValuedResourceRequest()) + ->setName($formattedName); + try { + $gapicClient->getValuedResource($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function groupFindingsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $totalSize = 705419236; + $groupByResultsElement = new GroupResult(); + $groupByResults = [ + $groupByResultsElement, + ]; + $expectedResponse = new GroupFindingsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setTotalSize($totalSize); + $expectedResponse->setGroupByResults($groupByResults); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $groupBy = 'groupBy506361367'; + $request = (new GroupFindingsRequest()) + ->setParent($formattedParent) + ->setGroupBy($groupBy); + $response = $gapicClient->groupFindings($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getGroupByResults()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/GroupFindings', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getGroupBy(); + $this->assertProtobufEquals($groupBy, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function groupFindingsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $groupBy = 'groupBy506361367'; + $request = (new GroupFindingsRequest()) + ->setParent($formattedParent) + ->setGroupBy($groupBy); + try { + $gapicClient->groupFindings($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listAttackPathsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $attackPathsElement = new AttackPath(); + $attackPaths = [ + $attackPathsElement, + ]; + $expectedResponse = new ListAttackPathsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setAttackPaths($attackPaths); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationValuedResourceName('[ORGANIZATION]', '[LOCATION]', '[SIMULATION]', '[VALUED_RESOURCE]'); + $request = (new ListAttackPathsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listAttackPaths($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getAttackPaths()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/ListAttackPaths', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listAttackPathsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->organizationValuedResourceName('[ORGANIZATION]', '[LOCATION]', '[SIMULATION]', '[VALUED_RESOURCE]'); + $request = (new ListAttackPathsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listAttackPaths($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listBigQueryExportsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $bigQueryExportsElement = new BigQueryExport(); + $bigQueryExports = [ + $bigQueryExportsElement, + ]; + $expectedResponse = new ListBigQueryExportsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setBigQueryExports($bigQueryExports); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListBigQueryExportsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listBigQueryExports($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getBigQueryExports()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/ListBigQueryExports', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listBigQueryExportsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListBigQueryExportsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listBigQueryExports($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listFindingsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $totalSize = 705419236; + $listFindingsResultsElement = new ListFindingsResult(); + $listFindingsResults = [ + $listFindingsResultsElement, + ]; + $expectedResponse = new ListFindingsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setTotalSize($totalSize); + $expectedResponse->setListFindingsResults($listFindingsResults); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $request = (new ListFindingsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listFindings($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getListFindingsResults()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/ListFindings', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listFindingsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); + $request = (new ListFindingsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listFindings($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listMuteConfigsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $muteConfigsElement = new MuteConfig(); + $muteConfigs = [ + $muteConfigsElement, + ]; + $expectedResponse = new ListMuteConfigsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setMuteConfigs($muteConfigs); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListMuteConfigsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listMuteConfigs($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getMuteConfigs()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/ListMuteConfigs', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listMuteConfigsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListMuteConfigsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listMuteConfigs($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listNotificationConfigsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $notificationConfigsElement = new NotificationConfig(); + $notificationConfigs = [ + $notificationConfigsElement, + ]; + $expectedResponse = new ListNotificationConfigsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setNotificationConfigs($notificationConfigs); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListNotificationConfigsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listNotificationConfigs($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getNotificationConfigs()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/ListNotificationConfigs', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listNotificationConfigsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListNotificationConfigsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listNotificationConfigs($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listResourceValueConfigsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $resourceValueConfigsElement = new ResourceValueConfig(); + $resourceValueConfigs = [ + $resourceValueConfigsElement, + ]; + $expectedResponse = new ListResourceValueConfigsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setResourceValueConfigs($resourceValueConfigs); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListResourceValueConfigsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listResourceValueConfigs($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getResourceValueConfigs()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/ListResourceValueConfigs', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listResourceValueConfigsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $request = (new ListResourceValueConfigsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listResourceValueConfigs($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listSourcesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $sourcesElement = new Source(); + $sources = [ + $sourcesElement, + ]; + $expectedResponse = new ListSourcesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setSources($sources); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $request = (new ListSourcesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listSources($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getSources()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/ListSources', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listSourcesExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->projectName('[PROJECT]'); + $request = (new ListSourcesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listSources($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listValuedResourcesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $totalSize = 705419236; + $valuedResourcesElement = new ValuedResource(); + $valuedResources = [ + $valuedResourcesElement, + ]; + $expectedResponse = new ListValuedResourcesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setTotalSize($totalSize); + $expectedResponse->setValuedResources($valuedResources); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->simulationName('[ORGANIZATION]', '[SIMULATION]'); + $request = (new ListValuedResourcesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listValuedResources($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getValuedResources()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/ListValuedResources', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listValuedResourcesExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedParent = $gapicClient->simulationName('[ORGANIZATION]', '[SIMULATION]'); + $request = (new ListValuedResourcesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listValuedResources($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function setFindingStateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $canonicalName = 'canonicalName1385400054'; + $parent = 'parent-995424086'; + $resourceName = 'resourceName979421212'; + $category = 'category50511102'; + $externalUri = 'externalUri-1385596168'; + $muteInitiator = 'muteInitiator7603081'; + $parentDisplayName = 'parentDisplayName934119773'; + $description = 'description-1724546052'; + $nextSteps = 'nextSteps-921338149'; + $moduleName = 'moduleName-1195003778'; + $expectedResponse = new Finding(); + $expectedResponse->setName($name2); + $expectedResponse->setCanonicalName($canonicalName); + $expectedResponse->setParent($parent); + $expectedResponse->setResourceName($resourceName); + $expectedResponse->setCategory($category); + $expectedResponse->setExternalUri($externalUri); + $expectedResponse->setMuteInitiator($muteInitiator); + $expectedResponse->setParentDisplayName($parentDisplayName); + $expectedResponse->setDescription($description); + $expectedResponse->setNextSteps($nextSteps); + $expectedResponse->setModuleName($moduleName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + $state = State::STATE_UNSPECIFIED; + $request = (new SetFindingStateRequest()) + ->setName($formattedName) + ->setState($state); + $response = $gapicClient->setFindingState($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/SetFindingState', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $actualValue = $actualRequestObject->getState(); + $this->assertProtobufEquals($state, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function setFindingStateExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + $state = State::STATE_UNSPECIFIED; + $request = (new SetFindingStateRequest()) + ->setName($formattedName) + ->setState($state); + try { + $gapicClient->setFindingState($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function setIamPolicyTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $version = 351608024; + $etag = '21'; + $expectedResponse = new Policy(); + $expectedResponse->setVersion($version); + $expectedResponse->setEtag($etag); + $transport->addResponse($expectedResponse); + // Mock request + $resource = 'resource-341064690'; + $policy = new Policy(); + $request = (new SetIamPolicyRequest()) + ->setResource($resource) + ->setPolicy($policy); + $response = $gapicClient->setIamPolicy($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/SetIamPolicy', $actualFuncCall); + $actualValue = $actualRequestObject->getResource(); + $this->assertProtobufEquals($resource, $actualValue); + $actualValue = $actualRequestObject->getPolicy(); + $this->assertProtobufEquals($policy, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function setIamPolicyExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $resource = 'resource-341064690'; + $policy = new Policy(); + $request = (new SetIamPolicyRequest()) + ->setResource($resource) + ->setPolicy($policy); + try { + $gapicClient->setIamPolicy($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function setMuteTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $canonicalName = 'canonicalName1385400054'; + $parent = 'parent-995424086'; + $resourceName = 'resourceName979421212'; + $category = 'category50511102'; + $externalUri = 'externalUri-1385596168'; + $muteInitiator = 'muteInitiator7603081'; + $parentDisplayName = 'parentDisplayName934119773'; + $description = 'description-1724546052'; + $nextSteps = 'nextSteps-921338149'; + $moduleName = 'moduleName-1195003778'; + $expectedResponse = new Finding(); + $expectedResponse->setName($name2); + $expectedResponse->setCanonicalName($canonicalName); + $expectedResponse->setParent($parent); + $expectedResponse->setResourceName($resourceName); + $expectedResponse->setCategory($category); + $expectedResponse->setExternalUri($externalUri); + $expectedResponse->setMuteInitiator($muteInitiator); + $expectedResponse->setParentDisplayName($parentDisplayName); + $expectedResponse->setDescription($description); + $expectedResponse->setNextSteps($nextSteps); + $expectedResponse->setModuleName($moduleName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + $mute = Mute::MUTE_UNSPECIFIED; + $request = (new SetMuteRequest()) + ->setName($formattedName) + ->setMute($mute); + $response = $gapicClient->setMute($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/SetMute', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $actualValue = $actualRequestObject->getMute(); + $this->assertProtobufEquals($mute, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function setMuteExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); + $mute = Mute::MUTE_UNSPECIFIED; + $request = (new SetMuteRequest()) + ->setName($formattedName) + ->setMute($mute); + try { + $gapicClient->setMute($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function testIamPermissionsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new TestIamPermissionsResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $resource = 'resource-341064690'; + $permissions = []; + $request = (new TestIamPermissionsRequest()) + ->setResource($resource) + ->setPermissions($permissions); + $response = $gapicClient->testIamPermissions($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/TestIamPermissions', $actualFuncCall); + $actualValue = $actualRequestObject->getResource(); + $this->assertProtobufEquals($resource, $actualValue); + $actualValue = $actualRequestObject->getPermissions(); + $this->assertProtobufEquals($permissions, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function testIamPermissionsExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $resource = 'resource-341064690'; + $permissions = []; + $request = (new TestIamPermissionsRequest()) + ->setResource($resource) + ->setPermissions($permissions); + try { + $gapicClient->testIamPermissions($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateBigQueryExportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $description = 'description-1724546052'; + $filter = 'filter-1274492040'; + $dataset = 'dataset1443214456'; + $mostRecentEditor = 'mostRecentEditor-657770475'; + $principal = 'principal-1812041682'; + $expectedResponse = new BigQueryExport(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setFilter($filter); + $expectedResponse->setDataset($dataset); + $expectedResponse->setMostRecentEditor($mostRecentEditor); + $expectedResponse->setPrincipal($principal); + $transport->addResponse($expectedResponse); + // Mock request + $bigQueryExport = new BigQueryExport(); + $request = (new UpdateBigQueryExportRequest()) + ->setBigQueryExport($bigQueryExport); + $response = $gapicClient->updateBigQueryExport($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/UpdateBigQueryExport', $actualFuncCall); + $actualValue = $actualRequestObject->getBigQueryExport(); + $this->assertProtobufEquals($bigQueryExport, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateBigQueryExportExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $bigQueryExport = new BigQueryExport(); + $request = (new UpdateBigQueryExportRequest()) + ->setBigQueryExport($bigQueryExport); + try { + $gapicClient->updateBigQueryExport($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateExternalSystemTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $externalUid = 'externalUid-1385596452'; + $status = 'status-892481550'; + $caseUri = 'caseUri21649373'; + $casePriority = 'casePriority715048403'; + $expectedResponse = new ExternalSystem(); + $expectedResponse->setName($name); + $expectedResponse->setExternalUid($externalUid); + $expectedResponse->setStatus($status); + $expectedResponse->setCaseUri($caseUri); + $expectedResponse->setCasePriority($casePriority); + $transport->addResponse($expectedResponse); + // Mock request + $externalSystem = new ExternalSystem(); + $request = (new UpdateExternalSystemRequest()) + ->setExternalSystem($externalSystem); + $response = $gapicClient->updateExternalSystem($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/UpdateExternalSystem', $actualFuncCall); + $actualValue = $actualRequestObject->getExternalSystem(); + $this->assertProtobufEquals($externalSystem, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateExternalSystemExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $externalSystem = new ExternalSystem(); + $request = (new UpdateExternalSystemRequest()) + ->setExternalSystem($externalSystem); + try { + $gapicClient->updateExternalSystem($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateFindingTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $canonicalName = 'canonicalName1385400054'; + $parent = 'parent-995424086'; + $resourceName = 'resourceName979421212'; + $category = 'category50511102'; + $externalUri = 'externalUri-1385596168'; + $muteInitiator = 'muteInitiator7603081'; + $parentDisplayName = 'parentDisplayName934119773'; + $description = 'description-1724546052'; + $nextSteps = 'nextSteps-921338149'; + $moduleName = 'moduleName-1195003778'; + $expectedResponse = new Finding(); + $expectedResponse->setName($name); + $expectedResponse->setCanonicalName($canonicalName); + $expectedResponse->setParent($parent); + $expectedResponse->setResourceName($resourceName); + $expectedResponse->setCategory($category); + $expectedResponse->setExternalUri($externalUri); + $expectedResponse->setMuteInitiator($muteInitiator); + $expectedResponse->setParentDisplayName($parentDisplayName); + $expectedResponse->setDescription($description); + $expectedResponse->setNextSteps($nextSteps); + $expectedResponse->setModuleName($moduleName); + $transport->addResponse($expectedResponse); + // Mock request + $finding = new Finding(); + $request = (new UpdateFindingRequest()) + ->setFinding($finding); + $response = $gapicClient->updateFinding($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/UpdateFinding', $actualFuncCall); + $actualValue = $actualRequestObject->getFinding(); + $this->assertProtobufEquals($finding, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateFindingExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $finding = new Finding(); + $request = (new UpdateFindingRequest()) + ->setFinding($finding); + try { + $gapicClient->updateFinding($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateMuteConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $description = 'description-1724546052'; + $filter = 'filter-1274492040'; + $mostRecentEditor = 'mostRecentEditor-657770475'; + $expectedResponse = new MuteConfig(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setFilter($filter); + $expectedResponse->setMostRecentEditor($mostRecentEditor); + $transport->addResponse($expectedResponse); + // Mock request + $muteConfig = new MuteConfig(); + $muteConfigFilter = 'muteConfigFilter-1921414637'; + $muteConfig->setFilter($muteConfigFilter); + $muteConfigType = MuteConfigType::MUTE_CONFIG_TYPE_UNSPECIFIED; + $muteConfig->setType($muteConfigType); + $request = (new UpdateMuteConfigRequest()) + ->setMuteConfig($muteConfig); + $response = $gapicClient->updateMuteConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/UpdateMuteConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getMuteConfig(); + $this->assertProtobufEquals($muteConfig, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateMuteConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $muteConfig = new MuteConfig(); + $muteConfigFilter = 'muteConfigFilter-1921414637'; + $muteConfig->setFilter($muteConfigFilter); + $muteConfigType = MuteConfigType::MUTE_CONFIG_TYPE_UNSPECIFIED; + $muteConfig->setType($muteConfigType); + $request = (new UpdateMuteConfigRequest()) + ->setMuteConfig($muteConfig); + try { + $gapicClient->updateMuteConfig($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateNotificationConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $description = 'description-1724546052'; + $pubsubTopic = 'pubsubTopic-338126829'; + $serviceAccount = 'serviceAccount-1948028253'; + $expectedResponse = new NotificationConfig(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setPubsubTopic($pubsubTopic); + $expectedResponse->setServiceAccount($serviceAccount); + $transport->addResponse($expectedResponse); + // Mock request + $notificationConfig = new NotificationConfig(); + $request = (new UpdateNotificationConfigRequest()) + ->setNotificationConfig($notificationConfig); + $response = $gapicClient->updateNotificationConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/UpdateNotificationConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getNotificationConfig(); + $this->assertProtobufEquals($notificationConfig, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateNotificationConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $notificationConfig = new NotificationConfig(); + $request = (new UpdateNotificationConfigRequest()) + ->setNotificationConfig($notificationConfig); + try { + $gapicClient->updateNotificationConfig($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateResourceValueConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $resourceType = 'resourceType979623115'; + $scope = 'scope109264468'; + $description = 'description-1724546052'; + $expectedResponse = new ResourceValueConfig(); + $expectedResponse->setName($name); + $expectedResponse->setResourceType($resourceType); + $expectedResponse->setScope($scope); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $resourceValueConfig = new ResourceValueConfig(); + $resourceValueConfigTagValues = []; + $resourceValueConfig->setTagValues($resourceValueConfigTagValues); + $request = (new UpdateResourceValueConfigRequest()) + ->setResourceValueConfig($resourceValueConfig); + $response = $gapicClient->updateResourceValueConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/UpdateResourceValueConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getResourceValueConfig(); + $this->assertProtobufEquals($resourceValueConfig, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateResourceValueConfigExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $resourceValueConfig = new ResourceValueConfig(); + $resourceValueConfigTagValues = []; + $resourceValueConfig->setTagValues($resourceValueConfigTagValues); + $request = (new UpdateResourceValueConfigRequest()) + ->setResourceValueConfig($resourceValueConfig); + try { + $gapicClient->updateResourceValueConfig($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSecurityMarksTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $canonicalName = 'canonicalName1385400054'; + $expectedResponse = new SecurityMarks(); + $expectedResponse->setName($name); + $expectedResponse->setCanonicalName($canonicalName); + $transport->addResponse($expectedResponse); + // Mock request + $securityMarks = new SecurityMarks(); + $request = (new UpdateSecurityMarksRequest()) + ->setSecurityMarks($securityMarks); + $response = $gapicClient->updateSecurityMarks($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/UpdateSecurityMarks', $actualFuncCall); + $actualValue = $actualRequestObject->getSecurityMarks(); + $this->assertProtobufEquals($securityMarks, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSecurityMarksExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $securityMarks = new SecurityMarks(); + $request = (new UpdateSecurityMarksRequest()) + ->setSecurityMarks($securityMarks); + try { + $gapicClient->updateSecurityMarks($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSourceTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $canonicalName = 'canonicalName1385400054'; + $expectedResponse = new Source(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setCanonicalName($canonicalName); + $transport->addResponse($expectedResponse); + // Mock request + $source = new Source(); + $request = (new UpdateSourceRequest()) + ->setSource($source); + $response = $gapicClient->updateSource($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/UpdateSource', $actualFuncCall); + $actualValue = $actualRequestObject->getSource(); + $this->assertProtobufEquals($source, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateSourceExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + $status = new stdClass(); + $status->code = Code::DATA_LOSS; + $status->details = 'internal error'; + $expectedExceptionMessage = json_encode([ + 'message' => 'internal error', + 'code' => Code::DATA_LOSS, + 'status' => 'DATA_LOSS', + 'details' => [], + ], JSON_PRETTY_PRINT); + $transport->addResponse(null, $status); + // Mock request + $source = new Source(); + $request = (new UpdateSourceRequest()) + ->setSource($source); + try { + $gapicClient->updateSource($request); + // If the $gapicClient method call did not throw, fail the test + $this->fail('Expected an ApiException, but no exception was thrown.'); + } catch (ApiException $ex) { + $this->assertEquals($status->code, $ex->getCode()); + $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); + } + // Call popReceivedCalls to ensure the stub is exhausted + $transport->popReceivedCalls(); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function batchCreateResourceValueConfigsAsyncTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new BatchCreateResourceValueConfigsResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $requests = []; + $request = (new BatchCreateResourceValueConfigsRequest()) + ->setParent($formattedParent) + ->setRequests($requests); + $response = $gapicClient->batchCreateResourceValueConfigsAsync($request)->wait(); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/BatchCreateResourceValueConfigs', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getRequests(); + $this->assertProtobufEquals($requests, $actualValue); + $this->assertTrue($transport->isExhausted()); + } +} From a7837dab230d575075c2ff7d07032821d4d32c93 Mon Sep 17 00:00:00 2001 From: Owl Bot Date: Thu, 27 Jun 2024 02:01:10 +0000 Subject: [PATCH 2/2] =?UTF-8?q?=F0=9F=A6=89=20Updates=20from=20OwlBot=20po?= =?UTF-8?q?st-processor?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --- SecurityCenter/metadata/V2/AttackPath.php | Bin 2204 -> 2341 bytes .../metadata}/V2/CloudArmor.php | 0 SecurityCenter/metadata/V2/Finding.php | Bin 8721 -> 9093 bytes .../metadata}/V2/Folder.php | 0 SecurityCenter/metadata/V2/MitreAttack.php | Bin 3195 -> 3313 bytes .../metadata}/V2/Notebook.php | 0 SecurityCenter/metadata/V2/Resource.php | Bin 1003 -> 3212 bytes .../metadata/V2/ResourceValueConfig.php | Bin 2190 -> 2522 bytes .../metadata/V2/SecuritycenterService.php | Bin 26576 -> 28020 bytes SecurityCenter/metadata/V2/Simulation.php | 10 +- SecurityCenter/metadata/V2/ValuedResource.php | Bin 1610 -> 1720 bytes .../batch_create_resource_value_configs.php | 15 +- .../SecurityCenterClient/group_findings.php | 8 - .../list_attack_paths.php | 5 +- .../list_resource_value_configs.php | 4 +- .../update_resource_value_config.php | 4 +- .../src}/V2/AdaptiveProtection.php | 2 +- .../src}/V2/Attack.php | 6 +- .../src}/V2/AwsMetadata.php | 4 +- .../src}/V2/AwsMetadata/AwsAccount.php | 4 +- .../src}/V2/AwsMetadata/AwsOrganization.php | 2 +- .../V2/AwsMetadata/AwsOrganizationalUnit.php | 4 +- .../src}/V2/AzureMetadata.php | 4 +- .../V2/AzureMetadata/AzureManagementGroup.php | 4 +- .../V2/AzureMetadata/AzureResourceGroup.php | 2 +- .../V2/AzureMetadata/AzureSubscription.php | 4 +- ...BatchCreateResourceValueConfigsRequest.php | 2 +- .../src/V2/Client/SecurityCenterClient.php | 140 + .../src}/V2/CloudArmor.php | 12 +- .../src}/V2/CloudProvider.php | 0 SecurityCenter/src/V2/Finding.php | 88 + .../src}/V2/Folder.php | 4 +- .../src}/V2/GcpMetadata.php | 10 +- .../src/V2/GroupFindingsRequest.php | 32 - .../src/V2/ListAttackPathsRequest.php | 2 +- .../ListFindingsResult/Resource.php | 324 ++ .../V2/ListResourceValueConfigsRequest.php | 2 +- .../src/V2/MitreAttack/Technique.php | 30 +- .../src}/V2/Notebook.php | 8 +- .../src}/V2/Requests.php | 8 +- SecurityCenter/src/V2/Resource.php | 324 ++ .../src}/V2/ResourcePath.php | 0 .../src}/V2/ResourcePath/ResourcePathNode.php | 6 +- .../V2/ResourcePath/ResourcePathNodeType.php | 0 SecurityCenter/src/V2/ResourceValueConfig.php | 170 +- .../src}/V2/SecurityPolicy.php | 6 +- SecurityCenter/src/V2/Simulation.php | 34 + .../V2/UpdateResourceValueConfigRequest.php | 16 + .../security_center_descriptor_config.php | 7 + .../security_center_rest_client_config.php | 52 + .../V2/Client/SecurityCenterClientTest.php | 14 +- .../Google/Cloud/Securitycenter/V1/Access.php | 45 - .../Cloud/Securitycenter/V1/Application.php | 30 - .../Google/Cloud/Securitycenter/V1/Asset.php | 60 - .../V1/BackupDisasterRecovery.php | 40 - .../Securitycenter/V1/BigqueryExport.php | 40 - .../Cloud/Securitycenter/V1/CloudArmor.php | 54 - .../Securitycenter/V1/CloudDlpDataProfile.php | Bin 1395 -> 0 bytes .../Securitycenter/V1/CloudDlpInspection.php | 35 - .../Cloud/Securitycenter/V1/Compliance.php | 32 - .../Cloud/Securitycenter/V1/Connection.php | Bin 1150 -> 0 bytes .../Securitycenter/V1/ContactDetails.php | 31 - .../Cloud/Securitycenter/V1/Container.php | 35 - .../Cloud/Securitycenter/V1/Database.php | 34 - ...iveSecurityHealthAnalyticsCustomModule.php | Bin 2124 -> 0 bytes .../Cloud/Securitycenter/V1/Exfiltration.php | 35 - .../Securitycenter/V1/ExternalSystem.php | 52 - .../Google/Cloud/Securitycenter/V1/File.php | 38 - .../Cloud/Securitycenter/V1/Finding.php | Bin 8589 -> 0 bytes .../Google/Cloud/Securitycenter/V1/Folder.php | 30 - .../Securitycenter/V1/GroupMembership.php | Bin 1104 -> 0 bytes .../Cloud/Securitycenter/V1/IamBinding.php | Bin 1059 -> 0 bytes .../Cloud/Securitycenter/V1/Indicator.php | Bin 1746 -> 0 bytes .../Cloud/Securitycenter/V1/KernelRootkit.php | 37 - .../Cloud/Securitycenter/V1/Kubernetes.php | Bin 2621 -> 0 bytes .../Google/Cloud/Securitycenter/V1/Label.php | 31 - .../Cloud/Securitycenter/V1/LoadBalancer.php | 29 - .../Cloud/Securitycenter/V1/LogEntry.php | Bin 1183 -> 0 bytes .../Cloud/Securitycenter/V1/MitreAttack.php | Bin 3195 -> 0 bytes .../Cloud/Securitycenter/V1/MuteConfig.php | 40 - .../Cloud/Securitycenter/V1/Notebook.php | 33 - .../Securitycenter/V1/NotificationConfig.php | Bin 1674 -> 0 bytes .../Securitycenter/V1/NotificationMessage.php | Bin 1310 -> 0 bytes .../Cloud/Securitycenter/V1/OrgPolicy.php | 31 - .../V1/OrganizationSettings.php | Bin 1504 -> 0 bytes .../Cloud/Securitycenter/V1/Process.php | 44 - .../Cloud/Securitycenter/V1/Resource.php | 38 - .../V1/RunAssetDiscoveryResponse.php | Bin 1217 -> 0 bytes .../SecurityHealthAnalyticsCustomConfig.php | Bin 1709 -> 0 bytes .../SecurityHealthAnalyticsCustomModule.php | Bin 2505 -> 0 bytes .../Cloud/Securitycenter/V1/SecurityMarks.php | 37 - .../Securitycenter/V1/SecurityPosture.php | 41 - .../V1/SecuritycenterService.php | 383 -- .../Google/Cloud/Securitycenter/V1/Source.php | 34 - .../Securitycenter/V1/ToxicCombination.php | 30 - .../Cloud/Securitycenter/V1/Vulnerability.php | Bin 3436 -> 0 bytes .../Google/Cloud/SecurityCenter/V1/Access.php | 521 -- .../SecurityCenter/V1/AdaptiveProtection.php | 84 - .../Cloud/SecurityCenter/V1/Application.php | 109 - .../Google/Cloud/SecurityCenter/V1/Asset.php | 412 -- .../SecurityCenter/V1/Asset/IamPolicy.php | 81 - .../V1/Asset/SecurityCenterProperties.php | 379 -- .../Google/Cloud/SecurityCenter/V1/Attack.php | 135 - .../V1/BackupDisasterRecovery.php | 495 -- .../SecurityCenter/V1/BigQueryExport.php | 449 -- .../V1/BulkMuteFindingsRequest.php | 227 - .../V1/BulkMuteFindingsResponse.php | 33 - .../Cloud/SecurityCenter/V1/CloudArmor.php | 323 -- .../SecurityCenter/V1/CloudDlpDataProfile.php | 106 - .../V1/CloudDlpDataProfile/ParentType.php | 64 - .../SecurityCenter/V1/CloudDlpInspection.php | 187 - .../SecurityCenter/V1/CloudLoggingEntry.php | 196 - .../Cloud/SecurityCenter/V1/Compliance.php | 140 - .../Cloud/SecurityCenter/V1/Connection.php | 211 - .../SecurityCenter/V1/Connection/Protocol.php | 85 - .../Cloud/SecurityCenter/V1/Contact.php | 67 - .../SecurityCenter/V1/ContactDetails.php | 67 - .../Cloud/SecurityCenter/V1/Container.php | 221 - .../V1/CreateBigQueryExportRequest.php | 188 - .../V1/CreateFindingRequest.php | 183 - .../V1/CreateMuteConfigRequest.php | 206 - .../V1/CreateNotificationConfigRequest.php | 218 - ...rityHealthAnalyticsCustomModuleRequest.php | 152 - .../SecurityCenter/V1/CreateSourceRequest.php | 137 - .../Cloud/SecurityCenter/V1/CustomConfig.php | 297 - .../V1/CustomConfig/CustomOutputSpec.php | 73 - .../CustomOutputSpec/Property.php | 122 - .../V1/CustomConfig/ResourceSelector.php | 70 - .../V1/CustomConfig/Severity.php | 78 - .../Google/Cloud/SecurityCenter/V1/Cve.php | 330 -- .../V1/Cve/ExploitationActivity.php | 87 - .../SecurityCenter/V1/Cve/RiskRating.php | 83 - .../Google/Cloud/SecurityCenter/V1/Cvssv3.php | 391 -- .../V1/Cvssv3/AttackComplexity.php | 71 - .../SecurityCenter/V1/Cvssv3/AttackVector.php | 84 - .../Cloud/SecurityCenter/V1/Cvssv3/Impact.php | 73 - .../V1/Cvssv3/PrivilegesRequired.php | 79 - .../Cloud/SecurityCenter/V1/Cvssv3/Scope.php | 67 - .../V1/Cvssv3/UserInteraction.php | 67 - .../Cloud/SecurityCenter/V1/Database.php | 287 - .../V1/DeleteBigQueryExportRequest.php | 96 - .../V1/DeleteMuteConfigRequest.php | 96 - .../V1/DeleteNotificationConfigRequest.php | 96 - ...rityHealthAnalyticsCustomModuleRequest.php | 101 - ...iveSecurityHealthAnalyticsCustomModule.php | 223 - .../EnablementState.php | 64 - .../SecurityCenter/V1/EnvironmentVariable.php | 102 - .../Cloud/SecurityCenter/V1/ExfilResource.php | 121 - .../Cloud/SecurityCenter/V1/Exfiltration.php | 150 - .../SecurityCenter/V1/ExternalSystem.php | 485 -- .../V1/ExternalSystem/TicketInfo.php | 255 - .../Google/Cloud/SecurityCenter/V1/File.php | 298 - .../Cloud/SecurityCenter/V1/File/DiskPath.php | 112 - .../Cloud/SecurityCenter/V1/Finding.php | 2170 ------- .../V1/Finding/FindingClass.php | 105 - .../Cloud/SecurityCenter/V1/Finding/Mute.php | 71 - .../SecurityCenter/V1/Finding/Severity.php | 116 - .../Cloud/SecurityCenter/V1/Finding/State.php | 65 - .../Google/Cloud/SecurityCenter/V1/Folder.php | 106 - .../Cloud/SecurityCenter/V1/Geolocation.php | 67 - .../V1/GetBigQueryExportRequest.php | 96 - ...rityHealthAnalyticsCustomModuleRequest.php | 102 - .../V1/GetMuteConfigRequest.php | 96 - .../V1/GetNotificationConfigRequest.php | 96 - .../V1/GetOrganizationSettingsRequest.php | 86 - ...rityHealthAnalyticsCustomModuleRequest.php | 101 - .../SecurityCenter/V1/GetSourceRequest.php | 86 - .../SecurityCenter/V1/GroupAssetsRequest.php | 643 --- .../SecurityCenter/V1/GroupAssetsResponse.php | 191 - .../V1/GroupFindingsRequest.php | 695 --- .../V1/GroupFindingsResponse.php | 191 - .../SecurityCenter/V1/GroupMembership.php | 102 - .../V1/GroupMembership/GroupType.php | 57 - .../Cloud/SecurityCenter/V1/GroupResult.php | 101 - .../Cloud/SecurityCenter/V1/IamBinding.php | 144 - .../SecurityCenter/V1/IamBinding/Action.php | 64 - .../Cloud/SecurityCenter/V1/Indicator.php | 177 - .../V1/Indicator/ProcessSignature.php | 145 - .../ProcessSignature/MemoryHashSignature.php | 108 - .../MemoryHashSignature/Detection.php | 112 - .../ProcessSignature/SignatureType.php | 64 - .../ProcessSignature/YaraRuleSignature.php | 70 - .../Cloud/SecurityCenter/V1/KernelRootkit.php | 367 -- .../Cloud/SecurityCenter/V1/Kubernetes.php | 319 - .../V1/Kubernetes/AccessReview.php | 289 - .../SecurityCenter/V1/Kubernetes/Binding.php | 186 - .../SecurityCenter/V1/Kubernetes/Node.php | 74 - .../SecurityCenter/V1/Kubernetes/NodePool.php | 104 - .../SecurityCenter/V1/Kubernetes/Object.php | 220 - .../SecurityCenter/V1/Kubernetes/Pod.php | 176 - .../SecurityCenter/V1/Kubernetes/Role.php | 138 - .../V1/Kubernetes/Role/Kind.php | 64 - .../SecurityCenter/V1/Kubernetes/Subject.php | 138 - .../V1/Kubernetes/Subject/AuthType.php | 71 - .../Google/Cloud/SecurityCenter/V1/Label.php | 104 - .../SecurityCenter/V1/ListAssetsRequest.php | 719 --- .../SecurityCenter/V1/ListAssetsResponse.php | 183 - .../ListAssetsResponse/ListAssetsResult.php | 114 - .../ListAssetsResult/StateChange.php | 75 - .../V1/ListBigQueryExportsRequest.php | 184 - .../V1/ListBigQueryExportsResponse.php | 105 - ...ityHealthAnalyticsCustomModulesRequest.php | 169 - ...tyHealthAnalyticsCustomModulesResponse.php | 106 - ...ityHealthAnalyticsCustomModulesRequest.php | 169 - ...tyHealthAnalyticsCustomModulesResponse.php | 106 - .../SecurityCenter/V1/ListFindingsRequest.php | 735 --- .../V1/ListFindingsResponse.php | 183 - .../ListFindingsResult.php | 158 - .../ListFindingsResult/Resource.php | 321 -- .../ListFindingsResult/StateChange.php | 87 - .../V1/ListMuteConfigsRequest.php | 184 - .../V1/ListMuteConfigsResponse.php | 105 - .../V1/ListNotificationConfigsRequest.php | 171 - .../V1/ListNotificationConfigsResponse.php | 105 - ...ityHealthAnalyticsCustomModulesRequest.php | 168 - ...tyHealthAnalyticsCustomModulesResponse.php | 105 - .../SecurityCenter/V1/ListSourcesRequest.php | 171 - .../SecurityCenter/V1/ListSourcesResponse.php | 105 - .../Cloud/SecurityCenter/V1/LoadBalancer.php | 68 - .../Cloud/SecurityCenter/V1/LogEntry.php | 75 - .../Cloud/SecurityCenter/V1/MitreAttack.php | 228 - .../SecurityCenter/V1/MitreAttack/Tactic.php | 149 - .../V1/MitreAttack/Technique.php | 458 -- .../Cloud/SecurityCenter/V1/MuteConfig.php | 401 -- .../Cloud/SecurityCenter/V1/Notebook.php | 181 - .../SecurityCenter/V1/NotificationConfig.php | 241 - .../V1/NotificationConfig/StreamingConfig.php | 131 - .../SecurityCenter/V1/NotificationMessage.php | 156 - .../Cloud/SecurityCenter/V1/OrgPolicy.php | 75 - .../V1/OrganizationSettings.php | 170 - .../AssetDiscoveryConfig.php | 142 - .../AssetDiscoveryConfig/InclusionMode.php | 74 - .../Cloud/SecurityCenter/V1/Package.php | 169 - .../Cloud/SecurityCenter/V1/Process.php | 409 -- .../Cloud/SecurityCenter/V1/Reference.php | 105 - .../Cloud/SecurityCenter/V1/Requests.php | 177 - .../Cloud/SecurityCenter/V1/Resource.php | 317 - .../V1/RunAssetDiscoveryRequest.php | 86 - .../V1/RunAssetDiscoveryResponse.php | 111 - .../V1/RunAssetDiscoveryResponse/State.php | 72 - .../SecurityCenter/V1/SecurityBulletin.php | 149 - .../SecurityHealthAnalyticsCustomModule.php | 355 -- .../EnablementState.php | 73 - .../Cloud/SecurityCenter/V1/SecurityMarks.php | 206 - .../SecurityCenter/V1/SecurityPolicy.php | 149 - .../SecurityCenter/V1/SecurityPosture.php | 325 -- .../V1/SecurityPosture/PolicyDriftDetails.php | 151 - .../V1/ServiceAccountDelegationInfo.php | 125 - .../V1/SetFindingStateRequest.php | 189 - .../SecurityCenter/V1/SetMuteRequest.php | 143 - ...rityHealthAnalyticsCustomModuleRequest.php | 193 - .../SimulatedResource.php | 168 - ...ityHealthAnalyticsCustomModuleResponse.php | 78 - .../SimulatedResult.php | 147 - .../Google/Cloud/SecurityCenter/V1/Source.php | 244 - .../SecurityCenter/V1/ToxicCombination.php | 123 - .../V1/UpdateBigQueryExportRequest.php | 141 - .../V1/UpdateExternalSystemRequest.php | 142 - .../V1/UpdateFindingRequest.php | 175 - .../V1/UpdateMuteConfigRequest.php | 141 - .../V1/UpdateNotificationConfigRequest.php | 155 - .../V1/UpdateOrganizationSettingsRequest.php | 138 - ...rityHealthAnalyticsCustomModuleRequest.php | 136 - .../V1/UpdateSecurityMarksRequest.php | 202 - .../SecurityCenter/V1/UpdateSourceRequest.php | 138 - .../Cloud/SecurityCenter/V1/Vulnerability.php | 213 - .../bulk_mute_findings.php | 86 - .../create_big_query_export.php | 81 - .../SecurityCenterClient/create_finding.php | 80 - .../create_mute_config.php | 106 - .../create_notification_config.php | 81 - ...ecurity_health_analytics_custom_module.php | 79 - .../V1/SecurityCenterClient/create_source.php | 74 - .../delete_big_query_export.php | 72 - .../delete_mute_config.php | 72 - .../delete_notification_config.php | 75 - ...ecurity_health_analytics_custom_module.php | 78 - .../get_big_query_export.php | 74 - ...ecurity_health_analytics_custom_module.php | 78 - .../SecurityCenterClient/get_iam_policy.php | 71 - .../SecurityCenterClient/get_mute_config.php | 74 - .../get_notification_config.php | 77 - .../get_organization_settings.php | 72 - ...ecurity_health_analytics_custom_module.php | 78 - .../V1/SecurityCenterClient/get_source.php | 72 - .../V1/SecurityCenterClient/group_assets.php | 99 - .../SecurityCenterClient/group_findings.php | 105 - .../V1/SecurityCenterClient/list_assets.php | 80 - .../list_big_query_exports.php | 82 - ...curity_health_analytics_custom_modules.php | 81 - ...curity_health_analytics_custom_modules.php | 82 - .../V1/SecurityCenterClient/list_findings.php | 85 - .../list_mute_configs.php | 78 - .../list_notification_configs.php | 78 - ...curity_health_analytics_custom_modules.php | 81 - .../V1/SecurityCenterClient/list_sources.php | 78 - .../run_asset_discovery.php | 89 - .../set_finding_state.php | 83 - .../SecurityCenterClient/set_iam_policy.php | 73 - .../V1/SecurityCenterClient/set_mute.php | 80 - ...ecurity_health_analytics_custom_module.php | 86 - .../test_iam_permissions.php | 78 - .../update_big_query_export.php | 59 - .../update_external_system.php | 59 - .../SecurityCenterClient/update_finding.php | 60 - .../update_mute_config.php | 91 - .../update_notification_config.php | 61 - .../update_organization_settings.php | 59 - ...ecurity_health_analytics_custom_module.php | 63 - .../update_security_marks.php | 59 - .../V1/SecurityCenterClient/update_source.php | 59 - .../v1/src/V1/Client/SecurityCenterClient.php | 2617 --------- .../V1/Gapic/SecurityCenterGapicClient.php | 5120 ----------------- .../v1/src/V1/SecurityCenterClient.php | 34 - .../v1/src/V1/gapic_metadata.json | 243 - .../security_center_client_config.json | 293 - .../security_center_descriptor_config.php | 739 --- .../security_center_rest_client_config.php | 1033 ---- .../V1/Client/SecurityCenterClientTest.php | 3616 ------------ .../Unit/V1/SecurityCenterClientTest.php | 3289 ----------- .../Cloud/Securitycenter/V1P1Beta1/Asset.php | 60 - .../Securitycenter/V1P1Beta1/Finding.php | Bin 2387 -> 0 bytes .../Cloud/Securitycenter/V1P1Beta1/Folder.php | 30 - .../V1P1Beta1/NotificationConfig.php | Bin 1738 -> 0 bytes .../V1P1Beta1/NotificationMessage.php | Bin 1381 -> 0 bytes .../V1P1Beta1/OrganizationSettings.php | Bin 1581 -> 0 bytes .../Securitycenter/V1P1Beta1/Resource.php | 36 - .../V1P1Beta1/RunAssetDiscoveryResponse.php | Bin 1287 -> 0 bytes .../V1P1Beta1/SecurityMarks.php | 37 - .../V1P1Beta1/SecuritycenterService.php | Bin 15636 -> 0 bytes .../Cloud/Securitycenter/V1P1Beta1/Source.php | 34 - .../Cloud/SecurityCenter/V1p1beta1/Asset.php | 412 -- .../V1p1beta1/Asset/IamPolicy.php | 81 - .../Asset/SecurityCenterProperties.php | 379 -- .../V1p1beta1/CreateFindingRequest.php | 153 - .../CreateNotificationConfigRequest.php | 161 - .../V1p1beta1/CreateSourceRequest.php | 119 - .../DeleteNotificationConfigRequest.php | 71 - .../SecurityCenter/V1p1beta1/Finding.php | 603 -- .../V1p1beta1/Finding/Severity.php | 79 - .../V1p1beta1/Finding/State.php | 65 - .../Cloud/SecurityCenter/V1p1beta1/Folder.php | 106 - .../GetNotificationConfigRequest.php | 71 - .../GetOrganizationSettingsRequest.php | 71 - .../V1p1beta1/GetSourceRequest.php | 71 - .../V1p1beta1/GroupAssetsRequest.php | 643 --- .../V1p1beta1/GroupAssetsResponse.php | 191 - .../V1p1beta1/GroupFindingsRequest.php | 627 -- .../V1p1beta1/GroupFindingsResponse.php | 191 - .../SecurityCenter/V1p1beta1/GroupResult.php | 101 - .../V1p1beta1/ListAssetsRequest.php | 711 --- .../V1p1beta1/ListAssetsResponse.php | 183 - .../ListAssetsResponse/ListAssetsResult.php | 114 - .../ListAssetsResult/StateChange.php | 75 - .../V1p1beta1/ListFindingsRequest.php | 695 --- .../V1p1beta1/ListFindingsResponse.php | 183 - .../ListFindingsResult.php | 158 - .../ListFindingsResult/Resource.php | 253 - .../ListFindingsResult/StateChange.php | 87 - .../ListNotificationConfigsRequest.php | 151 - .../ListNotificationConfigsResponse.php | 105 - .../V1p1beta1/ListSourcesRequest.php | 155 - .../V1p1beta1/ListSourcesResponse.php | 105 - .../V1p1beta1/NotificationConfig.php | 268 - .../NotificationConfig/EventType.php | 57 - .../NotificationConfig/StreamingConfig.php | 131 - .../V1p1beta1/NotificationMessage.php | 156 - .../V1p1beta1/OrganizationSettings.php | 170 - .../AssetDiscoveryConfig.php | 142 - .../AssetDiscoveryConfig/InclusionMode.php | 74 - .../SecurityCenter/V1p1beta1/Resource.php | 249 - .../V1p1beta1/RunAssetDiscoveryRequest.php | 71 - .../V1p1beta1/RunAssetDiscoveryResponse.php | 111 - .../RunAssetDiscoveryResponse/State.php | 72 - .../V1p1beta1/SecurityMarks.php | 206 - .../V1p1beta1/SetFindingStateRequest.php | 157 - .../Cloud/SecurityCenter/V1p1beta1/Source.php | 243 - .../V1p1beta1/UpdateFindingRequest.php | 157 - .../UpdateNotificationConfigRequest.php | 125 - .../UpdateOrganizationSettingsRequest.php | 125 - .../V1p1beta1/UpdateSecurityMarksRequest.php | 185 - .../V1p1beta1/UpdateSourceRequest.php | 125 - .../SecurityCenterClient/create_finding.php | 73 - .../create_notification_config.php | 78 - .../SecurityCenterClient/create_source.php | 70 - .../delete_notification_config.php | 68 - .../SecurityCenterClient/get_iam_policy.php | 66 - .../get_notification_config.php | 70 - .../get_organization_settings.php | 67 - .../SecurityCenterClient/get_source.php | 67 - .../SecurityCenterClient/group_assets.php | 93 - .../SecurityCenterClient/group_findings.php | 99 - .../SecurityCenterClient/list_assets.php | 73 - .../SecurityCenterClient/list_findings.php | 80 - .../list_notification_configs.php | 72 - .../SecurityCenterClient/list_sources.php | 73 - .../run_asset_discovery.php | 84 - .../set_finding_state.php | 76 - .../SecurityCenterClient/set_iam_policy.php | 69 - .../test_iam_permissions.php | 74 - .../SecurityCenterClient/update_finding.php | 57 - .../update_notification_config.php | 57 - .../update_organization_settings.php | 56 - .../update_security_marks.php | 56 - .../SecurityCenterClient/update_source.php | 56 - .../Gapic/SecurityCenterGapicClient.php | 2807 --------- .../src/V1p1beta1/SecurityCenterClient.php | 36 - .../src/V1p1beta1/gapic_metadata.json | 133 - .../security_center_client_config.json | 183 - .../security_center_descriptor_config.php | 98 - .../security_center_rest_client_config.php | 460 -- .../V1p1beta1/SecurityCenterClientTest.php | 1692 ------ .../Google/Cloud/Securitycenter/V2/Access.php | 46 - .../Cloud/Securitycenter/V2/Application.php | 30 - .../Securitycenter/V2/AttackExposure.php | Bin 1462 -> 0 bytes .../Cloud/Securitycenter/V2/AttackPath.php | Bin 2341 -> 0 bytes .../V2/BackupDisasterRecovery.php | 40 - .../Securitycenter/V2/BigqueryExport.php | 40 - .../Securitycenter/V2/CloudDlpDataProfile.php | Bin 1395 -> 0 bytes .../Securitycenter/V2/CloudDlpInspection.php | 35 - .../Cloud/Securitycenter/V2/Compliance.php | 32 - .../Cloud/Securitycenter/V2/Connection.php | Bin 1150 -> 0 bytes .../Securitycenter/V2/ContactDetails.php | 31 - .../Cloud/Securitycenter/V2/Container.php | 35 - .../Cloud/Securitycenter/V2/Database.php | 34 - .../Cloud/Securitycenter/V2/Exfiltration.php | 35 - .../Securitycenter/V2/ExternalSystem.php | 52 - .../Google/Cloud/Securitycenter/V2/File.php | 38 - .../Cloud/Securitycenter/V2/Finding.php | Bin 9093 -> 0 bytes .../Securitycenter/V2/GroupMembership.php | Bin 1104 -> 0 bytes .../Cloud/Securitycenter/V2/IamBinding.php | Bin 1059 -> 0 bytes .../Cloud/Securitycenter/V2/Indicator.php | Bin 1746 -> 0 bytes .../Cloud/Securitycenter/V2/KernelRootkit.php | 37 - .../Cloud/Securitycenter/V2/Kubernetes.php | Bin 2621 -> 0 bytes .../Google/Cloud/Securitycenter/V2/Label.php | 31 - .../Cloud/Securitycenter/V2/LoadBalancer.php | 29 - .../Cloud/Securitycenter/V2/LogEntry.php | Bin 1183 -> 0 bytes .../Cloud/Securitycenter/V2/MitreAttack.php | Bin 3313 -> 0 bytes .../Cloud/Securitycenter/V2/MuteConfig.php | Bin 1908 -> 0 bytes .../Securitycenter/V2/NotificationConfig.php | Bin 1778 -> 0 bytes .../Securitycenter/V2/NotificationMessage.php | Bin 1310 -> 0 bytes .../Cloud/Securitycenter/V2/OrgPolicy.php | 31 - .../Cloud/Securitycenter/V2/Process.php | 44 - .../Cloud/Securitycenter/V2/Resource.php | Bin 3212 -> 0 bytes .../Securitycenter/V2/ResourceValueConfig.php | Bin 2522 -> 0 bytes .../Cloud/Securitycenter/V2/SecurityMarks.php | 37 - .../Securitycenter/V2/SecurityPosture.php | 41 - .../V2/SecuritycenterService.php | Bin 28020 -> 0 bytes .../Cloud/Securitycenter/V2/Simulation.php | 40 - .../Google/Cloud/Securitycenter/V2/Source.php | 34 - .../Securitycenter/V2/ToxicCombination.php | 30 - .../Securitycenter/V2/ValuedResource.php | Bin 1720 -> 0 bytes .../Cloud/Securitycenter/V2/Vulnerability.php | Bin 3436 -> 0 bytes .../Google/Cloud/SecurityCenter/V2/Access.php | 521 -- .../Cloud/SecurityCenter/V2/Application.php | 109 - .../SecurityCenter/V2/AttackExposure.php | 313 - .../V2/AttackExposure/State.php | 64 - .../Cloud/SecurityCenter/V2/AttackPath.php | 139 - .../V2/AttackPath/AttackPathEdge.php | 105 - .../V2/AttackPath/AttackPathNode.php | 256 - .../AttackPathNode/AttackStepNode.php | 206 - .../V2/AttackPath/AttackPathNode/NodeType.php | 78 - .../PathNodeAssociatedFinding.php | 142 - .../V2/BackupDisasterRecovery.php | 495 -- ...BatchCreateResourceValueConfigsRequest.php | 127 - ...atchCreateResourceValueConfigsResponse.php | 67 - .../SecurityCenter/V2/BigQueryExport.php | 457 -- .../V2/BulkMuteFindingsRequest.php | 215 - .../V2/BulkMuteFindingsResponse.php | 33 - .../SecurityCenter/V2/CloudDlpDataProfile.php | 106 - .../V2/CloudDlpDataProfile/ParentType.php | 64 - .../SecurityCenter/V2/CloudDlpInspection.php | 187 - .../SecurityCenter/V2/CloudLoggingEntry.php | 196 - .../Cloud/SecurityCenter/V2/Compliance.php | 140 - .../Cloud/SecurityCenter/V2/Connection.php | 211 - .../SecurityCenter/V2/Connection/Protocol.php | 85 - .../Cloud/SecurityCenter/V2/Contact.php | 67 - .../SecurityCenter/V2/ContactDetails.php | 67 - .../Cloud/SecurityCenter/V2/Container.php | 221 - .../V2/CreateBigQueryExportRequest.php | 193 - .../V2/CreateFindingRequest.php | 203 - .../V2/CreateMuteConfigRequest.php | 193 - .../V2/CreateNotificationConfigRequest.php | 203 - .../V2/CreateResourceValueConfigRequest.php | 111 - .../SecurityCenter/V2/CreateSourceRequest.php | 137 - .../Google/Cloud/SecurityCenter/V2/Cve.php | 330 -- .../V2/Cve/ExploitationActivity.php | 87 - .../SecurityCenter/V2/Cve/RiskRating.php | 83 - .../Google/Cloud/SecurityCenter/V2/Cvssv3.php | 391 -- .../V2/Cvssv3/AttackComplexity.php | 71 - .../SecurityCenter/V2/Cvssv3/AttackVector.php | 84 - .../Cloud/SecurityCenter/V2/Cvssv3/Impact.php | 73 - .../V2/Cvssv3/PrivilegesRequired.php | 79 - .../Cloud/SecurityCenter/V2/Cvssv3/Scope.php | 67 - .../V2/Cvssv3/UserInteraction.php | 67 - .../Cloud/SecurityCenter/V2/Database.php | 287 - .../V2/DeleteBigQueryExportRequest.php | 107 - .../V2/DeleteMuteConfigRequest.php | 123 - .../V2/DeleteNotificationConfigRequest.php | 117 - .../V2/DeleteResourceValueConfigRequest.php | 81 - .../SecurityCenter/V2/EnvironmentVariable.php | 102 - .../Cloud/SecurityCenter/V2/ExfilResource.php | 121 - .../Cloud/SecurityCenter/V2/Exfiltration.php | 150 - .../SecurityCenter/V2/ExternalSystem.php | 513 -- .../V2/ExternalSystem/TicketInfo.php | 255 - .../Google/Cloud/SecurityCenter/V2/File.php | 298 - .../Cloud/SecurityCenter/V2/File/DiskPath.php | 112 - .../Cloud/SecurityCenter/V2/Finding.php | 2302 -------- .../V2/Finding/FindingClass.php | 103 - .../Cloud/SecurityCenter/V2/Finding/Mute.php | 71 - .../SecurityCenter/V2/Finding/Severity.php | 116 - .../Cloud/SecurityCenter/V2/Finding/State.php | 65 - .../Cloud/SecurityCenter/V2/Geolocation.php | 67 - .../V2/GetBigQueryExportRequest.php | 107 - .../V2/GetMuteConfigRequest.php | 123 - .../V2/GetNotificationConfigRequest.php | 117 - .../V2/GetResourceValueConfigRequest.php | 86 - .../V2/GetSimulationRequest.php | 99 - .../SecurityCenter/V2/GetSourceRequest.php | 86 - .../V2/GetValuedResourceRequest.php | 92 - .../V2/GroupFindingsRequest.php | 473 -- .../V2/GroupFindingsResponse.php | 147 - .../SecurityCenter/V2/GroupMembership.php | 102 - .../V2/GroupMembership/GroupType.php | 57 - .../Cloud/SecurityCenter/V2/GroupResult.php | 101 - .../Cloud/SecurityCenter/V2/IamBinding.php | 144 - .../SecurityCenter/V2/IamBinding/Action.php | 64 - .../Cloud/SecurityCenter/V2/Indicator.php | 177 - .../V2/Indicator/ProcessSignature.php | 145 - .../ProcessSignature/MemoryHashSignature.php | 108 - .../MemoryHashSignature/Detection.php | 112 - .../ProcessSignature/SignatureType.php | 64 - .../ProcessSignature/YaraRuleSignature.php | 70 - .../Cloud/SecurityCenter/V2/KernelRootkit.php | 367 -- .../Cloud/SecurityCenter/V2/Kubernetes.php | 319 - .../V2/Kubernetes/AccessReview.php | 289 - .../SecurityCenter/V2/Kubernetes/Binding.php | 186 - .../SecurityCenter/V2/Kubernetes/Node.php | 74 - .../SecurityCenter/V2/Kubernetes/NodePool.php | 104 - .../SecurityCenter/V2/Kubernetes/Object.php | 220 - .../SecurityCenter/V2/Kubernetes/Pod.php | 176 - .../SecurityCenter/V2/Kubernetes/Role.php | 138 - .../V2/Kubernetes/Role/Kind.php | 64 - .../SecurityCenter/V2/Kubernetes/Subject.php | 138 - .../V2/Kubernetes/Subject/AuthType.php | 71 - .../Google/Cloud/SecurityCenter/V2/Label.php | 104 - .../V2/ListAttackPathsRequest.php | 230 - .../V2/ListAttackPathsResponse.php | 106 - .../V2/ListBigQueryExportsRequest.php | 189 - .../V2/ListBigQueryExportsResponse.php | 105 - .../SecurityCenter/V2/ListFindingsRequest.php | 572 -- .../V2/ListFindingsResponse.php | 139 - .../ListFindingsResult.php | 124 - .../ListFindingsResult/Resource.php | 467 -- .../V2/ListMuteConfigsRequest.php | 200 - .../V2/ListMuteConfigsResponse.php | 105 - .../V2/ListNotificationConfigsRequest.php | 181 - .../V2/ListNotificationConfigsResponse.php | 105 - .../V2/ListResourceValueConfigsRequest.php | 191 - .../V2/ListResourceValueConfigsResponse.php | 105 - .../SecurityCenter/V2/ListSourcesRequest.php | 171 - .../SecurityCenter/V2/ListSourcesResponse.php | 105 - .../V2/ListValuedResourcesRequest.php | 298 - .../V2/ListValuedResourcesResponse.php | 139 - .../Cloud/SecurityCenter/V2/LoadBalancer.php | 68 - .../Cloud/SecurityCenter/V2/LogEntry.php | 75 - .../Cloud/SecurityCenter/V2/MitreAttack.php | 228 - .../SecurityCenter/V2/MitreAttack/Tactic.php | 149 - .../V2/MitreAttack/Technique.php | 486 -- .../Cloud/SecurityCenter/V2/MuteConfig.php | 420 -- .../V2/MuteConfig/MuteConfigType.php | 63 - .../SecurityCenter/V2/NotificationConfig.php | 253 - .../V2/NotificationConfig/StreamingConfig.php | 131 - .../SecurityCenter/V2/NotificationMessage.php | 156 - .../Cloud/SecurityCenter/V2/OrgPolicy.php | 75 - .../Cloud/SecurityCenter/V2/Package.php | 169 - .../Cloud/SecurityCenter/V2/Process.php | 409 -- .../Cloud/SecurityCenter/V2/Reference.php | 105 - .../Cloud/SecurityCenter/V2/Resource.php | 463 -- .../Cloud/SecurityCenter/V2/ResourceValue.php | 75 - .../SecurityCenter/V2/ResourceValueConfig.php | 506 -- .../SensitiveDataProtectionMapping.php | 114 - .../V2/ResourceValueConfigMetadata.php | 67 - .../SecurityCenter/V2/SecurityBulletin.php | 149 - .../Cloud/SecurityCenter/V2/SecurityMarks.php | 250 - .../SecurityCenter/V2/SecurityPosture.php | 325 -- .../V2/SecurityPosture/PolicyDriftDetails.php | 151 - .../V2/ServiceAccountDelegationInfo.php | 125 - .../V2/SetFindingStateRequest.php | 184 - .../SecurityCenter/V2/SetMuteRequest.php | 184 - .../Cloud/SecurityCenter/V2/Simulation.php | 187 - .../Google/Cloud/SecurityCenter/V2/Source.php | 244 - .../SecurityCenter/V2/ToxicCombination.php | 124 - .../V2/UpdateBigQueryExportRequest.php | 141 - .../V2/UpdateExternalSystemRequest.php | 142 - .../V2/UpdateFindingRequest.php | 183 - .../V2/UpdateMuteConfigRequest.php | 141 - .../V2/UpdateNotificationConfigRequest.php | 142 - .../V2/UpdateResourceValueConfigRequest.php | 157 - .../V2/UpdateSecurityMarksRequest.php | 152 - .../SecurityCenter/V2/UpdateSourceRequest.php | 142 - .../SecurityCenter/V2/ValuedResource.php | 307 - .../V2/ValuedResource/ResourceValue.php | 71 - .../Cloud/SecurityCenter/V2/Vulnerability.php | 213 - .../batch_create_resource_value_configs.php | 102 - .../bulk_mute_findings.php | 94 - .../create_big_query_export.php | 82 - .../SecurityCenterClient/create_finding.php | 84 - .../create_mute_config.php | 113 - .../create_notification_config.php | 82 - .../V2/SecurityCenterClient/create_source.php | 74 - .../delete_big_query_export.php | 79 - .../delete_mute_config.php | 79 - .../delete_notification_config.php | 81 - .../delete_resource_value_config.php | 72 - .../get_big_query_export.php | 81 - .../SecurityCenterClient/get_iam_policy.php | 71 - .../SecurityCenterClient/get_mute_config.php | 81 - .../get_notification_config.php | 83 - .../get_resource_value_config.php | 75 - .../SecurityCenterClient/get_simulation.php | 76 - .../V2/SecurityCenterClient/get_source.php | 72 - .../get_valued_resource.php | 78 - .../SecurityCenterClient/group_findings.php | 114 - .../list_attack_paths.php | 88 - .../list_big_query_exports.php | 83 - .../V2/SecurityCenterClient/list_findings.php | 103 - .../list_mute_configs.php | 82 - .../list_notification_configs.php | 80 - .../list_resource_value_configs.php | 78 - .../V2/SecurityCenterClient/list_sources.php | 78 - .../list_valued_resources.php | 81 - .../set_finding_state.php | 90 - .../SecurityCenterClient/set_iam_policy.php | 73 - .../V2/SecurityCenterClient/set_mute.php | 90 - .../test_iam_permissions.php | 78 - .../update_big_query_export.php | 59 - .../update_external_system.php | 60 - .../SecurityCenterClient/update_finding.php | 61 - .../update_mute_config.php | 97 - .../update_notification_config.php | 60 - .../update_resource_value_config.php | 76 - .../update_security_marks.php | 61 - .../V2/SecurityCenterClient/update_source.php | 59 - .../v2/src/V2/Client/SecurityCenterClient.php | 2791 --------- .../v2/src/V2/gapic_metadata.json | 218 - .../security_center_client_config.json | 226 - .../security_center_descriptor_config.php | 672 --- .../security_center_rest_client_config.php | 1125 ---- .../V2/Client/SecurityCenterClientTest.php | 3152 ---------- 650 files changed, 1195 insertions(+), 111007 deletions(-) rename {owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter => SecurityCenter/metadata}/V2/CloudArmor.php (100%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter => SecurityCenter/metadata}/V2/Folder.php (100%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter => SecurityCenter/metadata}/V2/Notebook.php (100%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/AdaptiveProtection.php (98%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/Attack.php (97%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/AwsMetadata.php (98%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/AwsMetadata/AwsAccount.php (98%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/AwsMetadata/AwsOrganization.php (99%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/AwsMetadata/AwsOrganizationalUnit.php (98%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/AzureMetadata.php (98%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/AzureMetadata/AzureManagementGroup.php (98%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/AzureMetadata/AzureResourceGroup.php (98%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/AzureMetadata/AzureSubscription.php (98%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/CloudArmor.php (98%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/CloudProvider.php (100%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/Folder.php (97%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/GcpMetadata.php (97%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/Notebook.php (97%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/Requests.php (97%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/ResourcePath.php (100%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/ResourcePath/ResourcePathNode.php (97%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/ResourcePath/ResourcePathNodeType.php (100%) rename {owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter => SecurityCenter/src}/V2/SecurityPolicy.php (98%) delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Access.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Application.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Asset.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/BackupDisasterRecovery.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/BigqueryExport.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudArmor.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudDlpDataProfile.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudDlpInspection.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Compliance.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Connection.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ContactDetails.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Container.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Database.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/EffectiveSecurityHealthAnalyticsCustomModule.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Exfiltration.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ExternalSystem.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/File.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Finding.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Folder.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/GroupMembership.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/IamBinding.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Indicator.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/KernelRootkit.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Kubernetes.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Label.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/LoadBalancer.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/LogEntry.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/MitreAttack.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/MuteConfig.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Notebook.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/NotificationConfig.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/NotificationMessage.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/OrgPolicy.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/OrganizationSettings.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Process.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Resource.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/RunAssetDiscoveryResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityHealthAnalyticsCustomConfig.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityHealthAnalyticsCustomModule.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityMarks.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityPosture.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecuritycenterService.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Source.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ToxicCombination.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Vulnerability.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Access.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/AdaptiveProtection.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Application.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset/IamPolicy.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset/SecurityCenterProperties.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Attack.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BackupDisasterRecovery.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BigQueryExport.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BulkMuteFindingsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BulkMuteFindingsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudArmor.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpDataProfile.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpDataProfile/ParentType.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpInspection.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudLoggingEntry.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Compliance.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Connection.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Connection/Protocol.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Contact.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ContactDetails.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Container.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateBigQueryExportRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateFindingRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateMuteConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateNotificationConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateSecurityHealthAnalyticsCustomModuleRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateSourceRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/CustomOutputSpec.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/CustomOutputSpec/Property.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/ResourceSelector.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/Severity.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve/ExploitationActivity.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve/RiskRating.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/AttackComplexity.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/AttackVector.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/Impact.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/PrivilegesRequired.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/Scope.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/UserInteraction.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Database.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteBigQueryExportRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteMuteConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteNotificationConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteSecurityHealthAnalyticsCustomModuleRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EffectiveSecurityHealthAnalyticsCustomModule.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EffectiveSecurityHealthAnalyticsCustomModule/EnablementState.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EnvironmentVariable.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExfilResource.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Exfiltration.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExternalSystem.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExternalSystem/TicketInfo.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/File.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/File/DiskPath.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/FindingClass.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/Mute.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/Severity.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/State.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Folder.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Geolocation.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetBigQueryExportRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetEffectiveSecurityHealthAnalyticsCustomModuleRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetMuteConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetNotificationConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetOrganizationSettingsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetSecurityHealthAnalyticsCustomModuleRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetSourceRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupAssetsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupAssetsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupFindingsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupFindingsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupMembership.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupMembership/GroupType.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupResult.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/IamBinding.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/IamBinding/Action.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/MemoryHashSignature.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/MemoryHashSignature/Detection.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/SignatureType.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/YaraRuleSignature.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/KernelRootkit.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/AccessReview.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Binding.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Node.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/NodePool.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Object.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Pod.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Role.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Role/Kind.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Subject.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Subject/AuthType.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Label.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse/ListAssetsResult.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse/ListAssetsResult/StateChange.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListBigQueryExportsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListBigQueryExportsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListDescendantSecurityHealthAnalyticsCustomModulesRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListDescendantSecurityHealthAnalyticsCustomModulesResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListEffectiveSecurityHealthAnalyticsCustomModulesRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListEffectiveSecurityHealthAnalyticsCustomModulesResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult/Resource.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult/StateChange.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListMuteConfigsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListMuteConfigsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListNotificationConfigsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListNotificationConfigsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSecurityHealthAnalyticsCustomModulesRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSecurityHealthAnalyticsCustomModulesResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSourcesRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSourcesResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/LoadBalancer.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/LogEntry.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack/Tactic.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack/Technique.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MuteConfig.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Notebook.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationConfig.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationConfig/StreamingConfig.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationMessage.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrgPolicy.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings/AssetDiscoveryConfig.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings/AssetDiscoveryConfig/InclusionMode.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Package.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Process.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Reference.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Requests.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Resource.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryResponse/State.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityBulletin.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityHealthAnalyticsCustomModule.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityHealthAnalyticsCustomModule/EnablementState.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityMarks.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPolicy.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPosture.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPosture/PolicyDriftDetails.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ServiceAccountDelegationInfo.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SetFindingStateRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SetMuteRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleRequest/SimulatedResource.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleResponse/SimulatedResult.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Source.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ToxicCombination.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateBigQueryExportRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateExternalSystemRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateFindingRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateMuteConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateNotificationConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateOrganizationSettingsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSecurityHealthAnalyticsCustomModuleRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSecurityMarksRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSourceRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Vulnerability.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/bulk_mute_findings.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_big_query_export.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_finding.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_mute_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_notification_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_security_health_analytics_custom_module.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_source.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_big_query_export.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_mute_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_notification_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_security_health_analytics_custom_module.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_big_query_export.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_effective_security_health_analytics_custom_module.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_iam_policy.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_mute_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_notification_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_organization_settings.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_security_health_analytics_custom_module.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_source.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/group_assets.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/group_findings.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_assets.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_big_query_exports.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_descendant_security_health_analytics_custom_modules.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_effective_security_health_analytics_custom_modules.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_findings.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_mute_configs.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_notification_configs.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_security_health_analytics_custom_modules.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_sources.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/run_asset_discovery.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_finding_state.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_iam_policy.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_mute.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/simulate_security_health_analytics_custom_module.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_big_query_export.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_external_system.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_finding.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_mute_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_notification_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_organization_settings.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_security_health_analytics_custom_module.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_security_marks.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_source.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/src/V1/Client/SecurityCenterClient.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/src/V1/Gapic/SecurityCenterGapicClient.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/src/V1/SecurityCenterClient.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/SecurityCenter/v1/src/V1/resources/security_center_client_config.json delete mode 100644 owl-bot-staging/SecurityCenter/v1/src/V1/resources/security_center_descriptor_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/src/V1/resources/security_center_rest_client_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/tests/Unit/V1/Client/SecurityCenterClientTest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1/tests/Unit/V1/SecurityCenterClientTest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Asset.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Finding.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Folder.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/NotificationConfig.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/NotificationMessage.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/OrganizationSettings.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Resource.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/RunAssetDiscoveryResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/SecurityMarks.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/SecuritycenterService.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Source.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset/IamPolicy.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset/SecurityCenterProperties.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateFindingRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateNotificationConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateSourceRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/DeleteNotificationConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding/Severity.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding/State.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Folder.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetNotificationConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetOrganizationSettingsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetSourceRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupAssetsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupAssetsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupFindingsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupFindingsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupResult.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse/ListAssetsResult.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse/ListAssetsResult/StateChange.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult/Resource.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult/StateChange.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListNotificationConfigsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListNotificationConfigsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListSourcesRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListSourcesResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig/EventType.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig/StreamingConfig.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationMessage.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings/AssetDiscoveryConfig.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings/AssetDiscoveryConfig/InclusionMode.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Resource.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryResponse/State.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/SecurityMarks.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/SetFindingStateRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Source.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateFindingRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateNotificationConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateOrganizationSettingsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateSecurityMarksRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateSourceRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_finding.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_notification_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_source.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/delete_notification_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_iam_policy.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_notification_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_organization_settings.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_source.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/group_assets.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/group_findings.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_assets.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_findings.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_notification_configs.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_sources.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/run_asset_discovery.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/set_finding_state.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/set_iam_policy.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_finding.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_notification_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_organization_settings.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_security_marks.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_source.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/Gapic/SecurityCenterGapicClient.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/SecurityCenterClient.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/gapic_metadata.json delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/resources/security_center_client_config.json delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/resources/security_center_descriptor_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/resources/security_center_rest_client_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v1p1beta1/tests/Unit/V1p1beta1/SecurityCenterClientTest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Access.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Application.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/AttackExposure.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/AttackPath.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/BackupDisasterRecovery.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/BigqueryExport.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudDlpDataProfile.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudDlpInspection.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Compliance.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Connection.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ContactDetails.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Container.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Database.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Exfiltration.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ExternalSystem.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/File.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Finding.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/GroupMembership.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/IamBinding.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Indicator.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/KernelRootkit.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Kubernetes.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Label.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/LoadBalancer.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/LogEntry.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/MitreAttack.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/MuteConfig.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/NotificationConfig.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/NotificationMessage.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/OrgPolicy.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Process.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Resource.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ResourceValueConfig.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecurityMarks.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecurityPosture.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecuritycenterService.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Simulation.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Source.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ToxicCombination.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ValuedResource.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Vulnerability.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Access.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Application.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackExposure.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackExposure/State.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathEdge.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/AttackStepNode.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/NodeType.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/PathNodeAssociatedFinding.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BackupDisasterRecovery.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BatchCreateResourceValueConfigsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BatchCreateResourceValueConfigsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BigQueryExport.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BulkMuteFindingsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BulkMuteFindingsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpDataProfile.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpDataProfile/ParentType.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpInspection.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudLoggingEntry.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Compliance.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Connection.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Connection/Protocol.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Contact.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ContactDetails.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Container.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateBigQueryExportRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateFindingRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateMuteConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateNotificationConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateResourceValueConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateSourceRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve/ExploitationActivity.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve/RiskRating.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/AttackComplexity.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/AttackVector.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/Impact.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/PrivilegesRequired.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/Scope.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/UserInteraction.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Database.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteBigQueryExportRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteMuteConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteNotificationConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteResourceValueConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/EnvironmentVariable.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExfilResource.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Exfiltration.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExternalSystem.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExternalSystem/TicketInfo.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/File.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/File/DiskPath.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/FindingClass.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/Mute.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/Severity.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/State.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Geolocation.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetBigQueryExportRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetMuteConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetNotificationConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetResourceValueConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetSimulationRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetSourceRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetValuedResourceRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupFindingsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupFindingsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupMembership.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupMembership/GroupType.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupResult.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/IamBinding.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/IamBinding/Action.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/MemoryHashSignature.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/MemoryHashSignature/Detection.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/SignatureType.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/YaraRuleSignature.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/KernelRootkit.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/AccessReview.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Binding.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Node.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/NodePool.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Object.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Pod.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Role.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Role/Kind.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Subject.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Subject/AuthType.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Label.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListAttackPathsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListAttackPathsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListBigQueryExportsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListBigQueryExportsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse/ListFindingsResult.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse/ListFindingsResult/Resource.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListMuteConfigsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListMuteConfigsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListNotificationConfigsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListNotificationConfigsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListResourceValueConfigsRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListResourceValueConfigsResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListSourcesRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListSourcesResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListValuedResourcesRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListValuedResourcesResponse.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/LoadBalancer.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/LogEntry.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack/Tactic.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack/Technique.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MuteConfig.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MuteConfig/MuteConfigType.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationConfig.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationConfig/StreamingConfig.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationMessage.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/OrgPolicy.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Package.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Process.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Reference.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Resource.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValue.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfig.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfig/SensitiveDataProtectionMapping.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfigMetadata.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityBulletin.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityMarks.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPosture.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPosture/PolicyDriftDetails.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ServiceAccountDelegationInfo.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SetFindingStateRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SetMuteRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Simulation.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Source.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ToxicCombination.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateBigQueryExportRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateExternalSystemRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateFindingRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateMuteConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateNotificationConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateResourceValueConfigRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateSecurityMarksRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateSourceRequest.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ValuedResource.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ValuedResource/ResourceValue.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Vulnerability.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/batch_create_resource_value_configs.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/bulk_mute_findings.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_big_query_export.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_finding.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_mute_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_notification_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_source.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_big_query_export.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_mute_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_notification_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_resource_value_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_big_query_export.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_iam_policy.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_mute_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_notification_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_resource_value_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_simulation.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_source.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_valued_resource.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/group_findings.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_attack_paths.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_big_query_exports.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_findings.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_mute_configs.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_notification_configs.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_resource_value_configs.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_sources.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_valued_resources.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_finding_state.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_iam_policy.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_mute.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_big_query_export.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_external_system.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_finding.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_mute_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_notification_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_resource_value_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_security_marks.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_source.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/src/V2/Client/SecurityCenterClient.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/src/V2/gapic_metadata.json delete mode 100644 owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_client_config.json delete mode 100644 owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_descriptor_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_rest_client_config.php delete mode 100644 owl-bot-staging/SecurityCenter/v2/tests/Unit/V2/Client/SecurityCenterClientTest.php diff --git a/SecurityCenter/metadata/V2/AttackPath.php b/SecurityCenter/metadata/V2/AttackPath.php index 1bf2dd05c5c3da8a94b1258dd22f8832f05e6031..f3fa8e4a833b05b10da3868eb04420fe6279a5b7 100644 GIT binary patch delta 90 zcmbOuxKwC^5);c#UM_=)-UgGym=u{laBZ$+(q>^h%=F4}Khxw@Y;*O5+8FbT(i8JC ds}f5x^Ye=JtC6|2`Z@W@FbN=Y^BcAei~w#_AqfBg delta 43 zcmV+`0M!4b5}XmRA_4@k3<@xjOE8mG0wDtD3A1?uD+C6*0qQ}v0h6i*owLvfRRJN# B4gCNB diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudArmor.php b/SecurityCenter/metadata/V2/CloudArmor.php similarity index 100% rename from owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudArmor.php rename to SecurityCenter/metadata/V2/CloudArmor.php diff --git a/SecurityCenter/metadata/V2/Finding.php b/SecurityCenter/metadata/V2/Finding.php index 2083d9f3ff9a64bac9e3e536e87f1353b9114b54..ce87104095b842c0fc52cec27e0d86325e3ee84f 100644 GIT binary patch delta 177 zcmbQ}((1lpDl@BNQEq8*d^=gI+;Veo4NR_2fVv`OWKjDw!E|K}_~Mi1y720(Fc`o8>nz5LDz6v*+SY z&dD!Li3e+yFjipH;5O2l%qXEK2@(doK*)-V1FAV&!d!uIvY)gH+%cOENC&b30EN6a A5C8xG delta 61 zcmV-D0K)%;N0CIZl>@Wk18oJfmw0kc;PnFEt35FoQZ T5mo^LwjQ&W5+Mq+H62g}hr|;8 diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Folder.php b/SecurityCenter/metadata/V2/Folder.php similarity index 100% rename from owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Folder.php rename to SecurityCenter/metadata/V2/Folder.php diff --git a/SecurityCenter/metadata/V2/MitreAttack.php b/SecurityCenter/metadata/V2/MitreAttack.php index e4de67b6f42ddd6ae9c64728cd88a395d54d5c87..61d429ac69c1ed935f724fabfc0fd7e14a367ecc 100644 GIT binary patch delta 149 zcmew@@lkTaJ4UAMqLV)`hA_Pm+U&+On~CW>@8-uWT#VdYTxH!KO PV{dJf5Cb2x+Y1%}fN~SS diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Notebook.php b/SecurityCenter/metadata/V2/Notebook.php similarity index 100% rename from owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Notebook.php rename to SecurityCenter/metadata/V2/Notebook.php diff --git a/SecurityCenter/metadata/V2/Resource.php b/SecurityCenter/metadata/V2/Resource.php index 13e8ca2d9e3d1c38d5fb1cd78df68db9010adce9..bd8db04f5de9caa50cdbea5390cac3f6883121e0 100644 GIT binary patch literal 3212 zcmbtW-*4Mg6kd}4JZaO+?ba-V%FCv;V{0mcK*(Jgj^lWl+BhUm2UU>eI=88jYg_)& z(W1WbfcR5*=9Pbde}Grska$Mom3yxp*GXH#MqXkcpYz@Cob%m#&+`|~u>%iT30cV1 zeAH(T&shH$v5sr|wr-p3VQ_SWTvoSF9K%FznPqD-+msbntTmJeIMlNPS4SK>u3J3*eK>4=qD)ji~Eea+W;5(ViA1f7nugALzUJeU$Je zx^LJPO9Es|M;lMr5R>>ma%^0I9d<~oMT&w8(rb{cEY0lIkf*zbwB`Eet+#|5A`&nD$G>{koNFz><22#D(Wu3-%dS&TJby$7qK{fSAJen~+# zQ616)+{AB??nnK{$dN(4Mh7{VaWoenW04Z>!*cjO>P+M?&pe0OP<0;eZwB}6@uVEX z9ahc!&S!`aZFitq#(6>zrSCJ4O*Dr2V$6$(I9u7Cv`_+~jGyJiLW~M4$%Qpj4e)X3 z71A^Z{(nGgW)~wd63lA4ZU<2nvz1TY5|a<3i|@nIIC+4y(GOc${1EPpeU1nuoZ{V2 z_j&O#01k=pnH&8|KWAWZMA*#NaQj5Fv;jK7>QD!+9XKB5LE2uOm|k*=ltbJYOCnHA z7Z$wWFuY#K@j&QiD=*#wxs!llzJy%7k0@uV>ulxocK{x4P)fM?DXd(ZNV2Bap0&k~ z;WmvNAv!s%1Pl!up%J&29`2>TGO#fGPS25Dn6~Ub8g^=DQrgMja`L5#QHnpNAU|$o z6qqMVsPz6IG;)=RdngHVWf=uuM3FSZ%W1rf^pYz5kcO2c4q-?`d+YG9Eq3H?TM*S2 zue?;7a!pi~uUewoZFX9s(5N@WTK*P3g7T8kQsuV9Hya1M(vX|^6q5rW*1Eh~6WjST zK0>qPz15aqiGq?RCs&?--5Cv=V(!E0xRu|<3pSMeG{GPrc|nl7O(j3W6yYv^&~1zA z9^d38aZhY2s??Udt^6!=7k8R|>vXFfq1|XvVslIZOOD#(?81oo559%P(W`e2io&kk ztr6Dy4V=eV=J()^B+JsSs77wPyi%9jdpP}7SmyWm1G%Zb7OQGUZ0|P&v4iWd3`=_r zp)Gghx}s7d`AqeX6qN9^JV960#kf;ssBEPUUeOCI4zo|T2KM+ItvLoBrAJ30=Wu)6 z@KbtCqJwleew2rUv_Plv@_yylp+hekwc}Ykbm`$?`_J@)5QO7sB{^;shU4}thco!* c^zDz<<6-YvIL0QX-Ww-g>KV?Z7jOaa4|PTO%>V!Z delta 43 zcmeB?e9gY$Gvj1yCVi&=Op|k%{F#(&CckE~;c$A+$fcB=pF7!+S$=aRw=g3BM-&Z+ diff --git a/SecurityCenter/metadata/V2/ResourceValueConfig.php b/SecurityCenter/metadata/V2/ResourceValueConfig.php index 16f5efa9a835b78db9ba130f2d52a6a9b9c6e806..8b11b3f6e6532c3e03dc7998ff68b2531b6af5e7 100644 GIT binary patch delta 197 zcmeAZyd}ILlxgA;@ySX|T}-ohC$D3wVAP$wfk}O`JhKMNPYy2O$rIT`Hpeq}FbcbJ z@g?Wvm!`xQ6y=v?rlb~0a7}JtR^xRB2?jvLHa}x&V`S@Pdga*3G`WziPFE-{zbHL1 zFS9DKBr`v+Sic&XTdSXwpA3@#GAHk0Gtm+$N-fSWElN%eOUx-vbCB J`90fwMgT!4M{ocD delta 59 zcmV-B0L1^=6OIwERRWWr0#^i>3ko`uaRVojaubs@13Z(T10e#Y2eZNho&mF`1%&|x RfdT44ev>i>ezQ9Wp8-YX6J-DZ diff --git a/SecurityCenter/metadata/V2/SecuritycenterService.php b/SecurityCenter/metadata/V2/SecuritycenterService.php index 0cc4197f73f2f8a145bf982e5b1b61923e5d0d6f..b0afb9ba07b805f8868f9c68b4c46e350d21bca8 100644 GIT binary patch delta 975 zcmZ9LT}V@57{@zjXLFu?xLz%fI=@y-v&3Cd=ZD%{@Oi3}A zh6Glak6i>oL^nYa#fiYXx{2r_lkNmbB#0ukAc#ILde1gLuJ~NDNg*R9eAS;plQ}h2FG|a_B5s zkVb;M!00iOjcl|rB=VdR6eElwskmu#fRFmZg2D}P3ddw&)l_#7zO|R{=cCujmjD13EIky#U){z%?5LY)9KR049-nkwpRB=IpqRFYc1ic!vV8S zV{0##ke$xk!T4lF3Pu8qNi*M3Kj zmG}v_8%K91a04pBg@xoTrK%QQ)EB~Ce?H}Ht7^pur^+_<62v;pG|M(I6F!eB!PQp; zVYfx+Z9wq6z5-UdEz|^>C!v|WjOKUro+c2R=FPCd=2G4+bX*&NFIm-1)$*8_rX zf*2~XpOyk#Bsi9Q+5=oDE)1PXe=8J%U&FO*jT{WeL&>^aGroP8s2SOT<6=tiZ9P1g H4D|d3Y6Vnj delta 441 zcmexzi}AvF#trXTHe0ejVPaabf3rLX8`I(tE#3G=y zPEl%MX=-svant1|lbM{9Y$tEjk)9k8Ahvmib_XBh_Q{G?TeeIZOmLs V$@#gH1Lfp5Kg*iRI9WZ{7XXEAq?rH! diff --git a/SecurityCenter/metadata/V2/Simulation.php b/SecurityCenter/metadata/V2/Simulation.php index c8c668418056..eb916ed5113f 100644 --- a/SecurityCenter/metadata/V2/Simulation.php +++ b/SecurityCenter/metadata/V2/Simulation.php @@ -16,18 +16,20 @@ public static function initOnce() { } \GPBMetadata\Google\Api\FieldBehavior::initOnce(); \GPBMetadata\Google\Api\Resource::initOnce(); + \GPBMetadata\Google\Cloud\Securitycenter\V2\Resource::initOnce(); \GPBMetadata\Google\Cloud\Securitycenter\V2\ValuedResource::initOnce(); \GPBMetadata\Google\Protobuf\Timestamp::initOnce(); $pool->internalAddGeneratedFile( ' -ï -/google/cloud/securitycenter/v2/simulation.protogoogle.cloud.securitycenter.v2google/api/resource.proto4google/cloud/securitycenter/v2/valued_resource.protogoogle/protobuf/timestamp.proto"µ +³ +/google/cloud/securitycenter/v2/simulation.protogoogle.cloud.securitycenter.v2google/api/resource.proto-google/cloud/securitycenter/v2/resource.proto4google/cloud/securitycenter/v2/valued_resource.protogoogle/protobuf/timestamp.proto"Ê Simulation name ( 4 create_time ( 2.google.protobuf.TimestampBàAd -resource_value_configs_metadata ( 2;.google.cloud.securitycenter.v2.ResourceValueConfigMetadata:}êAz -(securitycenter.googleapis.com/Simulation5organizations/{organization}/simulations/{simulation}* simulations2 +resource_value_configs_metadata ( 2;.google.cloud.securitycenter.v2.ResourceValueConfigMetadataE +cloud_provider (2-.google.cloud.securitycenter.v2.CloudProvider:ÊêAÆ +(securitycenter.googleapis.com/Simulation5organizations/{organization}/simulations/{simulation}Jorganizations/{organization}/locations/{location}/simulations/{simluation}* simulations2 simulationBé "com.google.cloud.securitycenter.v2BSimulationProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' , true); diff --git a/SecurityCenter/metadata/V2/ValuedResource.php b/SecurityCenter/metadata/V2/ValuedResource.php index 825a26de4b80bc2c2fe79042cfc060c6df0ad19a..936e64c1da32cd998e0a24646556da851a645cfa 100644 GIT binary patch delta 109 zcmX@bvx9eo78BDEj>$Sq;Y`O^H@7maVq}}e^vZD>(_~YYb~mA%{G#;4yv(Y^lFa

%fe8aSIi;JYuxw)l0DsCUhyVZp delta 38 ucmdnNdx~d+78BDo_Q^U-;Y>GJHn%dZVq{yx_{wnw<788o_RU(XeT)G4K@5EW diff --git a/SecurityCenter/samples/V2/SecurityCenterClient/batch_create_resource_value_configs.php b/SecurityCenter/samples/V2/SecurityCenterClient/batch_create_resource_value_configs.php index d9c8e5b260a4..f2258fa62849 100644 --- a/SecurityCenter/samples/V2/SecurityCenterClient/batch_create_resource_value_configs.php +++ b/SecurityCenter/samples/V2/SecurityCenterClient/batch_create_resource_value_configs.php @@ -37,12 +37,12 @@ * @param string $formattedParent Resource name of the new ResourceValueConfig's parent. * The parent field in the CreateResourceValueConfigRequest * messages must either be empty or match this field. Please see - * {@see SecurityCenterClient::organizationName()} for help formatting this field. + * {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. * @param string $formattedRequestsParent Resource name of the new ResourceValueConfig's parent. Please see - * {@see SecurityCenterClient::organizationName()} for help formatting this field. - * @param string $requestsResourceValueConfigTagValuesElement Tag values combined with AND to check against. + * {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. + * @param string $requestsResourceValueConfigTagValuesElement Tag values combined with AND to check against. * Values in the form "tagValues/123" - * E.g. [ "tagValues/123", "tagValues/456", "tagValues/789" ] + * Example: [ "tagValues/123", "tagValues/456", "tagValues/789" ] * https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing */ function batch_create_resource_value_configs_sample( @@ -86,8 +86,11 @@ function batch_create_resource_value_configs_sample( */ function callSample(): void { - $formattedParent = SecurityCenterClient::organizationName('[ORGANIZATION]'); - $formattedRequestsParent = SecurityCenterClient::organizationName('[ORGANIZATION]'); + $formattedParent = SecurityCenterClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); + $formattedRequestsParent = SecurityCenterClient::organizationLocationName( + '[ORGANIZATION]', + '[LOCATION]' + ); $requestsResourceValueConfigTagValuesElement = '[TAG_VALUES]'; batch_create_resource_value_configs_sample( diff --git a/SecurityCenter/samples/V2/SecurityCenterClient/group_findings.php b/SecurityCenter/samples/V2/SecurityCenterClient/group_findings.php index 008ac6126625..17c770cff8f4 100644 --- a/SecurityCenter/samples/V2/SecurityCenterClient/group_findings.php +++ b/SecurityCenter/samples/V2/SecurityCenterClient/group_findings.php @@ -70,14 +70,6 @@ * @param string $groupBy Expression that defines what assets fields to use for grouping. * The string value should follow SQL syntax: comma separated list of fields. * For example: "parent,resource_name". - * - * The following fields are supported: - * - * * resource_name - * * category - * * state - * * parent - * * severity */ function group_findings_sample(string $formattedParent, string $groupBy): void { diff --git a/SecurityCenter/samples/V2/SecurityCenterClient/list_attack_paths.php b/SecurityCenter/samples/V2/SecurityCenterClient/list_attack_paths.php index 3ee8df3ced4f..c73ae4482d56 100644 --- a/SecurityCenter/samples/V2/SecurityCenterClient/list_attack_paths.php +++ b/SecurityCenter/samples/V2/SecurityCenterClient/list_attack_paths.php @@ -40,7 +40,7 @@ * "organizations/{organization}/simulations/{simulation}" * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" - * Please see {@see SecurityCenterClient::valuedResourceName()} for help formatting this field. + * Please see {@see SecurityCenterClient::organizationValuedResourceName()} for help formatting this field. */ function list_attack_paths_sample(string $formattedParent): void { @@ -76,8 +76,9 @@ function list_attack_paths_sample(string $formattedParent): void */ function callSample(): void { - $formattedParent = SecurityCenterClient::valuedResourceName( + $formattedParent = SecurityCenterClient::organizationValuedResourceName( '[ORGANIZATION]', + '[LOCATION]', '[SIMULATION]', '[VALUED_RESOURCE]' ); diff --git a/SecurityCenter/samples/V2/SecurityCenterClient/list_resource_value_configs.php b/SecurityCenter/samples/V2/SecurityCenterClient/list_resource_value_configs.php index 18c265ad4619..63ea9e8e6697 100644 --- a/SecurityCenter/samples/V2/SecurityCenterClient/list_resource_value_configs.php +++ b/SecurityCenter/samples/V2/SecurityCenterClient/list_resource_value_configs.php @@ -35,7 +35,7 @@ * @param string $formattedParent The parent, which owns the collection of resource value configs. * Its format is * "organizations/[organization_id]" - * Please see {@see SecurityCenterClient::organizationName()} for help formatting this field. + * Please see {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. */ function list_resource_value_configs_sample(string $formattedParent): void { @@ -71,7 +71,7 @@ function list_resource_value_configs_sample(string $formattedParent): void */ function callSample(): void { - $formattedParent = SecurityCenterClient::organizationName('[ORGANIZATION]'); + $formattedParent = SecurityCenterClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); list_resource_value_configs_sample($formattedParent); } diff --git a/SecurityCenter/samples/V2/SecurityCenterClient/update_resource_value_config.php b/SecurityCenter/samples/V2/SecurityCenterClient/update_resource_value_config.php index c1af80104d70..88655d00e356 100644 --- a/SecurityCenter/samples/V2/SecurityCenterClient/update_resource_value_config.php +++ b/SecurityCenter/samples/V2/SecurityCenterClient/update_resource_value_config.php @@ -31,9 +31,9 @@ /** * Updates an existing ResourceValueConfigs with new rules. * - * @param string $resourceValueConfigTagValuesElement Tag values combined with AND to check against. + * @param string $resourceValueConfigTagValuesElement Tag values combined with AND to check against. * Values in the form "tagValues/123" - * E.g. [ "tagValues/123", "tagValues/456", "tagValues/789" ] + * Example: [ "tagValues/123", "tagValues/456", "tagValues/789" ] * https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing */ function update_resource_value_config_sample(string $resourceValueConfigTagValuesElement): void diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AdaptiveProtection.php b/SecurityCenter/src/V2/AdaptiveProtection.php similarity index 98% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AdaptiveProtection.php rename to SecurityCenter/src/V2/AdaptiveProtection.php index e9bb98caba93..fb7603dcbcfe 100644 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AdaptiveProtection.php +++ b/SecurityCenter/src/V2/AdaptiveProtection.php @@ -25,7 +25,7 @@ class AdaptiveProtection extends \Google\Protobuf\Internal\Message * * Generated from protobuf field double confidence = 1; */ - protected $confidence = 0.0; + private $confidence = 0.0; /** * Constructor. diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Attack.php b/SecurityCenter/src/V2/Attack.php similarity index 97% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Attack.php rename to SecurityCenter/src/V2/Attack.php index a260722cbc65..fb770283067d 100644 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Attack.php +++ b/SecurityCenter/src/V2/Attack.php @@ -20,19 +20,19 @@ class Attack extends \Google\Protobuf\Internal\Message * * Generated from protobuf field int32 volume_pps = 1; */ - protected $volume_pps = 0; + private $volume_pps = 0; /** * Total BPS (bytes per second) volume of attack. * * Generated from protobuf field int32 volume_bps = 2; */ - protected $volume_bps = 0; + private $volume_bps = 0; /** * Type of attack, for example, 'SYN-flood', 'NTP-udp', or 'CHARGEN-udp'. * * Generated from protobuf field string classification = 3; */ - protected $classification = ''; + private $classification = ''; /** * Constructor. diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata.php b/SecurityCenter/src/V2/AwsMetadata.php similarity index 98% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata.php rename to SecurityCenter/src/V2/AwsMetadata.php index a710970023db..65a0f456e159 100644 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata.php +++ b/SecurityCenter/src/V2/AwsMetadata.php @@ -21,7 +21,7 @@ class AwsMetadata extends \Google\Protobuf\Internal\Message * * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata.AwsOrganization organization = 1; */ - protected $organization = null; + private $organization = null; /** * A list of AWS organizational units associated with the resource, ordered * from lowest level (closest to the account) to highest level. @@ -34,7 +34,7 @@ class AwsMetadata extends \Google\Protobuf\Internal\Message * * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata.AwsAccount account = 3; */ - protected $account = null; + private $account = null; /** * Constructor. diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsAccount.php b/SecurityCenter/src/V2/AwsMetadata/AwsAccount.php similarity index 98% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsAccount.php rename to SecurityCenter/src/V2/AwsMetadata/AwsAccount.php index 96d785b57625..f23de823c412 100644 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsAccount.php +++ b/SecurityCenter/src/V2/AwsMetadata/AwsAccount.php @@ -20,13 +20,13 @@ class AwsAccount extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string id = 1; */ - protected $id = ''; + private $id = ''; /** * The friendly name of this account. * * Generated from protobuf field string name = 2; */ - protected $name = ''; + private $name = ''; /** * Constructor. diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsOrganization.php b/SecurityCenter/src/V2/AwsMetadata/AwsOrganization.php similarity index 99% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsOrganization.php rename to SecurityCenter/src/V2/AwsMetadata/AwsOrganization.php index 379175d8656a..201d8aaa0200 100644 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsOrganization.php +++ b/SecurityCenter/src/V2/AwsMetadata/AwsOrganization.php @@ -24,7 +24,7 @@ class AwsOrganization extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string id = 1; */ - protected $id = ''; + private $id = ''; /** * Constructor. diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsOrganizationalUnit.php b/SecurityCenter/src/V2/AwsMetadata/AwsOrganizationalUnit.php similarity index 98% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsOrganizationalUnit.php rename to SecurityCenter/src/V2/AwsMetadata/AwsOrganizationalUnit.php index 17f3c6caf448..1c2941130ea2 100644 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AwsMetadata/AwsOrganizationalUnit.php +++ b/SecurityCenter/src/V2/AwsMetadata/AwsOrganizationalUnit.php @@ -26,13 +26,13 @@ class AwsOrganizationalUnit extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string id = 1; */ - protected $id = ''; + private $id = ''; /** * The friendly name of the OU. * * Generated from protobuf field string name = 2; */ - protected $name = ''; + private $name = ''; /** * Constructor. diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata.php b/SecurityCenter/src/V2/AzureMetadata.php similarity index 98% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata.php rename to SecurityCenter/src/V2/AzureMetadata.php index 5d61d1e0f4a3..105a6924d1c1 100644 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata.php +++ b/SecurityCenter/src/V2/AzureMetadata.php @@ -28,13 +28,13 @@ class AzureMetadata extends \Google\Protobuf\Internal\Message * * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata.AzureSubscription subscription = 2; */ - protected $subscription = null; + private $subscription = null; /** * The Azure resource group associated with the resource. * * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata.AzureResourceGroup resource_group = 3; */ - protected $resource_group = null; + private $resource_group = null; /** * Constructor. diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureManagementGroup.php b/SecurityCenter/src/V2/AzureMetadata/AzureManagementGroup.php similarity index 98% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureManagementGroup.php rename to SecurityCenter/src/V2/AzureMetadata/AzureManagementGroup.php index dfc80438bc75..3c5e0ce771bf 100644 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureManagementGroup.php +++ b/SecurityCenter/src/V2/AzureMetadata/AzureManagementGroup.php @@ -21,13 +21,13 @@ class AzureManagementGroup extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string id = 1; */ - protected $id = ''; + private $id = ''; /** * The display name of the Azure management group. * * Generated from protobuf field string display_name = 2; */ - protected $display_name = ''; + private $display_name = ''; /** * Constructor. diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureResourceGroup.php b/SecurityCenter/src/V2/AzureMetadata/AzureResourceGroup.php similarity index 98% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureResourceGroup.php rename to SecurityCenter/src/V2/AzureMetadata/AzureResourceGroup.php index 7be762cc406b..e5e43d4ea77d 100644 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureResourceGroup.php +++ b/SecurityCenter/src/V2/AzureMetadata/AzureResourceGroup.php @@ -20,7 +20,7 @@ class AzureResourceGroup extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string name = 1; */ - protected $name = ''; + private $name = ''; /** * Constructor. diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureSubscription.php b/SecurityCenter/src/V2/AzureMetadata/AzureSubscription.php similarity index 98% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureSubscription.php rename to SecurityCenter/src/V2/AzureMetadata/AzureSubscription.php index 29b8e99fef59..574fc4fbc544 100644 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AzureMetadata/AzureSubscription.php +++ b/SecurityCenter/src/V2/AzureMetadata/AzureSubscription.php @@ -21,13 +21,13 @@ class AzureSubscription extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string id = 1; */ - protected $id = ''; + private $id = ''; /** * The display name of the Azure subscription. * * Generated from protobuf field string display_name = 2; */ - protected $display_name = ''; + private $display_name = ''; /** * Constructor. diff --git a/SecurityCenter/src/V2/BatchCreateResourceValueConfigsRequest.php b/SecurityCenter/src/V2/BatchCreateResourceValueConfigsRequest.php index e62664cbf26a..3b16520319c1 100644 --- a/SecurityCenter/src/V2/BatchCreateResourceValueConfigsRequest.php +++ b/SecurityCenter/src/V2/BatchCreateResourceValueConfigsRequest.php @@ -34,7 +34,7 @@ class BatchCreateResourceValueConfigsRequest extends \Google\Protobuf\Internal\M * @param string $parent Required. Resource name of the new ResourceValueConfig's parent. * The parent field in the CreateResourceValueConfigRequest * messages must either be empty or match this field. Please see - * {@see SecurityCenterClient::organizationName()} for help formatting this field. + * {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. * @param \Google\Cloud\SecurityCenter\V2\CreateResourceValueConfigRequest[] $requests Required. The resource value configs to be created. * * @return \Google\Cloud\SecurityCenter\V2\BatchCreateResourceValueConfigsRequest diff --git a/SecurityCenter/src/V2/Client/SecurityCenterClient.php b/SecurityCenter/src/V2/Client/SecurityCenterClient.php index 2f41e7df8dab..07df517a9ec6 100644 --- a/SecurityCenter/src/V2/Client/SecurityCenterClient.php +++ b/SecurityCenter/src/V2/Client/SecurityCenterClient.php @@ -774,6 +774,65 @@ public static function organizationLocationNotificationConfigName(string $organi ]); } + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_resource_value_config resource. + * + * @param string $organization + * @param string $location + * @param string $resourceValueConfig + * + * @return string The formatted organization_location_resource_value_config resource. + */ + public static function organizationLocationResourceValueConfigName(string $organization, string $location, string $resourceValueConfig): string + { + return self::getPathTemplate('organizationLocationResourceValueConfig')->render([ + 'organization' => $organization, + 'location' => $location, + 'resource_value_config' => $resourceValueConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_simluation resource. + * + * @param string $organization + * @param string $location + * @param string $simluation + * + * @return string The formatted organization_location_simluation resource. + */ + public static function organizationLocationSimluationName(string $organization, string $location, string $simluation): string + { + return self::getPathTemplate('organizationLocationSimluation')->render([ + 'organization' => $organization, + 'location' => $location, + 'simluation' => $simluation, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_location_simluation_valued_resource resource. + * + * @param string $organization + * @param string $location + * @param string $simluation + * @param string $valuedResource + * + * @return string The formatted organization_location_simluation_valued_resource resource. + */ + public static function organizationLocationSimluationValuedResourceName(string $organization, string $location, string $simluation, string $valuedResource): string + { + return self::getPathTemplate('organizationLocationSimluationValuedResource')->render([ + 'organization' => $organization, + 'location' => $location, + 'simluation' => $simluation, + 'valued_resource' => $valuedResource, + ]); + } + /** * Formats a string containing the fully-qualified path to represent a * organization_mute_config resource. @@ -791,6 +850,59 @@ public static function organizationMuteConfigName(string $organization, string $ ]); } + /** + * Formats a string containing the fully-qualified path to represent a + * organization_resource_value_config resource. + * + * @param string $organization + * @param string $resourceValueConfig + * + * @return string The formatted organization_resource_value_config resource. + */ + public static function organizationResourceValueConfigName(string $organization, string $resourceValueConfig): string + { + return self::getPathTemplate('organizationResourceValueConfig')->render([ + 'organization' => $organization, + 'resource_value_config' => $resourceValueConfig, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_simulation resource. + * + * @param string $organization + * @param string $simulation + * + * @return string The formatted organization_simulation resource. + */ + public static function organizationSimulationName(string $organization, string $simulation): string + { + return self::getPathTemplate('organizationSimulation')->render([ + 'organization' => $organization, + 'simulation' => $simulation, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * organization_simulation_valued_resource resource. + * + * @param string $organization + * @param string $simulation + * @param string $valuedResource + * + * @return string The formatted organization_simulation_valued_resource resource. + */ + public static function organizationSimulationValuedResourceName(string $organization, string $simulation, string $valuedResource): string + { + return self::getPathTemplate('organizationSimulationValuedResource')->render([ + 'organization' => $organization, + 'simulation' => $simulation, + 'valued_resource' => $valuedResource, + ]); + } + /** * Formats a string containing the fully-qualified path to represent a * organization_source resource. @@ -932,6 +1044,27 @@ public static function organizationSourceLocationFindingSecurityMarksName(string ]); } + /** + * Formats a string containing the fully-qualified path to represent a + * organization_valued_resource resource. + * + * @param string $organization + * @param string $location + * @param string $simulation + * @param string $valuedResource + * + * @return string The formatted organization_valued_resource resource. + */ + public static function organizationValuedResourceName(string $organization, string $location, string $simulation, string $valuedResource): string + { + return self::getPathTemplate('organizationValuedResource')->render([ + 'organization' => $organization, + 'location' => $location, + 'simulation' => $simulation, + 'valued_resource' => $valuedResource, + ]); + } + /** * Formats a string containing the fully-qualified path to represent a policy * resource. @@ -1439,7 +1572,13 @@ public static function valuedResourceName(string $organization, string $simulati * - organizationLocationExport: organizations/{organization}/locations/{location}/bigQueryExports/{export} * - organizationLocationMuteConfig: organizations/{organization}/locations/{location}/muteConfigs/{mute_config} * - organizationLocationNotificationConfig: organizations/{organization}/locations/{location}/notificationConfigs/{notification_config} + * - organizationLocationResourceValueConfig: organizations/{organization}/locations/{location}/resourceValueConfigs/{resource_value_config} + * - organizationLocationSimluation: organizations/{organization}/locations/{location}/simulations/{simluation} + * - organizationLocationSimluationValuedResource: organizations/{organization}/locations/{location}/simulations/{simluation}/valuedResources/{valued_resource} * - organizationMuteConfig: organizations/{organization}/muteConfigs/{mute_config} + * - organizationResourceValueConfig: organizations/{organization}/resourceValueConfigs/{resource_value_config} + * - organizationSimulation: organizations/{organization}/simulations/{simulation} + * - organizationSimulationValuedResource: organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource} * - organizationSource: organizations/{organization}/sources/{source} * - organizationSourceFinding: organizations/{organization}/sources/{source}/findings/{finding} * - organizationSourceFindingExternalsystem: organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} @@ -1447,6 +1586,7 @@ public static function valuedResourceName(string $organization, string $simulati * - organizationSourceLocationFinding: organizations/{organization}/sources/{source}/locations/{location}/findings/{finding} * - organizationSourceLocationFindingExternalsystem: organizations/{organization}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem} * - organizationSourceLocationFindingSecurityMarks: organizations/{organization}/sources/{source}/locations/{location}/findings/{finding}/securityMarks + * - organizationValuedResource: organizations/{organization}/locations/{location}/simulations/{simulation}/valuedResources/{valued_resource} * - policy: organizations/{organization}/policies/{constraint_name} * - project: projects/{project} * - projectAssetSecurityMarks: projects/{project}/assets/{asset}/securityMarks diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudArmor.php b/SecurityCenter/src/V2/CloudArmor.php similarity index 98% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudArmor.php rename to SecurityCenter/src/V2/CloudArmor.php index 6c2d8f970b52..514d2545cac7 100644 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudArmor.php +++ b/SecurityCenter/src/V2/CloudArmor.php @@ -22,7 +22,7 @@ class CloudArmor extends \Google\Protobuf\Internal\Message * * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityPolicy security_policy = 1; */ - protected $security_policy = null; + private $security_policy = null; /** * Information about incoming requests evaluated by [Google Cloud Armor * security @@ -30,7 +30,7 @@ class CloudArmor extends \Google\Protobuf\Internal\Message * * Generated from protobuf field .google.cloud.securitycenter.v2.Requests requests = 2; */ - protected $requests = null; + private $requests = null; /** * Information about potential Layer 7 DDoS attacks identified by [Google * Cloud Armor Adaptive @@ -38,13 +38,13 @@ class CloudArmor extends \Google\Protobuf\Internal\Message * * Generated from protobuf field .google.cloud.securitycenter.v2.AdaptiveProtection adaptive_protection = 3; */ - protected $adaptive_protection = null; + private $adaptive_protection = null; /** * Information about DDoS attack volume and classification. * * Generated from protobuf field .google.cloud.securitycenter.v2.Attack attack = 4; */ - protected $attack = null; + private $attack = null; /** * Distinguish between volumetric & protocol DDoS attack and * application layer attacks. For example, "L3_4" for Layer 3 and Layer 4 DDoS @@ -52,14 +52,14 @@ class CloudArmor extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string threat_vector = 5; */ - protected $threat_vector = ''; + private $threat_vector = ''; /** * Duration of attack from the start until the current moment (updated every 5 * minutes). * * Generated from protobuf field .google.protobuf.Duration duration = 6; */ - protected $duration = null; + private $duration = null; /** * Constructor. diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudProvider.php b/SecurityCenter/src/V2/CloudProvider.php similarity index 100% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudProvider.php rename to SecurityCenter/src/V2/CloudProvider.php diff --git a/SecurityCenter/src/V2/Finding.php b/SecurityCenter/src/V2/Finding.php index 0407a4a9fed4..baf0e8c66dab 100644 --- a/SecurityCenter/src/V2/Finding.php +++ b/SecurityCenter/src/V2/Finding.php @@ -381,6 +381,18 @@ class Finding extends \Google\Protobuf\Internal\Message * Generated from protobuf field repeated .google.cloud.securitycenter.v2.LoadBalancer load_balancers = 50; */ private $load_balancers; + /** + * Fields related to Cloud Armor findings. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudArmor cloud_armor = 51; + */ + private $cloud_armor = null; + /** + * Notebook associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Notebook notebook = 55; + */ + private $notebook = null; /** * Contains details about a group of security issues that, when the issues * occur together, represent a greater risk than when the issues occur @@ -587,6 +599,10 @@ class Finding extends \Google\Protobuf\Internal\Message * Log entries that are relevant to the finding. * @type array<\Google\Cloud\SecurityCenter\V2\LoadBalancer>|\Google\Protobuf\Internal\RepeatedField $load_balancers * The load balancers associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\CloudArmor $cloud_armor + * Fields related to Cloud Armor findings. + * @type \Google\Cloud\SecurityCenter\V2\Notebook $notebook + * Notebook associated with the finding. * @type \Google\Cloud\SecurityCenter\V2\ToxicCombination $toxic_combination * Contains details about a group of security issues that, when the issues * occur together, represent a greater risk than when the issues occur @@ -2136,6 +2152,78 @@ public function setLoadBalancers($var) return $this; } + /** + * Fields related to Cloud Armor findings. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudArmor cloud_armor = 51; + * @return \Google\Cloud\SecurityCenter\V2\CloudArmor|null + */ + public function getCloudArmor() + { + return $this->cloud_armor; + } + + public function hasCloudArmor() + { + return isset($this->cloud_armor); + } + + public function clearCloudArmor() + { + unset($this->cloud_armor); + } + + /** + * Fields related to Cloud Armor findings. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudArmor cloud_armor = 51; + * @param \Google\Cloud\SecurityCenter\V2\CloudArmor $var + * @return $this + */ + public function setCloudArmor($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\CloudArmor::class); + $this->cloud_armor = $var; + + return $this; + } + + /** + * Notebook associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Notebook notebook = 55; + * @return \Google\Cloud\SecurityCenter\V2\Notebook|null + */ + public function getNotebook() + { + return $this->notebook; + } + + public function hasNotebook() + { + return isset($this->notebook); + } + + public function clearNotebook() + { + unset($this->notebook); + } + + /** + * Notebook associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.Notebook notebook = 55; + * @param \Google\Cloud\SecurityCenter\V2\Notebook $var + * @return $this + */ + public function setNotebook($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Notebook::class); + $this->notebook = $var; + + return $this; + } + /** * Contains details about a group of security issues that, when the issues * occur together, represent a greater risk than when the issues occur diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Folder.php b/SecurityCenter/src/V2/Folder.php similarity index 97% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Folder.php rename to SecurityCenter/src/V2/Folder.php index 26ba49e37801..a2cae20d13be 100644 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Folder.php +++ b/SecurityCenter/src/V2/Folder.php @@ -22,13 +22,13 @@ class Folder extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string resource_folder = 1; */ - protected $resource_folder = ''; + private $resource_folder = ''; /** * The user defined display name for this folder. * * Generated from protobuf field string resource_folder_display_name = 2; */ - protected $resource_folder_display_name = ''; + private $resource_folder_display_name = ''; /** * Constructor. diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GcpMetadata.php b/SecurityCenter/src/V2/GcpMetadata.php similarity index 97% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GcpMetadata.php rename to SecurityCenter/src/V2/GcpMetadata.php index e9fa5e33a613..92a52afb846b 100644 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GcpMetadata.php +++ b/SecurityCenter/src/V2/GcpMetadata.php @@ -21,25 +21,25 @@ class GcpMetadata extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string project = 1; */ - protected $project = ''; + private $project = ''; /** * The project ID that the resource belongs to. * * Generated from protobuf field string project_display_name = 2; */ - protected $project_display_name = ''; + private $project_display_name = ''; /** * The full resource name of resource's parent. * * Generated from protobuf field string parent = 3; */ - protected $parent = ''; + private $parent = ''; /** * The human readable name of resource's parent. * * Generated from protobuf field string parent_display_name = 4; */ - protected $parent_display_name = ''; + private $parent_display_name = ''; /** * Output only. Contains a Folder message for each folder in the assets * ancestry. The first folder is the deepest nested folder, and the last @@ -53,7 +53,7 @@ class GcpMetadata extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string organization = 6; */ - protected $organization = ''; + private $organization = ''; /** * Constructor. diff --git a/SecurityCenter/src/V2/GroupFindingsRequest.php b/SecurityCenter/src/V2/GroupFindingsRequest.php index c1e5c83ba5c4..7c276cf7ad1b 100644 --- a/SecurityCenter/src/V2/GroupFindingsRequest.php +++ b/SecurityCenter/src/V2/GroupFindingsRequest.php @@ -84,12 +84,6 @@ class GroupFindingsRequest extends \Google\Protobuf\Internal\Message * Required. Expression that defines what assets fields to use for grouping. * The string value should follow SQL syntax: comma separated list of fields. * For example: "parent,resource_name". - * The following fields are supported: - * * resource_name - * * category - * * state - * * parent - * * severity * * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; */ @@ -137,14 +131,6 @@ class GroupFindingsRequest extends \Google\Protobuf\Internal\Message * The string value should follow SQL syntax: comma separated list of fields. * For example: "parent,resource_name". * - * The following fields are supported: - * - * * resource_name - * * category - * * state - * * parent - * * severity - * * @return \Google\Cloud\SecurityCenter\V2\GroupFindingsRequest * * @experimental @@ -223,12 +209,6 @@ public static function build(string $parent, string $groupBy): self * Required. Expression that defines what assets fields to use for grouping. * The string value should follow SQL syntax: comma separated list of fields. * For example: "parent,resource_name". - * The following fields are supported: - * * resource_name - * * category - * * state - * * parent - * * severity * @type string $page_token * The value returned by the last `GroupFindingsResponse`; indicates * that this is a continuation of a prior `GroupFindings` call, and @@ -405,12 +385,6 @@ public function setFilter($var) * Required. Expression that defines what assets fields to use for grouping. * The string value should follow SQL syntax: comma separated list of fields. * For example: "parent,resource_name". - * The following fields are supported: - * * resource_name - * * category - * * state - * * parent - * * severity * * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; * @return string @@ -424,12 +398,6 @@ public function getGroupBy() * Required. Expression that defines what assets fields to use for grouping. * The string value should follow SQL syntax: comma separated list of fields. * For example: "parent,resource_name". - * The following fields are supported: - * * resource_name - * * category - * * state - * * parent - * * severity * * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; * @param string $var diff --git a/SecurityCenter/src/V2/ListAttackPathsRequest.php b/SecurityCenter/src/V2/ListAttackPathsRequest.php index efab71d36070..cb5f28d84547 100644 --- a/SecurityCenter/src/V2/ListAttackPathsRequest.php +++ b/SecurityCenter/src/V2/ListAttackPathsRequest.php @@ -59,7 +59,7 @@ class ListAttackPathsRequest extends \Google\Protobuf\Internal\Message * "organizations/{organization}/simulations/{simulation}" * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" - * Please see {@see SecurityCenterClient::valuedResourceName()} for help formatting this field. + * Please see {@see SecurityCenterClient::organizationValuedResourceName()} for help formatting this field. * * @return \Google\Cloud\SecurityCenter\V2\ListAttackPathsRequest * diff --git a/SecurityCenter/src/V2/ListFindingsResponse/ListFindingsResult/Resource.php b/SecurityCenter/src/V2/ListFindingsResponse/ListFindingsResult/Resource.php index 170fdc61714e..e58fdf65c499 100644 --- a/SecurityCenter/src/V2/ListFindingsResponse/ListFindingsResult/Resource.php +++ b/SecurityCenter/src/V2/ListFindingsResponse/ListFindingsResult/Resource.php @@ -35,6 +35,46 @@ class Resource extends \Google\Protobuf\Internal\Message * Generated from protobuf field string type = 3; */ private $type = ''; + /** + * Indicates which cloud provider the finding is from. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; + */ + private $cloud_provider = 0; + /** + * The service or resource provider associated with the resource. + * + * Generated from protobuf field string service = 5; + */ + private $service = ''; + /** + * The region or location of the service (if applicable). + * + * Generated from protobuf field string location = 6; + */ + private $location = ''; + /** + * Provides the path to the resource within the resource hierarchy. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath resource_path = 10; + */ + private $resource_path = null; + /** + * A string representation of the resource path. + * For Google Cloud, it has the format of + * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} + * where there can be any number of folders. + * For AWS, it has the format of + * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} + * where there can be any number of organizational units. + * For Azure, it has the format of + * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} + * where there can be any number of management groups. + * + * Generated from protobuf field string resource_path_string = 11; + */ + private $resource_path_string = ''; + protected $cloud_provider_metadata; /** * Constructor. @@ -49,6 +89,31 @@ class Resource extends \Google\Protobuf\Internal\Message * The human readable name of the resource. * @type string $type * The full resource type of the resource. + * @type int $cloud_provider + * Indicates which cloud provider the finding is from. + * @type string $service + * The service or resource provider associated with the resource. + * @type string $location + * The region or location of the service (if applicable). + * @type \Google\Cloud\SecurityCenter\V2\GcpMetadata $gcp_metadata + * The GCP metadata associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\AwsMetadata $aws_metadata + * The AWS metadata associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\AzureMetadata $azure_metadata + * The Azure metadata associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\ResourcePath $resource_path + * Provides the path to the resource within the resource hierarchy. + * @type string $resource_path_string + * A string representation of the resource path. + * For Google Cloud, it has the format of + * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} + * where there can be any number of folders. + * For AWS, it has the format of + * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} + * where there can be any number of organizational units. + * For Azure, it has the format of + * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} + * where there can be any number of management groups. * } */ public function __construct($data = NULL) { @@ -136,6 +201,265 @@ public function setType($var) return $this; } + /** + * Indicates which cloud provider the finding is from. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; + * @return int + */ + public function getCloudProvider() + { + return $this->cloud_provider; + } + + /** + * Indicates which cloud provider the finding is from. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; + * @param int $var + * @return $this + */ + public function setCloudProvider($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\CloudProvider::class); + $this->cloud_provider = $var; + + return $this; + } + + /** + * The service or resource provider associated with the resource. + * + * Generated from protobuf field string service = 5; + * @return string + */ + public function getService() + { + return $this->service; + } + + /** + * The service or resource provider associated with the resource. + * + * Generated from protobuf field string service = 5; + * @param string $var + * @return $this + */ + public function setService($var) + { + GPBUtil::checkString($var, True); + $this->service = $var; + + return $this; + } + + /** + * The region or location of the service (if applicable). + * + * Generated from protobuf field string location = 6; + * @return string + */ + public function getLocation() + { + return $this->location; + } + + /** + * The region or location of the service (if applicable). + * + * Generated from protobuf field string location = 6; + * @param string $var + * @return $this + */ + public function setLocation($var) + { + GPBUtil::checkString($var, True); + $this->location = $var; + + return $this; + } + + /** + * The GCP metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.GcpMetadata gcp_metadata = 7; + * @return \Google\Cloud\SecurityCenter\V2\GcpMetadata|null + */ + public function getGcpMetadata() + { + return $this->readOneof(7); + } + + public function hasGcpMetadata() + { + return $this->hasOneof(7); + } + + /** + * The GCP metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.GcpMetadata gcp_metadata = 7; + * @param \Google\Cloud\SecurityCenter\V2\GcpMetadata $var + * @return $this + */ + public function setGcpMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\GcpMetadata::class); + $this->writeOneof(7, $var); + + return $this; + } + + /** + * The AWS metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata aws_metadata = 8; + * @return \Google\Cloud\SecurityCenter\V2\AwsMetadata|null + */ + public function getAwsMetadata() + { + return $this->readOneof(8); + } + + public function hasAwsMetadata() + { + return $this->hasOneof(8); + } + + /** + * The AWS metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata aws_metadata = 8; + * @param \Google\Cloud\SecurityCenter\V2\AwsMetadata $var + * @return $this + */ + public function setAwsMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\AwsMetadata::class); + $this->writeOneof(8, $var); + + return $this; + } + + /** + * The Azure metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata azure_metadata = 9; + * @return \Google\Cloud\SecurityCenter\V2\AzureMetadata|null + */ + public function getAzureMetadata() + { + return $this->readOneof(9); + } + + public function hasAzureMetadata() + { + return $this->hasOneof(9); + } + + /** + * The Azure metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata azure_metadata = 9; + * @param \Google\Cloud\SecurityCenter\V2\AzureMetadata $var + * @return $this + */ + public function setAzureMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\AzureMetadata::class); + $this->writeOneof(9, $var); + + return $this; + } + + /** + * Provides the path to the resource within the resource hierarchy. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath resource_path = 10; + * @return \Google\Cloud\SecurityCenter\V2\ResourcePath|null + */ + public function getResourcePath() + { + return $this->resource_path; + } + + public function hasResourcePath() + { + return isset($this->resource_path); + } + + public function clearResourcePath() + { + unset($this->resource_path); + } + + /** + * Provides the path to the resource within the resource hierarchy. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath resource_path = 10; + * @param \Google\Cloud\SecurityCenter\V2\ResourcePath $var + * @return $this + */ + public function setResourcePath($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ResourcePath::class); + $this->resource_path = $var; + + return $this; + } + + /** + * A string representation of the resource path. + * For Google Cloud, it has the format of + * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} + * where there can be any number of folders. + * For AWS, it has the format of + * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} + * where there can be any number of organizational units. + * For Azure, it has the format of + * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} + * where there can be any number of management groups. + * + * Generated from protobuf field string resource_path_string = 11; + * @return string + */ + public function getResourcePathString() + { + return $this->resource_path_string; + } + + /** + * A string representation of the resource path. + * For Google Cloud, it has the format of + * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} + * where there can be any number of folders. + * For AWS, it has the format of + * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} + * where there can be any number of organizational units. + * For Azure, it has the format of + * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} + * where there can be any number of management groups. + * + * Generated from protobuf field string resource_path_string = 11; + * @param string $var + * @return $this + */ + public function setResourcePathString($var) + { + GPBUtil::checkString($var, True); + $this->resource_path_string = $var; + + return $this; + } + + /** + * @return string + */ + public function getCloudProviderMetadata() + { + return $this->whichOneof("cloud_provider_metadata"); + } + } // Adding a class alias for backwards compatibility with the previous class name. diff --git a/SecurityCenter/src/V2/ListResourceValueConfigsRequest.php b/SecurityCenter/src/V2/ListResourceValueConfigsRequest.php index 198cb6608189..ae84858e7c34 100644 --- a/SecurityCenter/src/V2/ListResourceValueConfigsRequest.php +++ b/SecurityCenter/src/V2/ListResourceValueConfigsRequest.php @@ -48,7 +48,7 @@ class ListResourceValueConfigsRequest extends \Google\Protobuf\Internal\Message * @param string $parent Required. The parent, which owns the collection of resource value configs. * Its format is * "organizations/[organization_id]" - * Please see {@see SecurityCenterClient::organizationName()} for help formatting this field. + * Please see {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. * * @return \Google\Cloud\SecurityCenter\V2\ListResourceValueConfigsRequest * diff --git a/SecurityCenter/src/V2/MitreAttack/Technique.php b/SecurityCenter/src/V2/MitreAttack/Technique.php index 22a76a45291f..158c67ead96a 100644 --- a/SecurityCenter/src/V2/MitreAttack/Technique.php +++ b/SecurityCenter/src/V2/MitreAttack/Technique.php @@ -9,7 +9,7 @@ /** * MITRE ATT&CK techniques that can be referenced by SCC findings. * See: https://attack.mitre.org/techniques/enterprise/ - * Next ID: 59 + * Next ID: 63 * * Protobuf type google.cloud.securitycenter.v2.MitreAttack.Technique */ @@ -69,6 +69,12 @@ class Technique * Generated from protobuf enum UNIX_SHELL = 7; */ const UNIX_SHELL = 7; + /** + * T1059.006 + * + * Generated from protobuf enum PYTHON = 59; + */ + const PYTHON = 59; /** * T1069 * @@ -363,12 +369,30 @@ class Technique * Generated from protobuf enum SCANNING_IP_BLOCKS = 2; */ const SCANNING_IP_BLOCKS = 2; + /** + * T1613 + * + * Generated from protobuf enum CONTAINER_ADMINISTRATION_COMMAND = 60; + */ + const CONTAINER_ADMINISTRATION_COMMAND = 60; + /** + * T1611 + * + * Generated from protobuf enum ESCAPE_TO_HOST = 61; + */ + const ESCAPE_TO_HOST = 61; /** * T1613 * * Generated from protobuf enum CONTAINER_AND_RESOURCE_DISCOVERY = 57; */ const CONTAINER_AND_RESOURCE_DISCOVERY = 57; + /** + * T1649 + * + * Generated from protobuf enum STEAL_OR_FORGE_AUTHENTICATION_CERTIFICATES = 62; + */ + const STEAL_OR_FORGE_AUTHENTICATION_CERTIFICATES = 62; private static $valueToName = [ self::TECHNIQUE_UNSPECIFIED => 'TECHNIQUE_UNSPECIFIED', @@ -380,6 +404,7 @@ class Technique self::PROCESS_DISCOVERY => 'PROCESS_DISCOVERY', self::COMMAND_AND_SCRIPTING_INTERPRETER => 'COMMAND_AND_SCRIPTING_INTERPRETER', self::UNIX_SHELL => 'UNIX_SHELL', + self::PYTHON => 'PYTHON', self::PERMISSION_GROUPS_DISCOVERY => 'PERMISSION_GROUPS_DISCOVERY', self::CLOUD_GROUPS => 'CLOUD_GROUPS', self::APPLICATION_LAYER_PROTOCOL => 'APPLICATION_LAYER_PROTOCOL', @@ -429,7 +454,10 @@ class Technique self::OBTAIN_CAPABILITIES => 'OBTAIN_CAPABILITIES', self::ACTIVE_SCANNING => 'ACTIVE_SCANNING', self::SCANNING_IP_BLOCKS => 'SCANNING_IP_BLOCKS', + self::CONTAINER_ADMINISTRATION_COMMAND => 'CONTAINER_ADMINISTRATION_COMMAND', + self::ESCAPE_TO_HOST => 'ESCAPE_TO_HOST', self::CONTAINER_AND_RESOURCE_DISCOVERY => 'CONTAINER_AND_RESOURCE_DISCOVERY', + self::STEAL_OR_FORGE_AUTHENTICATION_CERTIFICATES => 'STEAL_OR_FORGE_AUTHENTICATION_CERTIFICATES', ]; public static function name($value) diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Notebook.php b/SecurityCenter/src/V2/Notebook.php similarity index 97% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Notebook.php rename to SecurityCenter/src/V2/Notebook.php index 91286a3b1b30..b14a264080e1 100644 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Notebook.php +++ b/SecurityCenter/src/V2/Notebook.php @@ -22,25 +22,25 @@ class Notebook extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string name = 1; */ - protected $name = ''; + private $name = ''; /** * The source notebook service, for example, "Colab Enterprise". * * Generated from protobuf field string service = 2; */ - protected $service = ''; + private $service = ''; /** * The user ID of the latest author to modify the notebook. * * Generated from protobuf field string last_author = 3; */ - protected $last_author = ''; + private $last_author = ''; /** * The most recent time the notebook was updated. * * Generated from protobuf field .google.protobuf.Timestamp notebook_update_time = 4; */ - protected $notebook_update_time = null; + private $notebook_update_time = null; /** * Constructor. diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Requests.php b/SecurityCenter/src/V2/Requests.php similarity index 97% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Requests.php rename to SecurityCenter/src/V2/Requests.php index 057e47a71238..ca0d993c914f 100644 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Requests.php +++ b/SecurityCenter/src/V2/Requests.php @@ -22,25 +22,25 @@ class Requests extends \Google\Protobuf\Internal\Message * * Generated from protobuf field double ratio = 1; */ - protected $ratio = 0.0; + private $ratio = 0.0; /** * Allowed RPS (requests per second) in the short term. * * Generated from protobuf field int32 short_term_allowed = 2; */ - protected $short_term_allowed = 0; + private $short_term_allowed = 0; /** * Allowed RPS (requests per second) over the long term. * * Generated from protobuf field int32 long_term_allowed = 3; */ - protected $long_term_allowed = 0; + private $long_term_allowed = 0; /** * Denied RPS (requests per second) over the long term. * * Generated from protobuf field int32 long_term_denied = 4; */ - protected $long_term_denied = 0; + private $long_term_denied = 0; /** * Constructor. diff --git a/SecurityCenter/src/V2/Resource.php b/SecurityCenter/src/V2/Resource.php index e2e11f0be19d..d7d3bb43b652 100644 --- a/SecurityCenter/src/V2/Resource.php +++ b/SecurityCenter/src/V2/Resource.php @@ -34,6 +34,46 @@ class Resource extends \Google\Protobuf\Internal\Message * Generated from protobuf field string type = 3; */ private $type = ''; + /** + * Indicates which cloud provider the finding is from. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; + */ + private $cloud_provider = 0; + /** + * The service or resource provider associated with the resource. + * + * Generated from protobuf field string service = 5; + */ + private $service = ''; + /** + * The region or location of the service (if applicable). + * + * Generated from protobuf field string location = 6; + */ + private $location = ''; + /** + * Provides the path to the resource within the resource hierarchy. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath resource_path = 10; + */ + private $resource_path = null; + /** + * A string representation of the resource path. + * For Google Cloud, it has the format of + * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} + * where there can be any number of folders. + * For AWS, it has the format of + * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} + * where there can be any number of organizational units. + * For Azure, it has the format of + * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} + * where there can be any number of management groups. + * + * Generated from protobuf field string resource_path_string = 11; + */ + private $resource_path_string = ''; + protected $cloud_provider_metadata; /** * Constructor. @@ -48,6 +88,31 @@ class Resource extends \Google\Protobuf\Internal\Message * The human readable name of the resource. * @type string $type * The full resource type of the resource. + * @type int $cloud_provider + * Indicates which cloud provider the finding is from. + * @type string $service + * The service or resource provider associated with the resource. + * @type string $location + * The region or location of the service (if applicable). + * @type \Google\Cloud\SecurityCenter\V2\GcpMetadata $gcp_metadata + * The GCP metadata associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\AwsMetadata $aws_metadata + * The AWS metadata associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\AzureMetadata $azure_metadata + * The Azure metadata associated with the finding. + * @type \Google\Cloud\SecurityCenter\V2\ResourcePath $resource_path + * Provides the path to the resource within the resource hierarchy. + * @type string $resource_path_string + * A string representation of the resource path. + * For Google Cloud, it has the format of + * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} + * where there can be any number of folders. + * For AWS, it has the format of + * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} + * where there can be any number of organizational units. + * For Azure, it has the format of + * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} + * where there can be any number of management groups. * } */ public function __construct($data = NULL) { @@ -135,5 +200,264 @@ public function setType($var) return $this; } + /** + * Indicates which cloud provider the finding is from. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; + * @return int + */ + public function getCloudProvider() + { + return $this->cloud_provider; + } + + /** + * Indicates which cloud provider the finding is from. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; + * @param int $var + * @return $this + */ + public function setCloudProvider($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\CloudProvider::class); + $this->cloud_provider = $var; + + return $this; + } + + /** + * The service or resource provider associated with the resource. + * + * Generated from protobuf field string service = 5; + * @return string + */ + public function getService() + { + return $this->service; + } + + /** + * The service or resource provider associated with the resource. + * + * Generated from protobuf field string service = 5; + * @param string $var + * @return $this + */ + public function setService($var) + { + GPBUtil::checkString($var, True); + $this->service = $var; + + return $this; + } + + /** + * The region or location of the service (if applicable). + * + * Generated from protobuf field string location = 6; + * @return string + */ + public function getLocation() + { + return $this->location; + } + + /** + * The region or location of the service (if applicable). + * + * Generated from protobuf field string location = 6; + * @param string $var + * @return $this + */ + public function setLocation($var) + { + GPBUtil::checkString($var, True); + $this->location = $var; + + return $this; + } + + /** + * The GCP metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.GcpMetadata gcp_metadata = 7; + * @return \Google\Cloud\SecurityCenter\V2\GcpMetadata|null + */ + public function getGcpMetadata() + { + return $this->readOneof(7); + } + + public function hasGcpMetadata() + { + return $this->hasOneof(7); + } + + /** + * The GCP metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.GcpMetadata gcp_metadata = 7; + * @param \Google\Cloud\SecurityCenter\V2\GcpMetadata $var + * @return $this + */ + public function setGcpMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\GcpMetadata::class); + $this->writeOneof(7, $var); + + return $this; + } + + /** + * The AWS metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata aws_metadata = 8; + * @return \Google\Cloud\SecurityCenter\V2\AwsMetadata|null + */ + public function getAwsMetadata() + { + return $this->readOneof(8); + } + + public function hasAwsMetadata() + { + return $this->hasOneof(8); + } + + /** + * The AWS metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata aws_metadata = 8; + * @param \Google\Cloud\SecurityCenter\V2\AwsMetadata $var + * @return $this + */ + public function setAwsMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\AwsMetadata::class); + $this->writeOneof(8, $var); + + return $this; + } + + /** + * The Azure metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata azure_metadata = 9; + * @return \Google\Cloud\SecurityCenter\V2\AzureMetadata|null + */ + public function getAzureMetadata() + { + return $this->readOneof(9); + } + + public function hasAzureMetadata() + { + return $this->hasOneof(9); + } + + /** + * The Azure metadata associated with the finding. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata azure_metadata = 9; + * @param \Google\Cloud\SecurityCenter\V2\AzureMetadata $var + * @return $this + */ + public function setAzureMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\AzureMetadata::class); + $this->writeOneof(9, $var); + + return $this; + } + + /** + * Provides the path to the resource within the resource hierarchy. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath resource_path = 10; + * @return \Google\Cloud\SecurityCenter\V2\ResourcePath|null + */ + public function getResourcePath() + { + return $this->resource_path; + } + + public function hasResourcePath() + { + return isset($this->resource_path); + } + + public function clearResourcePath() + { + unset($this->resource_path); + } + + /** + * Provides the path to the resource within the resource hierarchy. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath resource_path = 10; + * @param \Google\Cloud\SecurityCenter\V2\ResourcePath $var + * @return $this + */ + public function setResourcePath($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ResourcePath::class); + $this->resource_path = $var; + + return $this; + } + + /** + * A string representation of the resource path. + * For Google Cloud, it has the format of + * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} + * where there can be any number of folders. + * For AWS, it has the format of + * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} + * where there can be any number of organizational units. + * For Azure, it has the format of + * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} + * where there can be any number of management groups. + * + * Generated from protobuf field string resource_path_string = 11; + * @return string + */ + public function getResourcePathString() + { + return $this->resource_path_string; + } + + /** + * A string representation of the resource path. + * For Google Cloud, it has the format of + * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} + * where there can be any number of folders. + * For AWS, it has the format of + * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} + * where there can be any number of organizational units. + * For Azure, it has the format of + * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} + * where there can be any number of management groups. + * + * Generated from protobuf field string resource_path_string = 11; + * @param string $var + * @return $this + */ + public function setResourcePathString($var) + { + GPBUtil::checkString($var, True); + $this->resource_path_string = $var; + + return $this; + } + + /** + * @return string + */ + public function getCloudProviderMetadata() + { + return $this->whichOneof("cloud_provider_metadata"); + } + } diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourcePath.php b/SecurityCenter/src/V2/ResourcePath.php similarity index 100% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourcePath.php rename to SecurityCenter/src/V2/ResourcePath.php diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourcePath/ResourcePathNode.php b/SecurityCenter/src/V2/ResourcePath/ResourcePathNode.php similarity index 97% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourcePath/ResourcePathNode.php rename to SecurityCenter/src/V2/ResourcePath/ResourcePathNode.php index 96d25aecdc50..25f12ad83ed8 100644 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourcePath/ResourcePathNode.php +++ b/SecurityCenter/src/V2/ResourcePath/ResourcePathNode.php @@ -21,19 +21,19 @@ class ResourcePathNode extends \Google\Protobuf\Internal\Message * * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath.ResourcePathNodeType node_type = 1; */ - protected $node_type = 0; + private $node_type = 0; /** * The ID of the resource this node represents. * * Generated from protobuf field string id = 2; */ - protected $id = ''; + private $id = ''; /** * The display name of the resource this node represents. * * Generated from protobuf field string display_name = 3; */ - protected $display_name = ''; + private $display_name = ''; /** * Constructor. diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourcePath/ResourcePathNodeType.php b/SecurityCenter/src/V2/ResourcePath/ResourcePathNodeType.php similarity index 100% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourcePath/ResourcePathNodeType.php rename to SecurityCenter/src/V2/ResourcePath/ResourcePathNodeType.php diff --git a/SecurityCenter/src/V2/ResourceValueConfig.php b/SecurityCenter/src/V2/ResourceValueConfig.php index d98172f159cc..e1a33c514f09 100644 --- a/SecurityCenter/src/V2/ResourceValueConfig.php +++ b/SecurityCenter/src/V2/ResourceValueConfig.php @@ -9,15 +9,15 @@ use Google\Protobuf\Internal\GPBUtil; /** - * A resource value config (RVC) is a mapping configuration of user's resources - * to resource values. Used in Attack path simulations. + * A resource value configuration (RVC) is a mapping configuration of user's + * resources to resource values. Used in Attack path simulations. * * Generated from protobuf message google.cloud.securitycenter.v2.ResourceValueConfig */ class ResourceValueConfig extends \Google\Protobuf\Internal\Message { /** - * Name for the resource value config + * Name for the resource value configuration * * Generated from protobuf field string name = 1; */ @@ -30,9 +30,9 @@ class ResourceValueConfig extends \Google\Protobuf\Internal\Message */ private $resource_value = 0; /** - * Required. Tag values combined with AND to check against. + * Required. Tag values combined with AND to check against. * Values in the form "tagValues/123" - * E.g. [ "tagValues/123", "tagValues/456", "tagValues/789" ] + * Example: [ "tagValues/123", "tagValues/456", "tagValues/789" ] * https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing * * Generated from protobuf field repeated string tag_values = 3 [(.google.api.field_behavior) = REQUIRED]; @@ -40,49 +40,56 @@ class ResourceValueConfig extends \Google\Protobuf\Internal\Message private $tag_values; /** * Apply resource_value only to resources that match resource_type. - * resource_type will be checked with "AND" of other resources. - * E.g. "storage.googleapis.com/Bucket" with resource_value "HIGH" will - * apply "HIGH" value only to "storage.googleapis.com/Bucket" resources. + * resource_type will be checked with AND of other resources. + * For example, "storage.googleapis.com/Bucket" with resource_value "HIGH" + * will apply "HIGH" value only to "storage.googleapis.com/Bucket" resources. * * Generated from protobuf field string resource_type = 4; */ private $resource_type = ''; /** - * Project or folder to scope this config to. - * For example, "project/456" would apply this config only to resources in - * "project/456" - * scope will be checked with "AND" of other resources. + * Project or folder to scope this configuration to. + * For example, "project/456" would apply this configuration only to resources + * in "project/456" scope will be checked with AND of other + * resources. * * Generated from protobuf field string scope = 5; */ private $scope = ''; /** - * List of resource labels to search for, evaluated with AND. - * E.g. "resource_labels_selector": {"key": "value", "env": "prod"} - * will match resources with labels "key": "value" AND "env": "prod" + * List of resource labels to search for, evaluated with AND. + * For example, "resource_labels_selector": {"key": "value", "env": "prod"} + * will match resources with labels "key": "value" AND "env": + * "prod" * https://cloud.google.com/resource-manager/docs/creating-managing-labels * * Generated from protobuf field map resource_labels_selector = 6; */ private $resource_labels_selector; /** - * Description of the resource value config. + * Description of the resource value configuration. * * Generated from protobuf field string description = 7; */ private $description = ''; /** - * Output only. Timestamp this resource value config was created. + * Output only. Timestamp this resource value configuration was created. * * Generated from protobuf field .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; */ private $create_time = null; /** - * Output only. Timestamp this resource value config was last updated. + * Output only. Timestamp this resource value configuration was last updated. * * Generated from protobuf field .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; */ private $update_time = null; + /** + * Cloud provider this configuration applies to + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 10; + */ + private $cloud_provider = 0; /** * A mapping of the sensitivity on Sensitive Data Protection finding to * resource values. This mapping can only be used in combination with a @@ -100,36 +107,39 @@ class ResourceValueConfig extends \Google\Protobuf\Internal\Message * Optional. Data for populating the Message object. * * @type string $name - * Name for the resource value config + * Name for the resource value configuration * @type int $resource_value * Resource value level this expression represents * Only required when there is no SDP mapping in the request * @type array|\Google\Protobuf\Internal\RepeatedField $tag_values - * Required. Tag values combined with AND to check against. + * Required. Tag values combined with AND to check against. * Values in the form "tagValues/123" - * E.g. [ "tagValues/123", "tagValues/456", "tagValues/789" ] + * Example: [ "tagValues/123", "tagValues/456", "tagValues/789" ] * https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing * @type string $resource_type * Apply resource_value only to resources that match resource_type. - * resource_type will be checked with "AND" of other resources. - * E.g. "storage.googleapis.com/Bucket" with resource_value "HIGH" will - * apply "HIGH" value only to "storage.googleapis.com/Bucket" resources. + * resource_type will be checked with AND of other resources. + * For example, "storage.googleapis.com/Bucket" with resource_value "HIGH" + * will apply "HIGH" value only to "storage.googleapis.com/Bucket" resources. * @type string $scope - * Project or folder to scope this config to. - * For example, "project/456" would apply this config only to resources in - * "project/456" - * scope will be checked with "AND" of other resources. + * Project or folder to scope this configuration to. + * For example, "project/456" would apply this configuration only to resources + * in "project/456" scope will be checked with AND of other + * resources. * @type array|\Google\Protobuf\Internal\MapField $resource_labels_selector - * List of resource labels to search for, evaluated with AND. - * E.g. "resource_labels_selector": {"key": "value", "env": "prod"} - * will match resources with labels "key": "value" AND "env": "prod" + * List of resource labels to search for, evaluated with AND. + * For example, "resource_labels_selector": {"key": "value", "env": "prod"} + * will match resources with labels "key": "value" AND "env": + * "prod" * https://cloud.google.com/resource-manager/docs/creating-managing-labels * @type string $description - * Description of the resource value config. + * Description of the resource value configuration. * @type \Google\Protobuf\Timestamp $create_time - * Output only. Timestamp this resource value config was created. + * Output only. Timestamp this resource value configuration was created. * @type \Google\Protobuf\Timestamp $update_time - * Output only. Timestamp this resource value config was last updated. + * Output only. Timestamp this resource value configuration was last updated. + * @type int $cloud_provider + * Cloud provider this configuration applies to * @type \Google\Cloud\SecurityCenter\V2\ResourceValueConfig\SensitiveDataProtectionMapping $sensitive_data_protection_mapping * A mapping of the sensitivity on Sensitive Data Protection finding to * resource values. This mapping can only be used in combination with a @@ -143,7 +153,7 @@ public function __construct($data = NULL) { } /** - * Name for the resource value config + * Name for the resource value configuration * * Generated from protobuf field string name = 1; * @return string @@ -154,7 +164,7 @@ public function getName() } /** - * Name for the resource value config + * Name for the resource value configuration * * Generated from protobuf field string name = 1; * @param string $var @@ -197,9 +207,9 @@ public function setResourceValue($var) } /** - * Required. Tag values combined with AND to check against. + * Required. Tag values combined with AND to check against. * Values in the form "tagValues/123" - * E.g. [ "tagValues/123", "tagValues/456", "tagValues/789" ] + * Example: [ "tagValues/123", "tagValues/456", "tagValues/789" ] * https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing * * Generated from protobuf field repeated string tag_values = 3 [(.google.api.field_behavior) = REQUIRED]; @@ -211,9 +221,9 @@ public function getTagValues() } /** - * Required. Tag values combined with AND to check against. + * Required. Tag values combined with AND to check against. * Values in the form "tagValues/123" - * E.g. [ "tagValues/123", "tagValues/456", "tagValues/789" ] + * Example: [ "tagValues/123", "tagValues/456", "tagValues/789" ] * https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing * * Generated from protobuf field repeated string tag_values = 3 [(.google.api.field_behavior) = REQUIRED]; @@ -230,9 +240,9 @@ public function setTagValues($var) /** * Apply resource_value only to resources that match resource_type. - * resource_type will be checked with "AND" of other resources. - * E.g. "storage.googleapis.com/Bucket" with resource_value "HIGH" will - * apply "HIGH" value only to "storage.googleapis.com/Bucket" resources. + * resource_type will be checked with AND of other resources. + * For example, "storage.googleapis.com/Bucket" with resource_value "HIGH" + * will apply "HIGH" value only to "storage.googleapis.com/Bucket" resources. * * Generated from protobuf field string resource_type = 4; * @return string @@ -244,9 +254,9 @@ public function getResourceType() /** * Apply resource_value only to resources that match resource_type. - * resource_type will be checked with "AND" of other resources. - * E.g. "storage.googleapis.com/Bucket" with resource_value "HIGH" will - * apply "HIGH" value only to "storage.googleapis.com/Bucket" resources. + * resource_type will be checked with AND of other resources. + * For example, "storage.googleapis.com/Bucket" with resource_value "HIGH" + * will apply "HIGH" value only to "storage.googleapis.com/Bucket" resources. * * Generated from protobuf field string resource_type = 4; * @param string $var @@ -261,10 +271,10 @@ public function setResourceType($var) } /** - * Project or folder to scope this config to. - * For example, "project/456" would apply this config only to resources in - * "project/456" - * scope will be checked with "AND" of other resources. + * Project or folder to scope this configuration to. + * For example, "project/456" would apply this configuration only to resources + * in "project/456" scope will be checked with AND of other + * resources. * * Generated from protobuf field string scope = 5; * @return string @@ -275,10 +285,10 @@ public function getScope() } /** - * Project or folder to scope this config to. - * For example, "project/456" would apply this config only to resources in - * "project/456" - * scope will be checked with "AND" of other resources. + * Project or folder to scope this configuration to. + * For example, "project/456" would apply this configuration only to resources + * in "project/456" scope will be checked with AND of other + * resources. * * Generated from protobuf field string scope = 5; * @param string $var @@ -293,9 +303,10 @@ public function setScope($var) } /** - * List of resource labels to search for, evaluated with AND. - * E.g. "resource_labels_selector": {"key": "value", "env": "prod"} - * will match resources with labels "key": "value" AND "env": "prod" + * List of resource labels to search for, evaluated with AND. + * For example, "resource_labels_selector": {"key": "value", "env": "prod"} + * will match resources with labels "key": "value" AND "env": + * "prod" * https://cloud.google.com/resource-manager/docs/creating-managing-labels * * Generated from protobuf field map resource_labels_selector = 6; @@ -307,9 +318,10 @@ public function getResourceLabelsSelector() } /** - * List of resource labels to search for, evaluated with AND. - * E.g. "resource_labels_selector": {"key": "value", "env": "prod"} - * will match resources with labels "key": "value" AND "env": "prod" + * List of resource labels to search for, evaluated with AND. + * For example, "resource_labels_selector": {"key": "value", "env": "prod"} + * will match resources with labels "key": "value" AND "env": + * "prod" * https://cloud.google.com/resource-manager/docs/creating-managing-labels * * Generated from protobuf field map resource_labels_selector = 6; @@ -325,7 +337,7 @@ public function setResourceLabelsSelector($var) } /** - * Description of the resource value config. + * Description of the resource value configuration. * * Generated from protobuf field string description = 7; * @return string @@ -336,7 +348,7 @@ public function getDescription() } /** - * Description of the resource value config. + * Description of the resource value configuration. * * Generated from protobuf field string description = 7; * @param string $var @@ -351,7 +363,7 @@ public function setDescription($var) } /** - * Output only. Timestamp this resource value config was created. + * Output only. Timestamp this resource value configuration was created. * * Generated from protobuf field .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return \Google\Protobuf\Timestamp|null @@ -372,7 +384,7 @@ public function clearCreateTime() } /** - * Output only. Timestamp this resource value config was created. + * Output only. Timestamp this resource value configuration was created. * * Generated from protobuf field .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @param \Google\Protobuf\Timestamp $var @@ -387,7 +399,7 @@ public function setCreateTime($var) } /** - * Output only. Timestamp this resource value config was last updated. + * Output only. Timestamp this resource value configuration was last updated. * * Generated from protobuf field .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return \Google\Protobuf\Timestamp|null @@ -408,7 +420,7 @@ public function clearUpdateTime() } /** - * Output only. Timestamp this resource value config was last updated. + * Output only. Timestamp this resource value configuration was last updated. * * Generated from protobuf field .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @param \Google\Protobuf\Timestamp $var @@ -422,6 +434,32 @@ public function setUpdateTime($var) return $this; } + /** + * Cloud provider this configuration applies to + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 10; + * @return int + */ + public function getCloudProvider() + { + return $this->cloud_provider; + } + + /** + * Cloud provider this configuration applies to + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 10; + * @param int $var + * @return $this + */ + public function setCloudProvider($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\CloudProvider::class); + $this->cloud_provider = $var; + + return $this; + } + /** * A mapping of the sensitivity on Sensitive Data Protection finding to * resource values. This mapping can only be used in combination with a diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPolicy.php b/SecurityCenter/src/V2/SecurityPolicy.php similarity index 98% rename from owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPolicy.php rename to SecurityCenter/src/V2/SecurityPolicy.php index efb0f5344f98..78df89133868 100644 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPolicy.php +++ b/SecurityCenter/src/V2/SecurityPolicy.php @@ -23,7 +23,7 @@ class SecurityPolicy extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string name = 1; */ - protected $name = ''; + private $name = ''; /** * The type of Google Cloud Armor security policy for example, 'backend * security policy', 'edge security policy', 'network edge security policy', @@ -31,13 +31,13 @@ class SecurityPolicy extends \Google\Protobuf\Internal\Message * * Generated from protobuf field string type = 2; */ - protected $type = ''; + private $type = ''; /** * Whether or not the associated rule or policy is in preview mode. * * Generated from protobuf field bool preview = 3; */ - protected $preview = false; + private $preview = false; /** * Constructor. diff --git a/SecurityCenter/src/V2/Simulation.php b/SecurityCenter/src/V2/Simulation.php index 5c0d1c6e3752..ce32484bc932 100644 --- a/SecurityCenter/src/V2/Simulation.php +++ b/SecurityCenter/src/V2/Simulation.php @@ -35,6 +35,12 @@ class Simulation extends \Google\Protobuf\Internal\Message * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfigMetadata resource_value_configs_metadata = 3; */ private $resource_value_configs_metadata; + /** + * Indicates which cloud provider was used in this simulation. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; + */ + private $cloud_provider = 0; /** * Constructor. @@ -50,6 +56,8 @@ class Simulation extends \Google\Protobuf\Internal\Message * @type array<\Google\Cloud\SecurityCenter\V2\ResourceValueConfigMetadata>|\Google\Protobuf\Internal\RepeatedField $resource_value_configs_metadata * Resource value configurations' metadata used in this simulation. Maximum of * 100. + * @type int $cloud_provider + * Indicates which cloud provider was used in this simulation. * } */ public function __construct($data = NULL) { @@ -149,5 +157,31 @@ public function setResourceValueConfigsMetadata($var) return $this; } + /** + * Indicates which cloud provider was used in this simulation. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; + * @return int + */ + public function getCloudProvider() + { + return $this->cloud_provider; + } + + /** + * Indicates which cloud provider was used in this simulation. + * + * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; + * @param int $var + * @return $this + */ + public function setCloudProvider($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\CloudProvider::class); + $this->cloud_provider = $var; + + return $this; + } + } diff --git a/SecurityCenter/src/V2/UpdateResourceValueConfigRequest.php b/SecurityCenter/src/V2/UpdateResourceValueConfigRequest.php index 23b644494eda..ee0f1c28b29c 100644 --- a/SecurityCenter/src/V2/UpdateResourceValueConfigRequest.php +++ b/SecurityCenter/src/V2/UpdateResourceValueConfigRequest.php @@ -24,6 +24,9 @@ class UpdateResourceValueConfigRequest extends \Google\Protobuf\Internal\Message /** * The list of fields to be updated. * If empty all mutable fields will be updated. + * To update nested fields, include the top level field in the mask + * For example, to update gcp_metadata.resource_type, include the + * "gcp_metadata" field mask * * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; */ @@ -34,6 +37,10 @@ class UpdateResourceValueConfigRequest extends \Google\Protobuf\Internal\Message * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. * If empty all mutable fields will be updated. * + * To update nested fields, include the top level field in the mask + * For example, to update gcp_metadata.resource_type, include the + * "gcp_metadata" field mask + * * @return \Google\Cloud\SecurityCenter\V2\UpdateResourceValueConfigRequest * * @experimental @@ -56,6 +63,9 @@ public static function build(\Google\Cloud\SecurityCenter\V2\ResourceValueConfig * @type \Google\Protobuf\FieldMask $update_mask * The list of fields to be updated. * If empty all mutable fields will be updated. + * To update nested fields, include the top level field in the mask + * For example, to update gcp_metadata.resource_type, include the + * "gcp_metadata" field mask * } */ public function __construct($data = NULL) { @@ -102,6 +112,9 @@ public function setResourceValueConfig($var) /** * The list of fields to be updated. * If empty all mutable fields will be updated. + * To update nested fields, include the top level field in the mask + * For example, to update gcp_metadata.resource_type, include the + * "gcp_metadata" field mask * * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; * @return \Google\Protobuf\FieldMask|null @@ -124,6 +137,9 @@ public function clearUpdateMask() /** * The list of fields to be updated. * If empty all mutable fields will be updated. + * To update nested fields, include the top level field in the mask + * For example, to update gcp_metadata.resource_type, include the + * "gcp_metadata" field mask * * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; * @param \Google\Protobuf\FieldMask $var diff --git a/SecurityCenter/src/V2/resources/security_center_descriptor_config.php b/SecurityCenter/src/V2/resources/security_center_descriptor_config.php index c6c32ab3fce2..c8e952422ea3 100644 --- a/SecurityCenter/src/V2/resources/security_center_descriptor_config.php +++ b/SecurityCenter/src/V2/resources/security_center_descriptor_config.php @@ -625,7 +625,13 @@ 'organizationLocationExport' => 'organizations/{organization}/locations/{location}/bigQueryExports/{export}', 'organizationLocationMuteConfig' => 'organizations/{organization}/locations/{location}/muteConfigs/{mute_config}', 'organizationLocationNotificationConfig' => 'organizations/{organization}/locations/{location}/notificationConfigs/{notification_config}', + 'organizationLocationResourceValueConfig' => 'organizations/{organization}/locations/{location}/resourceValueConfigs/{resource_value_config}', + 'organizationLocationSimluation' => 'organizations/{organization}/locations/{location}/simulations/{simluation}', + 'organizationLocationSimluationValuedResource' => 'organizations/{organization}/locations/{location}/simulations/{simluation}/valuedResources/{valued_resource}', 'organizationMuteConfig' => 'organizations/{organization}/muteConfigs/{mute_config}', + 'organizationResourceValueConfig' => 'organizations/{organization}/resourceValueConfigs/{resource_value_config}', + 'organizationSimulation' => 'organizations/{organization}/simulations/{simulation}', + 'organizationSimulationValuedResource' => 'organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}', 'organizationSource' => 'organizations/{organization}/sources/{source}', 'organizationSourceFinding' => 'organizations/{organization}/sources/{source}/findings/{finding}', 'organizationSourceFindingExternalsystem' => 'organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}', @@ -633,6 +639,7 @@ 'organizationSourceLocationFinding' => 'organizations/{organization}/sources/{source}/locations/{location}/findings/{finding}', 'organizationSourceLocationFindingExternalsystem' => 'organizations/{organization}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem}', 'organizationSourceLocationFindingSecurityMarks' => 'organizations/{organization}/sources/{source}/locations/{location}/findings/{finding}/securityMarks', + 'organizationValuedResource' => 'organizations/{organization}/locations/{location}/simulations/{simulation}/valuedResources/{valued_resource}', 'policy' => 'organizations/{organization}/policies/{constraint_name}', 'project' => 'projects/{project}', 'projectAssetSecurityMarks' => 'projects/{project}/assets/{asset}/securityMarks', diff --git a/SecurityCenter/src/V2/resources/security_center_rest_client_config.php b/SecurityCenter/src/V2/resources/security_center_rest_client_config.php index 61e7d9d2b9db..ae5110e7ac2d 100644 --- a/SecurityCenter/src/V2/resources/security_center_rest_client_config.php +++ b/SecurityCenter/src/V2/resources/security_center_rest_client_config.php @@ -27,6 +27,13 @@ 'method' => 'post', 'uriTemplate' => '/v2/{parent=organizations/*}/resourceValueConfigs:batchCreate', 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/resourceValueConfigs:batchCreate', + 'body' => '*', + ], + ], 'placeholders' => [ 'parent' => [ 'getters' => [ @@ -312,6 +319,12 @@ 'DeleteResourceValueConfig' => [ 'method' => 'delete', 'uriTemplate' => '/v2/{name=organizations/*/resourceValueConfigs/*}', + 'additionalBindings' => [ + [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/resourceValueConfigs/*}', + ], + ], 'placeholders' => [ 'name' => [ 'getters' => [ @@ -410,6 +423,12 @@ 'GetResourceValueConfig' => [ 'method' => 'get', 'uriTemplate' => '/v2/{name=organizations/*/resourceValueConfigs/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/resourceValueConfigs/*}', + ], + ], 'placeholders' => [ 'name' => [ 'getters' => [ @@ -421,6 +440,12 @@ 'GetSimulation' => [ 'method' => 'get', 'uriTemplate' => '/v2/{name=organizations/*/simulations/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/simulations/*}', + ], + ], 'placeholders' => [ 'name' => [ 'getters' => [ @@ -443,6 +468,12 @@ 'GetValuedResource' => [ 'method' => 'get', 'uriTemplate' => '/v2/{name=organizations/*/simulations/*/valuedResources/*}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=organizations/*/locations/*/simulations/*/valuedResources/*}', + ], + ], 'placeholders' => [ 'name' => [ 'getters' => [ @@ -498,10 +529,18 @@ 'method' => 'get', 'uriTemplate' => '/v2/{parent=organizations/*/simulations/*/valuedResources/*}/attackPaths', ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*/simulations/*/valuedResources/*}/attackPaths', + ], [ 'method' => 'get', 'uriTemplate' => '/v2/{parent=organizations/*/simulations/*/attackExposureResults/*}/attackPaths', ], + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*/simulations/*/attackExposureResults/*}/attackPaths', + ], ], 'placeholders' => [ 'parent' => [ @@ -622,6 +661,12 @@ 'ListResourceValueConfigs' => [ 'method' => 'get', 'uriTemplate' => '/v2/{parent=organizations/*}/resourceValueConfigs', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/resourceValueConfigs', + ], + ], 'placeholders' => [ 'parent' => [ 'getters' => [ @@ -944,6 +989,13 @@ 'method' => 'patch', 'uriTemplate' => '/v2/{resource_value_config.name=organizations/*/resourceValueConfigs/*}', 'body' => 'resource_value_config', + 'additionalBindings' => [ + [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{resource_value_config.name=organizations/*/locations/*/resourceValueConfigs/*}', + 'body' => 'resource_value_config', + ], + ], 'placeholders' => [ 'resource_value_config.name' => [ 'getters' => [ diff --git a/SecurityCenter/tests/Unit/V2/Client/SecurityCenterClientTest.php b/SecurityCenter/tests/Unit/V2/Client/SecurityCenterClientTest.php index 1fa344e78293..b3717581d42b 100644 --- a/SecurityCenter/tests/Unit/V2/Client/SecurityCenterClientTest.php +++ b/SecurityCenter/tests/Unit/V2/Client/SecurityCenterClientTest.php @@ -144,7 +144,7 @@ public function batchCreateResourceValueConfigsTest() $expectedResponse = new BatchCreateResourceValueConfigsResponse(); $transport->addResponse($expectedResponse); // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); $requests = []; $request = (new BatchCreateResourceValueConfigsRequest()) ->setParent($formattedParent) @@ -182,7 +182,7 @@ public function batchCreateResourceValueConfigsExceptionTest() ], JSON_PRETTY_PRINT); $transport->addResponse(null, $status); // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); $requests = []; $request = (new BatchCreateResourceValueConfigsRequest()) ->setParent($formattedParent) @@ -1650,7 +1650,7 @@ public function listAttackPathsTest() $expectedResponse->setAttackPaths($attackPaths); $transport->addResponse($expectedResponse); // Mock request - $formattedParent = $gapicClient->valuedResourceName('[ORGANIZATION]', '[SIMULATION]', '[VALUED_RESOURCE]'); + $formattedParent = $gapicClient->organizationValuedResourceName('[ORGANIZATION]', '[LOCATION]', '[SIMULATION]', '[VALUED_RESOURCE]'); $request = (new ListAttackPathsRequest()) ->setParent($formattedParent); $response = $gapicClient->listAttackPaths($request); @@ -1687,7 +1687,7 @@ public function listAttackPathsExceptionTest() ], JSON_PRETTY_PRINT); $transport->addResponse(null, $status); // Mock request - $formattedParent = $gapicClient->valuedResourceName('[ORGANIZATION]', '[SIMULATION]', '[VALUED_RESOURCE]'); + $formattedParent = $gapicClient->organizationValuedResourceName('[ORGANIZATION]', '[LOCATION]', '[SIMULATION]', '[VALUED_RESOURCE]'); $request = (new ListAttackPathsRequest()) ->setParent($formattedParent); try { @@ -2012,7 +2012,7 @@ public function listResourceValueConfigsTest() $expectedResponse->setResourceValueConfigs($resourceValueConfigs); $transport->addResponse($expectedResponse); // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); $request = (new ListResourceValueConfigsRequest()) ->setParent($formattedParent); $response = $gapicClient->listResourceValueConfigs($request); @@ -2049,7 +2049,7 @@ public function listResourceValueConfigsExceptionTest() ], JSON_PRETTY_PRINT); $transport->addResponse(null, $status); // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); $request = (new ListResourceValueConfigsRequest()) ->setParent($formattedParent); try { @@ -3131,7 +3131,7 @@ public function batchCreateResourceValueConfigsAsyncTest() $expectedResponse = new BatchCreateResourceValueConfigsResponse(); $transport->addResponse($expectedResponse); // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); + $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); $requests = []; $request = (new BatchCreateResourceValueConfigsRequest()) ->setParent($formattedParent) diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Access.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Access.php deleted file mode 100644 index 878958841e81..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Access.php +++ /dev/null @@ -1,45 +0,0 @@ -internalAddGeneratedFile( - ' -Á -+google/cloud/securitycenter/v1/access.protogoogle.cloud.securitycenter.v1"‰ -Access -principal_email (  - caller_ip ( B - caller_ip_geo ( 2+.google.cloud.securitycenter.v1.Geolocation -user_agent_family (  - -user_agent (  - service_name (  - method_name (  -principal_subject (  -service_account_key_name ( e -service_account_delegation_info ( 2<.google.cloud.securitycenter.v1.ServiceAccountDelegationInfo - user_name ( "R -ServiceAccountDelegationInfo -principal_email (  -principal_subject ( "" - Geolocation - region_code ( Bå -"com.google.cloud.securitycenter.v1B AccessProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Application.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Application.php deleted file mode 100644 index ac621b34fd25..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Application.php +++ /dev/null @@ -1,30 +0,0 @@ -internalAddGeneratedFile( - ' -ú -0google/cloud/securitycenter/v1/application.protogoogle.cloud.securitycenter.v1"1 - Application -base_uri (  -full_uri ( Bê -"com.google.cloud.securitycenter.v1BApplicationProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Asset.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Asset.php deleted file mode 100644 index 71df8833b9fd..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Asset.php +++ /dev/null @@ -1,60 +0,0 @@ -internalAddGeneratedFile( - ' -ü -*google/cloud/securitycenter/v1/asset.protogoogle.cloud.securitycenter.v1+google/cloud/securitycenter/v1/folder.proto3google/cloud/securitycenter/v1/security_marks.protogoogle/protobuf/struct.protogoogle/protobuf/timestamp.proto"© -Asset -name ( b -security_center_properties ( 2>.google.cloud.securitycenter.v1.Asset.SecurityCenterPropertiesZ -resource_properties ( 2=.google.cloud.securitycenter.v1.Asset.ResourcePropertiesEntryE -security_marks ( 2-.google.cloud.securitycenter.v1.SecurityMarks/ - create_time ( 2.google.protobuf.Timestamp/ - update_time - ( 2.google.protobuf.TimestampC - -iam_policy ( 2/.google.cloud.securitycenter.v1.Asset.IamPolicy -canonical_name ( ¹ -SecurityCenterProperties - resource_name (  - resource_type (  -resource_parent (  -resource_project (  -resource_owners (  -resource_display_name ( $ -resource_parent_display_name ( % -resource_project_display_name ( 7 -folders - ( 2&.google.cloud.securitycenter.v1.Folder - IamPolicy - policy_blob ( Q -ResourcePropertiesEntry -key ( % -value ( 2.google.protobuf.Value:8:šêA– -#securitycenter.googleapis.com/Asset+organizations/{organization}/assets/{asset}folders/{folder}/assets/{asset}!projects/{project}/assets/{asset}BØ -"com.google.cloud.securitycenter.v1PZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/BackupDisasterRecovery.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/BackupDisasterRecovery.php deleted file mode 100644 index 8b92fdb20c0d..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/BackupDisasterRecovery.php +++ /dev/null @@ -1,40 +0,0 @@ -internalAddGeneratedFile( - ' -è -=google/cloud/securitycenter/v1/backup_disaster_recovery.protogoogle.cloud.securitycenter.v1"† -BackupDisasterRecovery -backup_template (  -policies (  -host (  - applications (  - storage_pool (  -policy_options (  -profile (  - appliance (  - backup_type ( 6 -backup_create_time - ( 2.google.protobuf.TimestampBõ -"com.google.cloud.securitycenter.v1BBackupDisasterRecoveryProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/BigqueryExport.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/BigqueryExport.php deleted file mode 100644 index d05399eac4ce..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/BigqueryExport.php +++ /dev/null @@ -1,40 +0,0 @@ -internalAddGeneratedFile( - ' -Ê -4google/cloud/securitycenter/v1/bigquery_export.protogoogle.cloud.securitycenter.v1google/api/resource.protogoogle/protobuf/timestamp.proto"½ -BigQueryExport -name (  - description (  -filter (  -dataset ( 4 - create_time ( 2.google.protobuf.TimestampBàA4 - update_time ( 2.google.protobuf.TimestampBàA -most_recent_editor ( BàA - principal ( BàA:ÁêA½ -,securitycenter.googleapis.com/BigQueryExport5organizations/{organization}/bigQueryExports/{export})folders/{folder}/bigQueryExports/{export}+projects/{project}/bigQueryExports/{export}Bí -"com.google.cloud.securitycenter.v1BBigQueryExportProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudArmor.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudArmor.php deleted file mode 100644 index 1831a22fd0be..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudArmor.php +++ /dev/null @@ -1,54 +0,0 @@ -internalAddGeneratedFile( - ' -Æ -0google/cloud/securitycenter/v1/cloud_armor.protogoogle.cloud.securitycenter.v1"Þ - -CloudArmorG -security_policy ( 2..google.cloud.securitycenter.v1.SecurityPolicy: -requests ( 2(.google.cloud.securitycenter.v1.RequestsO -adaptive_protection ( 22.google.cloud.securitycenter.v1.AdaptiveProtection6 -attack ( 2&.google.cloud.securitycenter.v1.Attack - threat_vector ( + -duration ( 2.google.protobuf.Duration"= -SecurityPolicy -name (  -type (  -preview ("j -Requests -ratio ( -short_term_allowed ( -long_term_allowed ( -long_term_denied ("( -AdaptiveProtection - -confidence ("H -Attack - -volume_pps ( - -volume_bps ( -classification ( Bé -"com.google.cloud.securitycenter.v1BCloudArmorProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudDlpDataProfile.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudDlpDataProfile.php deleted file mode 100644 index 36164f95b221e61def775212a3f99a19329bd29a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1395 zcmbtUU2oGc6s1Lg@FrA+2PPp+-UnKdAf@n@vZ1uiN+;1qU6{laDRN!6Gsjk;ar+cqGIqWEC2UbWlkcO=GUkDT@?~ zD`(YwKNy5E7!XAQz#jshsp}vVkyDmPLK$wk^$$#uEXZ$ZNWYOm`iBdU{!z7t5DiI^ zVEw-t$|mHvIWD?D7#^ASLr!s`h=SKPPXZos#YxD&z)^Sckc0^Xoa?c}G@^=&2xkf1 zh_do?oMUFO+fsluyLieFswx3W`R(ku5efY!OK8lc60r-RmNjB(rg64Yem*Ii!SNw3 z=Nv8T8p&O(;*`x-$2evxjiZ|8odJwzD}RZ8w&Z?~P5NYA9_TV(pXcQspRl(FgBjU< z=u&wGpB39dzwV*hf3(|J&y!6(E9T;?m}k|^-v#t|NmGqIv^qaLYXw{=KdhJk*w4@w zOqQ9$63G)2=C$IHe#qvA!Z<`LlEg5QfjXCLtqAFlUhhrPZen9DVPd)(#siei_Xu5n z8Bfs@*X}tTFYrFOPVljF=sJz|e%oo5?ieMs+U>RMPW#yQ+TBj6V631AZm)abG`v!= z{`D@}1m3sssjn>|qzBL~93SM8PW1&5M&ha&K_BqrqUy3=ySnkcxZcwK%LOo}{%dGU zn@80j(*S?s(3wT^5Fb4Hv$&CiSe9mOS&J~11u^!w!oT(J72Fn|8C6N;VzL@nRMuoT zes-I{zW$uvE@Q)4k`W3D*MW#2db+#?rhgw`lz6i<^TCVUlye@w(Z4z}x7rwu5&8>; Cs@xj@ diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudDlpInspection.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudDlpInspection.php deleted file mode 100644 index d5020e24d7c5..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/CloudDlpInspection.php +++ /dev/null @@ -1,35 +0,0 @@ -internalAddGeneratedFile( - ' -á -9google/cloud/securitycenter/v1/cloud_dlp_inspection.protogoogle.cloud.securitycenter.v1"ˆ -CloudDlpInspection3 - inspect_job ( BúA -dlp.googleapis.com/DlpJob - info_type (  -info_type_count ( - full_scan (Bð -"com.google.cloud.securitycenter.v1BCloudDlpInspectionProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1êA| -dlp.googleapis.com/DlpJob$projects/{project}/dlpJobs/{dlp_job}9projects/{project}/locations/{location}/dlpJobs/{dlp_job}bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Compliance.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Compliance.php deleted file mode 100644 index eb7e2081031a..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Compliance.php +++ /dev/null @@ -1,32 +0,0 @@ -internalAddGeneratedFile( - ' -ƒ -/google/cloud/securitycenter/v1/compliance.protogoogle.cloud.securitycenter.v1"< - -Compliance -standard (  -version (  -ids ( Bé -"com.google.cloud.securitycenter.v1BComplianceProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Connection.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Connection.php deleted file mode 100644 index ecd7c31729ab4384d95f3c1c55c7abcc70256cbe..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1150 zcmb7D(Qeu>6djay)RVe2niW>|g&ICg&gyUo~ z!5ktsi%5vM1!1cPFMC7SZgq!;vNdK2N7#l_#-<^zqL3v)HO466MBE`v1?JV;S`{%$ zF%pDPOLGH2{TYrUA7R*Wn-^I4fiHZoqiH-x(RhOm8t=MR2LOeB9789g1784?zbF}p z1i@JNLjE0*ctj`>#1F}5`Kkt-_+gA?`$Oy`p;{MI4Lyo*dKvXYuZ3g8NhBC|CDgX3SY+c=mCDKDT17`Du##%D?FS+oQ1Aq=-wq+iBH^^I zbt{5-cGAjTzaVJA<9;6MHHr3iR)w->fzvcm0Ibps4 zdjXCGq0$3JM3tksT@Ku~(>?FDTgD@^2nt>2!ZmW{ zW3V-JTw_Nau3E0KuMVAl+o-BTd*B+U&7V0?mg)G1oaWP&9xcJmefp4&b@>i9lm6UK zjvo;jp3TWe^R%5SLxEO?f4(}TO-p|o`X36zX7qZa^wI2 diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ContactDetails.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ContactDetails.php deleted file mode 100644 index 894ca1d04c11..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ContactDetails.php +++ /dev/null @@ -1,31 +0,0 @@ -internalAddGeneratedFile( - ' -µ -4google/cloud/securitycenter/v1/contact_details.protogoogle.cloud.securitycenter.v1"K -ContactDetails9 -contacts ( 2\'.google.cloud.securitycenter.v1.Contact" -Contact -email ( Bí -"com.google.cloud.securitycenter.v1BContactDetailsProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Container.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Container.php deleted file mode 100644 index f3cfed09c352..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Container.php +++ /dev/null @@ -1,35 +0,0 @@ -internalAddGeneratedFile( - ' -‡ -.google/cloud/securitycenter/v1/container.protogoogle.cloud.securitycenter.v1google/protobuf/timestamp.proto"  - Container -name (  -uri (  -image_id ( 5 -labels ( 2%.google.cloud.securitycenter.v1.Label/ - create_time ( 2.google.protobuf.TimestampBè -"com.google.cloud.securitycenter.v1BContainerProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Database.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Database.php deleted file mode 100644 index 717d7fb26198..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Database.php +++ /dev/null @@ -1,34 +0,0 @@ -internalAddGeneratedFile( - ' -¶ --google/cloud/securitycenter/v1/database.protogoogle.cloud.securitycenter.v1"s -Database -name (  - display_name (  - user_name (  -query (  -grantees (  -version ( Bç -"com.google.cloud.securitycenter.v1B DatabaseProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/EffectiveSecurityHealthAnalyticsCustomModule.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/EffectiveSecurityHealthAnalyticsCustomModule.php deleted file mode 100644 index 81ddd71378bee6c71219d587a8597b5d7889ef2c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2124 zcmcIl%TC)s6fFsTFwi#53Q&axibRm8qtKlxt@1D-2tw4PSyYy+iG7ny<#;T690^cX zU3Aeu>8JE7y5x`bI!fzzTUofhc0@B>)?P#I9RxMg!vG#>oLwu zX5(Ja?}LX;Hgc&Ao`P}h5H}AySgSQU%i^lf0?z~$4;UNRP&928SVbSqz@z-g1c!rH z9G8k9U`$TOU?l&HArPAn4dM{{h*Q%y%)sYtWQ>><*q}r%Amoq{_%1O4*IShX;KU-F z==F$AuZC=T`vRNZEo~uW+Qj#6gq+(ralI8PEY#H-p+v$V zy#~JNQI|8XB}`Ry06fi0_@%HO(}r-gj|N^x{s{%tZrp!~-v#8EMZo2vb;HYd0jnyq% zRx0L>sN_N#ekjHo`Za^P_fx|8C5fviDX|ua~Abon;aQYh|_6^D^2wL z(v>_$FSTa5vacOz&5qITlslU7vDt2E)y7UktK}Z#XVGJ6QOix`=g^Z{qaE7UavAk& z_O$#Zi}sRa#hI6aiKP3An6AaUgp?mKZ$KP+EM^pQ{Nl;^*GW2kFZE0tIH%6QKbytp z$DcrfWLjRF#FISfGur}Bn8?FDP?%!ee-;};aKxwoPg41oK`TP*TdJ#4x=SviIo_K3 zv?tp;X#OB%#bM|H}9flinbDUc=H!hjTQm%ptnjrKCO2YD} diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Exfiltration.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Exfiltration.php deleted file mode 100644 index d61d6bcfd96e..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Exfiltration.php +++ /dev/null @@ -1,35 +0,0 @@ -internalAddGeneratedFile( - ' -® -1google/cloud/securitycenter/v1/exfiltration.protogoogle.cloud.securitycenter.v1"¯ - Exfiltration> -sources ( 2-.google.cloud.securitycenter.v1.ExfilResource> -targets ( 2-.google.cloud.securitycenter.v1.ExfilResource -total_exfiltrated_bytes ("1 - ExfilResource -name (  - -components ( Bë -"com.google.cloud.securitycenter.v1BExfiltrationProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ExternalSystem.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ExternalSystem.php deleted file mode 100644 index 831b281808d5..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ExternalSystem.php +++ /dev/null @@ -1,52 +0,0 @@ -internalAddGeneratedFile( - ' -ô -4google/cloud/securitycenter/v1/external_system.protogoogle.cloud.securitycenter.v1google/protobuf/timestamp.proto"‚ -ExternalSystem -name (  - assignees (  - external_uid (  -status ( ? -external_system_update_time ( 2.google.protobuf.Timestamp -case_uri (  - case_priority ( , -case_sla ( 2.google.protobuf.Timestamp4 -case_create_time - ( 2.google.protobuf.Timestamp3 -case_close_time ( 2.google.protobuf.TimestampN - ticket_info ( 29.google.cloud.securitycenter.v1.ExternalSystem.TicketInfo - -TicketInfo - -id (  -assignee (  - description (  -uri (  -status ( / - update_time ( 2.google.protobuf.Timestamp:ÅêAÁ -,securitycenter.googleapis.com/ExternalSystemaorganizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}Ufolders/{folder}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}Wprojects/{project}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}Bí -"com.google.cloud.securitycenter.v1BExternalSystemProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/File.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/File.php deleted file mode 100644 index 4aa4fc116a6b..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/File.php +++ /dev/null @@ -1,38 +0,0 @@ -internalAddGeneratedFile( - ' -¬ -)google/cloud/securitycenter/v1/file.protogoogle.cloud.securitycenter.v1"ð -File -path (  -size ( -sha256 (  - hashed_size ( -partially_hashed ( -contents ( @ - disk_path ( 2-.google.cloud.securitycenter.v1.File.DiskPath9 -DiskPath -partition_uuid (  - relative_path ( Bã -"com.google.cloud.securitycenter.v1B FileProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Finding.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Finding.php deleted file mode 100644 index f850bf33828727a10ee0c7df3fdc88d8dfbe8d37..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 8589 zcmb_i+j85;5sj{vhLV=T$}U*tcwxm}%WIpo=Z);iUq4^;C5FY+wU(OSKuBN}Ly*Y$0O1{qB&RkcdBp_NN|;}$?euNPP}r*%B9 z2@8`&ejDuWFyU1l-ZonN6}C& zavd5aj$}{P?}=#{oqeRO^EKvjpDc1qi-H~a+{=gLz_mK`z&~s!wtev_{1~j*PlslbU(UqG34t>=*L*K5Q%OspnpvtYBKlJ-=j! zW(a#%qn39XaNNeUKp@rK(5D#eW8j2b;MgXd zmvL~p?)cW_My3^&Ae-3E7$UIf0iO+t@$zP}J#Crc7#vpq2!Rnnt{%&|D1YRstbPjT zqI-Eex5pB+JAv2p_h`38gYbjxUw&D-*)8yzF$ONEW001{apK=W8KF+i^P*!ry8O!C z^}t~+jp!I+f7dhH1=C@Nd<@~g>vhU*G>(M3XGa0eM{v%MFYmC57txmIje)5eboM^V%vwrmHa=jh>) z2)jCnFzX8rVghW~pk^bpdqJu~CHe4sTj<7oyPe2HmN3^7VaH_NUGn$);b-`x(b~X?~j|=hD`;v)FRC8kRBiZ1-WD|%j38IC%%xDW?W&}c+ zjW{71Y?w@c3B*gugdEX!e1ly$44>;P0e&$u*iPh>fM#XTL^F*Hh=q{=Jdw_T>c?nv z`6E!7QBX|di1804o6N*gAYX#tT1mMdzp7%ns03p$366;}Xc852%AE30C(Y%Ag% zYIIrg6d+k(B_N-dNCA5$*^r3UK?52raUm2q*+!lWRy%>YA?5;Wu~(4|v80J_zd8SH z6xS_2VC`Qw$Q99CQ5MKFYtpC_+Qj<2vP5QmGk_RSC-L)DvKUtq1BXrF<5y&c^*E?H z4Ih^_ABw=bs4`{5WSKexDQPkX=Y@8>;8dMKz7?{NJz3`63YNcp8bme? z)hpW6dTMiP(x1!F(o&oE}B&+whB}K%TFm8Lg)#2%wS$t z=aDDQ8QkB{Ov)tELCKPo6;QCB1Bet*Aafzi!1`?J0*qeTd^EE40;gOfOP1++E+i_4 zZ{!j%%_})F-R;3XeucabM&;cDjPi~wif*5Q{W^6SNuG>KB7&mGdVR_(GN0s8RRN;Z z<~7mRiMoOe(zqN_lFAE`X3j8rK9oPPJy((F|Li9Zg1?Y-62QEmh3Yko z)K@Yq;whpibC}k zVxP*Ov6r#g1GoYAqK$E@D^%A;wK0Y$8u^+hO(t-C$2{dH>^3u$@8H)Y)fP=;=;x?+ z&;)O(@Y)aS^Ul`+N@U-UziEs~05GIP@lbdxj^^v0jg;Q>>G$9gfp3k-8)`mMh6Ha*FB_uvKc!Crbwxk9FPt3Rcu*NS8s_2UXj z?;U)ylzB44o|b?oMXnrF_=iblk<1@dO66_60^d!q{bPbG3<=2Jlk4zZNw4e}#oc_p zer|=ZlE&LwIo|-@WwLm9uv;nD@&$btjDdx+wdnO?wX&`69Mtj+y;^}Ke??N&LcLr& zP8wkx^+PW+nx z_XN2UXCnU6T!ahs?7|FO4zt22z73T{=}bu;0J@>QPJd%cm9V2 z;0^dK!LXzJ*30t`{x*4Y2Y*VC!PJ(Cb9E7}W6z&4jn*t?hsSr57VZQ7CV$|?Kf4gy)@NS&<4FE${*0Uv@*ADecxV6s diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Folder.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Folder.php deleted file mode 100644 index d497fe11d042..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Folder.php +++ /dev/null @@ -1,30 +0,0 @@ -internalAddGeneratedFile( - ' -† -+google/cloud/securitycenter/v1/folder.protogoogle.cloud.securitycenter.v1"G -Folder -resource_folder ( $ -resource_folder_display_name ( Bå -"com.google.cloud.securitycenter.v1B FolderProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/GroupMembership.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/GroupMembership.php deleted file mode 100644 index fac67776518bddd0cfbd4cc6d6cc68df5e24ff37..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1104 zcmbW0-HOvd6vs^wapyuy5m`i*vvpy+pea?nFty6|V?%^C!Oa$xK*`6n9Y{07WU^4D z@8EOz4!(eo;)T!PWYUJViwfo@$;|)!=FBLyajGJLhv#6QkFylllL!1cAo7b)8 zjMI!w7I+b0p3Vu=)d>hC{sO1W4>6cdcZh`_`NH>11@n42%)8uydE-_ap)mH-6wDkt zEScyF0{O5kh)D>k@P&MxkaR*4B8VT8&+>vDnEG*wCF7=cnkAtiG=V(8PD0!`gMyiB zPZ*U2>A)sCC$EvLk7wnVO#ImE<22-i3CbNQHH;Y+Wo7e~#@YJV97m?mC~`E68%cIR z@C}Lr zm-Xvb{kw+l?=_`1M5t)KSTcO5f!4V9{FVN9kiG{g{#^;ERngr7N20@ugdNl^bfDyF z`w@C*zPGQOiTlwROs+}`$eAIDTFi-}yJ6+*uO Du*PwX diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/IamBinding.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/IamBinding.php deleted file mode 100644 index e5dab7d5c25505dba260038dab0dd77a63420e5a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1059 zcmb7D(TdYR6g90>9AqtdkUlMU>%w+HQ=|BjTBU8eCBnAFt$mO{nIzNhK#~cQ$-*lA z8=w3X|3txma58Dr?Jg?jCCPBkx#!+{=FPk0GC@yaL}J3RAOU#SAT9|coC)T$5WH-; zBpiGeB{U@50I(-8p3GoqJF_E6OB&zgtxEEHpS7x zqj5mvm7&BDig85J1p5R=)BZUTIKTqCBcKAh83j+Bh znHN$YQh|kh9n*9{V=5>P>1Wwi7nV3oiKO4fF06T$dYLM>}WL^;p=q;HwUG zjK>}2I~Q1&U&`6@w{+v97X)S5Gr6l)3Cw9H=vNiJ_}?YzhXun>Yc=-QYFwGkuNp$T zRp>ob!)lfd4Ybz5OVju}-`H`Do+9dx(0$HA(x^y*hx!4kMI`bFZ&dUD=4({j;GQ78 zH<&q-@#5q7Vmcf+XU@>B-_swUYR|UonvPKI!|;4EAJ!}V9~x@P2>-)P|MAX_TJu!< z^uFkP+Xjo;D|S2HIH5A(`@>1R&h3M5mBWz=x1qvqY{NZJm&BNx-?spF6aO;*1;mvX s;AiEi5V0(!Vp;n#mNhrMnz~`HPRay4D}r?+hkwkVLKbmbqcuXm0U8KdTmS$7 diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Indicator.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Indicator.php deleted file mode 100644 index 4e0680b916cb812e13a30a8f327c6ef07bcfa538..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1746 zcmbtUVNcUQ7^VY;dx1HM=(0p|Ad!)1m*KY}8ra5|!EIrKh*?r^?QOf*wN39zG7Z1Q z@BR=!_ybJ*2gYCFwcVPHL5$Kb>#pxT&-1>|-ShIb({tbnDie#im=goF2Z;9wa$K9+ zx^1Gi*Xa-!>2}|tCUF&niZxWNHBqTpX>N$E%=TQJsHkh(U6bT=)Ao!UBf95OKG2E9 ziJQC3=cr{+9dp}N0%!mW_X%^bPEfgi_?B>NV2)em0Hsy%QCf`&l-7BE4?s6DW2iDh zgU^7(<9Kb8>WFd7#m^RH8nq~=*rcCCPy48YO-97->DrEG>73dY@;B5hon&`Vi0RjE zIkuR=J{sw&`(qI!X;u8bENr%lgy}AIL}PVPs;XVWqhb0h*_|P+4@WyF8){V5DUth# zyB-;5N601IbFIBVw-0a?y#>mizoJ7O2Zj;R9toqeQK7$W8@?n!`8S8;^{`$E991SA zRW9?JKjV;ye2^c&5_L3e7%pLqu(X6`vkCb=EEsklQ;Vfz!9o>)(XNF>TcT)ItS#=U zLuI!yDG`ez=C2F<#t1@Qf;n-}SbEM!&wQJQ)KrNLYkktU-GSD_tfxiv={S-Ed-ea> zmA3)zv4D*f9nZ)gVRe9Atht^^#^@FTx|2K5T?o`u0Xk0h0g_Qi8Xq_$eNXTtcaQJD z6X7=nUgn1ct2Z<%ufcMgT3F1rgZtDR2+Jj5xd~tpPJ&An`m(tD?hayZpjL__f{Y4@ z=#QL)c&JDmHebqPSaXO7CyQ$i?h>Z;G1q&<5a&+HN|~pyGBr_o1rm{Y>3JV!(}3lP ziOB1aX;jM9gXY<3No!uzOWIkrQ7;uLN0m}BH6v%>;kEDe(^{d_Xrv_h5v*SOc2qej zrDBJRkcf;t{3XGrh}^%7?JybLj3Aim()%~zZ5>@*yPxaY*V7m~R0Q(mg?8F|*B8FV z*26Sbf;3h}X6SvE;lpHG|49Ag|yG;18r}MUwyk diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/KernelRootkit.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/KernelRootkit.php deleted file mode 100644 index 0d7f479ab77e..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/KernelRootkit.php +++ /dev/null @@ -1,37 +0,0 @@ -internalAddGeneratedFile( - ' -¦ -3google/cloud/securitycenter/v1/kernel_rootkit.protogoogle.cloud.securitycenter.v1"× - KernelRootkit -name ( $ -unexpected_code_modification (. -&unexpected_read_only_data_modification (! -unexpected_ftrace_handler (! -unexpected_kprobe_handler ($ -unexpected_kernel_code_pages (& -unexpected_system_call_handler ($ -unexpected_interrupt_handler (( - unexpected_processes_in_runqueue (Bì -"com.google.cloud.securitycenter.v1BKernelRootkitProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Kubernetes.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Kubernetes.php deleted file mode 100644 index 53d182f98fafc58b327cec8c6f3d535f00137197..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2621 zcmbtW-EQMV6efRd_H5}!W|2ZJRDMa|EK(2_*?sQ_7u9A}c6b#2RI z7Zp@4cn5B|Mmz)$z?;AWaLt*S*lF6`&06Fp&g6XGocYdoJm={b-kAsQlQwmzZv=Ek zrk5l*qr~&wz%^Z)OvCw{`owh4Jw@DmXHc;VExOu_;qz^_LZn^=w&ScYx=h^MNNxnVPk@Y}KT&@ltc zbqELa9Fvy!iR9$5k31JusF5hKJ{JZ>(L4NPj$!Lf%1qz#0@v?jsHQDw5X;F|%KOW0 zIh{2pWtpR<-Ab}X0zahJcPGTBLFhY&B5zJ`6+h{3E}PzPoxrfL#+tS|<%%>3)rm2s zc*>X22(3PTW-XODn$2P%o}+onaq9dakKx~4s3dfa@<0MqVKa5zX6i+?^x+0Vn`bW_ zxcAErz{*F;Q^A|jHnv}7LPcJO` z11oL`uFn#19SMSgz$yUkc1rt*29(=MX<7<}ZaP=6mOEINCxAy+J$@^^&Y%?G#-698GYMt-IjMe zYzN`Nn$l-mCwef;}8=Hq@$qZ{>Y40rXSfeI@Up=$dfP@iMzP_!yprv(Nf9 z&fHzD*i~$9M?vaSB@tlQVtDQa0T!mX*MqI diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Label.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Label.php deleted file mode 100644 index 6d6184d29230..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Label.php +++ /dev/null @@ -1,31 +0,0 @@ -internalAddGeneratedFile( - ' -á -*google/cloud/securitycenter/v1/label.protogoogle.cloud.securitycenter.v1"$ -Label -name (  -value ( Bä -"com.google.cloud.securitycenter.v1B -LabelProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/LoadBalancer.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/LoadBalancer.php deleted file mode 100644 index d9a5d7eb068c..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/LoadBalancer.php +++ /dev/null @@ -1,29 +0,0 @@ -internalAddGeneratedFile( - ' -è -2google/cloud/securitycenter/v1/load_balancer.protogoogle.cloud.securitycenter.v1" - LoadBalancer -name ( Bë -"com.google.cloud.securitycenter.v1BLoadBalancerProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/LogEntry.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/LogEntry.php deleted file mode 100644 index 225e8367a89d14020930b0c644343ce1d33a1b4d..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1183 zcmb7DU2hUW6cub5nMRYYFQgC66q}SLcFESaK{Qe-)~Jw3crcrgVRqO~vdnB|XPcnm z!N231f5Sgw;;(Q%*lj8DATO}Xx#!+{?l~`Cr`IWX2K$s#i4~3DbOF^hg{c%u5Rt%X zKATYqiI}G>q0)!2H-Mi8BY4@n8Xf7n3O= zBA)06x$rGD036S0mSRF-f7ty<6^^jNVc)WZ7ltMLyv7oagEjyp!C3}Bi1^Zwfo}ln zPnu5?Mqs9}(qG3cn=sB4!wLJUSL(nSPBN;CH?gyv6U79FreMGcZJt8MX|Tts&=PcD zG1kziq7@0R%vu~LVUK1+vQ!B<)KG+Cs!A=*o95}Nt)XKx*mN@@v@v7{Dw)%}-651z z<&wAU+=gIT{tEvgS~=Z_X=xRnrwHAyb<1M6I(x-dJG_aaa^$!A#?7*cX?X&E?g0P) zj_Vydyl>6mubaWY2^tJMDlX^^!BY#HXotj%uUt~Ez)ExPJXm$!#^hV0Xf9J}9r5l# zcMsGwmvdX=dj;%ofV_QBV?3i$O;}`G)x0NQ*Hr1}s%~BL4uB`AGxvlDt}xRPsXw&; zoq?JvG_LR1Ne_xit-ZBJ{PGIj-xbi%0V)t%ROvp}d)OW9A%~SO?;WxbQ_NejxF0Q? zGM%ngLl-Tlm|sNeLT6H^dK~;J0O2ZpW%?W>)baaMJ#r)nSxFIEr$J~O cOn0pSFHTAqJ$J^wlY^}put;arC0GLR7m%xo!~g&Q diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/MitreAttack.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/MitreAttack.php deleted file mode 100644 index 7645341c03ea0e088a8ec7a8f6fd099c920c6aa0..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3195 zcmbtW+j84R5?x8L9gS^yJif^{8IqM)&V^bzo4wHMO$~t|ITnCHFaRyOST#jakj+|( z`}i1M6^he4I?I-soi9A0(5CWjV_7Rb&ZAMw{?-I+{&-N!5Ba z8oe4MyS>3^cC2#9!Q%`*#-8{nlQ zvAAJ(&~cJ!Z_*#9qe%c)tJPOYx?mJfb{-dD5w3r1?c_ODs~;r!%t|M-q#WI{CP_M* z44-CsBfz`GZ&_wv{;gl+!H

Ve6pQ&f+3Idqn?FHIjd~t&ED4k zu9Ax-G1zmmHlFlPx|6pC#0DwWm#n3owI@$1KMhnVfmEXGCHt1J1y<5~J?#HumQ2@| ztrfug`WNBNUo)Su?$HtWVg$++8BW(%GRR+(Vnl9~@#b-+>mU7=EU%CYZ<5Irl3YIr z?5%Enzf8^-q}(Jd;&vo$6Z<+4wyaCx(BCme)~&ZRyKMa@TO%7FyGD>@ryu2f~gcseHP^u8@m?2({FaK(zCS7KE}TUC|Im zXq&q{yZSM^My@!bE_@B=Ew1tX1$Kj6wL{@Ryi$}^jN(XbtCk4cl(6fB0*nYD5f9F? z^e(bBLTu%_0_p^;OY9c8W-HI*zGLt&lo^G}r5`a$E{TJ>bfYlOnPI()1H{m0Z>l52H9RG7_GqpR)VpwlAU=D%>|( zge{3GEvT`Oz#vp8PU-m1m|2;NJOU&Qp@GLB6!0&o1r)}ecK<*IKHM8EJUk%^n!=z zv%pnt)X_vrxti{x*;?F{pq*{2*ate+P^da6vax+urH?QDXp4Z|vWvk>I z+G*wU>UPSvA2nLKKgSfEoO=gjM+<`ANAO=A4V5ipA zbO-&Xb<^-TYN}Aa6pq;!ZB1{nPsvvKDfp60A6T;882TnO;8LM!6}<-%K{M)%6$5_t zbsdCSL7{vwOG_9YNU${YT`i2kZgmBHOTWMhbrYy{phKJ(@y;RRdEWxuzVOdhw22kv z=gx4AMkUGVUG#vXJSfTp3NE!V2N*d; z18ihE@`!`%Itt^wU+<%r=8o2p3g{o$U2;qMO<99*x((EL2B%dv1hyH>w8fli%IDnP z$0q!^+#oPVaEz$>yjAE`#LUH-$2#qv-?J^U0b$TeB@351qo1)mA+@V=+^pm|Vt# zK?Ek$9^FE3z$k~oixQW8cbRRH`vo{!4@YUyi}N7&(CawwWC#*uBUsZ1$P947Yi>Ee zydD39pyioqPz94$nGGR&{evr!D%t|n40%J)8>pGnhKUHqLG9f9YvU4DGau*}@YLy# zS?3XXSd>#Vneqa3y7cQI&;0`=&^uUEL9h0Cpqnb9e?&#|XJ@aMhU3@RsH%oNXlx$v znslM7p-;UeFLZR|j#xICw^d5`b_ diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/MuteConfig.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/MuteConfig.php deleted file mode 100644 index d96ced9daf41..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/MuteConfig.php +++ /dev/null @@ -1,40 +0,0 @@ -internalAddGeneratedFile( - ' -³ -0google/cloud/securitycenter/v1/mute_config.protogoogle.cloud.securitycenter.v1google/api/resource.protogoogle/protobuf/timestamp.proto"® - -MuteConfig -name (  - display_name ( B - description (  -filter ( BàA4 - create_time ( 2.google.protobuf.TimestampBàA4 - update_time ( 2.google.protobuf.TimestampBàA -most_recent_editor ( BàA:ÀêA¼ -(securitycenter.googleapis.com/MuteConfig6organizations/{organization}/muteConfigs/{mute_config}*folders/{folder}/muteConfigs/{mute_config},projects/{project}/muteConfigs/{mute_config}Bé -"com.google.cloud.securitycenter.v1BMuteConfigProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Notebook.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Notebook.php deleted file mode 100644 index 4a3e44210f39..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Notebook.php +++ /dev/null @@ -1,33 +0,0 @@ -internalAddGeneratedFile( - ' -» --google/cloud/securitycenter/v1/notebook.protogoogle.cloud.securitycenter.v1"x -Notebook -name (  -service (  - last_author ( 8 -notebook_update_time ( 2.google.protobuf.TimestampBç -"com.google.cloud.securitycenter.v1B NotebookProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/NotificationConfig.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/NotificationConfig.php deleted file mode 100644 index 4d5fdca064de9e62da6c40b2c8f56641ec50929b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1674 zcmbVMT~8B16tx904k%`Qu%ePFnottmT1|`@Ky5)PCPE{G2eYx6&d!!G%gknWwh55_ z6Muov{t93H13vTYgYn7PnQiF@Xs|EcoxS(md(WJER$fN?5x5WQlv9Zn^ZcvZf)(ySilHYOz$d2@wt1!S}Of}4SY>;r0wh7aO zZBA%u30llF_CX{xEvvBCU?XKpv*c~2qjDU2>og{kMM}tq4n?RJ;R>)b}*I z-ZQfd6^~x9Z1Ae@_vhTuVkz}IOZ!{|->-n@|Em&b-e$T+U+%EJ+)icgc7}{2R+d@U zR$vRCCxJ6A6K4iYrphbiV6Jr4xe2EI?B4X%7xL!t8JN*Bij!7TiHMQHM0#3-zpMAa z9s9wxWp&lq)jLw&P2-%qU^b?*!w79+LPWw5MZa<<)t@==c!bB1VaBUD8$z}* zXGdm_-#z@`0%C}yCmsw-q8*PZE&G95(v>*r>6oiIh5YjQ#SAW-V@eG#D7HHbdf44QI bLzH;B*x&Pq)~^Qa?Oba!k=B5^pbNksZoxyS diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/NotificationMessage.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/NotificationMessage.php deleted file mode 100644 index da90f1e8f69d040f37bd17468861254da9bb91f7..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1310 zcmbVM%We}f6eZzNFuSmcSX8&AQc{Ud6uQD8AkxrKq&5*$S)h?3$K#n=n%E42EVsZ~BrDdzOP)*f+Ve^!j*X$3 zCHHib2KsgfJ^ybf)wZ)%$C}VtHK8+aKR(z1t@2eeWA1*fphs)$RRdICu``vz=fNbk zalHbS=7SnWTYjc*y=o2~K64w+pSd~teZ0M8n(r4x>bGrob5nD12fZzHm(5M+dOs^@ z*MxRMW3RquKkMgF<>R|d#)7w;wE}rP*(Bm7+^b4Q)6VsSFV*dVjk9Cp>=bc6vhRa4 zZhtQd+&u7Q;internalAddGeneratedFile( - ' - -/google/cloud/securitycenter/v1/org_policy.protogoogle.cloud.securitycenter.v1"Ö - OrgPolicy -name ( :ºêA¶ -orgpolicy.googleapis.com/Policy7organizations/{organization}/policies/{constraint_name}+folders/{folder}/policies/{constraint_name}-projects/{project}/policies/{constraint_name}Bè -"com.google.cloud.securitycenter.v1BOrgPolicyProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/OrganizationSettings.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/OrganizationSettings.php deleted file mode 100644 index 3dd3636474395a4b644d26642084c472911c9ea1..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1504 zcmb_c-A>yu6kZErn_;NR5JFs3h9S{OTdK0VFgBH@RGFZuR$xDh6s3+6j6xjQ4icbB zdy+lC9%WCk%U$ynbDXxcrQ4)wxk_@*`ObI#zSnP)vjjYYEgWO!3GBn(6%=O}CX5P- zXasv{5MTxoy+}xenGT_8!?t}4o2GTVAwxM$8Nvn(DGeiBMG;N?D#s{gL|h>p3(TsQ zwJK$y7n5sG5E{E23qj(L>naTZv3G%a;vo!Mo&6&$Jl_+Z(^7~|BSUn$6Nt`fZ5IF( zd7MLg47oc11~&l8CrNt|L68fX7QrpTT@n*Pyog-OQukosMI1|@`@TUMql_xd0_+&! z%5#`wX1-eqm95!>LyDcOTe4G*m6aQNkz-y`yGa6V=i1Qu~=49LzbQiDcdHIG6*w=l3MD{>V zy)uH&l5K;Z3&8mIacku~R#&T{Pp*o7S=;ICE~0Tj!nHYRU)-_uKl9LManS2oE_0Zwp#ayv6v4_Y zgZ30G$`wDyNVvr3lK7k?PQfyXQIzuR6fUTb72)Nb5C4sjZVmB|B)p~p5YWiSOp%z& zNNl#jlS!vCShw1Z!;`LMx7{P#Y`Q1yZl~F>4y>kGdZ3lSlCn#K-9G$ODrk$~Ve_Mm zFq@^KaeiA5!Oqk$^9Fkf;kp!%>a2!pH9B^`ym~YK*`JV&;c@T(D1c3g_m_5c3ZLKQ zD>j_7q!7|+ZIbMyJWUc$db`s<#Yb05@iz7Ab swz!dl7=}VIj7b>7IIZ;-lqkO19v$6_Tmi-einternalAddGeneratedFile( - ' -é -,google/cloud/securitycenter/v1/process.protogoogle.cloud.securitycenter.v1"õ -Process -name ( 4 -binary ( 2$.google.cloud.securitycenter.v1.File7 - libraries ( 2$.google.cloud.securitycenter.v1.File4 -script ( 2$.google.cloud.securitycenter.v1.File -args (  -arguments_truncated (J - env_variables ( 23.google.cloud.securitycenter.v1.EnvironmentVariable -env_variables_truncated ( -pid - ( - -parent_pid ("0 -EnvironmentVariable -name (  -val ( Bæ -"com.google.cloud.securitycenter.v1B ProcessProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Resource.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Resource.php deleted file mode 100644 index cefe60f0d35d..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Resource.php +++ /dev/null @@ -1,38 +0,0 @@ -internalAddGeneratedFile( - ' -Ç --google/cloud/securitycenter/v1/resource.protogoogle.cloud.securitycenter.v1+google/cloud/securitycenter/v1/folder.proto"Ö -Resource -name (  - display_name (  -type (  -project (  -project_display_name (  -parent (  -parent_display_name ( < -folders ( 2&.google.cloud.securitycenter.v1.FolderBàABç -"com.google.cloud.securitycenter.v1B ResourceProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/RunAssetDiscoveryResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/RunAssetDiscoveryResponse.php deleted file mode 100644 index d9bf96aaf436dffaaeb3c0a91ba70638d8c5791f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1217 zcmbu8(QeZ)6oyG*2#lCUC8X_U^2(%j0#bF{xs<7EvZ{!-QIquoMXFNA?JT8nI-qjbMOSb0TNGvoiy3HQEtdhV(0if=lnkZ`}62J0;+nvSGr=$m z;3Sz&35S@?BN`B{Lud?Of8apV=sHL8Xv`9h34$}mW&x?;fF*t{COF|#EHMcM;k8A* z#*=XD#W4|MpT?Li2w#pli6a)qL{GB;5PEaD<6#0j)N!8r0YCZG<*B~+GG!l$kG8Ca15ry7rr+T_h zt8jD*t67Z*-7B&Q1y9KB>=1Gy5*{|vx)oqme7S#7v8c{Sj*X_%b#@@q=pBku0$L0C92x4iU zKW4x3R@uBZV|UHxMO6B4Q_g78xV!PKbl6Fqrl(HRbEmaa3+to$k37I#d$BNM7UD`b r{w^J55QI_+LYo+bM)k?#RKIs8#Sp#8#`=~EwmKk<%;t0jRsj3~XMdK| diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityHealthAnalyticsCustomConfig.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityHealthAnalyticsCustomConfig.php deleted file mode 100644 index 8a74b618fbc99a59094d92d3e0e001a65d0aad54..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1709 zcmb_c-EI>{6vj>n&VeGcMaarUG=xYPXg6{YHyZ*<9LF(Au)!u2w34+RA3GzhcSf_b z5eDU^FHrFs-1jB=C_Du-v+KoaidrgsWgnmUzVG~fkDrPY0e46fBb0%{AsI}GIzb{N zSDf;Y43g0ZC82yGScuXkWUo!0w|k_q*XrHYPh*})iXItrJ`Qn%hCCT=#7Gm#)RbbR zP;Q*o@<{&#gHWCHgD426iqW`FlUVUdpYmwL#;zp>h=K{mBA`f`o!ui;!7xyP-?SWl z-EjEba~%G0Z3}>gK^&9WKL?g-XU0^wM0LvpAAsnONCqLJBvyfzLe^Q_XAx5@2-$nx zi)}Ir!WcE~#oSR6QN?&f%!77Bv3ifBm?n2!aNWCYGE>|!?bNOGTc#gckiUm9l}sou zJ37_##;Eckm`L?rMr+{Mh*VRJo_9gyHc>Lcd3Hi1szgRxR<{8-%fI>m(9hmfpx<~W zr00FD=Idiy%&$*aCVgi(%$4rzov7y6hUqT+QG&xCxeU%~isstYa?h`pdsLoWg&6MsNU#GffTA&H*dHZh|;yXrdFp1KV_@O6D1N=Dca2KS>`wB+inW1zu5T^;H7*ElhRb^2FUf+E5T~fQ*W9MhMI?T3D zFL33u##(l6!F7rH$|o4*7=fMPvhx7Sr$LxtANBY!j*ZB4W*4Wsav#bUI%sRmW@GjsmA<_8 z0!n#vDsZ#gIBvXb_1^SfJ@0lJ_11o?u~)vN#gytg+^X*!mJ3b^77tp@gL2UUSUS>X z`0A*<;9P-)!}ja);_mN7SkvA7m!9la|ASRo@8}fXK1&yJb_{&7G3L3gW=0zbHs`fz zPz<)t-;5Z1Dy}xImAckS-IY&@n3_W3MkAx%t-JBPS;IK)n;JG={5Q=TP0weW=VNl2T1$g`lC zQa?+WIQD5IXwp2|D*t#>N{L(yRR_Zw#0A;CotUCTRRB(AxTqQoIF=hc7fDZKnDs3y+atDI2(n`$EhF?3ck-$ zk3~!{60*0z#V#I`Fs0!4W7}~S`GWBX%L|8*Pa6-h_9<=e#~irZ#YMz@NheV0b|oJW zklUfDpRic)qz|T+HKC#`g8b8Xn8QkUY>XQ^M$7sr$XzUwj4q;MoKTS^(T<8+I+&Ml z?iqaAF?07A4TBb)k|V|w%leSj2PfxUeMxf-EPd;o0+uB`vv6%5joD=R&`QpS474Q3 zEI#|Ls?~STSY8=B2+Bh2f#e${b&|*j=#Mq@;&W=1Q zurvbsCXTNM|r7JgIP6zXB&;ZV$}=XT@A14$~=p52S1330lo!7$nq_ znbofX((3j`fmEbzmU@w)*Ni$^g{dMu8ZhYA`bv>h%^0Cu1UetaSCWsf`Zaahg?spGqFFN{@mO2DB Ri~roEuPpUyo})QJ{{i`GdT0Ou diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityMarks.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityMarks.php deleted file mode 100644 index a095177909fe..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityMarks.php +++ /dev/null @@ -1,37 +0,0 @@ -internalAddGeneratedFile( - ' - -3google/cloud/securitycenter/v1/security_marks.protogoogle.cloud.securitycenter.v1"Õ - SecurityMarks -name ( G -marks ( 28.google.cloud.securitycenter.v1.SecurityMarks.MarksEntry -canonical_name ( , - -MarksEntry -key (  -value ( :8:¦êA¢ -+securitycenter.googleapis.com/SecurityMarks9organizations/{organization}/assets/{asset}/securityMarksNorganizations/{organization}/sources/{source}/findings/{finding}/securityMarks-folders/{folder}/assets/{asset}/securityMarks/projects/{project}/assets/{asset}/securityMarksBfolders/{folder}/sources/{source}/findings/{finding}/securityMarksDprojects/{project}/sources/{source}/findings/{finding}/securityMarksBØ -"com.google.cloud.securitycenter.v1PZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityPosture.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityPosture.php deleted file mode 100644 index 2e64f8687ba6..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecurityPosture.php +++ /dev/null @@ -1,41 +0,0 @@ -internalAddGeneratedFile( - ' -» -5google/cloud/securitycenter/v1/security_posture.protogoogle.cloud.securitycenter.v1"è -SecurityPosture -name (  - revision_id ( # -posture_deployment_resource (  -posture_deployment (  -changed_policy (  - -policy_set (  -policy ( ` -policy_drift_details ( 2B.google.cloud.securitycenter.v1.SecurityPosture.PolicyDriftDetailsS -PolicyDriftDetails -field (  -expected_value (  -detected_value ( Bî -"com.google.cloud.securitycenter.v1BSecurityPostureProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecuritycenterService.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecuritycenterService.php deleted file mode 100644 index eebef284d6ba..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/SecuritycenterService.php +++ /dev/null @@ -1,383 +0,0 @@ -internalAddGeneratedFile( - ' -ŒÖ -;google/cloud/securitycenter/v1/securitycenter_service.protogoogle.cloud.securitycenter.v1google/api/client.protogoogle/api/field_behavior.protogoogle/api/resource.proto*google/cloud/securitycenter/v1/asset.proto4google/cloud/securitycenter/v1/bigquery_export.protoVgoogle/cloud/securitycenter/v1/effective_security_health_analytics_custom_module.proto4google/cloud/securitycenter/v1/external_system.proto,google/cloud/securitycenter/v1/finding.proto+google/cloud/securitycenter/v1/folder.proto0google/cloud/securitycenter/v1/mute_config.proto8google/cloud/securitycenter/v1/notification_config.proto:google/cloud/securitycenter/v1/organization_settings.protoAgoogle/cloud/securitycenter/v1/run_asset_discovery_response.protoLgoogle/cloud/securitycenter/v1/security_health_analytics_custom_config.protoLgoogle/cloud/securitycenter/v1/security_health_analytics_custom_module.proto3google/cloud/securitycenter/v1/security_marks.proto+google/cloud/securitycenter/v1/source.protogoogle/iam/v1/iam_policy.protogoogle/iam/v1/policy.proto#google/longrunning/operations.protogoogle/protobuf/duration.protogoogle/protobuf/empty.proto google/protobuf/field_mask.protogoogle/protobuf/struct.protogoogle/protobuf/timestamp.protogoogle/rpc/status.proto"a -BulkMuteFindingsRequest -parent ( B àAúA -* -filter (  -mute_annotation ( B" -BulkMuteFindingsResponse"¬ -CreateFindingRequest< -parent ( B,àAúA& -$securitycenter.googleapis.com/Source - -finding_id ( BàA= -finding ( 2\'.google.cloud.securitycenter.v1.FindingBàA"¾ -CreateMuteConfigRequest@ -parent ( B0àAúA*(securitycenter.googleapis.com/MuteConfigD - mute_config ( 2*.google.cloud.securitycenter.v1.MuteConfigBàA -mute_config_id ( BàA"Ù -CreateNotificationConfigRequestH -parent ( B8àAúA20securitycenter.googleapis.com/NotificationConfig - config_id ( BàAT -notification_config ( 22.google.cloud.securitycenter.v1.NotificationConfigBàA"ˆ -0CreateSecurityHealthAnalyticsCustomModuleRequestY -parent ( BIàAúACAsecuritycenter.googleapis.com/SecurityHealthAnalyticsCustomModuley -\'security_health_analytics_custom_module ( 2C.google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModuleBàA"œ -CreateSourceRequestH -parent ( B8àAúA2 -0cloudresourcemanager.googleapis.com/Organization; -source ( 2&.google.cloud.securitycenter.v1.SourceBàA"Y -DeleteMuteConfigRequest> -name ( B0àAúA* -(securitycenter.googleapis.com/MuteConfig"i -DeleteNotificationConfigRequestF -name ( B8àAúA2 -0securitycenter.googleapis.com/NotificationConfig"‹ -0DeleteSecurityHealthAnalyticsCustomModuleRequestW -name ( BIàAúAC -Asecuritycenter.googleapis.com/SecurityHealthAnalyticsCustomModule"^ -GetBigQueryExportRequestB -name ( B4àAúA. -,securitycenter.googleapis.com/BigQueryExport"V -GetMuteConfigRequest> -name ( B0àAúA* -(securitycenter.googleapis.com/MuteConfig"f -GetNotificationConfigRequestF -name ( B8àAúA2 -0securitycenter.googleapis.com/NotificationConfig"j -GetOrganizationSettingsRequestH -name ( B:àAúA4 -2securitycenter.googleapis.com/OrganizationSettings"š -6GetEffectiveSecurityHealthAnalyticsCustomModuleRequest` -name ( BRàAúAL -Jsecuritycenter.googleapis.com/EffectiveSecurityHealthAnalyticsCustomModule"ˆ --GetSecurityHealthAnalyticsCustomModuleRequestW -name ( BIàAúAC -Asecuritycenter.googleapis.com/SecurityHealthAnalyticsCustomModule"N -GetSourceRequest: -name ( B,àAúA& -$securitycenter.googleapis.com/Source"ƒ -GroupAssetsRequest; -parent ( B+àAúA%#securitycenter.googleapis.com/Asset -filter (  -group_by ( BàA3 -compare_duration ( 2.google.protobuf.Duration- - read_time ( 2.google.protobuf.Timestamp - -page_token (  - page_size ("¸ -GroupAssetsResponseE -group_by_results ( 2+.google.cloud.securitycenter.v1.GroupResult- - read_time ( 2.google.protobuf.Timestamp -next_page_token (  - -total_size ("† -GroupFindingsRequest< -parent ( B,àAúA& -$securitycenter.googleapis.com/Source -filter (  -group_by ( BàA- - read_time ( 2.google.protobuf.Timestamp3 -compare_duration ( 2.google.protobuf.Duration - -page_token (  - page_size ("º -GroupFindingsResponseE -group_by_results ( 2+.google.cloud.securitycenter.v1.GroupResult- - read_time ( 2.google.protobuf.Timestamp -next_page_token (  - -total_size ("¸ - GroupResultO - -properties ( 2;.google.cloud.securitycenter.v1.GroupResult.PropertiesEntry -count (I -PropertiesEntry -key ( % -value ( 2.google.protobuf.Value:8"½ -9ListDescendantSecurityHealthAnalyticsCustomModulesRequestY -parent ( BIàAúACAsecuritycenter.googleapis.com/SecurityHealthAnalyticsCustomModule - page_size ( - -page_token ( "Ì -:ListDescendantSecurityHealthAnalyticsCustomModulesResponseu -(security_health_analytics_custom_modules ( 2C.google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule -next_page_token ( " -ListMuteConfigsRequest@ -parent ( B0àAúA*(securitycenter.googleapis.com/MuteConfig - page_size ( - -page_token ( "t -ListMuteConfigsResponse@ - mute_configs ( 2*.google.cloud.securitycenter.v1.MuteConfig -next_page_token ( "‘ -ListNotificationConfigsRequestH -parent ( B8àAúA20securitycenter.googleapis.com/NotificationConfig - -page_token (  - page_size ("Œ -ListNotificationConfigsResponseP -notification_configs ( 22.google.cloud.securitycenter.v1.NotificationConfig -next_page_token ( "¼ -8ListEffectiveSecurityHealthAnalyticsCustomModulesRequestY -parent ( BIàAúACAsecuritycenter.googleapis.com/SecurityHealthAnalyticsCustomModule - page_size ( - -page_token ( "ß -9ListEffectiveSecurityHealthAnalyticsCustomModulesResponseˆ -2effective_security_health_analytics_custom_modules ( 2L.google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule -next_page_token ( "³ -/ListSecurityHealthAnalyticsCustomModulesRequestY -parent ( BIàAúACAsecuritycenter.googleapis.com/SecurityHealthAnalyticsCustomModule - page_size ( - -page_token ( " -0ListSecurityHealthAnalyticsCustomModulesResponseu -(security_health_analytics_custom_modules ( 2C.google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule -next_page_token ( "y -ListSourcesRequest< -parent ( B,àAúA&$securitycenter.googleapis.com/Source - -page_token (  - page_size ("g -ListSourcesResponse7 -sources ( 2&.google.cloud.securitycenter.v1.Source -next_page_token ( "­ -ListAssetsRequest; -parent ( B+àAúA%#securitycenter.googleapis.com/Asset -filter (  -order_by ( - - read_time ( 2.google.protobuf.Timestamp3 -compare_duration ( 2.google.protobuf.Duration. - -field_mask ( 2.google.protobuf.FieldMask - -page_token (  - page_size ("à -ListAssetsResponse` -list_assets_results ( 2C.google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult- - read_time ( 2.google.protobuf.Timestamp -next_page_token (  - -total_size (î -ListAssetsResult4 -asset ( 2%.google.cloud.securitycenter.v1.Assete - state_change (2O.google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult.StateChange"= - StateChange - -UNUSED -ADDED -REMOVED - -ACTIVE"° -ListFindingsRequest< -parent ( B,àAúA& -$securitycenter.googleapis.com/Source -filter (  -order_by ( - - read_time ( 2.google.protobuf.Timestamp3 -compare_duration ( 2.google.protobuf.Duration. - -field_mask ( 2.google.protobuf.FieldMask - -page_token (  - page_size ("¬ -ListFindingsResponsef -list_findings_results ( 2G.google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult- - read_time ( 2.google.protobuf.Timestamp -next_page_token (  - -total_size (Ï -ListFindingsResult8 -finding ( 2\'.google.cloud.securitycenter.v1.Findingi - state_change (2S.google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.StateChangeg -resource ( 2P.google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.ResourceBàAÛ -Resource -name (  - display_name (  -type (  - project_name (  -project_display_name (  - parent_name (  -parent_display_name ( 7 -folders ( 2&.google.cloud.securitycenter.v1.Folder"M - StateChange - -UNUSED -CHANGED - UNCHANGED -ADDED -REMOVED"Í -SetFindingStateRequest; -name ( B-àAúA\' -%securitycenter.googleapis.com/FindingA -state (2-.google.cloud.securitycenter.v1.Finding.StateBàA3 - -start_time ( 2.google.protobuf.TimestampBàA"Ž -SetMuteRequest; -name ( B-àAúA\' -%securitycenter.googleapis.com/Finding? -mute (2,.google.cloud.securitycenter.v1.Finding.MuteBàA"d -RunAssetDiscoveryRequestH -parent ( B8àAúA2 -0cloudresourcemanager.googleapis.com/Organization"¬ -2SimulateSecurityHealthAnalyticsCustomModuleRequest -parent ( BàAH - custom_config ( 2,.google.cloud.securitycenter.v1.CustomConfigBàA{ -resource ( 2d.google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleRequest.SimulatedResourceBàA™ -SimulatedResource - resource_type ( BàA3 - resource_data ( 2.google.protobuf.StructBàA3 -iam_policy_data ( 2.google.iam.v1.PolicyBàA"Ù -3SimulateSecurityHealthAnalyticsCustomModuleResponses -result ( 2c.google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleResponse.SimulatedResult¬ -SimulatedResult: -finding ( 2\'.google.cloud.securitycenter.v1.FindingH. - no_violation ( 2.google.protobuf.EmptyH# -error ( 2.google.rpc.StatusHB -result"œ -UpdateExternalSystemRequestL -external_system ( 2..google.cloud.securitycenter.v1.ExternalSystemBàA/ - update_mask ( 2.google.protobuf.FieldMask"† -UpdateFindingRequest= -finding ( 2\'.google.cloud.securitycenter.v1.FindingBàA/ - update_mask ( 2.google.protobuf.FieldMask" -UpdateMuteConfigRequestD - mute_config ( 2*.google.cloud.securitycenter.v1.MuteConfigBàA/ - update_mask ( 2.google.protobuf.FieldMask"¨ -UpdateNotificationConfigRequestT -notification_config ( 22.google.cloud.securitycenter.v1.NotificationConfigBàA/ - update_mask ( 2.google.protobuf.FieldMask"® -!UpdateOrganizationSettingsRequestX -organization_settings ( 24.google.cloud.securitycenter.v1.OrganizationSettingsBàA/ - update_mask ( 2.google.protobuf.FieldMask"Þ -0UpdateSecurityHealthAnalyticsCustomModuleRequesty -\'security_health_analytics_custom_module ( 2C.google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModuleBàA/ - update_mask ( 2.google.protobuf.FieldMask"ƒ -UpdateSourceRequest; -source ( 2&.google.cloud.securitycenter.v1.SourceBàA/ - update_mask ( 2.google.protobuf.FieldMask"É -UpdateSecurityMarksRequestJ -security_marks ( 2-.google.cloud.securitycenter.v1.SecurityMarksBàA/ - update_mask ( 2.google.protobuf.FieldMask. - -start_time ( 2.google.protobuf.Timestamp"Ô -CreateBigQueryExportRequestD -parent ( B4àAúA.,securitycenter.googleapis.com/BigQueryExportM -big_query_export ( 2..google.cloud.securitycenter.v1.BigQueryExportBàA -big_query_export_id ( BàA" -UpdateBigQueryExportRequestM -big_query_export ( 2..google.cloud.securitycenter.v1.BigQueryExportBàA/ - update_mask ( 2.google.protobuf.FieldMask"‰ -ListBigQueryExportsRequestD -parent ( B4àAúA.,securitycenter.googleapis.com/BigQueryExport - page_size ( - -page_token ( " -ListBigQueryExportsResponseI -big_query_exports ( 2..google.cloud.securitycenter.v1.BigQueryExport -next_page_token ( "a -DeleteBigQueryExportRequestB -name ( B4àAúA. -,securitycenter.googleapis.com/BigQueryExport2x -SecurityCenterâ -BulkMuteFindings7.google.cloud.securitycenter.v1.BulkMuteFindingsRequest.google.longrunning.Operation"õÊAP -7google.cloud.securitycenter.v1.BulkMuteFindingsResponsegoogle.protobuf.EmptyÚAparent‚Óä“’"./v1/{parent=organizations/*}/findings:bulkMute:*Z-"(/v1/{parent=folders/*}/findings:bulkMute:*Z.")/v1/{parent=projects/*}/findings:bulkMute:*Õ -)CreateSecurityHealthAnalyticsCustomModuleP.google.cloud.securitycenter.v1.CreateSecurityHealthAnalyticsCustomModuleRequestC.google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule"ÚA.parent,security_health_analytics_custom_module‚Óä“Ø"J/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/customModules:\'security_health_analytics_custom_moduleZo"D/v1/{parent=folders/*/securityHealthAnalyticsSettings}/customModules:\'security_health_analytics_custom_moduleZp"E/v1/{parent=projects/*/securityHealthAnalyticsSettings}/customModules:\'security_health_analytics_custom_module± - CreateSource3.google.cloud.securitycenter.v1.CreateSourceRequest&.google.cloud.securitycenter.v1.Source"DÚA parent,source‚Óä“."$/v1/{parent=organizations/*}/sources:sourceÌ - CreateFinding4.google.cloud.securitycenter.v1.CreateFindingRequest\'.google.cloud.securitycenter.v1.Finding"\\ÚAparent,finding_id,finding‚Óä“:"//v1/{parent=organizations/*/sources/*}/findings:findingØ -CreateMuteConfig7.google.cloud.securitycenter.v1.CreateMuteConfigRequest*.google.cloud.securitycenter.v1.MuteConfig"ÞÚAparent,mute_configÚA!parent,mute_config,mute_config_id‚Óä“ž"(/v1/{parent=organizations/*}/muteConfigs: mute_configZ1""/v1/{parent=folders/*}/muteConfigs: mute_configZ2"#/v1/{parent=projects/*}/muteConfigs: mute_config« -CreateNotificationConfig?.google.cloud.securitycenter.v1.CreateNotificationConfigRequest2.google.cloud.securitycenter.v1.NotificationConfig"™ÚA$parent,config_id,notification_configÚAparent,notification_config‚Óä“Î"0/v1/{parent=organizations/*}/notificationConfigs:notification_configZA"*/v1/{parent=folders/*}/notificationConfigs:notification_configZB"+/v1/{parent=projects/*}/notificationConfigs:notification_configê -DeleteMuteConfig7.google.cloud.securitycenter.v1.DeleteMuteConfigRequest.google.protobuf.Empty"„ÚAname‚Óä“w*(/v1/{name=organizations/*/muteConfigs/*}Z$*"/v1/{name=folders/*/muteConfigs/*}Z%*#/v1/{name=projects/*/muteConfigs/*}“ -DeleteNotificationConfig?.google.cloud.securitycenter.v1.DeleteNotificationConfigRequest.google.protobuf.Empty"ÚAname‚Óä“*0/v1/{name=organizations/*/notificationConfigs/*}Z,**/v1/{name=folders/*/notificationConfigs/*}Z-*+/v1/{name=projects/*/notificationConfigs/*}ƒ -)DeleteSecurityHealthAnalyticsCustomModuleP.google.cloud.securitycenter.v1.DeleteSecurityHealthAnalyticsCustomModuleRequest.google.protobuf.Empty"ëÚAname‚Óä“Ý*J/v1/{name=organizations/*/securityHealthAnalyticsSettings/customModules/*}ZF*D/v1/{name=folders/*/securityHealthAnalyticsSettings/customModules/*}ZG*E/v1/{name=projects/*/securityHealthAnalyticsSettings/customModules/*}‘ -GetBigQueryExport8.google.cloud.securitycenter.v1.GetBigQueryExportRequest..google.cloud.securitycenter.v1.BigQueryExport"‘ÚAname‚Ó䓃,/v1/{name=organizations/*/bigQueryExports/*}Z(&/v1/{name=folders/*/bigQueryExports/*}Z)\'/v1/{name=projects/*/bigQueryExports/*}– - GetIamPolicy".google.iam.v1.GetIamPolicyRequest.google.iam.v1.Policy"KÚAresource‚Óä“:"5/v1/{resource=organizations/*/sources/*}:getIamPolicy:*ø - GetMuteConfig4.google.cloud.securitycenter.v1.GetMuteConfigRequest*.google.cloud.securitycenter.v1.MuteConfig"„ÚAname‚Óä“w(/v1/{name=organizations/*/muteConfigs/*}Z$"/v1/{name=folders/*/muteConfigs/*}Z%#/v1/{name=projects/*/muteConfigs/*}© -GetNotificationConfig<.google.cloud.securitycenter.v1.GetNotificationConfigRequest2.google.cloud.securitycenter.v1.NotificationConfig"ÚAname‚Óä“0/v1/{name=organizations/*/notificationConfigs/*}Z,*/v1/{name=folders/*/notificationConfigs/*}Z-+/v1/{name=projects/*/notificationConfigs/*}Ï -GetOrganizationSettings>.google.cloud.securitycenter.v1.GetOrganizationSettingsRequest4.google.cloud.securitycenter.v1.OrganizationSettings">ÚAname‚Óä“1//v1/{name=organizations/*/organizationSettings}à -/GetEffectiveSecurityHealthAnalyticsCustomModuleV.google.cloud.securitycenter.v1.GetEffectiveSecurityHealthAnalyticsCustomModuleRequestL.google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule"†ÚAname‚Óä“øS/v1/{name=organizations/*/securityHealthAnalyticsSettings/effectiveCustomModules/*}ZOM/v1/{name=folders/*/securityHealthAnalyticsSettings/effectiveCustomModules/*}ZPN/v1/{name=projects/*/securityHealthAnalyticsSettings/effectiveCustomModules/*}ª -&GetSecurityHealthAnalyticsCustomModuleM.google.cloud.securitycenter.v1.GetSecurityHealthAnalyticsCustomModuleRequestC.google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule"ëÚAname‚Óä“ÝJ/v1/{name=organizations/*/securityHealthAnalyticsSettings/customModules/*}ZFD/v1/{name=folders/*/securityHealthAnalyticsSettings/customModules/*}ZGE/v1/{name=projects/*/securityHealthAnalyticsSettings/customModules/*}š - GetSource0.google.cloud.securitycenter.v1.GetSourceRequest&.google.cloud.securitycenter.v1.Source"3ÚAname‚Óä“&$/v1/{name=organizations/*/sources/*}† - GroupAssets2.google.cloud.securitycenter.v1.GroupAssetsRequest3.google.cloud.securitycenter.v1.GroupAssetsResponse"ˆ‚Ó䓃")/v1/{parent=organizations/*}/assets:group:*Z("#/v1/{parent=folders/*}/assets:group:*Z)"$/v1/{parent=projects/*}/assets:group:*¿ - GroupFindings4.google.cloud.securitycenter.v1.GroupFindingsRequest5.google.cloud.securitycenter.v1.GroupFindingsResponse"ÀÚAparent,group_by‚Ó䓧"5/v1/{parent=organizations/*/sources/*}/findings:group:*Z4"//v1/{parent=folders/*/sources/*}/findings:group:*Z5"0/v1/{parent=projects/*/sources/*}/findings:group:*æ - -ListAssets1.google.cloud.securitycenter.v1.ListAssetsRequest2.google.cloud.securitycenter.v1.ListAssetsResponse"qˆ‚Óä“h#/v1/{parent=organizations/*}/assetsZ/v1/{parent=folders/*}/assetsZ /v1/{parent=projects/*}/assetsˆ -2ListDescendantSecurityHealthAnalyticsCustomModulesY.google.cloud.securitycenter.v1.ListDescendantSecurityHealthAnalyticsCustomModulesRequestZ.google.cloud.securitycenter.v1.ListDescendantSecurityHealthAnalyticsCustomModulesResponse"šÚAparent‚Óä“ŠY/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/customModules:listDescendantZUS/v1/{parent=folders/*/securityHealthAnalyticsSettings}/customModules:listDescendantZVT/v1/{parent=projects/*/securityHealthAnalyticsSettings}/customModules:listDescendant - ListFindings3.google.cloud.securitycenter.v1.ListFindingsRequest4.google.cloud.securitycenter.v1.ListFindingsResponse"“‚Óä“Œ//v1/{parent=organizations/*/sources/*}/findingsZ+)/v1/{parent=folders/*/sources/*}/findingsZ,*/v1/{parent=projects/*/sources/*}/findings‹ -ListMuteConfigs6.google.cloud.securitycenter.v1.ListMuteConfigsRequest7.google.cloud.securitycenter.v1.ListMuteConfigsResponse"†ÚAparent‚Óä“w(/v1/{parent=organizations/*}/muteConfigsZ$"/v1/{parent=folders/*}/muteConfigsZ%#/v1/{parent=projects/*}/muteConfigs¼ -ListNotificationConfigs>.google.cloud.securitycenter.v1.ListNotificationConfigsRequest?.google.cloud.securitycenter.v1.ListNotificationConfigsResponse"ŸÚAparent‚Óä“0/v1/{parent=organizations/*}/notificationConfigsZ,*/v1/{parent=folders/*}/notificationConfigsZ-+/v1/{parent=projects/*}/notificationConfigsó -1ListEffectiveSecurityHealthAnalyticsCustomModulesX.google.cloud.securitycenter.v1.ListEffectiveSecurityHealthAnalyticsCustomModulesRequestY.google.cloud.securitycenter.v1.ListEffectiveSecurityHealthAnalyticsCustomModulesResponse"ˆÚAparent‚Óä“øS/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/effectiveCustomModulesZOM/v1/{parent=folders/*/securityHealthAnalyticsSettings}/effectiveCustomModulesZPN/v1/{parent=projects/*/securityHealthAnalyticsSettings}/effectiveCustomModules½ -(ListSecurityHealthAnalyticsCustomModulesO.google.cloud.securitycenter.v1.ListSecurityHealthAnalyticsCustomModulesRequestP.google.cloud.securitycenter.v1.ListSecurityHealthAnalyticsCustomModulesResponse"íÚAparent‚Óä“ÝJ/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/customModulesZFD/v1/{parent=folders/*/securityHealthAnalyticsSettings}/customModulesZGE/v1/{parent=projects/*/securityHealthAnalyticsSettings}/customModulesò - ListSources2.google.cloud.securitycenter.v1.ListSourcesRequest3.google.cloud.securitycenter.v1.ListSourcesResponse"zÚAparent‚Óä“k$/v1/{parent=organizations/*}/sourcesZ /v1/{parent=folders/*}/sourcesZ!/v1/{parent=projects/*}/sourcesŠ -RunAssetDiscovery8.google.cloud.securitycenter.v1.RunAssetDiscoveryRequest.google.longrunning.Operation"›ˆÊAQ -8google.cloud.securitycenter.v1.RunAssetDiscoveryResponsegoogle.protobuf.EmptyÚAparent‚Óä“5"0/v1/{parent=organizations/*}/assets:runDiscovery:*Ä -SetFindingState6.google.cloud.securitycenter.v1.SetFindingStateRequest\'.google.cloud.securitycenter.v1.Finding"ÏÚAname,state,start_time‚Óä“°"8/v1/{name=organizations/*/sources/*/findings/*}:setState:*Z7"2/v1/{name=folders/*/sources/*/findings/*}:setState:*Z8"3/v1/{name=projects/*/sources/*/findings/*}:setState:*¥ -SetMute..google.cloud.securitycenter.v1.SetMuteRequest\'.google.cloud.securitycenter.v1.Finding"ÀÚA name,mute‚Óä“­"7/v1/{name=organizations/*/sources/*/findings/*}:setMute:*Z6"1/v1/{name=folders/*/sources/*/findings/*}:setMute:*Z7"2/v1/{name=projects/*/sources/*/findings/*}:setMute:* - SetIamPolicy".google.iam.v1.SetIamPolicyRequest.google.iam.v1.Policy"RÚAresource,policy‚Óä“:"5/v1/{resource=organizations/*/sources/*}:setIamPolicy:*È -TestIamPermissions(.google.iam.v1.TestIamPermissionsRequest).google.iam.v1.TestIamPermissionsResponse"]ÚAresource,permissions‚Óä“@";/v1/{resource=organizations/*/sources/*}:testIamPermissions:* -+SimulateSecurityHealthAnalyticsCustomModuleR.google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleRequestS.google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleResponse"¨ÚAparent,custom_config,resource‚Óä“"S/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/customModules:simulate:*ZR"M/v1/{parent=folders/*/securityHealthAnalyticsSettings}/customModules:simulate:*ZS"N/v1/{parent=projects/*/securityHealthAnalyticsSettings}/customModules:simulate:*Ð -UpdateExternalSystem;.google.cloud.securitycenter.v1.UpdateExternalSystemRequest..google.cloud.securitycenter.v1.ExternalSystem"ÊÚAexternal_system,update_mask‚Óä“¥2Q/v1/{external_system.name=organizations/*/sources/*/findings/*/externalSystems/*}:external_systemZ^2K/v1/{external_system.name=folders/*/sources/*/findings/*/externalSystems/*}:external_systemZ_2L/v1/{external_system.name=projects/*/sources/*/findings/*/externalSystems/*}:external_systemÁ - UpdateFinding4.google.cloud.securitycenter.v1.UpdateFindingRequest\'.google.cloud.securitycenter.v1.Finding"ÐÚAfinding‚Óä“¿27/v1/{finding.name=organizations/*/sources/*/findings/*}:findingZ<21/v1/{finding.name=folders/*/sources/*/findings/*}:findingZ=22/v1/{finding.name=projects/*/sources/*/findings/*}:findingÝ -UpdateMuteConfig7.google.cloud.securitycenter.v1.UpdateMuteConfigRequest*.google.cloud.securitycenter.v1.MuteConfig"ãÚAmute_config,update_mask‚Óä“Â24/v1/{mute_config.name=organizations/*/muteConfigs/*}: mute_configZ=2./v1/{mute_config.name=folders/*/muteConfigs/*}: mute_configZ>2//v1/{mute_config.name=projects/*/muteConfigs/*}: mute_configÛ -UpdateNotificationConfig?.google.cloud.securitycenter.v1.UpdateNotificationConfigRequest2.google.cloud.securitycenter.v1.NotificationConfig"ÉÚAnotification_configÚAnotification_config,update_mask‚Óä“Š2D/v1/{notification_config.name=organizations/*/notificationConfigs/*}:notification_configZU2>/v1/{notification_config.name=folders/*/notificationConfigs/*}:notification_configZV2?/v1/{notification_config.name=projects/*/notificationConfigs/*}:notification_config“ -UpdateOrganizationSettingsA.google.cloud.securitycenter.v1.UpdateOrganizationSettingsRequest4.google.cloud.securitycenter.v1.OrganizationSettings"|ÚAorganization_settings‚Óä“^2E/v1/{organization_settings.name=organizations/*/organizationSettings}:organization_settingsÔ -)UpdateSecurityHealthAnalyticsCustomModuleP.google.cloud.securitycenter.v1.UpdateSecurityHealthAnalyticsCustomModuleRequestC.google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule"ÚA3security_health_analytics_custom_module,update_mask‚Óä“Ò2r/v1/{security_health_analytics_custom_module.name=organizations/*/securityHealthAnalyticsSettings/customModules/*}:\'security_health_analytics_custom_moduleZ—2l/v1/{security_health_analytics_custom_module.name=folders/*/securityHealthAnalyticsSettings/customModules/*}:\'security_health_analytics_custom_moduleZ˜2m/v1/{security_health_analytics_custom_module.name=projects/*/securityHealthAnalyticsSettings/customModules/*}:\'security_health_analytics_custom_module± - UpdateSource3.google.cloud.securitycenter.v1.UpdateSourceRequest&.google.cloud.securitycenter.v1.Source"DÚAsource‚Óä“52+/v1/{source.name=organizations/*/sources/*}:sourceŸ -UpdateSecurityMarks:.google.cloud.securitycenter.v1.UpdateSecurityMarksRequest-.google.cloud.securitycenter.v1.SecurityMarks"œÚAsecurity_marks‚Óä“„2@/v1/{security_marks.name=organizations/*/assets/*/securityMarks}:security_marksZL2:/v1/{security_marks.name=folders/*/assets/*/securityMarks}:security_marksZM2;/v1/{security_marks.name=projects/*/assets/*/securityMarks}:security_marksZ^2L/v1/{security_marks.name=organizations/*/sources/*/findings/*/securityMarks}:security_marksZX2F/v1/{security_marks.name=folders/*/sources/*/findings/*/securityMarks}:security_marksZY2G/v1/{security_marks.name=projects/*/sources/*/findings/*/securityMarks}:security_marksô -CreateBigQueryExport;.google.cloud.securitycenter.v1.CreateBigQueryExportRequest..google.cloud.securitycenter.v1.BigQueryExport"îÚA+parent,big_query_export,big_query_export_id‚Ó䓹",/v1/{parent=organizations/*}/bigQueryExports:big_query_exportZ:"&/v1/{parent=folders/*}/bigQueryExports:big_query_exportZ;"\'/v1/{parent=projects/*}/bigQueryExports:big_query_exportÿ -DeleteBigQueryExport;.google.cloud.securitycenter.v1.DeleteBigQueryExportRequest.google.protobuf.Empty"‘ÚAname‚Ó䓃*,/v1/{name=organizations/*/bigQueryExports/*}Z(*&/v1/{name=folders/*/bigQueryExports/*}Z)*\'/v1/{name=projects/*/bigQueryExports/*}˜ -UpdateBigQueryExport;.google.cloud.securitycenter.v1.UpdateBigQueryExportRequest..google.cloud.securitycenter.v1.BigQueryExport"’ÚAbig_query_export,update_mask‚Óä“ì2=/v1/{big_query_export.name=organizations/*/bigQueryExports/*}:big_query_exportZK27/v1/{big_query_export.name=folders/*/bigQueryExports/*}:big_query_exportZL28/v1/{big_query_export.name=projects/*/bigQueryExports/*}:big_query_export¤ -ListBigQueryExports:.google.cloud.securitycenter.v1.ListBigQueryExportsRequest;.google.cloud.securitycenter.v1.ListBigQueryExportsResponse"“ÚAparent‚Ó䓃,/v1/{parent=organizations/*}/bigQueryExportsZ(&/v1/{parent=folders/*}/bigQueryExportsZ)\'/v1/{parent=projects/*}/bigQueryExportsQÊAsecuritycenter.googleapis.comÒA.https://www.googleapis.com/auth/cloud-platformBØ -"com.google.cloud.securitycenter.v1PZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Source.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Source.php deleted file mode 100644 index 86db591f38be..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Source.php +++ /dev/null @@ -1,34 +0,0 @@ -internalAddGeneratedFile( - ' -° -+google/cloud/securitycenter/v1/source.protogoogle.cloud.securitycenter.v1"ý -Source -name (  - display_name (  - description (  -canonical_name ( :¡êA -$securitycenter.googleapis.com/Source-organizations/{organization}/sources/{source}!folders/{folder}/sources/{source}#projects/{project}/sources/{source}BØ -"com.google.cloud.securitycenter.v1PZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ToxicCombination.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ToxicCombination.php deleted file mode 100644 index c95a4ce1508d..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/ToxicCombination.php +++ /dev/null @@ -1,30 +0,0 @@ -internalAddGeneratedFile( - ' -Ÿ -6google/cloud/securitycenter/v1/toxic_combination.protogoogle.cloud.securitycenter.v1"K -ToxicCombination -attack_exposure_score ( -related_findings ( Bï -"com.google.cloud.securitycenter.v1BToxicCombinationProtoPZJcloud.google.com/go/securitycenter/apiv1/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V1ÊGoogle\\Cloud\\SecurityCenter\\V1ê!Google::Cloud::SecurityCenter::V1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Vulnerability.php b/owl-bot-staging/SecurityCenter/v1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1/Vulnerability.php deleted file mode 100644 index 96d54a80edd1311126fe443b7847161f0778b4d4..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3436 zcmbVP-BR0D5Uy>0mp>x{andvuPTG)}!~~d0TT{{zvM>T8yRtAz$1@sPJ~*1llByp! zq?74QpCEUAh2Hfwde!IX^sX<^)sbXuLkfv+Y@f6H?a$f$&Yo|-b6z@dk1Z36xSCJe zZ0n5mUlP`FZQs^ylWhg3r^ID-yXzPxaSJS4sYtfH!C2d++vY{#}cCRx`_ zJ7}+aL=RlUKhufj6L-D0vEB>J&_v5Hak)U@0W7UcJV(`>uX)7 zSUeBw9EC>p_?Z#Mz_r_bm-q0n*ZM|6lMmqEW!U`iQ)cc)It5x8h2hF5^fvPE(l9r4 zmdq2#=sl84v8lD0&3lFa*Dvrr!tBDLjdg0Z4XdMKLA}yCB$uZ8%?DQj)FOH28O)s; zuSvTPkoiD>Ls(40Q(J*)65p_LV-)1cRZb*zz8mZ1{~Ci#7#cv@XwzIwGdln-!FD8A zpB~1S!TdbD3RzAxn5QtI_dKt+m5U<#@+wuHN;7w1C2&07C0bX-45?aAGfb^z5*pkT zCT_y$V%GiKI0ievS-2XP6lBADC1aaf9p(g<$!o{7jj(NPOGPB3hcuC!pm1Mb2Tm9O z;9`B|4&1O?9&vkksD`B?v8g{9W;-{DxKm6Prrr?OR@>THZYo^KHvk6Q`V?-;V*OB+ zIYpGp>akR>3B0%`3Z?8P%p_zg)st)r&u8KYx$yWXn`Wk9Y+o$zXEV$!O!2a)h&)%x zj^%$%!Hr8D`~p^m=e0^zRM19MQaN4`8=~@J#2Dh9h$R87&A~KZmG(p#ZK6T^%QZN$ z!tGWBw7LK@oPNjK{tt{Q zK70(YrFlg4blZ)3GQ}LgoaX!3HfoRPNO|$OZ(V&*Vf7U_s@tHdj0}r0R(Qvl?!)37MorJk=#X28K(bW1rvr=9;LrK7t$rFg3^qSWZ|=$ogTG+7_*x z`OT--1U*J|dS^u1%r=Z;VjYs3rltPqnlSZHhdF{3-L_7RHr}$~9p|5^aUTLjdwfka zkv1<=hHMyEC%m{5pqY;WI)J5^BIs?OV9kC6R{pmX%nsGdXK;&C6plYs8v?IX<&jpo z11RNH@1kK5XWY~8-+N zF%Vxps#S#N7rXh~#Q~9sOwL^#*rJq@&c90mb4g9!gU@R+l14=+3w2c%zCRXap)`_} zJCM6fNUBO9sUXo^wi~*XMh?AHHR8E^7ZyfKnuR;ZbwO4|NfG3b(2&=Lxf2s`K_Yeq zPxr!B5>qyv--Gd}^p|0=&R1)~2=WpvB+L9hCzX)|Q_LdFMT^N&IxoXST=Xlzh(|Sa za|8*gG+w8XrkHtvcp=Kmxd3%NlUHFfnIvw&Y&?Xh;fNbE>;g>c4pI9o%M6J5XUGBJ ztvrpTxR5CKi0g$M6V4FR`ClMAIwdemFq2FgYJW`Ff(0*Vbqz06R(%`-<5}o-LI`yJ z#`(3-pAeZMMo=rCGK{csS8 zC&QfGUGLbV?*z>;@Tri@P|@STX>E@#{GPsBrf-A-eIpc-tnl=;QD|)ZnFuuFS496A z5s5VM9r1U1H3BIXDN3<83{xyNHd+%jQCkoClklTxI3Jkh-#f=s$!OSq3vU7b1G=&( A)&Kwi diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Access.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Access.php deleted file mode 100644 index 7e170a2e838e..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Access.php +++ /dev/null @@ -1,521 +0,0 @@ -google.cloud.securitycenter.v1.Access - */ -class Access extends \Google\Protobuf\Internal\Message -{ - /** - * Associated email, such as "foo@google.com". - * The email address of the authenticated user or a service account acting on - * behalf of a third party principal making the request. For third party - * identity callers, the `principal_subject` field is populated instead of - * this field. For privacy reasons, the principal email address is sometimes - * redacted. For more information, see [Caller identities in audit - * logs](https://cloud.google.com/logging/docs/audit#user-id). - * - * Generated from protobuf field string principal_email = 1; - */ - protected $principal_email = ''; - /** - * Caller's IP address, such as "1.1.1.1". - * - * Generated from protobuf field string caller_ip = 2; - */ - protected $caller_ip = ''; - /** - * The caller IP's geolocation, which identifies where the call came from. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Geolocation caller_ip_geo = 3; - */ - protected $caller_ip_geo = null; - /** - * Type of user agent associated with the finding. For example, an operating - * system shell or an embedded or standalone application. - * - * Generated from protobuf field string user_agent_family = 4; - */ - protected $user_agent_family = ''; - /** - * The caller's user agent string associated with the finding. - * - * Generated from protobuf field string user_agent = 12; - */ - protected $user_agent = ''; - /** - * This is the API service that the service account made a call to, e.g. - * "iam.googleapis.com" - * - * Generated from protobuf field string service_name = 5; - */ - protected $service_name = ''; - /** - * The method that the service account called, e.g. "SetIamPolicy". - * - * Generated from protobuf field string method_name = 6; - */ - protected $method_name = ''; - /** - * A string that represents the principal_subject that is associated with the - * identity. Unlike `principal_email`, `principal_subject` supports principals - * that aren't associated with email addresses, such as third party - * principals. For most identities, the format is - * `principal://iam.googleapis.com/{identity pool name}/subject/{subject}`. - * Some GKE identities, such as GKE_WORKLOAD, FREEFORM, and GKE_HUB_WORKLOAD, - * still use the legacy format `serviceAccount:{identity pool - * name}[{subject}]`. - * - * Generated from protobuf field string principal_subject = 7; - */ - protected $principal_subject = ''; - /** - * The name of the service account key that was used to create or exchange - * credentials when authenticating the service account that made the request. - * This is a scheme-less URI full resource name. For example: - * "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}". - * - * Generated from protobuf field string service_account_key_name = 8; - */ - protected $service_account_key_name = ''; - /** - * The identity delegation history of an authenticated service account that - * made the request. The `serviceAccountDelegationInfo[]` object contains - * information about the real authorities that try to access Google Cloud - * resources by delegating on a service account. When multiple authorities are - * present, they are guaranteed to be sorted based on the original ordering of - * the identity delegation events. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ServiceAccountDelegationInfo service_account_delegation_info = 9; - */ - private $service_account_delegation_info; - /** - * A string that represents a username. The username provided depends on the - * type of the finding and is likely not an IAM principal. For example, this - * can be a system username if the finding is related to a virtual machine, or - * it can be an application login username. - * - * Generated from protobuf field string user_name = 11; - */ - protected $user_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $principal_email - * Associated email, such as "foo@google.com". - * The email address of the authenticated user or a service account acting on - * behalf of a third party principal making the request. For third party - * identity callers, the `principal_subject` field is populated instead of - * this field. For privacy reasons, the principal email address is sometimes - * redacted. For more information, see [Caller identities in audit - * logs](https://cloud.google.com/logging/docs/audit#user-id). - * @type string $caller_ip - * Caller's IP address, such as "1.1.1.1". - * @type \Google\Cloud\SecurityCenter\V1\Geolocation $caller_ip_geo - * The caller IP's geolocation, which identifies where the call came from. - * @type string $user_agent_family - * Type of user agent associated with the finding. For example, an operating - * system shell or an embedded or standalone application. - * @type string $user_agent - * The caller's user agent string associated with the finding. - * @type string $service_name - * This is the API service that the service account made a call to, e.g. - * "iam.googleapis.com" - * @type string $method_name - * The method that the service account called, e.g. "SetIamPolicy". - * @type string $principal_subject - * A string that represents the principal_subject that is associated with the - * identity. Unlike `principal_email`, `principal_subject` supports principals - * that aren't associated with email addresses, such as third party - * principals. For most identities, the format is - * `principal://iam.googleapis.com/{identity pool name}/subject/{subject}`. - * Some GKE identities, such as GKE_WORKLOAD, FREEFORM, and GKE_HUB_WORKLOAD, - * still use the legacy format `serviceAccount:{identity pool - * name}[{subject}]`. - * @type string $service_account_key_name - * The name of the service account key that was used to create or exchange - * credentials when authenticating the service account that made the request. - * This is a scheme-less URI full resource name. For example: - * "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}". - * @type array<\Google\Cloud\SecurityCenter\V1\ServiceAccountDelegationInfo>|\Google\Protobuf\Internal\RepeatedField $service_account_delegation_info - * The identity delegation history of an authenticated service account that - * made the request. The `serviceAccountDelegationInfo[]` object contains - * information about the real authorities that try to access Google Cloud - * resources by delegating on a service account. When multiple authorities are - * present, they are guaranteed to be sorted based on the original ordering of - * the identity delegation events. - * @type string $user_name - * A string that represents a username. The username provided depends on the - * type of the finding and is likely not an IAM principal. For example, this - * can be a system username if the finding is related to a virtual machine, or - * it can be an application login username. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Access::initOnce(); - parent::__construct($data); - } - - /** - * Associated email, such as "foo@google.com". - * The email address of the authenticated user or a service account acting on - * behalf of a third party principal making the request. For third party - * identity callers, the `principal_subject` field is populated instead of - * this field. For privacy reasons, the principal email address is sometimes - * redacted. For more information, see [Caller identities in audit - * logs](https://cloud.google.com/logging/docs/audit#user-id). - * - * Generated from protobuf field string principal_email = 1; - * @return string - */ - public function getPrincipalEmail() - { - return $this->principal_email; - } - - /** - * Associated email, such as "foo@google.com". - * The email address of the authenticated user or a service account acting on - * behalf of a third party principal making the request. For third party - * identity callers, the `principal_subject` field is populated instead of - * this field. For privacy reasons, the principal email address is sometimes - * redacted. For more information, see [Caller identities in audit - * logs](https://cloud.google.com/logging/docs/audit#user-id). - * - * Generated from protobuf field string principal_email = 1; - * @param string $var - * @return $this - */ - public function setPrincipalEmail($var) - { - GPBUtil::checkString($var, True); - $this->principal_email = $var; - - return $this; - } - - /** - * Caller's IP address, such as "1.1.1.1". - * - * Generated from protobuf field string caller_ip = 2; - * @return string - */ - public function getCallerIp() - { - return $this->caller_ip; - } - - /** - * Caller's IP address, such as "1.1.1.1". - * - * Generated from protobuf field string caller_ip = 2; - * @param string $var - * @return $this - */ - public function setCallerIp($var) - { - GPBUtil::checkString($var, True); - $this->caller_ip = $var; - - return $this; - } - - /** - * The caller IP's geolocation, which identifies where the call came from. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Geolocation caller_ip_geo = 3; - * @return \Google\Cloud\SecurityCenter\V1\Geolocation|null - */ - public function getCallerIpGeo() - { - return $this->caller_ip_geo; - } - - public function hasCallerIpGeo() - { - return isset($this->caller_ip_geo); - } - - public function clearCallerIpGeo() - { - unset($this->caller_ip_geo); - } - - /** - * The caller IP's geolocation, which identifies where the call came from. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Geolocation caller_ip_geo = 3; - * @param \Google\Cloud\SecurityCenter\V1\Geolocation $var - * @return $this - */ - public function setCallerIpGeo($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Geolocation::class); - $this->caller_ip_geo = $var; - - return $this; - } - - /** - * Type of user agent associated with the finding. For example, an operating - * system shell or an embedded or standalone application. - * - * Generated from protobuf field string user_agent_family = 4; - * @return string - */ - public function getUserAgentFamily() - { - return $this->user_agent_family; - } - - /** - * Type of user agent associated with the finding. For example, an operating - * system shell or an embedded or standalone application. - * - * Generated from protobuf field string user_agent_family = 4; - * @param string $var - * @return $this - */ - public function setUserAgentFamily($var) - { - GPBUtil::checkString($var, True); - $this->user_agent_family = $var; - - return $this; - } - - /** - * The caller's user agent string associated with the finding. - * - * Generated from protobuf field string user_agent = 12; - * @return string - */ - public function getUserAgent() - { - return $this->user_agent; - } - - /** - * The caller's user agent string associated with the finding. - * - * Generated from protobuf field string user_agent = 12; - * @param string $var - * @return $this - */ - public function setUserAgent($var) - { - GPBUtil::checkString($var, True); - $this->user_agent = $var; - - return $this; - } - - /** - * This is the API service that the service account made a call to, e.g. - * "iam.googleapis.com" - * - * Generated from protobuf field string service_name = 5; - * @return string - */ - public function getServiceName() - { - return $this->service_name; - } - - /** - * This is the API service that the service account made a call to, e.g. - * "iam.googleapis.com" - * - * Generated from protobuf field string service_name = 5; - * @param string $var - * @return $this - */ - public function setServiceName($var) - { - GPBUtil::checkString($var, True); - $this->service_name = $var; - - return $this; - } - - /** - * The method that the service account called, e.g. "SetIamPolicy". - * - * Generated from protobuf field string method_name = 6; - * @return string - */ - public function getMethodName() - { - return $this->method_name; - } - - /** - * The method that the service account called, e.g. "SetIamPolicy". - * - * Generated from protobuf field string method_name = 6; - * @param string $var - * @return $this - */ - public function setMethodName($var) - { - GPBUtil::checkString($var, True); - $this->method_name = $var; - - return $this; - } - - /** - * A string that represents the principal_subject that is associated with the - * identity. Unlike `principal_email`, `principal_subject` supports principals - * that aren't associated with email addresses, such as third party - * principals. For most identities, the format is - * `principal://iam.googleapis.com/{identity pool name}/subject/{subject}`. - * Some GKE identities, such as GKE_WORKLOAD, FREEFORM, and GKE_HUB_WORKLOAD, - * still use the legacy format `serviceAccount:{identity pool - * name}[{subject}]`. - * - * Generated from protobuf field string principal_subject = 7; - * @return string - */ - public function getPrincipalSubject() - { - return $this->principal_subject; - } - - /** - * A string that represents the principal_subject that is associated with the - * identity. Unlike `principal_email`, `principal_subject` supports principals - * that aren't associated with email addresses, such as third party - * principals. For most identities, the format is - * `principal://iam.googleapis.com/{identity pool name}/subject/{subject}`. - * Some GKE identities, such as GKE_WORKLOAD, FREEFORM, and GKE_HUB_WORKLOAD, - * still use the legacy format `serviceAccount:{identity pool - * name}[{subject}]`. - * - * Generated from protobuf field string principal_subject = 7; - * @param string $var - * @return $this - */ - public function setPrincipalSubject($var) - { - GPBUtil::checkString($var, True); - $this->principal_subject = $var; - - return $this; - } - - /** - * The name of the service account key that was used to create or exchange - * credentials when authenticating the service account that made the request. - * This is a scheme-less URI full resource name. For example: - * "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}". - * - * Generated from protobuf field string service_account_key_name = 8; - * @return string - */ - public function getServiceAccountKeyName() - { - return $this->service_account_key_name; - } - - /** - * The name of the service account key that was used to create or exchange - * credentials when authenticating the service account that made the request. - * This is a scheme-less URI full resource name. For example: - * "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}". - * - * Generated from protobuf field string service_account_key_name = 8; - * @param string $var - * @return $this - */ - public function setServiceAccountKeyName($var) - { - GPBUtil::checkString($var, True); - $this->service_account_key_name = $var; - - return $this; - } - - /** - * The identity delegation history of an authenticated service account that - * made the request. The `serviceAccountDelegationInfo[]` object contains - * information about the real authorities that try to access Google Cloud - * resources by delegating on a service account. When multiple authorities are - * present, they are guaranteed to be sorted based on the original ordering of - * the identity delegation events. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ServiceAccountDelegationInfo service_account_delegation_info = 9; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getServiceAccountDelegationInfo() - { - return $this->service_account_delegation_info; - } - - /** - * The identity delegation history of an authenticated service account that - * made the request. The `serviceAccountDelegationInfo[]` object contains - * information about the real authorities that try to access Google Cloud - * resources by delegating on a service account. When multiple authorities are - * present, they are guaranteed to be sorted based on the original ordering of - * the identity delegation events. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ServiceAccountDelegationInfo service_account_delegation_info = 9; - * @param array<\Google\Cloud\SecurityCenter\V1\ServiceAccountDelegationInfo>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setServiceAccountDelegationInfo($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\ServiceAccountDelegationInfo::class); - $this->service_account_delegation_info = $arr; - - return $this; - } - - /** - * A string that represents a username. The username provided depends on the - * type of the finding and is likely not an IAM principal. For example, this - * can be a system username if the finding is related to a virtual machine, or - * it can be an application login username. - * - * Generated from protobuf field string user_name = 11; - * @return string - */ - public function getUserName() - { - return $this->user_name; - } - - /** - * A string that represents a username. The username provided depends on the - * type of the finding and is likely not an IAM principal. For example, this - * can be a system username if the finding is related to a virtual machine, or - * it can be an application login username. - * - * Generated from protobuf field string user_name = 11; - * @param string $var - * @return $this - */ - public function setUserName($var) - { - GPBUtil::checkString($var, True); - $this->user_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/AdaptiveProtection.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/AdaptiveProtection.php deleted file mode 100644 index ff0bc1a51916..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/AdaptiveProtection.php +++ /dev/null @@ -1,84 +0,0 @@ -google.cloud.securitycenter.v1.AdaptiveProtection - */ -class AdaptiveProtection extends \Google\Protobuf\Internal\Message -{ - /** - * A score of 0 means that there is low confidence that the detected event is - * an actual attack. A score of 1 means that there is high confidence that the - * detected event is an attack. See the [Adaptive Protection - * documentation](https://cloud.google.com/armor/docs/adaptive-protection-overview#configure-alert-tuning) - * for further explanation. - * - * Generated from protobuf field double confidence = 1; - */ - protected $confidence = 0.0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type float $confidence - * A score of 0 means that there is low confidence that the detected event is - * an actual attack. A score of 1 means that there is high confidence that the - * detected event is an attack. See the [Adaptive Protection - * documentation](https://cloud.google.com/armor/docs/adaptive-protection-overview#configure-alert-tuning) - * for further explanation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\CloudArmor::initOnce(); - parent::__construct($data); - } - - /** - * A score of 0 means that there is low confidence that the detected event is - * an actual attack. A score of 1 means that there is high confidence that the - * detected event is an attack. See the [Adaptive Protection - * documentation](https://cloud.google.com/armor/docs/adaptive-protection-overview#configure-alert-tuning) - * for further explanation. - * - * Generated from protobuf field double confidence = 1; - * @return float - */ - public function getConfidence() - { - return $this->confidence; - } - - /** - * A score of 0 means that there is low confidence that the detected event is - * an actual attack. A score of 1 means that there is high confidence that the - * detected event is an attack. See the [Adaptive Protection - * documentation](https://cloud.google.com/armor/docs/adaptive-protection-overview#configure-alert-tuning) - * for further explanation. - * - * Generated from protobuf field double confidence = 1; - * @param float $var - * @return $this - */ - public function setConfidence($var) - { - GPBUtil::checkDouble($var); - $this->confidence = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Application.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Application.php deleted file mode 100644 index 9d6b9c134d80..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Application.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.securitycenter.v1.Application - */ -class Application extends \Google\Protobuf\Internal\Message -{ - /** - * The base URI that identifies the network location of the application in - * which the vulnerability was detected. For example, `http://example.com`. - * - * Generated from protobuf field string base_uri = 1; - */ - protected $base_uri = ''; - /** - * The full URI with payload that can be used to reproduce the - * vulnerability. For example, `http://example.com?p=aMmYgI6H`. - * - * Generated from protobuf field string full_uri = 2; - */ - protected $full_uri = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $base_uri - * The base URI that identifies the network location of the application in - * which the vulnerability was detected. For example, `http://example.com`. - * @type string $full_uri - * The full URI with payload that can be used to reproduce the - * vulnerability. For example, `http://example.com?p=aMmYgI6H`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Application::initOnce(); - parent::__construct($data); - } - - /** - * The base URI that identifies the network location of the application in - * which the vulnerability was detected. For example, `http://example.com`. - * - * Generated from protobuf field string base_uri = 1; - * @return string - */ - public function getBaseUri() - { - return $this->base_uri; - } - - /** - * The base URI that identifies the network location of the application in - * which the vulnerability was detected. For example, `http://example.com`. - * - * Generated from protobuf field string base_uri = 1; - * @param string $var - * @return $this - */ - public function setBaseUri($var) - { - GPBUtil::checkString($var, True); - $this->base_uri = $var; - - return $this; - } - - /** - * The full URI with payload that can be used to reproduce the - * vulnerability. For example, `http://example.com?p=aMmYgI6H`. - * - * Generated from protobuf field string full_uri = 2; - * @return string - */ - public function getFullUri() - { - return $this->full_uri; - } - - /** - * The full URI with payload that can be used to reproduce the - * vulnerability. For example, `http://example.com?p=aMmYgI6H`. - * - * Generated from protobuf field string full_uri = 2; - * @param string $var - * @return $this - */ - public function setFullUri($var) - { - GPBUtil::checkString($var, True); - $this->full_uri = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset.php deleted file mode 100644 index 9a5c7fa0c831..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset.php +++ /dev/null @@ -1,412 +0,0 @@ -google.cloud.securitycenter.v1.Asset - */ -class Asset extends \Google\Protobuf\Internal\Message -{ - /** - * The relative resource name of this asset. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/assets/{asset_id}". - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Security Command Center managed properties. These properties are managed by - * Security Command Center and cannot be modified by the user. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Asset.SecurityCenterProperties security_center_properties = 2; - */ - protected $security_center_properties = null; - /** - * Resource managed properties. These properties are managed and defined by - * the Google Cloud resource and cannot be modified by the user. - * - * Generated from protobuf field map resource_properties = 7; - */ - private $resource_properties; - /** - * User specified security marks. These marks are entirely managed by the user - * and come from the SecurityMarks resource that belongs to the asset. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityMarks security_marks = 8; - */ - protected $security_marks = null; - /** - * The time at which the asset was created in Security Command Center. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 9; - */ - protected $create_time = null; - /** - * The time at which the asset was last updated or added in Cloud SCC. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 10; - */ - protected $update_time = null; - /** - * Cloud IAM Policy information associated with the Google Cloud resource - * described by the Security Command Center asset. This information is managed - * and defined by the Google Cloud resource and cannot be modified by the - * user. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Asset.IamPolicy iam_policy = 11; - */ - protected $iam_policy = null; - /** - * The canonical name of the resource. It's either - * "organizations/{organization_id}/assets/{asset_id}", - * "folders/{folder_id}/assets/{asset_id}" or - * "projects/{project_number}/assets/{asset_id}", depending on the closest CRM - * ancestor of the resource. - * - * Generated from protobuf field string canonical_name = 13; - */ - protected $canonical_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The relative resource name of this asset. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/assets/{asset_id}". - * @type \Google\Cloud\SecurityCenter\V1\Asset\SecurityCenterProperties $security_center_properties - * Security Command Center managed properties. These properties are managed by - * Security Command Center and cannot be modified by the user. - * @type array|\Google\Protobuf\Internal\MapField $resource_properties - * Resource managed properties. These properties are managed and defined by - * the Google Cloud resource and cannot be modified by the user. - * @type \Google\Cloud\SecurityCenter\V1\SecurityMarks $security_marks - * User specified security marks. These marks are entirely managed by the user - * and come from the SecurityMarks resource that belongs to the asset. - * @type \Google\Protobuf\Timestamp $create_time - * The time at which the asset was created in Security Command Center. - * @type \Google\Protobuf\Timestamp $update_time - * The time at which the asset was last updated or added in Cloud SCC. - * @type \Google\Cloud\SecurityCenter\V1\Asset\IamPolicy $iam_policy - * Cloud IAM Policy information associated with the Google Cloud resource - * described by the Security Command Center asset. This information is managed - * and defined by the Google Cloud resource and cannot be modified by the - * user. - * @type string $canonical_name - * The canonical name of the resource. It's either - * "organizations/{organization_id}/assets/{asset_id}", - * "folders/{folder_id}/assets/{asset_id}" or - * "projects/{project_number}/assets/{asset_id}", depending on the closest CRM - * ancestor of the resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Asset::initOnce(); - parent::__construct($data); - } - - /** - * The relative resource name of this asset. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/assets/{asset_id}". - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The relative resource name of this asset. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/assets/{asset_id}". - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Security Command Center managed properties. These properties are managed by - * Security Command Center and cannot be modified by the user. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Asset.SecurityCenterProperties security_center_properties = 2; - * @return \Google\Cloud\SecurityCenter\V1\Asset\SecurityCenterProperties|null - */ - public function getSecurityCenterProperties() - { - return $this->security_center_properties; - } - - public function hasSecurityCenterProperties() - { - return isset($this->security_center_properties); - } - - public function clearSecurityCenterProperties() - { - unset($this->security_center_properties); - } - - /** - * Security Command Center managed properties. These properties are managed by - * Security Command Center and cannot be modified by the user. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Asset.SecurityCenterProperties security_center_properties = 2; - * @param \Google\Cloud\SecurityCenter\V1\Asset\SecurityCenterProperties $var - * @return $this - */ - public function setSecurityCenterProperties($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Asset\SecurityCenterProperties::class); - $this->security_center_properties = $var; - - return $this; - } - - /** - * Resource managed properties. These properties are managed and defined by - * the Google Cloud resource and cannot be modified by the user. - * - * Generated from protobuf field map resource_properties = 7; - * @return \Google\Protobuf\Internal\MapField - */ - public function getResourceProperties() - { - return $this->resource_properties; - } - - /** - * Resource managed properties. These properties are managed and defined by - * the Google Cloud resource and cannot be modified by the user. - * - * Generated from protobuf field map resource_properties = 7; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setResourceProperties($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Value::class); - $this->resource_properties = $arr; - - return $this; - } - - /** - * User specified security marks. These marks are entirely managed by the user - * and come from the SecurityMarks resource that belongs to the asset. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityMarks security_marks = 8; - * @return \Google\Cloud\SecurityCenter\V1\SecurityMarks|null - */ - public function getSecurityMarks() - { - return $this->security_marks; - } - - public function hasSecurityMarks() - { - return isset($this->security_marks); - } - - public function clearSecurityMarks() - { - unset($this->security_marks); - } - - /** - * User specified security marks. These marks are entirely managed by the user - * and come from the SecurityMarks resource that belongs to the asset. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityMarks security_marks = 8; - * @param \Google\Cloud\SecurityCenter\V1\SecurityMarks $var - * @return $this - */ - public function setSecurityMarks($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SecurityMarks::class); - $this->security_marks = $var; - - return $this; - } - - /** - * The time at which the asset was created in Security Command Center. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 9; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * The time at which the asset was created in Security Command Center. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 9; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * The time at which the asset was last updated or added in Cloud SCC. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 10; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * The time at which the asset was last updated or added in Cloud SCC. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 10; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Cloud IAM Policy information associated with the Google Cloud resource - * described by the Security Command Center asset. This information is managed - * and defined by the Google Cloud resource and cannot be modified by the - * user. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Asset.IamPolicy iam_policy = 11; - * @return \Google\Cloud\SecurityCenter\V1\Asset\IamPolicy|null - */ - public function getIamPolicy() - { - return $this->iam_policy; - } - - public function hasIamPolicy() - { - return isset($this->iam_policy); - } - - public function clearIamPolicy() - { - unset($this->iam_policy); - } - - /** - * Cloud IAM Policy information associated with the Google Cloud resource - * described by the Security Command Center asset. This information is managed - * and defined by the Google Cloud resource and cannot be modified by the - * user. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Asset.IamPolicy iam_policy = 11; - * @param \Google\Cloud\SecurityCenter\V1\Asset\IamPolicy $var - * @return $this - */ - public function setIamPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Asset\IamPolicy::class); - $this->iam_policy = $var; - - return $this; - } - - /** - * The canonical name of the resource. It's either - * "organizations/{organization_id}/assets/{asset_id}", - * "folders/{folder_id}/assets/{asset_id}" or - * "projects/{project_number}/assets/{asset_id}", depending on the closest CRM - * ancestor of the resource. - * - * Generated from protobuf field string canonical_name = 13; - * @return string - */ - public function getCanonicalName() - { - return $this->canonical_name; - } - - /** - * The canonical name of the resource. It's either - * "organizations/{organization_id}/assets/{asset_id}", - * "folders/{folder_id}/assets/{asset_id}" or - * "projects/{project_number}/assets/{asset_id}", depending on the closest CRM - * ancestor of the resource. - * - * Generated from protobuf field string canonical_name = 13; - * @param string $var - * @return $this - */ - public function setCanonicalName($var) - { - GPBUtil::checkString($var, True); - $this->canonical_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset/IamPolicy.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset/IamPolicy.php deleted file mode 100644 index 6df487a6cfce..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset/IamPolicy.php +++ /dev/null @@ -1,81 +0,0 @@ -google.cloud.securitycenter.v1.Asset.IamPolicy - */ -class IamPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * The JSON representation of the Policy associated with the asset. - * See https://cloud.google.com/iam/reference/rest/v1/Policy for format - * details. - * - * Generated from protobuf field string policy_blob = 1; - */ - protected $policy_blob = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $policy_blob - * The JSON representation of the Policy associated with the asset. - * See https://cloud.google.com/iam/reference/rest/v1/Policy for format - * details. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Asset::initOnce(); - parent::__construct($data); - } - - /** - * The JSON representation of the Policy associated with the asset. - * See https://cloud.google.com/iam/reference/rest/v1/Policy for format - * details. - * - * Generated from protobuf field string policy_blob = 1; - * @return string - */ - public function getPolicyBlob() - { - return $this->policy_blob; - } - - /** - * The JSON representation of the Policy associated with the asset. - * See https://cloud.google.com/iam/reference/rest/v1/Policy for format - * details. - * - * Generated from protobuf field string policy_blob = 1; - * @param string $var - * @return $this - */ - public function setPolicyBlob($var) - { - GPBUtil::checkString($var, True); - $this->policy_blob = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(IamPolicy::class, \Google\Cloud\SecurityCenter\V1\Asset_IamPolicy::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset/SecurityCenterProperties.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset/SecurityCenterProperties.php deleted file mode 100644 index e52bfc4be7db..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Asset/SecurityCenterProperties.php +++ /dev/null @@ -1,379 +0,0 @@ -google.cloud.securitycenter.v1.Asset.SecurityCenterProperties - */ -class SecurityCenterProperties extends \Google\Protobuf\Internal\Message -{ - /** - * The full resource name of the Google Cloud resource this asset - * represents. This field is immutable after create time. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_name = 1; - */ - protected $resource_name = ''; - /** - * The type of the Google Cloud resource. Examples include: APPLICATION, - * PROJECT, and ORGANIZATION. This is a case insensitive field defined by - * Security Command Center and/or the producer of the resource and is - * immutable after create time. - * - * Generated from protobuf field string resource_type = 2; - */ - protected $resource_type = ''; - /** - * The full resource name of the immediate parent of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_parent = 3; - */ - protected $resource_parent = ''; - /** - * The full resource name of the project the resource belongs to. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_project = 4; - */ - protected $resource_project = ''; - /** - * Owners of the Google Cloud resource. - * - * Generated from protobuf field repeated string resource_owners = 5; - */ - private $resource_owners; - /** - * The user defined display name for this resource. - * - * Generated from protobuf field string resource_display_name = 6; - */ - protected $resource_display_name = ''; - /** - * The user defined display name for the parent of this resource. - * - * Generated from protobuf field string resource_parent_display_name = 7; - */ - protected $resource_parent_display_name = ''; - /** - * The user defined display name for the project of this resource. - * - * Generated from protobuf field string resource_project_display_name = 8; - */ - protected $resource_project_display_name = ''; - /** - * Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is the - * folder directly under the Organization. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Folder folders = 10; - */ - private $folders; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $resource_name - * The full resource name of the Google Cloud resource this asset - * represents. This field is immutable after create time. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * @type string $resource_type - * The type of the Google Cloud resource. Examples include: APPLICATION, - * PROJECT, and ORGANIZATION. This is a case insensitive field defined by - * Security Command Center and/or the producer of the resource and is - * immutable after create time. - * @type string $resource_parent - * The full resource name of the immediate parent of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * @type string $resource_project - * The full resource name of the project the resource belongs to. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * @type array|\Google\Protobuf\Internal\RepeatedField $resource_owners - * Owners of the Google Cloud resource. - * @type string $resource_display_name - * The user defined display name for this resource. - * @type string $resource_parent_display_name - * The user defined display name for the parent of this resource. - * @type string $resource_project_display_name - * The user defined display name for the project of this resource. - * @type array<\Google\Cloud\SecurityCenter\V1\Folder>|\Google\Protobuf\Internal\RepeatedField $folders - * Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is the - * folder directly under the Organization. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Asset::initOnce(); - parent::__construct($data); - } - - /** - * The full resource name of the Google Cloud resource this asset - * represents. This field is immutable after create time. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_name = 1; - * @return string - */ - public function getResourceName() - { - return $this->resource_name; - } - - /** - * The full resource name of the Google Cloud resource this asset - * represents. This field is immutable after create time. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_name = 1; - * @param string $var - * @return $this - */ - public function setResourceName($var) - { - GPBUtil::checkString($var, True); - $this->resource_name = $var; - - return $this; - } - - /** - * The type of the Google Cloud resource. Examples include: APPLICATION, - * PROJECT, and ORGANIZATION. This is a case insensitive field defined by - * Security Command Center and/or the producer of the resource and is - * immutable after create time. - * - * Generated from protobuf field string resource_type = 2; - * @return string - */ - public function getResourceType() - { - return $this->resource_type; - } - - /** - * The type of the Google Cloud resource. Examples include: APPLICATION, - * PROJECT, and ORGANIZATION. This is a case insensitive field defined by - * Security Command Center and/or the producer of the resource and is - * immutable after create time. - * - * Generated from protobuf field string resource_type = 2; - * @param string $var - * @return $this - */ - public function setResourceType($var) - { - GPBUtil::checkString($var, True); - $this->resource_type = $var; - - return $this; - } - - /** - * The full resource name of the immediate parent of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_parent = 3; - * @return string - */ - public function getResourceParent() - { - return $this->resource_parent; - } - - /** - * The full resource name of the immediate parent of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_parent = 3; - * @param string $var - * @return $this - */ - public function setResourceParent($var) - { - GPBUtil::checkString($var, True); - $this->resource_parent = $var; - - return $this; - } - - /** - * The full resource name of the project the resource belongs to. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_project = 4; - * @return string - */ - public function getResourceProject() - { - return $this->resource_project; - } - - /** - * The full resource name of the project the resource belongs to. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_project = 4; - * @param string $var - * @return $this - */ - public function setResourceProject($var) - { - GPBUtil::checkString($var, True); - $this->resource_project = $var; - - return $this; - } - - /** - * Owners of the Google Cloud resource. - * - * Generated from protobuf field repeated string resource_owners = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getResourceOwners() - { - return $this->resource_owners; - } - - /** - * Owners of the Google Cloud resource. - * - * Generated from protobuf field repeated string resource_owners = 5; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setResourceOwners($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->resource_owners = $arr; - - return $this; - } - - /** - * The user defined display name for this resource. - * - * Generated from protobuf field string resource_display_name = 6; - * @return string - */ - public function getResourceDisplayName() - { - return $this->resource_display_name; - } - - /** - * The user defined display name for this resource. - * - * Generated from protobuf field string resource_display_name = 6; - * @param string $var - * @return $this - */ - public function setResourceDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->resource_display_name = $var; - - return $this; - } - - /** - * The user defined display name for the parent of this resource. - * - * Generated from protobuf field string resource_parent_display_name = 7; - * @return string - */ - public function getResourceParentDisplayName() - { - return $this->resource_parent_display_name; - } - - /** - * The user defined display name for the parent of this resource. - * - * Generated from protobuf field string resource_parent_display_name = 7; - * @param string $var - * @return $this - */ - public function setResourceParentDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->resource_parent_display_name = $var; - - return $this; - } - - /** - * The user defined display name for the project of this resource. - * - * Generated from protobuf field string resource_project_display_name = 8; - * @return string - */ - public function getResourceProjectDisplayName() - { - return $this->resource_project_display_name; - } - - /** - * The user defined display name for the project of this resource. - * - * Generated from protobuf field string resource_project_display_name = 8; - * @param string $var - * @return $this - */ - public function setResourceProjectDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->resource_project_display_name = $var; - - return $this; - } - - /** - * Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is the - * folder directly under the Organization. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Folder folders = 10; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFolders() - { - return $this->folders; - } - - /** - * Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is the - * folder directly under the Organization. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Folder folders = 10; - * @param array<\Google\Cloud\SecurityCenter\V1\Folder>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFolders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Folder::class); - $this->folders = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SecurityCenterProperties::class, \Google\Cloud\SecurityCenter\V1\Asset_SecurityCenterProperties::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Attack.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Attack.php deleted file mode 100644 index 9e82c4b8ffd9..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Attack.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.securitycenter.v1.Attack - */ -class Attack extends \Google\Protobuf\Internal\Message -{ - /** - * Total PPS (packets per second) volume of attack. - * - * Generated from protobuf field int32 volume_pps = 1; - */ - protected $volume_pps = 0; - /** - * Total BPS (bytes per second) volume of attack. - * - * Generated from protobuf field int32 volume_bps = 2; - */ - protected $volume_bps = 0; - /** - * Type of attack, for example, ‘SYN-flood’, ‘NTP-udp’, or ‘CHARGEN-udp’. - * - * Generated from protobuf field string classification = 3; - */ - protected $classification = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $volume_pps - * Total PPS (packets per second) volume of attack. - * @type int $volume_bps - * Total BPS (bytes per second) volume of attack. - * @type string $classification - * Type of attack, for example, ‘SYN-flood’, ‘NTP-udp’, or ‘CHARGEN-udp’. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\CloudArmor::initOnce(); - parent::__construct($data); - } - - /** - * Total PPS (packets per second) volume of attack. - * - * Generated from protobuf field int32 volume_pps = 1; - * @return int - */ - public function getVolumePps() - { - return $this->volume_pps; - } - - /** - * Total PPS (packets per second) volume of attack. - * - * Generated from protobuf field int32 volume_pps = 1; - * @param int $var - * @return $this - */ - public function setVolumePps($var) - { - GPBUtil::checkInt32($var); - $this->volume_pps = $var; - - return $this; - } - - /** - * Total BPS (bytes per second) volume of attack. - * - * Generated from protobuf field int32 volume_bps = 2; - * @return int - */ - public function getVolumeBps() - { - return $this->volume_bps; - } - - /** - * Total BPS (bytes per second) volume of attack. - * - * Generated from protobuf field int32 volume_bps = 2; - * @param int $var - * @return $this - */ - public function setVolumeBps($var) - { - GPBUtil::checkInt32($var); - $this->volume_bps = $var; - - return $this; - } - - /** - * Type of attack, for example, ‘SYN-flood’, ‘NTP-udp’, or ‘CHARGEN-udp’. - * - * Generated from protobuf field string classification = 3; - * @return string - */ - public function getClassification() - { - return $this->classification; - } - - /** - * Type of attack, for example, ‘SYN-flood’, ‘NTP-udp’, or ‘CHARGEN-udp’. - * - * Generated from protobuf field string classification = 3; - * @param string $var - * @return $this - */ - public function setClassification($var) - { - GPBUtil::checkString($var, True); - $this->classification = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BackupDisasterRecovery.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BackupDisasterRecovery.php deleted file mode 100644 index 82e7db8a2ad7..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BackupDisasterRecovery.php +++ /dev/null @@ -1,495 +0,0 @@ -google.cloud.securitycenter.v1.BackupDisasterRecovery - */ -class BackupDisasterRecovery extends \Google\Protobuf\Internal\Message -{ - /** - * The name of a Backup and DR template which comprises one or more backup - * policies. See the [Backup and DR - * documentation](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#temp) - * for more information. For example, `snap-ov`. - * - * Generated from protobuf field string backup_template = 1; - */ - protected $backup_template = ''; - /** - * The names of Backup and DR policies that are associated with a template - * and that define when to run a backup, how frequently to run a backup, and - * how long to retain the backup image. For example, `onvaults`. - * - * Generated from protobuf field repeated string policies = 2; - */ - private $policies; - /** - * The name of a Backup and DR host, which is managed by the backup and - * recovery appliance and known to the management console. The host can be of - * type Generic (for example, Compute Engine, SQL Server, Oracle DB, SMB file - * system, etc.), vCenter, or an ESX server. See the [Backup and DR - * documentation on - * hosts](https://cloud.google.com/backup-disaster-recovery/docs/configuration/manage-hosts-and-their-applications) - * for more information. For example, `centos7-01`. - * - * Generated from protobuf field string host = 3; - */ - protected $host = ''; - /** - * The names of Backup and DR applications. An application is a VM, database, - * or file system on a managed host monitored by a backup and recovery - * appliance. For example, `centos7-01-vol00`, `centos7-01-vol01`, - * `centos7-01-vol02`. - * - * Generated from protobuf field repeated string applications = 4; - */ - private $applications; - /** - * The name of the Backup and DR storage pool that the backup and recovery - * appliance is storing data in. The storage pool could be of type Cloud, - * Primary, Snapshot, or OnVault. See the [Backup and DR documentation on - * storage - * pools](https://cloud.google.com/backup-disaster-recovery/docs/concepts/storage-pools). - * For example, `DiskPoolOne`. - * - * Generated from protobuf field string storage_pool = 5; - */ - protected $storage_pool = ''; - /** - * The names of Backup and DR advanced policy options of a policy applying to - * an application. See the [Backup and DR documentation on policy - * options](https://cloud.google.com/backup-disaster-recovery/docs/create-plan/policy-settings). - * For example, `skipofflineappsincongrp, nounmap`. - * - * Generated from protobuf field repeated string policy_options = 6; - */ - private $policy_options; - /** - * The name of the Backup and DR resource profile that specifies the storage - * media for backups of application and VM data. See the [Backup and DR - * documentation on - * profiles](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#profile). - * For example, `GCP`. - * - * Generated from protobuf field string profile = 7; - */ - protected $profile = ''; - /** - * The name of the Backup and DR appliance that captures, moves, and manages - * the lifecycle of backup data. For example, `backup-server-57137`. - * - * Generated from protobuf field string appliance = 8; - */ - protected $appliance = ''; - /** - * The backup type of the Backup and DR image. - * For example, `Snapshot`, `Remote Snapshot`, `OnVault`. - * - * Generated from protobuf field string backup_type = 9; - */ - protected $backup_type = ''; - /** - * The timestamp at which the Backup and DR backup was created. - * - * Generated from protobuf field .google.protobuf.Timestamp backup_create_time = 10; - */ - protected $backup_create_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $backup_template - * The name of a Backup and DR template which comprises one or more backup - * policies. See the [Backup and DR - * documentation](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#temp) - * for more information. For example, `snap-ov`. - * @type array|\Google\Protobuf\Internal\RepeatedField $policies - * The names of Backup and DR policies that are associated with a template - * and that define when to run a backup, how frequently to run a backup, and - * how long to retain the backup image. For example, `onvaults`. - * @type string $host - * The name of a Backup and DR host, which is managed by the backup and - * recovery appliance and known to the management console. The host can be of - * type Generic (for example, Compute Engine, SQL Server, Oracle DB, SMB file - * system, etc.), vCenter, or an ESX server. See the [Backup and DR - * documentation on - * hosts](https://cloud.google.com/backup-disaster-recovery/docs/configuration/manage-hosts-and-their-applications) - * for more information. For example, `centos7-01`. - * @type array|\Google\Protobuf\Internal\RepeatedField $applications - * The names of Backup and DR applications. An application is a VM, database, - * or file system on a managed host monitored by a backup and recovery - * appliance. For example, `centos7-01-vol00`, `centos7-01-vol01`, - * `centos7-01-vol02`. - * @type string $storage_pool - * The name of the Backup and DR storage pool that the backup and recovery - * appliance is storing data in. The storage pool could be of type Cloud, - * Primary, Snapshot, or OnVault. See the [Backup and DR documentation on - * storage - * pools](https://cloud.google.com/backup-disaster-recovery/docs/concepts/storage-pools). - * For example, `DiskPoolOne`. - * @type array|\Google\Protobuf\Internal\RepeatedField $policy_options - * The names of Backup and DR advanced policy options of a policy applying to - * an application. See the [Backup and DR documentation on policy - * options](https://cloud.google.com/backup-disaster-recovery/docs/create-plan/policy-settings). - * For example, `skipofflineappsincongrp, nounmap`. - * @type string $profile - * The name of the Backup and DR resource profile that specifies the storage - * media for backups of application and VM data. See the [Backup and DR - * documentation on - * profiles](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#profile). - * For example, `GCP`. - * @type string $appliance - * The name of the Backup and DR appliance that captures, moves, and manages - * the lifecycle of backup data. For example, `backup-server-57137`. - * @type string $backup_type - * The backup type of the Backup and DR image. - * For example, `Snapshot`, `Remote Snapshot`, `OnVault`. - * @type \Google\Protobuf\Timestamp $backup_create_time - * The timestamp at which the Backup and DR backup was created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\BackupDisasterRecovery::initOnce(); - parent::__construct($data); - } - - /** - * The name of a Backup and DR template which comprises one or more backup - * policies. See the [Backup and DR - * documentation](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#temp) - * for more information. For example, `snap-ov`. - * - * Generated from protobuf field string backup_template = 1; - * @return string - */ - public function getBackupTemplate() - { - return $this->backup_template; - } - - /** - * The name of a Backup and DR template which comprises one or more backup - * policies. See the [Backup and DR - * documentation](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#temp) - * for more information. For example, `snap-ov`. - * - * Generated from protobuf field string backup_template = 1; - * @param string $var - * @return $this - */ - public function setBackupTemplate($var) - { - GPBUtil::checkString($var, True); - $this->backup_template = $var; - - return $this; - } - - /** - * The names of Backup and DR policies that are associated with a template - * and that define when to run a backup, how frequently to run a backup, and - * how long to retain the backup image. For example, `onvaults`. - * - * Generated from protobuf field repeated string policies = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPolicies() - { - return $this->policies; - } - - /** - * The names of Backup and DR policies that are associated with a template - * and that define when to run a backup, how frequently to run a backup, and - * how long to retain the backup image. For example, `onvaults`. - * - * Generated from protobuf field repeated string policies = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPolicies($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->policies = $arr; - - return $this; - } - - /** - * The name of a Backup and DR host, which is managed by the backup and - * recovery appliance and known to the management console. The host can be of - * type Generic (for example, Compute Engine, SQL Server, Oracle DB, SMB file - * system, etc.), vCenter, or an ESX server. See the [Backup and DR - * documentation on - * hosts](https://cloud.google.com/backup-disaster-recovery/docs/configuration/manage-hosts-and-their-applications) - * for more information. For example, `centos7-01`. - * - * Generated from protobuf field string host = 3; - * @return string - */ - public function getHost() - { - return $this->host; - } - - /** - * The name of a Backup and DR host, which is managed by the backup and - * recovery appliance and known to the management console. The host can be of - * type Generic (for example, Compute Engine, SQL Server, Oracle DB, SMB file - * system, etc.), vCenter, or an ESX server. See the [Backup and DR - * documentation on - * hosts](https://cloud.google.com/backup-disaster-recovery/docs/configuration/manage-hosts-and-their-applications) - * for more information. For example, `centos7-01`. - * - * Generated from protobuf field string host = 3; - * @param string $var - * @return $this - */ - public function setHost($var) - { - GPBUtil::checkString($var, True); - $this->host = $var; - - return $this; - } - - /** - * The names of Backup and DR applications. An application is a VM, database, - * or file system on a managed host monitored by a backup and recovery - * appliance. For example, `centos7-01-vol00`, `centos7-01-vol01`, - * `centos7-01-vol02`. - * - * Generated from protobuf field repeated string applications = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getApplications() - { - return $this->applications; - } - - /** - * The names of Backup and DR applications. An application is a VM, database, - * or file system on a managed host monitored by a backup and recovery - * appliance. For example, `centos7-01-vol00`, `centos7-01-vol01`, - * `centos7-01-vol02`. - * - * Generated from protobuf field repeated string applications = 4; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setApplications($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->applications = $arr; - - return $this; - } - - /** - * The name of the Backup and DR storage pool that the backup and recovery - * appliance is storing data in. The storage pool could be of type Cloud, - * Primary, Snapshot, or OnVault. See the [Backup and DR documentation on - * storage - * pools](https://cloud.google.com/backup-disaster-recovery/docs/concepts/storage-pools). - * For example, `DiskPoolOne`. - * - * Generated from protobuf field string storage_pool = 5; - * @return string - */ - public function getStoragePool() - { - return $this->storage_pool; - } - - /** - * The name of the Backup and DR storage pool that the backup and recovery - * appliance is storing data in. The storage pool could be of type Cloud, - * Primary, Snapshot, or OnVault. See the [Backup and DR documentation on - * storage - * pools](https://cloud.google.com/backup-disaster-recovery/docs/concepts/storage-pools). - * For example, `DiskPoolOne`. - * - * Generated from protobuf field string storage_pool = 5; - * @param string $var - * @return $this - */ - public function setStoragePool($var) - { - GPBUtil::checkString($var, True); - $this->storage_pool = $var; - - return $this; - } - - /** - * The names of Backup and DR advanced policy options of a policy applying to - * an application. See the [Backup and DR documentation on policy - * options](https://cloud.google.com/backup-disaster-recovery/docs/create-plan/policy-settings). - * For example, `skipofflineappsincongrp, nounmap`. - * - * Generated from protobuf field repeated string policy_options = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPolicyOptions() - { - return $this->policy_options; - } - - /** - * The names of Backup and DR advanced policy options of a policy applying to - * an application. See the [Backup and DR documentation on policy - * options](https://cloud.google.com/backup-disaster-recovery/docs/create-plan/policy-settings). - * For example, `skipofflineappsincongrp, nounmap`. - * - * Generated from protobuf field repeated string policy_options = 6; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPolicyOptions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->policy_options = $arr; - - return $this; - } - - /** - * The name of the Backup and DR resource profile that specifies the storage - * media for backups of application and VM data. See the [Backup and DR - * documentation on - * profiles](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#profile). - * For example, `GCP`. - * - * Generated from protobuf field string profile = 7; - * @return string - */ - public function getProfile() - { - return $this->profile; - } - - /** - * The name of the Backup and DR resource profile that specifies the storage - * media for backups of application and VM data. See the [Backup and DR - * documentation on - * profiles](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#profile). - * For example, `GCP`. - * - * Generated from protobuf field string profile = 7; - * @param string $var - * @return $this - */ - public function setProfile($var) - { - GPBUtil::checkString($var, True); - $this->profile = $var; - - return $this; - } - - /** - * The name of the Backup and DR appliance that captures, moves, and manages - * the lifecycle of backup data. For example, `backup-server-57137`. - * - * Generated from protobuf field string appliance = 8; - * @return string - */ - public function getAppliance() - { - return $this->appliance; - } - - /** - * The name of the Backup and DR appliance that captures, moves, and manages - * the lifecycle of backup data. For example, `backup-server-57137`. - * - * Generated from protobuf field string appliance = 8; - * @param string $var - * @return $this - */ - public function setAppliance($var) - { - GPBUtil::checkString($var, True); - $this->appliance = $var; - - return $this; - } - - /** - * The backup type of the Backup and DR image. - * For example, `Snapshot`, `Remote Snapshot`, `OnVault`. - * - * Generated from protobuf field string backup_type = 9; - * @return string - */ - public function getBackupType() - { - return $this->backup_type; - } - - /** - * The backup type of the Backup and DR image. - * For example, `Snapshot`, `Remote Snapshot`, `OnVault`. - * - * Generated from protobuf field string backup_type = 9; - * @param string $var - * @return $this - */ - public function setBackupType($var) - { - GPBUtil::checkString($var, True); - $this->backup_type = $var; - - return $this; - } - - /** - * The timestamp at which the Backup and DR backup was created. - * - * Generated from protobuf field .google.protobuf.Timestamp backup_create_time = 10; - * @return \Google\Protobuf\Timestamp|null - */ - public function getBackupCreateTime() - { - return $this->backup_create_time; - } - - public function hasBackupCreateTime() - { - return isset($this->backup_create_time); - } - - public function clearBackupCreateTime() - { - unset($this->backup_create_time); - } - - /** - * The timestamp at which the Backup and DR backup was created. - * - * Generated from protobuf field .google.protobuf.Timestamp backup_create_time = 10; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setBackupCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->backup_create_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BigQueryExport.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BigQueryExport.php deleted file mode 100644 index 9d9444af8a9b..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BigQueryExport.php +++ /dev/null @@ -1,449 +0,0 @@ -google.cloud.securitycenter.v1.BigQueryExport - */ -class BigQueryExport extends \Google\Protobuf\Internal\Message -{ - /** - * The relative resource name of this export. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name. - * Example format: - * "organizations/{organization_id}/bigQueryExports/{export_id}" Example - * format: "folders/{folder_id}/bigQueryExports/{export_id}" Example format: - * "projects/{project_id}/bigQueryExports/{export_id}" - * This field is provided in responses, and is ignored when provided in create - * requests. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The description of the export (max of 1024 characters). - * - * Generated from protobuf field string description = 2; - */ - protected $description = ''; - /** - * Expression that defines the filter to apply across create/update events - * of findings. The expression is a list of zero or more restrictions combined - * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` - * has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 3; - */ - protected $filter = ''; - /** - * The dataset to write findings' updates to. Its format is - * "projects/[project_id]/datasets/[bigquery_dataset_id]". - * BigQuery Dataset unique ID must contain only letters (a-z, A-Z), numbers - * (0-9), or underscores (_). - * - * Generated from protobuf field string dataset = 4; - */ - protected $dataset = ''; - /** - * Output only. The time at which the BigQuery export was created. - * This field is set by the server and will be ignored if provided on export - * on creation. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The most recent time at which the BigQuery export was updated. - * This field is set by the server and will be ignored if provided on export - * creation or update. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. Email address of the user who last edited the BigQuery export. - * This field is set by the server and will be ignored if provided on export - * creation or update. - * - * Generated from protobuf field string most_recent_editor = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $most_recent_editor = ''; - /** - * Output only. The service account that needs permission to create table and - * upload data to the BigQuery dataset. - * - * Generated from protobuf field string principal = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $principal = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The relative resource name of this export. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name. - * Example format: - * "organizations/{organization_id}/bigQueryExports/{export_id}" Example - * format: "folders/{folder_id}/bigQueryExports/{export_id}" Example format: - * "projects/{project_id}/bigQueryExports/{export_id}" - * This field is provided in responses, and is ignored when provided in create - * requests. - * @type string $description - * The description of the export (max of 1024 characters). - * @type string $filter - * Expression that defines the filter to apply across create/update events - * of findings. The expression is a list of zero or more restrictions combined - * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` - * has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * @type string $dataset - * The dataset to write findings' updates to. Its format is - * "projects/[project_id]/datasets/[bigquery_dataset_id]". - * BigQuery Dataset unique ID must contain only letters (a-z, A-Z), numbers - * (0-9), or underscores (_). - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time at which the BigQuery export was created. - * This field is set by the server and will be ignored if provided on export - * on creation. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The most recent time at which the BigQuery export was updated. - * This field is set by the server and will be ignored if provided on export - * creation or update. - * @type string $most_recent_editor - * Output only. Email address of the user who last edited the BigQuery export. - * This field is set by the server and will be ignored if provided on export - * creation or update. - * @type string $principal - * Output only. The service account that needs permission to create table and - * upload data to the BigQuery dataset. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\BigqueryExport::initOnce(); - parent::__construct($data); - } - - /** - * The relative resource name of this export. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name. - * Example format: - * "organizations/{organization_id}/bigQueryExports/{export_id}" Example - * format: "folders/{folder_id}/bigQueryExports/{export_id}" Example format: - * "projects/{project_id}/bigQueryExports/{export_id}" - * This field is provided in responses, and is ignored when provided in create - * requests. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The relative resource name of this export. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name. - * Example format: - * "organizations/{organization_id}/bigQueryExports/{export_id}" Example - * format: "folders/{folder_id}/bigQueryExports/{export_id}" Example format: - * "projects/{project_id}/bigQueryExports/{export_id}" - * This field is provided in responses, and is ignored when provided in create - * requests. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The description of the export (max of 1024 characters). - * - * Generated from protobuf field string description = 2; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * The description of the export (max of 1024 characters). - * - * Generated from protobuf field string description = 2; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Expression that defines the filter to apply across create/update events - * of findings. The expression is a list of zero or more restrictions combined - * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` - * has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 3; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Expression that defines the filter to apply across create/update events - * of findings. The expression is a list of zero or more restrictions combined - * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` - * has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 3; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * The dataset to write findings' updates to. Its format is - * "projects/[project_id]/datasets/[bigquery_dataset_id]". - * BigQuery Dataset unique ID must contain only letters (a-z, A-Z), numbers - * (0-9), or underscores (_). - * - * Generated from protobuf field string dataset = 4; - * @return string - */ - public function getDataset() - { - return $this->dataset; - } - - /** - * The dataset to write findings' updates to. Its format is - * "projects/[project_id]/datasets/[bigquery_dataset_id]". - * BigQuery Dataset unique ID must contain only letters (a-z, A-Z), numbers - * (0-9), or underscores (_). - * - * Generated from protobuf field string dataset = 4; - * @param string $var - * @return $this - */ - public function setDataset($var) - { - GPBUtil::checkString($var, True); - $this->dataset = $var; - - return $this; - } - - /** - * Output only. The time at which the BigQuery export was created. - * This field is set by the server and will be ignored if provided on export - * on creation. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The time at which the BigQuery export was created. - * This field is set by the server and will be ignored if provided on export - * on creation. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The most recent time at which the BigQuery export was updated. - * This field is set by the server and will be ignored if provided on export - * creation or update. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. The most recent time at which the BigQuery export was updated. - * This field is set by the server and will be ignored if provided on export - * creation or update. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Output only. Email address of the user who last edited the BigQuery export. - * This field is set by the server and will be ignored if provided on export - * creation or update. - * - * Generated from protobuf field string most_recent_editor = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getMostRecentEditor() - { - return $this->most_recent_editor; - } - - /** - * Output only. Email address of the user who last edited the BigQuery export. - * This field is set by the server and will be ignored if provided on export - * creation or update. - * - * Generated from protobuf field string most_recent_editor = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setMostRecentEditor($var) - { - GPBUtil::checkString($var, True); - $this->most_recent_editor = $var; - - return $this; - } - - /** - * Output only. The service account that needs permission to create table and - * upload data to the BigQuery dataset. - * - * Generated from protobuf field string principal = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getPrincipal() - { - return $this->principal; - } - - /** - * Output only. The service account that needs permission to create table and - * upload data to the BigQuery dataset. - * - * Generated from protobuf field string principal = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setPrincipal($var) - { - GPBUtil::checkString($var, True); - $this->principal = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BulkMuteFindingsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BulkMuteFindingsRequest.php deleted file mode 100644 index 5c6e40c5f606..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BulkMuteFindingsRequest.php +++ /dev/null @@ -1,227 +0,0 @@ -google.cloud.securitycenter.v1.BulkMuteFindingsRequest - */ -class BulkMuteFindingsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent, at which bulk action needs to be applied. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Expression that identifies findings that should be updated. - * The expression is a list of zero or more restrictions combined - * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` - * has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 2; - */ - protected $filter = ''; - /** - * This can be a mute configuration name or any identifier for mute/unmute - * of findings based on the filter. - * - * Generated from protobuf field string mute_annotation = 3 [deprecated = true]; - * @deprecated - */ - protected $mute_annotation = ''; - - /** - * @param string $parent Required. The parent, at which bulk action needs to be applied. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]". - * - * @return \Google\Cloud\SecurityCenter\V1\BulkMuteFindingsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent, at which bulk action needs to be applied. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]". - * @type string $filter - * Expression that identifies findings that should be updated. - * The expression is a list of zero or more restrictions combined - * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` - * has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * @type string $mute_annotation - * This can be a mute configuration name or any identifier for mute/unmute - * of findings based on the filter. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent, at which bulk action needs to be applied. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent, at which bulk action needs to be applied. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Expression that identifies findings that should be updated. - * The expression is a list of zero or more restrictions combined - * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` - * has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 2; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Expression that identifies findings that should be updated. - * The expression is a list of zero or more restrictions combined - * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` - * has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 2; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * This can be a mute configuration name or any identifier for mute/unmute - * of findings based on the filter. - * - * Generated from protobuf field string mute_annotation = 3 [deprecated = true]; - * @return string - * @deprecated - */ - public function getMuteAnnotation() - { - @trigger_error('mute_annotation is deprecated.', E_USER_DEPRECATED); - return $this->mute_annotation; - } - - /** - * This can be a mute configuration name or any identifier for mute/unmute - * of findings based on the filter. - * - * Generated from protobuf field string mute_annotation = 3 [deprecated = true]; - * @param string $var - * @return $this - * @deprecated - */ - public function setMuteAnnotation($var) - { - @trigger_error('mute_annotation is deprecated.', E_USER_DEPRECATED); - GPBUtil::checkString($var, True); - $this->mute_annotation = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BulkMuteFindingsResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BulkMuteFindingsResponse.php deleted file mode 100644 index 68edc47a055a..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/BulkMuteFindingsResponse.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.securitycenter.v1.BulkMuteFindingsResponse - */ -class BulkMuteFindingsResponse extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudArmor.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudArmor.php deleted file mode 100644 index 0ad826f6e3fd..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudArmor.php +++ /dev/null @@ -1,323 +0,0 @@ -google.cloud.securitycenter.v1.CloudArmor - */ -class CloudArmor extends \Google\Protobuf\Internal\Message -{ - /** - * Information about the [Google Cloud Armor security - * policy](https://cloud.google.com/armor/docs/security-policy-overview) - * relevant to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityPolicy security_policy = 1; - */ - protected $security_policy = null; - /** - * Information about incoming requests evaluated by [Google Cloud Armor - * security - * policies](https://cloud.google.com/armor/docs/security-policy-overview). - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Requests requests = 2; - */ - protected $requests = null; - /** - * Information about potential Layer 7 DDoS attacks identified by [Google - * Cloud Armor Adaptive - * Protection](https://cloud.google.com/armor/docs/adaptive-protection-overview). - * - * Generated from protobuf field .google.cloud.securitycenter.v1.AdaptiveProtection adaptive_protection = 3; - */ - protected $adaptive_protection = null; - /** - * Information about DDoS attack volume and classification. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Attack attack = 4; - */ - protected $attack = null; - /** - * Distinguish between volumetric & protocol DDoS attack and - * application layer attacks. For example, “L3_4†for Layer 3 and Layer 4 DDoS - * attacks, or “L_7†for Layer 7 DDoS attacks. - * - * Generated from protobuf field string threat_vector = 5; - */ - protected $threat_vector = ''; - /** - * Duration of attack from the start until the current moment (updated every 5 - * minutes). - * - * Generated from protobuf field .google.protobuf.Duration duration = 6; - */ - protected $duration = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1\SecurityPolicy $security_policy - * Information about the [Google Cloud Armor security - * policy](https://cloud.google.com/armor/docs/security-policy-overview) - * relevant to the finding. - * @type \Google\Cloud\SecurityCenter\V1\Requests $requests - * Information about incoming requests evaluated by [Google Cloud Armor - * security - * policies](https://cloud.google.com/armor/docs/security-policy-overview). - * @type \Google\Cloud\SecurityCenter\V1\AdaptiveProtection $adaptive_protection - * Information about potential Layer 7 DDoS attacks identified by [Google - * Cloud Armor Adaptive - * Protection](https://cloud.google.com/armor/docs/adaptive-protection-overview). - * @type \Google\Cloud\SecurityCenter\V1\Attack $attack - * Information about DDoS attack volume and classification. - * @type string $threat_vector - * Distinguish between volumetric & protocol DDoS attack and - * application layer attacks. For example, “L3_4†for Layer 3 and Layer 4 DDoS - * attacks, or “L_7†for Layer 7 DDoS attacks. - * @type \Google\Protobuf\Duration $duration - * Duration of attack from the start until the current moment (updated every 5 - * minutes). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\CloudArmor::initOnce(); - parent::__construct($data); - } - - /** - * Information about the [Google Cloud Armor security - * policy](https://cloud.google.com/armor/docs/security-policy-overview) - * relevant to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityPolicy security_policy = 1; - * @return \Google\Cloud\SecurityCenter\V1\SecurityPolicy|null - */ - public function getSecurityPolicy() - { - return $this->security_policy; - } - - public function hasSecurityPolicy() - { - return isset($this->security_policy); - } - - public function clearSecurityPolicy() - { - unset($this->security_policy); - } - - /** - * Information about the [Google Cloud Armor security - * policy](https://cloud.google.com/armor/docs/security-policy-overview) - * relevant to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityPolicy security_policy = 1; - * @param \Google\Cloud\SecurityCenter\V1\SecurityPolicy $var - * @return $this - */ - public function setSecurityPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SecurityPolicy::class); - $this->security_policy = $var; - - return $this; - } - - /** - * Information about incoming requests evaluated by [Google Cloud Armor - * security - * policies](https://cloud.google.com/armor/docs/security-policy-overview). - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Requests requests = 2; - * @return \Google\Cloud\SecurityCenter\V1\Requests|null - */ - public function getRequests() - { - return $this->requests; - } - - public function hasRequests() - { - return isset($this->requests); - } - - public function clearRequests() - { - unset($this->requests); - } - - /** - * Information about incoming requests evaluated by [Google Cloud Armor - * security - * policies](https://cloud.google.com/armor/docs/security-policy-overview). - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Requests requests = 2; - * @param \Google\Cloud\SecurityCenter\V1\Requests $var - * @return $this - */ - public function setRequests($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Requests::class); - $this->requests = $var; - - return $this; - } - - /** - * Information about potential Layer 7 DDoS attacks identified by [Google - * Cloud Armor Adaptive - * Protection](https://cloud.google.com/armor/docs/adaptive-protection-overview). - * - * Generated from protobuf field .google.cloud.securitycenter.v1.AdaptiveProtection adaptive_protection = 3; - * @return \Google\Cloud\SecurityCenter\V1\AdaptiveProtection|null - */ - public function getAdaptiveProtection() - { - return $this->adaptive_protection; - } - - public function hasAdaptiveProtection() - { - return isset($this->adaptive_protection); - } - - public function clearAdaptiveProtection() - { - unset($this->adaptive_protection); - } - - /** - * Information about potential Layer 7 DDoS attacks identified by [Google - * Cloud Armor Adaptive - * Protection](https://cloud.google.com/armor/docs/adaptive-protection-overview). - * - * Generated from protobuf field .google.cloud.securitycenter.v1.AdaptiveProtection adaptive_protection = 3; - * @param \Google\Cloud\SecurityCenter\V1\AdaptiveProtection $var - * @return $this - */ - public function setAdaptiveProtection($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\AdaptiveProtection::class); - $this->adaptive_protection = $var; - - return $this; - } - - /** - * Information about DDoS attack volume and classification. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Attack attack = 4; - * @return \Google\Cloud\SecurityCenter\V1\Attack|null - */ - public function getAttack() - { - return $this->attack; - } - - public function hasAttack() - { - return isset($this->attack); - } - - public function clearAttack() - { - unset($this->attack); - } - - /** - * Information about DDoS attack volume and classification. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Attack attack = 4; - * @param \Google\Cloud\SecurityCenter\V1\Attack $var - * @return $this - */ - public function setAttack($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Attack::class); - $this->attack = $var; - - return $this; - } - - /** - * Distinguish between volumetric & protocol DDoS attack and - * application layer attacks. For example, “L3_4†for Layer 3 and Layer 4 DDoS - * attacks, or “L_7†for Layer 7 DDoS attacks. - * - * Generated from protobuf field string threat_vector = 5; - * @return string - */ - public function getThreatVector() - { - return $this->threat_vector; - } - - /** - * Distinguish between volumetric & protocol DDoS attack and - * application layer attacks. For example, “L3_4†for Layer 3 and Layer 4 DDoS - * attacks, or “L_7†for Layer 7 DDoS attacks. - * - * Generated from protobuf field string threat_vector = 5; - * @param string $var - * @return $this - */ - public function setThreatVector($var) - { - GPBUtil::checkString($var, True); - $this->threat_vector = $var; - - return $this; - } - - /** - * Duration of attack from the start until the current moment (updated every 5 - * minutes). - * - * Generated from protobuf field .google.protobuf.Duration duration = 6; - * @return \Google\Protobuf\Duration|null - */ - public function getDuration() - { - return $this->duration; - } - - public function hasDuration() - { - return isset($this->duration); - } - - public function clearDuration() - { - unset($this->duration); - } - - /** - * Duration of attack from the start until the current moment (updated every 5 - * minutes). - * - * Generated from protobuf field .google.protobuf.Duration duration = 6; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setDuration($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->duration = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpDataProfile.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpDataProfile.php deleted file mode 100644 index 452c80d52546..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpDataProfile.php +++ /dev/null @@ -1,106 +0,0 @@ -google.cloud.securitycenter.v1.CloudDlpDataProfile - */ -class CloudDlpDataProfile extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the data profile, for example, - * `projects/123/locations/europe/tableProfiles/8383929`. - * - * Generated from protobuf field string data_profile = 1 [(.google.api.resource_reference) = { - */ - protected $data_profile = ''; - /** - * The resource hierarchy level at which the data profile was generated. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CloudDlpDataProfile.ParentType parent_type = 2; - */ - protected $parent_type = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $data_profile - * Name of the data profile, for example, - * `projects/123/locations/europe/tableProfiles/8383929`. - * @type int $parent_type - * The resource hierarchy level at which the data profile was generated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\CloudDlpDataProfile::initOnce(); - parent::__construct($data); - } - - /** - * Name of the data profile, for example, - * `projects/123/locations/europe/tableProfiles/8383929`. - * - * Generated from protobuf field string data_profile = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getDataProfile() - { - return $this->data_profile; - } - - /** - * Name of the data profile, for example, - * `projects/123/locations/europe/tableProfiles/8383929`. - * - * Generated from protobuf field string data_profile = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setDataProfile($var) - { - GPBUtil::checkString($var, True); - $this->data_profile = $var; - - return $this; - } - - /** - * The resource hierarchy level at which the data profile was generated. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CloudDlpDataProfile.ParentType parent_type = 2; - * @return int - */ - public function getParentType() - { - return $this->parent_type; - } - - /** - * The resource hierarchy level at which the data profile was generated. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CloudDlpDataProfile.ParentType parent_type = 2; - * @param int $var - * @return $this - */ - public function setParentType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\CloudDlpDataProfile\ParentType::class); - $this->parent_type = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpDataProfile/ParentType.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpDataProfile/ParentType.php deleted file mode 100644 index 05f30f7a6786..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpDataProfile/ParentType.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.securitycenter.v1.CloudDlpDataProfile.ParentType - */ -class ParentType -{ - /** - * Unspecified parent type. - * - * Generated from protobuf enum PARENT_TYPE_UNSPECIFIED = 0; - */ - const PARENT_TYPE_UNSPECIFIED = 0; - /** - * Organization-level configurations. - * - * Generated from protobuf enum ORGANIZATION = 1; - */ - const ORGANIZATION = 1; - /** - * Project-level configurations. - * - * Generated from protobuf enum PROJECT = 2; - */ - const PROJECT = 2; - - private static $valueToName = [ - self::PARENT_TYPE_UNSPECIFIED => 'PARENT_TYPE_UNSPECIFIED', - self::ORGANIZATION => 'ORGANIZATION', - self::PROJECT => 'PROJECT', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ParentType::class, \Google\Cloud\SecurityCenter\V1\CloudDlpDataProfile_ParentType::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpInspection.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpInspection.php deleted file mode 100644 index 0c7dd6a2013d..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudDlpInspection.php +++ /dev/null @@ -1,187 +0,0 @@ -google.cloud.securitycenter.v1.CloudDlpInspection - */ -class CloudDlpInspection extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the inspection job, for example, - * `projects/123/locations/europe/dlpJobs/i-8383929`. - * - * Generated from protobuf field string inspect_job = 1 [(.google.api.resource_reference) = { - */ - protected $inspect_job = ''; - /** - * The type of information (or - * *[infoType](https://cloud.google.com/dlp/docs/infotypes-reference)*) found, - * for example, `EMAIL_ADDRESS` or `STREET_ADDRESS`. - * - * Generated from protobuf field string info_type = 2; - */ - protected $info_type = ''; - /** - * The number of times Cloud DLP found this infoType within this job - * and resource. - * - * Generated from protobuf field int64 info_type_count = 3; - */ - protected $info_type_count = 0; - /** - * Whether Cloud DLP scanned the complete resource or a sampled subset. - * - * Generated from protobuf field bool full_scan = 4; - */ - protected $full_scan = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $inspect_job - * Name of the inspection job, for example, - * `projects/123/locations/europe/dlpJobs/i-8383929`. - * @type string $info_type - * The type of information (or - * *[infoType](https://cloud.google.com/dlp/docs/infotypes-reference)*) found, - * for example, `EMAIL_ADDRESS` or `STREET_ADDRESS`. - * @type int|string $info_type_count - * The number of times Cloud DLP found this infoType within this job - * and resource. - * @type bool $full_scan - * Whether Cloud DLP scanned the complete resource or a sampled subset. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\CloudDlpInspection::initOnce(); - parent::__construct($data); - } - - /** - * Name of the inspection job, for example, - * `projects/123/locations/europe/dlpJobs/i-8383929`. - * - * Generated from protobuf field string inspect_job = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getInspectJob() - { - return $this->inspect_job; - } - - /** - * Name of the inspection job, for example, - * `projects/123/locations/europe/dlpJobs/i-8383929`. - * - * Generated from protobuf field string inspect_job = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setInspectJob($var) - { - GPBUtil::checkString($var, True); - $this->inspect_job = $var; - - return $this; - } - - /** - * The type of information (or - * *[infoType](https://cloud.google.com/dlp/docs/infotypes-reference)*) found, - * for example, `EMAIL_ADDRESS` or `STREET_ADDRESS`. - * - * Generated from protobuf field string info_type = 2; - * @return string - */ - public function getInfoType() - { - return $this->info_type; - } - - /** - * The type of information (or - * *[infoType](https://cloud.google.com/dlp/docs/infotypes-reference)*) found, - * for example, `EMAIL_ADDRESS` or `STREET_ADDRESS`. - * - * Generated from protobuf field string info_type = 2; - * @param string $var - * @return $this - */ - public function setInfoType($var) - { - GPBUtil::checkString($var, True); - $this->info_type = $var; - - return $this; - } - - /** - * The number of times Cloud DLP found this infoType within this job - * and resource. - * - * Generated from protobuf field int64 info_type_count = 3; - * @return int|string - */ - public function getInfoTypeCount() - { - return $this->info_type_count; - } - - /** - * The number of times Cloud DLP found this infoType within this job - * and resource. - * - * Generated from protobuf field int64 info_type_count = 3; - * @param int|string $var - * @return $this - */ - public function setInfoTypeCount($var) - { - GPBUtil::checkInt64($var); - $this->info_type_count = $var; - - return $this; - } - - /** - * Whether Cloud DLP scanned the complete resource or a sampled subset. - * - * Generated from protobuf field bool full_scan = 4; - * @return bool - */ - public function getFullScan() - { - return $this->full_scan; - } - - /** - * Whether Cloud DLP scanned the complete resource or a sampled subset. - * - * Generated from protobuf field bool full_scan = 4; - * @param bool $var - * @return $this - */ - public function setFullScan($var) - { - GPBUtil::checkBool($var); - $this->full_scan = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudLoggingEntry.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudLoggingEntry.php deleted file mode 100644 index e734077cde56..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CloudLoggingEntry.php +++ /dev/null @@ -1,196 +0,0 @@ -google.cloud.securitycenter.v1.CloudLoggingEntry - */ -class CloudLoggingEntry extends \Google\Protobuf\Internal\Message -{ - /** - * A unique identifier for the log entry. - * - * Generated from protobuf field string insert_id = 1; - */ - protected $insert_id = ''; - /** - * The type of the log (part of `log_name`. `log_name` is the resource name of - * the log to which this log entry belongs). For example: - * `cloudresourcemanager.googleapis.com/activity`. Note that this field is not - * URL-encoded, unlike the `LOG_ID` field in `LogEntry`. - * - * Generated from protobuf field string log_id = 2; - */ - protected $log_id = ''; - /** - * The organization, folder, or project of the monitored resource that - * produced this log entry. - * - * Generated from protobuf field string resource_container = 3; - */ - protected $resource_container = ''; - /** - * The time the event described by the log entry occurred. - * - * Generated from protobuf field .google.protobuf.Timestamp timestamp = 4; - */ - protected $timestamp = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $insert_id - * A unique identifier for the log entry. - * @type string $log_id - * The type of the log (part of `log_name`. `log_name` is the resource name of - * the log to which this log entry belongs). For example: - * `cloudresourcemanager.googleapis.com/activity`. Note that this field is not - * URL-encoded, unlike the `LOG_ID` field in `LogEntry`. - * @type string $resource_container - * The organization, folder, or project of the monitored resource that - * produced this log entry. - * @type \Google\Protobuf\Timestamp $timestamp - * The time the event described by the log entry occurred. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\LogEntry::initOnce(); - parent::__construct($data); - } - - /** - * A unique identifier for the log entry. - * - * Generated from protobuf field string insert_id = 1; - * @return string - */ - public function getInsertId() - { - return $this->insert_id; - } - - /** - * A unique identifier for the log entry. - * - * Generated from protobuf field string insert_id = 1; - * @param string $var - * @return $this - */ - public function setInsertId($var) - { - GPBUtil::checkString($var, True); - $this->insert_id = $var; - - return $this; - } - - /** - * The type of the log (part of `log_name`. `log_name` is the resource name of - * the log to which this log entry belongs). For example: - * `cloudresourcemanager.googleapis.com/activity`. Note that this field is not - * URL-encoded, unlike the `LOG_ID` field in `LogEntry`. - * - * Generated from protobuf field string log_id = 2; - * @return string - */ - public function getLogId() - { - return $this->log_id; - } - - /** - * The type of the log (part of `log_name`. `log_name` is the resource name of - * the log to which this log entry belongs). For example: - * `cloudresourcemanager.googleapis.com/activity`. Note that this field is not - * URL-encoded, unlike the `LOG_ID` field in `LogEntry`. - * - * Generated from protobuf field string log_id = 2; - * @param string $var - * @return $this - */ - public function setLogId($var) - { - GPBUtil::checkString($var, True); - $this->log_id = $var; - - return $this; - } - - /** - * The organization, folder, or project of the monitored resource that - * produced this log entry. - * - * Generated from protobuf field string resource_container = 3; - * @return string - */ - public function getResourceContainer() - { - return $this->resource_container; - } - - /** - * The organization, folder, or project of the monitored resource that - * produced this log entry. - * - * Generated from protobuf field string resource_container = 3; - * @param string $var - * @return $this - */ - public function setResourceContainer($var) - { - GPBUtil::checkString($var, True); - $this->resource_container = $var; - - return $this; - } - - /** - * The time the event described by the log entry occurred. - * - * Generated from protobuf field .google.protobuf.Timestamp timestamp = 4; - * @return \Google\Protobuf\Timestamp|null - */ - public function getTimestamp() - { - return $this->timestamp; - } - - public function hasTimestamp() - { - return isset($this->timestamp); - } - - public function clearTimestamp() - { - unset($this->timestamp); - } - - /** - * The time the event described by the log entry occurred. - * - * Generated from protobuf field .google.protobuf.Timestamp timestamp = 4; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setTimestamp($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->timestamp = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Compliance.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Compliance.php deleted file mode 100644 index e8ba84f97551..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Compliance.php +++ /dev/null @@ -1,140 +0,0 @@ -google.cloud.securitycenter.v1.Compliance - */ -class Compliance extends \Google\Protobuf\Internal\Message -{ - /** - * Industry-wide compliance standards or benchmarks, such as CIS, PCI, and - * OWASP. - * - * Generated from protobuf field string standard = 1; - */ - protected $standard = ''; - /** - * Version of the standard or benchmark, for example, 1.1 - * - * Generated from protobuf field string version = 2; - */ - protected $version = ''; - /** - * Policies within the standard or benchmark, for example, A.12.4.1 - * - * Generated from protobuf field repeated string ids = 3; - */ - private $ids; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $standard - * Industry-wide compliance standards or benchmarks, such as CIS, PCI, and - * OWASP. - * @type string $version - * Version of the standard or benchmark, for example, 1.1 - * @type array|\Google\Protobuf\Internal\RepeatedField $ids - * Policies within the standard or benchmark, for example, A.12.4.1 - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Compliance::initOnce(); - parent::__construct($data); - } - - /** - * Industry-wide compliance standards or benchmarks, such as CIS, PCI, and - * OWASP. - * - * Generated from protobuf field string standard = 1; - * @return string - */ - public function getStandard() - { - return $this->standard; - } - - /** - * Industry-wide compliance standards or benchmarks, such as CIS, PCI, and - * OWASP. - * - * Generated from protobuf field string standard = 1; - * @param string $var - * @return $this - */ - public function setStandard($var) - { - GPBUtil::checkString($var, True); - $this->standard = $var; - - return $this; - } - - /** - * Version of the standard or benchmark, for example, 1.1 - * - * Generated from protobuf field string version = 2; - * @return string - */ - public function getVersion() - { - return $this->version; - } - - /** - * Version of the standard or benchmark, for example, 1.1 - * - * Generated from protobuf field string version = 2; - * @param string $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkString($var, True); - $this->version = $var; - - return $this; - } - - /** - * Policies within the standard or benchmark, for example, A.12.4.1 - * - * Generated from protobuf field repeated string ids = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getIds() - { - return $this->ids; - } - - /** - * Policies within the standard or benchmark, for example, A.12.4.1 - * - * Generated from protobuf field repeated string ids = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setIds($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->ids = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Connection.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Connection.php deleted file mode 100644 index ddaeaf3950ae..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Connection.php +++ /dev/null @@ -1,211 +0,0 @@ -google.cloud.securitycenter.v1.Connection - */ -class Connection extends \Google\Protobuf\Internal\Message -{ - /** - * Destination IP address. Not present for sockets that are listening and not - * connected. - * - * Generated from protobuf field string destination_ip = 1; - */ - protected $destination_ip = ''; - /** - * Destination port. Not present for sockets that are listening and not - * connected. - * - * Generated from protobuf field int32 destination_port = 2; - */ - protected $destination_port = 0; - /** - * Source IP address. - * - * Generated from protobuf field string source_ip = 3; - */ - protected $source_ip = ''; - /** - * Source port. - * - * Generated from protobuf field int32 source_port = 4; - */ - protected $source_port = 0; - /** - * IANA Internet Protocol Number such as TCP(6) and UDP(17). - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Connection.Protocol protocol = 5; - */ - protected $protocol = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $destination_ip - * Destination IP address. Not present for sockets that are listening and not - * connected. - * @type int $destination_port - * Destination port. Not present for sockets that are listening and not - * connected. - * @type string $source_ip - * Source IP address. - * @type int $source_port - * Source port. - * @type int $protocol - * IANA Internet Protocol Number such as TCP(6) and UDP(17). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Connection::initOnce(); - parent::__construct($data); - } - - /** - * Destination IP address. Not present for sockets that are listening and not - * connected. - * - * Generated from protobuf field string destination_ip = 1; - * @return string - */ - public function getDestinationIp() - { - return $this->destination_ip; - } - - /** - * Destination IP address. Not present for sockets that are listening and not - * connected. - * - * Generated from protobuf field string destination_ip = 1; - * @param string $var - * @return $this - */ - public function setDestinationIp($var) - { - GPBUtil::checkString($var, True); - $this->destination_ip = $var; - - return $this; - } - - /** - * Destination port. Not present for sockets that are listening and not - * connected. - * - * Generated from protobuf field int32 destination_port = 2; - * @return int - */ - public function getDestinationPort() - { - return $this->destination_port; - } - - /** - * Destination port. Not present for sockets that are listening and not - * connected. - * - * Generated from protobuf field int32 destination_port = 2; - * @param int $var - * @return $this - */ - public function setDestinationPort($var) - { - GPBUtil::checkInt32($var); - $this->destination_port = $var; - - return $this; - } - - /** - * Source IP address. - * - * Generated from protobuf field string source_ip = 3; - * @return string - */ - public function getSourceIp() - { - return $this->source_ip; - } - - /** - * Source IP address. - * - * Generated from protobuf field string source_ip = 3; - * @param string $var - * @return $this - */ - public function setSourceIp($var) - { - GPBUtil::checkString($var, True); - $this->source_ip = $var; - - return $this; - } - - /** - * Source port. - * - * Generated from protobuf field int32 source_port = 4; - * @return int - */ - public function getSourcePort() - { - return $this->source_port; - } - - /** - * Source port. - * - * Generated from protobuf field int32 source_port = 4; - * @param int $var - * @return $this - */ - public function setSourcePort($var) - { - GPBUtil::checkInt32($var); - $this->source_port = $var; - - return $this; - } - - /** - * IANA Internet Protocol Number such as TCP(6) and UDP(17). - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Connection.Protocol protocol = 5; - * @return int - */ - public function getProtocol() - { - return $this->protocol; - } - - /** - * IANA Internet Protocol Number such as TCP(6) and UDP(17). - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Connection.Protocol protocol = 5; - * @param int $var - * @return $this - */ - public function setProtocol($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Connection\Protocol::class); - $this->protocol = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Connection/Protocol.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Connection/Protocol.php deleted file mode 100644 index 8c4837dac97d..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Connection/Protocol.php +++ /dev/null @@ -1,85 +0,0 @@ -google.cloud.securitycenter.v1.Connection.Protocol - */ -class Protocol -{ - /** - * Unspecified protocol (not HOPOPT). - * - * Generated from protobuf enum PROTOCOL_UNSPECIFIED = 0; - */ - const PROTOCOL_UNSPECIFIED = 0; - /** - * Internet Control Message Protocol. - * - * Generated from protobuf enum ICMP = 1; - */ - const ICMP = 1; - /** - * Transmission Control Protocol. - * - * Generated from protobuf enum TCP = 6; - */ - const TCP = 6; - /** - * User Datagram Protocol. - * - * Generated from protobuf enum UDP = 17; - */ - const UDP = 17; - /** - * Generic Routing Encapsulation. - * - * Generated from protobuf enum GRE = 47; - */ - const GRE = 47; - /** - * Encap Security Payload. - * - * Generated from protobuf enum ESP = 50; - */ - const ESP = 50; - - private static $valueToName = [ - self::PROTOCOL_UNSPECIFIED => 'PROTOCOL_UNSPECIFIED', - self::ICMP => 'ICMP', - self::TCP => 'TCP', - self::UDP => 'UDP', - self::GRE => 'GRE', - self::ESP => 'ESP', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Protocol::class, \Google\Cloud\SecurityCenter\V1\Connection_Protocol::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Contact.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Contact.php deleted file mode 100644 index c930a46f7f51..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Contact.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.securitycenter.v1.Contact - */ -class Contact extends \Google\Protobuf\Internal\Message -{ - /** - * An email address. For example, "`person123@company.com`". - * - * Generated from protobuf field string email = 1; - */ - protected $email = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $email - * An email address. For example, "`person123@company.com`". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\ContactDetails::initOnce(); - parent::__construct($data); - } - - /** - * An email address. For example, "`person123@company.com`". - * - * Generated from protobuf field string email = 1; - * @return string - */ - public function getEmail() - { - return $this->email; - } - - /** - * An email address. For example, "`person123@company.com`". - * - * Generated from protobuf field string email = 1; - * @param string $var - * @return $this - */ - public function setEmail($var) - { - GPBUtil::checkString($var, True); - $this->email = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ContactDetails.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ContactDetails.php deleted file mode 100644 index fb1bd8fe5e82..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ContactDetails.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.securitycenter.v1.ContactDetails - */ -class ContactDetails extends \Google\Protobuf\Internal\Message -{ - /** - * A list of contacts - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Contact contacts = 1; - */ - private $contacts; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1\Contact>|\Google\Protobuf\Internal\RepeatedField $contacts - * A list of contacts - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\ContactDetails::initOnce(); - parent::__construct($data); - } - - /** - * A list of contacts - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Contact contacts = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getContacts() - { - return $this->contacts; - } - - /** - * A list of contacts - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Contact contacts = 1; - * @param array<\Google\Cloud\SecurityCenter\V1\Contact>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setContacts($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Contact::class); - $this->contacts = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Container.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Container.php deleted file mode 100644 index cacdf9423402..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Container.php +++ /dev/null @@ -1,221 +0,0 @@ -google.cloud.securitycenter.v1.Container - */ -class Container extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the container. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Container image URI provided when configuring a pod or container. This - * string can identify a container image version using mutable tags. - * - * Generated from protobuf field string uri = 2; - */ - protected $uri = ''; - /** - * Optional container image ID, if provided by the container runtime. Uniquely - * identifies the container image launched using a container image digest. - * - * Generated from protobuf field string image_id = 3; - */ - protected $image_id = ''; - /** - * Container labels, as provided by the container runtime. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Label labels = 4; - */ - private $labels; - /** - * The time that the container was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5; - */ - protected $create_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Name of the container. - * @type string $uri - * Container image URI provided when configuring a pod or container. This - * string can identify a container image version using mutable tags. - * @type string $image_id - * Optional container image ID, if provided by the container runtime. Uniquely - * identifies the container image launched using a container image digest. - * @type array<\Google\Cloud\SecurityCenter\V1\Label>|\Google\Protobuf\Internal\RepeatedField $labels - * Container labels, as provided by the container runtime. - * @type \Google\Protobuf\Timestamp $create_time - * The time that the container was created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Container::initOnce(); - parent::__construct($data); - } - - /** - * Name of the container. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Name of the container. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Container image URI provided when configuring a pod or container. This - * string can identify a container image version using mutable tags. - * - * Generated from protobuf field string uri = 2; - * @return string - */ - public function getUri() - { - return $this->uri; - } - - /** - * Container image URI provided when configuring a pod or container. This - * string can identify a container image version using mutable tags. - * - * Generated from protobuf field string uri = 2; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->uri = $var; - - return $this; - } - - /** - * Optional container image ID, if provided by the container runtime. Uniquely - * identifies the container image launched using a container image digest. - * - * Generated from protobuf field string image_id = 3; - * @return string - */ - public function getImageId() - { - return $this->image_id; - } - - /** - * Optional container image ID, if provided by the container runtime. Uniquely - * identifies the container image launched using a container image digest. - * - * Generated from protobuf field string image_id = 3; - * @param string $var - * @return $this - */ - public function setImageId($var) - { - GPBUtil::checkString($var, True); - $this->image_id = $var; - - return $this; - } - - /** - * Container labels, as provided by the container runtime. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Label labels = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Container labels, as provided by the container runtime. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Label labels = 4; - * @param array<\Google\Cloud\SecurityCenter\V1\Label>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Label::class); - $this->labels = $arr; - - return $this; - } - - /** - * The time that the container was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * The time that the container was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateBigQueryExportRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateBigQueryExportRequest.php deleted file mode 100644 index a893628cb305..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateBigQueryExportRequest.php +++ /dev/null @@ -1,188 +0,0 @@ -google.cloud.securitycenter.v1.CreateBigQueryExportRequest - */ -class CreateBigQueryExportRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the parent resource of the new BigQuery export. Its - * format is "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The BigQuery export being created. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.BigQueryExport big_query_export = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $big_query_export = null; - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * - * Generated from protobuf field string big_query_export_id = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $big_query_export_id = ''; - - /** - * @param string $parent Required. The name of the parent resource of the new BigQuery export. Its - * format is "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". Please see - * {@see SecurityCenterClient::projectName()} for help formatting this field. - * @param \Google\Cloud\SecurityCenter\V1\BigQueryExport $bigQueryExport Required. The BigQuery export being created. - * @param string $bigQueryExportId Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * - * @return \Google\Cloud\SecurityCenter\V1\CreateBigQueryExportRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\SecurityCenter\V1\BigQueryExport $bigQueryExport, string $bigQueryExportId): self - { - return (new self()) - ->setParent($parent) - ->setBigQueryExport($bigQueryExport) - ->setBigQueryExportId($bigQueryExportId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The name of the parent resource of the new BigQuery export. Its - * format is "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * @type \Google\Cloud\SecurityCenter\V1\BigQueryExport $big_query_export - * Required. The BigQuery export being created. - * @type string $big_query_export_id - * Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the parent resource of the new BigQuery export. Its - * format is "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The name of the parent resource of the new BigQuery export. Its - * format is "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The BigQuery export being created. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.BigQueryExport big_query_export = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1\BigQueryExport|null - */ - public function getBigQueryExport() - { - return $this->big_query_export; - } - - public function hasBigQueryExport() - { - return isset($this->big_query_export); - } - - public function clearBigQueryExport() - { - unset($this->big_query_export); - } - - /** - * Required. The BigQuery export being created. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.BigQueryExport big_query_export = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1\BigQueryExport $var - * @return $this - */ - public function setBigQueryExport($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\BigQueryExport::class); - $this->big_query_export = $var; - - return $this; - } - - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * - * Generated from protobuf field string big_query_export_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getBigQueryExportId() - { - return $this->big_query_export_id; - } - - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * - * Generated from protobuf field string big_query_export_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setBigQueryExportId($var) - { - GPBUtil::checkString($var, True); - $this->big_query_export_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateFindingRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateFindingRequest.php deleted file mode 100644 index 8e04470b0fa5..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateFindingRequest.php +++ /dev/null @@ -1,183 +0,0 @@ -google.cloud.securitycenter.v1.CreateFindingRequest - */ -class CreateFindingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the new finding's parent. Its format should be - * "organizations/[organization_id]/sources/[source_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must be alphanumeric and less than or equal to 32 characters and - * greater than 0 characters in length. - * - * Generated from protobuf field string finding_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $finding_id = ''; - /** - * Required. The Finding being created. The name and security_marks will be - * ignored as they are both output only fields on this resource. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $finding = null; - - /** - * @param string $parent Required. Resource name of the new finding's parent. Its format should be - * "organizations/[organization_id]/sources/[source_id]". Please see - * {@see SecurityCenterClient::sourceName()} for help formatting this field. - * @param string $findingId Required. Unique identifier provided by the client within the parent scope. - * It must be alphanumeric and less than or equal to 32 characters and - * greater than 0 characters in length. - * @param \Google\Cloud\SecurityCenter\V1\Finding $finding Required. The Finding being created. The name and security_marks will be - * ignored as they are both output only fields on this resource. - * - * @return \Google\Cloud\SecurityCenter\V1\CreateFindingRequest - * - * @experimental - */ - public static function build(string $parent, string $findingId, \Google\Cloud\SecurityCenter\V1\Finding $finding): self - { - return (new self()) - ->setParent($parent) - ->setFindingId($findingId) - ->setFinding($finding); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the new finding's parent. Its format should be - * "organizations/[organization_id]/sources/[source_id]". - * @type string $finding_id - * Required. Unique identifier provided by the client within the parent scope. - * It must be alphanumeric and less than or equal to 32 characters and - * greater than 0 characters in length. - * @type \Google\Cloud\SecurityCenter\V1\Finding $finding - * Required. The Finding being created. The name and security_marks will be - * ignored as they are both output only fields on this resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the new finding's parent. Its format should be - * "organizations/[organization_id]/sources/[source_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the new finding's parent. Its format should be - * "organizations/[organization_id]/sources/[source_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must be alphanumeric and less than or equal to 32 characters and - * greater than 0 characters in length. - * - * Generated from protobuf field string finding_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getFindingId() - { - return $this->finding_id; - } - - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must be alphanumeric and less than or equal to 32 characters and - * greater than 0 characters in length. - * - * Generated from protobuf field string finding_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setFindingId($var) - { - GPBUtil::checkString($var, True); - $this->finding_id = $var; - - return $this; - } - - /** - * Required. The Finding being created. The name and security_marks will be - * ignored as they are both output only fields on this resource. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1\Finding|null - */ - public function getFinding() - { - return $this->finding; - } - - public function hasFinding() - { - return isset($this->finding); - } - - public function clearFinding() - { - unset($this->finding); - } - - /** - * Required. The Finding being created. The name and security_marks will be - * ignored as they are both output only fields on this resource. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1\Finding $var - * @return $this - */ - public function setFinding($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Finding::class); - $this->finding = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateMuteConfigRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateMuteConfigRequest.php deleted file mode 100644 index c4fe4a60a0fa..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateMuteConfigRequest.php +++ /dev/null @@ -1,206 +0,0 @@ -google.cloud.securitycenter.v1.CreateMuteConfigRequest - */ -class CreateMuteConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the new mute configs's parent. Its format is - * "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The mute config being created. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.MuteConfig mute_config = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $mute_config = null; - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * - * Generated from protobuf field string mute_config_id = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $mute_config_id = ''; - - /** - * @param string $parent Required. Resource name of the new mute configs's parent. Its format is - * "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". Please see - * {@see SecurityCenterClient::projectName()} for help formatting this field. - * @param \Google\Cloud\SecurityCenter\V1\MuteConfig $muteConfig Required. The mute config being created. - * - * @return \Google\Cloud\SecurityCenter\V1\CreateMuteConfigRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\SecurityCenter\V1\MuteConfig $muteConfig): self - { - return (new self()) - ->setParent($parent) - ->setMuteConfig($muteConfig); - } - - /** - * @param string $parent Required. Resource name of the new mute configs's parent. Its format is - * "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". Please see - * {@see SecurityCenterClient::projectName()} for help formatting this field. - * @param \Google\Cloud\SecurityCenter\V1\MuteConfig $muteConfig Required. The mute config being created. - * @param string $muteConfigId Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * - * @return \Google\Cloud\SecurityCenter\V1\CreateMuteConfigRequest - * - * @experimental - */ - public static function buildFromParentMuteConfigMuteConfigId(string $parent, \Google\Cloud\SecurityCenter\V1\MuteConfig $muteConfig, string $muteConfigId): self - { - return (new self()) - ->setParent($parent) - ->setMuteConfig($muteConfig) - ->setMuteConfigId($muteConfigId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the new mute configs's parent. Its format is - * "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * @type \Google\Cloud\SecurityCenter\V1\MuteConfig $mute_config - * Required. The mute config being created. - * @type string $mute_config_id - * Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the new mute configs's parent. Its format is - * "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the new mute configs's parent. Its format is - * "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The mute config being created. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.MuteConfig mute_config = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1\MuteConfig|null - */ - public function getMuteConfig() - { - return $this->mute_config; - } - - public function hasMuteConfig() - { - return isset($this->mute_config); - } - - public function clearMuteConfig() - { - unset($this->mute_config); - } - - /** - * Required. The mute config being created. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.MuteConfig mute_config = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1\MuteConfig $var - * @return $this - */ - public function setMuteConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\MuteConfig::class); - $this->mute_config = $var; - - return $this; - } - - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * - * Generated from protobuf field string mute_config_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getMuteConfigId() - { - return $this->mute_config_id; - } - - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * - * Generated from protobuf field string mute_config_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setMuteConfigId($var) - { - GPBUtil::checkString($var, True); - $this->mute_config_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateNotificationConfigRequest.php deleted file mode 100644 index 325c4600eb91..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateNotificationConfigRequest.php +++ /dev/null @@ -1,218 +0,0 @@ -google.cloud.securitycenter.v1.CreateNotificationConfigRequest - */ -class CreateNotificationConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the new notification config's parent. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. - * Unique identifier provided by the client within the parent scope. - * It must be between 1 and 128 characters and contain alphanumeric - * characters, underscores, or hyphens only. - * - * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $config_id = ''; - /** - * Required. The notification config being created. The name and the service - * account will be ignored as they are both output only fields on this - * resource. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.NotificationConfig notification_config = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $notification_config = null; - - /** - * @param string $parent Required. Resource name of the new notification config's parent. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". Please see - * {@see SecurityCenterClient::projectName()} for help formatting this field. - * @param string $configId Required. - * Unique identifier provided by the client within the parent scope. - * It must be between 1 and 128 characters and contain alphanumeric - * characters, underscores, or hyphens only. - * @param \Google\Cloud\SecurityCenter\V1\NotificationConfig $notificationConfig Required. The notification config being created. The name and the service - * account will be ignored as they are both output only fields on this - * resource. - * - * @return \Google\Cloud\SecurityCenter\V1\CreateNotificationConfigRequest - * - * @experimental - */ - public static function build(string $parent, string $configId, \Google\Cloud\SecurityCenter\V1\NotificationConfig $notificationConfig): self - { - return (new self()) - ->setParent($parent) - ->setConfigId($configId) - ->setNotificationConfig($notificationConfig); - } - - /** - * @param string $parent Required. Resource name of the new notification config's parent. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". Please see - * {@see SecurityCenterClient::projectName()} for help formatting this field. - * @param \Google\Cloud\SecurityCenter\V1\NotificationConfig $notificationConfig Required. The notification config being created. The name and the service - * account will be ignored as they are both output only fields on this - * resource. - * - * @return \Google\Cloud\SecurityCenter\V1\CreateNotificationConfigRequest - * - * @experimental - */ - public static function buildFromParentNotificationConfig(string $parent, \Google\Cloud\SecurityCenter\V1\NotificationConfig $notificationConfig): self - { - return (new self()) - ->setParent($parent) - ->setNotificationConfig($notificationConfig); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the new notification config's parent. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * @type string $config_id - * Required. - * Unique identifier provided by the client within the parent scope. - * It must be between 1 and 128 characters and contain alphanumeric - * characters, underscores, or hyphens only. - * @type \Google\Cloud\SecurityCenter\V1\NotificationConfig $notification_config - * Required. The notification config being created. The name and the service - * account will be ignored as they are both output only fields on this - * resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the new notification config's parent. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the new notification config's parent. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. - * Unique identifier provided by the client within the parent scope. - * It must be between 1 and 128 characters and contain alphanumeric - * characters, underscores, or hyphens only. - * - * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getConfigId() - { - return $this->config_id; - } - - /** - * Required. - * Unique identifier provided by the client within the parent scope. - * It must be between 1 and 128 characters and contain alphanumeric - * characters, underscores, or hyphens only. - * - * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setConfigId($var) - { - GPBUtil::checkString($var, True); - $this->config_id = $var; - - return $this; - } - - /** - * Required. The notification config being created. The name and the service - * account will be ignored as they are both output only fields on this - * resource. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.NotificationConfig notification_config = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1\NotificationConfig|null - */ - public function getNotificationConfig() - { - return $this->notification_config; - } - - public function hasNotificationConfig() - { - return isset($this->notification_config); - } - - public function clearNotificationConfig() - { - unset($this->notification_config); - } - - /** - * Required. The notification config being created. The name and the service - * account will be ignored as they are both output only fields on this - * resource. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.NotificationConfig notification_config = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1\NotificationConfig $var - * @return $this - */ - public function setNotificationConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\NotificationConfig::class); - $this->notification_config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateSecurityHealthAnalyticsCustomModuleRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateSecurityHealthAnalyticsCustomModuleRequest.php deleted file mode 100644 index 20d1e474ef68..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateSecurityHealthAnalyticsCustomModuleRequest.php +++ /dev/null @@ -1,152 +0,0 @@ -google.cloud.securitycenter.v1.CreateSecurityHealthAnalyticsCustomModuleRequest - */ -class CreateSecurityHealthAnalyticsCustomModuleRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the new custom module's parent. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. SecurityHealthAnalytics custom module to create. The provided - * name is ignored and reset with provided parent information and - * server-generated ID. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_module = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $security_health_analytics_custom_module = null; - - /** - * @param string $parent Required. Resource name of the new custom module's parent. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * Please see {@see SecurityCenterClient::securityHealthAnalyticsSettingsName()} for help formatting this field. - * @param \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule $securityHealthAnalyticsCustomModule Required. SecurityHealthAnalytics custom module to create. The provided - * name is ignored and reset with provided parent information and - * server-generated ID. - * - * @return \Google\Cloud\SecurityCenter\V1\CreateSecurityHealthAnalyticsCustomModuleRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule $securityHealthAnalyticsCustomModule): self - { - return (new self()) - ->setParent($parent) - ->setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the new custom module's parent. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * @type \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule $security_health_analytics_custom_module - * Required. SecurityHealthAnalytics custom module to create. The provided - * name is ignored and reset with provided parent information and - * server-generated ID. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the new custom module's parent. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the new custom module's parent. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. SecurityHealthAnalytics custom module to create. The provided - * name is ignored and reset with provided parent information and - * server-generated ID. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_module = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule|null - */ - public function getSecurityHealthAnalyticsCustomModule() - { - return $this->security_health_analytics_custom_module; - } - - public function hasSecurityHealthAnalyticsCustomModule() - { - return isset($this->security_health_analytics_custom_module); - } - - public function clearSecurityHealthAnalyticsCustomModule() - { - unset($this->security_health_analytics_custom_module); - } - - /** - * Required. SecurityHealthAnalytics custom module to create. The provided - * name is ignored and reset with provided parent information and - * server-generated ID. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_module = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule $var - * @return $this - */ - public function setSecurityHealthAnalyticsCustomModule($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule::class); - $this->security_health_analytics_custom_module = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateSourceRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateSourceRequest.php deleted file mode 100644 index bfec5e12c859..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CreateSourceRequest.php +++ /dev/null @@ -1,137 +0,0 @@ -google.cloud.securitycenter.v1.CreateSourceRequest - */ -class CreateSourceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the new source's parent. Its format should be - * "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The Source being created, only the display_name and description - * will be used. All other fields will be ignored. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Source source = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $source = null; - - /** - * @param string $parent Required. Resource name of the new source's parent. Its format should be - * "organizations/[organization_id]". Please see - * {@see SecurityCenterClient::organizationName()} for help formatting this field. - * @param \Google\Cloud\SecurityCenter\V1\Source $source Required. The Source being created, only the display_name and description - * will be used. All other fields will be ignored. - * - * @return \Google\Cloud\SecurityCenter\V1\CreateSourceRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\SecurityCenter\V1\Source $source): self - { - return (new self()) - ->setParent($parent) - ->setSource($source); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the new source's parent. Its format should be - * "organizations/[organization_id]". - * @type \Google\Cloud\SecurityCenter\V1\Source $source - * Required. The Source being created, only the display_name and description - * will be used. All other fields will be ignored. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the new source's parent. Its format should be - * "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the new source's parent. Its format should be - * "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The Source being created, only the display_name and description - * will be used. All other fields will be ignored. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Source source = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1\Source|null - */ - public function getSource() - { - return $this->source; - } - - public function hasSource() - { - return isset($this->source); - } - - public function clearSource() - { - unset($this->source); - } - - /** - * Required. The Source being created, only the display_name and description - * will be used. All other fields will be ignored. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Source source = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1\Source $var - * @return $this - */ - public function setSource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Source::class); - $this->source = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig.php deleted file mode 100644 index 3e04151b84f1..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig.php +++ /dev/null @@ -1,297 +0,0 @@ -google.cloud.securitycenter.v1.CustomConfig - */ -class CustomConfig extends \Google\Protobuf\Internal\Message -{ - /** - * The CEL expression to evaluate to produce findings. When the expression - * evaluates to true against a resource, a finding is generated. - * - * Generated from protobuf field .google.type.Expr predicate = 1; - */ - protected $predicate = null; - /** - * Custom output properties. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig.CustomOutputSpec custom_output = 2; - */ - protected $custom_output = null; - /** - * The resource types that the custom module operates on. Each custom module - * can specify up to 5 resource types. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig.ResourceSelector resource_selector = 3; - */ - protected $resource_selector = null; - /** - * The severity to assign to findings generated by the module. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig.Severity severity = 4; - */ - protected $severity = 0; - /** - * Text that describes the vulnerability or misconfiguration that the custom - * module detects. This explanation is returned with each finding instance to - * help investigators understand the detected issue. The text must be enclosed - * in quotation marks. - * - * Generated from protobuf field string description = 5; - */ - protected $description = ''; - /** - * An explanation of the recommended steps that security teams can take to - * resolve the detected issue. This explanation is returned with each finding - * generated by this module in the `nextSteps` property of the finding JSON. - * - * Generated from protobuf field string recommendation = 6; - */ - protected $recommendation = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Type\Expr $predicate - * The CEL expression to evaluate to produce findings. When the expression - * evaluates to true against a resource, a finding is generated. - * @type \Google\Cloud\SecurityCenter\V1\CustomConfig\CustomOutputSpec $custom_output - * Custom output properties. - * @type \Google\Cloud\SecurityCenter\V1\CustomConfig\ResourceSelector $resource_selector - * The resource types that the custom module operates on. Each custom module - * can specify up to 5 resource types. - * @type int $severity - * The severity to assign to findings generated by the module. - * @type string $description - * Text that describes the vulnerability or misconfiguration that the custom - * module detects. This explanation is returned with each finding instance to - * help investigators understand the detected issue. The text must be enclosed - * in quotation marks. - * @type string $recommendation - * An explanation of the recommended steps that security teams can take to - * resolve the detected issue. This explanation is returned with each finding - * generated by this module in the `nextSteps` property of the finding JSON. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecurityHealthAnalyticsCustomConfig::initOnce(); - parent::__construct($data); - } - - /** - * The CEL expression to evaluate to produce findings. When the expression - * evaluates to true against a resource, a finding is generated. - * - * Generated from protobuf field .google.type.Expr predicate = 1; - * @return \Google\Type\Expr|null - */ - public function getPredicate() - { - return $this->predicate; - } - - public function hasPredicate() - { - return isset($this->predicate); - } - - public function clearPredicate() - { - unset($this->predicate); - } - - /** - * The CEL expression to evaluate to produce findings. When the expression - * evaluates to true against a resource, a finding is generated. - * - * Generated from protobuf field .google.type.Expr predicate = 1; - * @param \Google\Type\Expr $var - * @return $this - */ - public function setPredicate($var) - { - GPBUtil::checkMessage($var, \Google\Type\Expr::class); - $this->predicate = $var; - - return $this; - } - - /** - * Custom output properties. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig.CustomOutputSpec custom_output = 2; - * @return \Google\Cloud\SecurityCenter\V1\CustomConfig\CustomOutputSpec|null - */ - public function getCustomOutput() - { - return $this->custom_output; - } - - public function hasCustomOutput() - { - return isset($this->custom_output); - } - - public function clearCustomOutput() - { - unset($this->custom_output); - } - - /** - * Custom output properties. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig.CustomOutputSpec custom_output = 2; - * @param \Google\Cloud\SecurityCenter\V1\CustomConfig\CustomOutputSpec $var - * @return $this - */ - public function setCustomOutput($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\CustomConfig\CustomOutputSpec::class); - $this->custom_output = $var; - - return $this; - } - - /** - * The resource types that the custom module operates on. Each custom module - * can specify up to 5 resource types. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig.ResourceSelector resource_selector = 3; - * @return \Google\Cloud\SecurityCenter\V1\CustomConfig\ResourceSelector|null - */ - public function getResourceSelector() - { - return $this->resource_selector; - } - - public function hasResourceSelector() - { - return isset($this->resource_selector); - } - - public function clearResourceSelector() - { - unset($this->resource_selector); - } - - /** - * The resource types that the custom module operates on. Each custom module - * can specify up to 5 resource types. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig.ResourceSelector resource_selector = 3; - * @param \Google\Cloud\SecurityCenter\V1\CustomConfig\ResourceSelector $var - * @return $this - */ - public function setResourceSelector($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\CustomConfig\ResourceSelector::class); - $this->resource_selector = $var; - - return $this; - } - - /** - * The severity to assign to findings generated by the module. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig.Severity severity = 4; - * @return int - */ - public function getSeverity() - { - return $this->severity; - } - - /** - * The severity to assign to findings generated by the module. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig.Severity severity = 4; - * @param int $var - * @return $this - */ - public function setSeverity($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\CustomConfig\Severity::class); - $this->severity = $var; - - return $this; - } - - /** - * Text that describes the vulnerability or misconfiguration that the custom - * module detects. This explanation is returned with each finding instance to - * help investigators understand the detected issue. The text must be enclosed - * in quotation marks. - * - * Generated from protobuf field string description = 5; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Text that describes the vulnerability or misconfiguration that the custom - * module detects. This explanation is returned with each finding instance to - * help investigators understand the detected issue. The text must be enclosed - * in quotation marks. - * - * Generated from protobuf field string description = 5; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * An explanation of the recommended steps that security teams can take to - * resolve the detected issue. This explanation is returned with each finding - * generated by this module in the `nextSteps` property of the finding JSON. - * - * Generated from protobuf field string recommendation = 6; - * @return string - */ - public function getRecommendation() - { - return $this->recommendation; - } - - /** - * An explanation of the recommended steps that security teams can take to - * resolve the detected issue. This explanation is returned with each finding - * generated by this module in the `nextSteps` property of the finding JSON. - * - * Generated from protobuf field string recommendation = 6; - * @param string $var - * @return $this - */ - public function setRecommendation($var) - { - GPBUtil::checkString($var, True); - $this->recommendation = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/CustomOutputSpec.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/CustomOutputSpec.php deleted file mode 100644 index f5fd23d84efd..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/CustomOutputSpec.php +++ /dev/null @@ -1,73 +0,0 @@ -google.cloud.securitycenter.v1.CustomConfig.CustomOutputSpec - */ -class CustomOutputSpec extends \Google\Protobuf\Internal\Message -{ - /** - * A list of custom output properties to add to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.CustomConfig.CustomOutputSpec.Property properties = 1; - */ - private $properties; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1\CustomConfig\CustomOutputSpec\Property>|\Google\Protobuf\Internal\RepeatedField $properties - * A list of custom output properties to add to the finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecurityHealthAnalyticsCustomConfig::initOnce(); - parent::__construct($data); - } - - /** - * A list of custom output properties to add to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.CustomConfig.CustomOutputSpec.Property properties = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getProperties() - { - return $this->properties; - } - - /** - * A list of custom output properties to add to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.CustomConfig.CustomOutputSpec.Property properties = 1; - * @param array<\Google\Cloud\SecurityCenter\V1\CustomConfig\CustomOutputSpec\Property>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setProperties($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\CustomConfig\CustomOutputSpec\Property::class); - $this->properties = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(CustomOutputSpec::class, \Google\Cloud\SecurityCenter\V1\CustomConfig_CustomOutputSpec::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/CustomOutputSpec/Property.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/CustomOutputSpec/Property.php deleted file mode 100644 index 4ab8ce23ac6a..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/CustomOutputSpec/Property.php +++ /dev/null @@ -1,122 +0,0 @@ -google.cloud.securitycenter.v1.CustomConfig.CustomOutputSpec.Property - */ -class Property extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the property for the custom output. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The CEL expression for the custom output. A resource property can be - * specified to return the value of the property or a text string enclosed - * in quotation marks. - * - * Generated from protobuf field .google.type.Expr value_expression = 2; - */ - protected $value_expression = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Name of the property for the custom output. - * @type \Google\Type\Expr $value_expression - * The CEL expression for the custom output. A resource property can be - * specified to return the value of the property or a text string enclosed - * in quotation marks. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecurityHealthAnalyticsCustomConfig::initOnce(); - parent::__construct($data); - } - - /** - * Name of the property for the custom output. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Name of the property for the custom output. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The CEL expression for the custom output. A resource property can be - * specified to return the value of the property or a text string enclosed - * in quotation marks. - * - * Generated from protobuf field .google.type.Expr value_expression = 2; - * @return \Google\Type\Expr|null - */ - public function getValueExpression() - { - return $this->value_expression; - } - - public function hasValueExpression() - { - return isset($this->value_expression); - } - - public function clearValueExpression() - { - unset($this->value_expression); - } - - /** - * The CEL expression for the custom output. A resource property can be - * specified to return the value of the property or a text string enclosed - * in quotation marks. - * - * Generated from protobuf field .google.type.Expr value_expression = 2; - * @param \Google\Type\Expr $var - * @return $this - */ - public function setValueExpression($var) - { - GPBUtil::checkMessage($var, \Google\Type\Expr::class); - $this->value_expression = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Property::class, \Google\Cloud\SecurityCenter\V1\CustomConfig_CustomOutputSpec_Property::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/ResourceSelector.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/ResourceSelector.php deleted file mode 100644 index f16fa3fe0910..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/ResourceSelector.php +++ /dev/null @@ -1,70 +0,0 @@ -google.cloud.securitycenter.v1.CustomConfig.ResourceSelector - */ -class ResourceSelector extends \Google\Protobuf\Internal\Message -{ - /** - * The resource types to run the detector on. - * - * Generated from protobuf field repeated string resource_types = 1; - */ - private $resource_types; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $resource_types - * The resource types to run the detector on. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecurityHealthAnalyticsCustomConfig::initOnce(); - parent::__construct($data); - } - - /** - * The resource types to run the detector on. - * - * Generated from protobuf field repeated string resource_types = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getResourceTypes() - { - return $this->resource_types; - } - - /** - * The resource types to run the detector on. - * - * Generated from protobuf field repeated string resource_types = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setResourceTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->resource_types = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ResourceSelector::class, \Google\Cloud\SecurityCenter\V1\CustomConfig_ResourceSelector::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/Severity.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/Severity.php deleted file mode 100644 index 1ad1df7543cd..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/CustomConfig/Severity.php +++ /dev/null @@ -1,78 +0,0 @@ -google.cloud.securitycenter.v1.CustomConfig.Severity - */ -class Severity -{ - /** - * Unspecified severity. - * - * Generated from protobuf enum SEVERITY_UNSPECIFIED = 0; - */ - const SEVERITY_UNSPECIFIED = 0; - /** - * Critical severity. - * - * Generated from protobuf enum CRITICAL = 1; - */ - const CRITICAL = 1; - /** - * High severity. - * - * Generated from protobuf enum HIGH = 2; - */ - const HIGH = 2; - /** - * Medium severity. - * - * Generated from protobuf enum MEDIUM = 3; - */ - const MEDIUM = 3; - /** - * Low severity. - * - * Generated from protobuf enum LOW = 4; - */ - const LOW = 4; - - private static $valueToName = [ - self::SEVERITY_UNSPECIFIED => 'SEVERITY_UNSPECIFIED', - self::CRITICAL => 'CRITICAL', - self::HIGH => 'HIGH', - self::MEDIUM => 'MEDIUM', - self::LOW => 'LOW', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Severity::class, \Google\Cloud\SecurityCenter\V1\CustomConfig_Severity::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve.php deleted file mode 100644 index fe9664a68a58..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve.php +++ /dev/null @@ -1,330 +0,0 @@ -google.cloud.securitycenter.v1.Cve - */ -class Cve extends \Google\Protobuf\Internal\Message -{ - /** - * The unique identifier for the vulnerability. e.g. CVE-2021-34527 - * - * Generated from protobuf field string id = 1; - */ - protected $id = ''; - /** - * Additional information about the CVE. - * e.g. https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527 - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Reference references = 2; - */ - private $references; - /** - * Describe Common Vulnerability Scoring System specified at - * https://www.first.org/cvss/v3.1/specification-document - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3 cvssv3 = 3; - */ - protected $cvssv3 = null; - /** - * Whether upstream fix is available for the CVE. - * - * Generated from protobuf field bool upstream_fix_available = 4; - */ - protected $upstream_fix_available = false; - /** - * The potential impact of the vulnerability if it was to be exploited. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cve.RiskRating impact = 5; - */ - protected $impact = 0; - /** - * The exploitation activity of the vulnerability in the wild. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cve.ExploitationActivity exploitation_activity = 6; - */ - protected $exploitation_activity = 0; - /** - * Whether or not the vulnerability has been observed in the wild. - * - * Generated from protobuf field bool observed_in_the_wild = 7; - */ - protected $observed_in_the_wild = false; - /** - * Whether or not the vulnerability was zero day when the finding was - * published. - * - * Generated from protobuf field bool zero_day = 8; - */ - protected $zero_day = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $id - * The unique identifier for the vulnerability. e.g. CVE-2021-34527 - * @type array<\Google\Cloud\SecurityCenter\V1\Reference>|\Google\Protobuf\Internal\RepeatedField $references - * Additional information about the CVE. - * e.g. https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527 - * @type \Google\Cloud\SecurityCenter\V1\Cvssv3 $cvssv3 - * Describe Common Vulnerability Scoring System specified at - * https://www.first.org/cvss/v3.1/specification-document - * @type bool $upstream_fix_available - * Whether upstream fix is available for the CVE. - * @type int $impact - * The potential impact of the vulnerability if it was to be exploited. - * @type int $exploitation_activity - * The exploitation activity of the vulnerability in the wild. - * @type bool $observed_in_the_wild - * Whether or not the vulnerability has been observed in the wild. - * @type bool $zero_day - * Whether or not the vulnerability was zero day when the finding was - * published. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Vulnerability::initOnce(); - parent::__construct($data); - } - - /** - * The unique identifier for the vulnerability. e.g. CVE-2021-34527 - * - * Generated from protobuf field string id = 1; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * The unique identifier for the vulnerability. e.g. CVE-2021-34527 - * - * Generated from protobuf field string id = 1; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - - /** - * Additional information about the CVE. - * e.g. https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527 - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Reference references = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getReferences() - { - return $this->references; - } - - /** - * Additional information about the CVE. - * e.g. https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527 - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Reference references = 2; - * @param array<\Google\Cloud\SecurityCenter\V1\Reference>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setReferences($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Reference::class); - $this->references = $arr; - - return $this; - } - - /** - * Describe Common Vulnerability Scoring System specified at - * https://www.first.org/cvss/v3.1/specification-document - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3 cvssv3 = 3; - * @return \Google\Cloud\SecurityCenter\V1\Cvssv3|null - */ - public function getCvssv3() - { - return $this->cvssv3; - } - - public function hasCvssv3() - { - return isset($this->cvssv3); - } - - public function clearCvssv3() - { - unset($this->cvssv3); - } - - /** - * Describe Common Vulnerability Scoring System specified at - * https://www.first.org/cvss/v3.1/specification-document - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3 cvssv3 = 3; - * @param \Google\Cloud\SecurityCenter\V1\Cvssv3 $var - * @return $this - */ - public function setCvssv3($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Cvssv3::class); - $this->cvssv3 = $var; - - return $this; - } - - /** - * Whether upstream fix is available for the CVE. - * - * Generated from protobuf field bool upstream_fix_available = 4; - * @return bool - */ - public function getUpstreamFixAvailable() - { - return $this->upstream_fix_available; - } - - /** - * Whether upstream fix is available for the CVE. - * - * Generated from protobuf field bool upstream_fix_available = 4; - * @param bool $var - * @return $this - */ - public function setUpstreamFixAvailable($var) - { - GPBUtil::checkBool($var); - $this->upstream_fix_available = $var; - - return $this; - } - - /** - * The potential impact of the vulnerability if it was to be exploited. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cve.RiskRating impact = 5; - * @return int - */ - public function getImpact() - { - return $this->impact; - } - - /** - * The potential impact of the vulnerability if it was to be exploited. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cve.RiskRating impact = 5; - * @param int $var - * @return $this - */ - public function setImpact($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cve\RiskRating::class); - $this->impact = $var; - - return $this; - } - - /** - * The exploitation activity of the vulnerability in the wild. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cve.ExploitationActivity exploitation_activity = 6; - * @return int - */ - public function getExploitationActivity() - { - return $this->exploitation_activity; - } - - /** - * The exploitation activity of the vulnerability in the wild. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cve.ExploitationActivity exploitation_activity = 6; - * @param int $var - * @return $this - */ - public function setExploitationActivity($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cve\ExploitationActivity::class); - $this->exploitation_activity = $var; - - return $this; - } - - /** - * Whether or not the vulnerability has been observed in the wild. - * - * Generated from protobuf field bool observed_in_the_wild = 7; - * @return bool - */ - public function getObservedInTheWild() - { - return $this->observed_in_the_wild; - } - - /** - * Whether or not the vulnerability has been observed in the wild. - * - * Generated from protobuf field bool observed_in_the_wild = 7; - * @param bool $var - * @return $this - */ - public function setObservedInTheWild($var) - { - GPBUtil::checkBool($var); - $this->observed_in_the_wild = $var; - - return $this; - } - - /** - * Whether or not the vulnerability was zero day when the finding was - * published. - * - * Generated from protobuf field bool zero_day = 8; - * @return bool - */ - public function getZeroDay() - { - return $this->zero_day; - } - - /** - * Whether or not the vulnerability was zero day when the finding was - * published. - * - * Generated from protobuf field bool zero_day = 8; - * @param bool $var - * @return $this - */ - public function setZeroDay($var) - { - GPBUtil::checkBool($var); - $this->zero_day = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve/ExploitationActivity.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve/ExploitationActivity.php deleted file mode 100644 index fcc54b82f136..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve/ExploitationActivity.php +++ /dev/null @@ -1,87 +0,0 @@ -google.cloud.securitycenter.v1.Cve.ExploitationActivity - */ -class ExploitationActivity -{ - /** - * Invalid or empty value. - * - * Generated from protobuf enum EXPLOITATION_ACTIVITY_UNSPECIFIED = 0; - */ - const EXPLOITATION_ACTIVITY_UNSPECIFIED = 0; - /** - * Exploitation has been reported or confirmed to widely occur. - * - * Generated from protobuf enum WIDE = 1; - */ - const WIDE = 1; - /** - * Limited reported or confirmed exploitation activities. - * - * Generated from protobuf enum CONFIRMED = 2; - */ - const CONFIRMED = 2; - /** - * Exploit is publicly available. - * - * Generated from protobuf enum AVAILABLE = 3; - */ - const AVAILABLE = 3; - /** - * No known exploitation activity, but has a high potential for - * exploitation. - * - * Generated from protobuf enum ANTICIPATED = 4; - */ - const ANTICIPATED = 4; - /** - * No known exploitation activity. - * - * Generated from protobuf enum NO_KNOWN = 5; - */ - const NO_KNOWN = 5; - - private static $valueToName = [ - self::EXPLOITATION_ACTIVITY_UNSPECIFIED => 'EXPLOITATION_ACTIVITY_UNSPECIFIED', - self::WIDE => 'WIDE', - self::CONFIRMED => 'CONFIRMED', - self::AVAILABLE => 'AVAILABLE', - self::ANTICIPATED => 'ANTICIPATED', - self::NO_KNOWN => 'NO_KNOWN', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ExploitationActivity::class, \Google\Cloud\SecurityCenter\V1\Cve_ExploitationActivity::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve/RiskRating.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve/RiskRating.php deleted file mode 100644 index b18aa86caf9c..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cve/RiskRating.php +++ /dev/null @@ -1,83 +0,0 @@ -google.cloud.securitycenter.v1.Cve.RiskRating - */ -class RiskRating -{ - /** - * Invalid or empty value. - * - * Generated from protobuf enum RISK_RATING_UNSPECIFIED = 0; - */ - const RISK_RATING_UNSPECIFIED = 0; - /** - * Exploitation would have little to no security impact. - * - * Generated from protobuf enum LOW = 1; - */ - const LOW = 1; - /** - * Exploitation would enable attackers to perform activities, or could allow - * attackers to have a direct impact, but would require additional steps. - * - * Generated from protobuf enum MEDIUM = 2; - */ - const MEDIUM = 2; - /** - * Exploitation would enable attackers to have a notable direct impact - * without needing to overcome any major mitigating factors. - * - * Generated from protobuf enum HIGH = 3; - */ - const HIGH = 3; - /** - * Exploitation would fundamentally undermine the security of affected - * systems, enable actors to perform significant attacks with minimal - * effort, with little to no mitigating factors to overcome. - * - * Generated from protobuf enum CRITICAL = 4; - */ - const CRITICAL = 4; - - private static $valueToName = [ - self::RISK_RATING_UNSPECIFIED => 'RISK_RATING_UNSPECIFIED', - self::LOW => 'LOW', - self::MEDIUM => 'MEDIUM', - self::HIGH => 'HIGH', - self::CRITICAL => 'CRITICAL', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RiskRating::class, \Google\Cloud\SecurityCenter\V1\Cve_RiskRating::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3.php deleted file mode 100644 index d7eb6ed7aaa5..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3.php +++ /dev/null @@ -1,391 +0,0 @@ -google.cloud.securitycenter.v1.Cvssv3 - */ -class Cvssv3 extends \Google\Protobuf\Internal\Message -{ - /** - * The base score is a function of the base metric scores. - * - * Generated from protobuf field double base_score = 1; - */ - protected $base_score = 0.0; - /** - * Base Metrics - * Represents the intrinsic characteristics of a vulnerability that are - * constant over time and across user environments. - * This metric reflects the context by which vulnerability exploitation is - * possible. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.AttackVector attack_vector = 5; - */ - protected $attack_vector = 0; - /** - * This metric describes the conditions beyond the attacker's control that - * must exist in order to exploit the vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.AttackComplexity attack_complexity = 6; - */ - protected $attack_complexity = 0; - /** - * This metric describes the level of privileges an attacker must possess - * before successfully exploiting the vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.PrivilegesRequired privileges_required = 7; - */ - protected $privileges_required = 0; - /** - * This metric captures the requirement for a human user, other than the - * attacker, to participate in the successful compromise of the vulnerable - * component. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.UserInteraction user_interaction = 8; - */ - protected $user_interaction = 0; - /** - * The Scope metric captures whether a vulnerability in one vulnerable - * component impacts resources in components beyond its security scope. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Scope scope = 9; - */ - protected $scope = 0; - /** - * This metric measures the impact to the confidentiality of the information - * resources managed by a software component due to a successfully exploited - * vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Impact confidentiality_impact = 10; - */ - protected $confidentiality_impact = 0; - /** - * This metric measures the impact to integrity of a successfully exploited - * vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Impact integrity_impact = 11; - */ - protected $integrity_impact = 0; - /** - * This metric measures the impact to the availability of the impacted - * component resulting from a successfully exploited vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Impact availability_impact = 12; - */ - protected $availability_impact = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type float $base_score - * The base score is a function of the base metric scores. - * @type int $attack_vector - * Base Metrics - * Represents the intrinsic characteristics of a vulnerability that are - * constant over time and across user environments. - * This metric reflects the context by which vulnerability exploitation is - * possible. - * @type int $attack_complexity - * This metric describes the conditions beyond the attacker's control that - * must exist in order to exploit the vulnerability. - * @type int $privileges_required - * This metric describes the level of privileges an attacker must possess - * before successfully exploiting the vulnerability. - * @type int $user_interaction - * This metric captures the requirement for a human user, other than the - * attacker, to participate in the successful compromise of the vulnerable - * component. - * @type int $scope - * The Scope metric captures whether a vulnerability in one vulnerable - * component impacts resources in components beyond its security scope. - * @type int $confidentiality_impact - * This metric measures the impact to the confidentiality of the information - * resources managed by a software component due to a successfully exploited - * vulnerability. - * @type int $integrity_impact - * This metric measures the impact to integrity of a successfully exploited - * vulnerability. - * @type int $availability_impact - * This metric measures the impact to the availability of the impacted - * component resulting from a successfully exploited vulnerability. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Vulnerability::initOnce(); - parent::__construct($data); - } - - /** - * The base score is a function of the base metric scores. - * - * Generated from protobuf field double base_score = 1; - * @return float - */ - public function getBaseScore() - { - return $this->base_score; - } - - /** - * The base score is a function of the base metric scores. - * - * Generated from protobuf field double base_score = 1; - * @param float $var - * @return $this - */ - public function setBaseScore($var) - { - GPBUtil::checkDouble($var); - $this->base_score = $var; - - return $this; - } - - /** - * Base Metrics - * Represents the intrinsic characteristics of a vulnerability that are - * constant over time and across user environments. - * This metric reflects the context by which vulnerability exploitation is - * possible. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.AttackVector attack_vector = 5; - * @return int - */ - public function getAttackVector() - { - return $this->attack_vector; - } - - /** - * Base Metrics - * Represents the intrinsic characteristics of a vulnerability that are - * constant over time and across user environments. - * This metric reflects the context by which vulnerability exploitation is - * possible. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.AttackVector attack_vector = 5; - * @param int $var - * @return $this - */ - public function setAttackVector($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cvssv3\AttackVector::class); - $this->attack_vector = $var; - - return $this; - } - - /** - * This metric describes the conditions beyond the attacker's control that - * must exist in order to exploit the vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.AttackComplexity attack_complexity = 6; - * @return int - */ - public function getAttackComplexity() - { - return $this->attack_complexity; - } - - /** - * This metric describes the conditions beyond the attacker's control that - * must exist in order to exploit the vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.AttackComplexity attack_complexity = 6; - * @param int $var - * @return $this - */ - public function setAttackComplexity($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cvssv3\AttackComplexity::class); - $this->attack_complexity = $var; - - return $this; - } - - /** - * This metric describes the level of privileges an attacker must possess - * before successfully exploiting the vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.PrivilegesRequired privileges_required = 7; - * @return int - */ - public function getPrivilegesRequired() - { - return $this->privileges_required; - } - - /** - * This metric describes the level of privileges an attacker must possess - * before successfully exploiting the vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.PrivilegesRequired privileges_required = 7; - * @param int $var - * @return $this - */ - public function setPrivilegesRequired($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cvssv3\PrivilegesRequired::class); - $this->privileges_required = $var; - - return $this; - } - - /** - * This metric captures the requirement for a human user, other than the - * attacker, to participate in the successful compromise of the vulnerable - * component. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.UserInteraction user_interaction = 8; - * @return int - */ - public function getUserInteraction() - { - return $this->user_interaction; - } - - /** - * This metric captures the requirement for a human user, other than the - * attacker, to participate in the successful compromise of the vulnerable - * component. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.UserInteraction user_interaction = 8; - * @param int $var - * @return $this - */ - public function setUserInteraction($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cvssv3\UserInteraction::class); - $this->user_interaction = $var; - - return $this; - } - - /** - * The Scope metric captures whether a vulnerability in one vulnerable - * component impacts resources in components beyond its security scope. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Scope scope = 9; - * @return int - */ - public function getScope() - { - return $this->scope; - } - - /** - * The Scope metric captures whether a vulnerability in one vulnerable - * component impacts resources in components beyond its security scope. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Scope scope = 9; - * @param int $var - * @return $this - */ - public function setScope($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cvssv3\Scope::class); - $this->scope = $var; - - return $this; - } - - /** - * This metric measures the impact to the confidentiality of the information - * resources managed by a software component due to a successfully exploited - * vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Impact confidentiality_impact = 10; - * @return int - */ - public function getConfidentialityImpact() - { - return $this->confidentiality_impact; - } - - /** - * This metric measures the impact to the confidentiality of the information - * resources managed by a software component due to a successfully exploited - * vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Impact confidentiality_impact = 10; - * @param int $var - * @return $this - */ - public function setConfidentialityImpact($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cvssv3\Impact::class); - $this->confidentiality_impact = $var; - - return $this; - } - - /** - * This metric measures the impact to integrity of a successfully exploited - * vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Impact integrity_impact = 11; - * @return int - */ - public function getIntegrityImpact() - { - return $this->integrity_impact; - } - - /** - * This metric measures the impact to integrity of a successfully exploited - * vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Impact integrity_impact = 11; - * @param int $var - * @return $this - */ - public function setIntegrityImpact($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cvssv3\Impact::class); - $this->integrity_impact = $var; - - return $this; - } - - /** - * This metric measures the impact to the availability of the impacted - * component resulting from a successfully exploited vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Impact availability_impact = 12; - * @return int - */ - public function getAvailabilityImpact() - { - return $this->availability_impact; - } - - /** - * This metric measures the impact to the availability of the impacted - * component resulting from a successfully exploited vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cvssv3.Impact availability_impact = 12; - * @param int $var - * @return $this - */ - public function setAvailabilityImpact($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Cvssv3\Impact::class); - $this->availability_impact = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/AttackComplexity.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/AttackComplexity.php deleted file mode 100644 index 179eeffa8a5e..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/AttackComplexity.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.securitycenter.v1.Cvssv3.AttackComplexity - */ -class AttackComplexity -{ - /** - * Invalid value. - * - * Generated from protobuf enum ATTACK_COMPLEXITY_UNSPECIFIED = 0; - */ - const ATTACK_COMPLEXITY_UNSPECIFIED = 0; - /** - * Specialized access conditions or extenuating circumstances do not exist. - * An attacker can expect repeatable success when attacking the vulnerable - * component. - * - * Generated from protobuf enum ATTACK_COMPLEXITY_LOW = 1; - */ - const ATTACK_COMPLEXITY_LOW = 1; - /** - * A successful attack depends on conditions beyond the attacker's control. - * That is, a successful attack cannot be accomplished at will, but requires - * the attacker to invest in some measurable amount of effort in preparation - * or execution against the vulnerable component before a successful attack - * can be expected. - * - * Generated from protobuf enum ATTACK_COMPLEXITY_HIGH = 2; - */ - const ATTACK_COMPLEXITY_HIGH = 2; - - private static $valueToName = [ - self::ATTACK_COMPLEXITY_UNSPECIFIED => 'ATTACK_COMPLEXITY_UNSPECIFIED', - self::ATTACK_COMPLEXITY_LOW => 'ATTACK_COMPLEXITY_LOW', - self::ATTACK_COMPLEXITY_HIGH => 'ATTACK_COMPLEXITY_HIGH', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AttackComplexity::class, \Google\Cloud\SecurityCenter\V1\Cvssv3_AttackComplexity::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/AttackVector.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/AttackVector.php deleted file mode 100644 index fa6acfc9dc84..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/AttackVector.php +++ /dev/null @@ -1,84 +0,0 @@ -google.cloud.securitycenter.v1.Cvssv3.AttackVector - */ -class AttackVector -{ - /** - * Invalid value. - * - * Generated from protobuf enum ATTACK_VECTOR_UNSPECIFIED = 0; - */ - const ATTACK_VECTOR_UNSPECIFIED = 0; - /** - * The vulnerable component is bound to the network stack and the set of - * possible attackers extends beyond the other options listed below, up to - * and including the entire Internet. - * - * Generated from protobuf enum ATTACK_VECTOR_NETWORK = 1; - */ - const ATTACK_VECTOR_NETWORK = 1; - /** - * The vulnerable component is bound to the network stack, but the attack is - * limited at the protocol level to a logically adjacent topology. - * - * Generated from protobuf enum ATTACK_VECTOR_ADJACENT = 2; - */ - const ATTACK_VECTOR_ADJACENT = 2; - /** - * The vulnerable component is not bound to the network stack and the - * attacker's path is via read/write/execute capabilities. - * - * Generated from protobuf enum ATTACK_VECTOR_LOCAL = 3; - */ - const ATTACK_VECTOR_LOCAL = 3; - /** - * The attack requires the attacker to physically touch or manipulate the - * vulnerable component. - * - * Generated from protobuf enum ATTACK_VECTOR_PHYSICAL = 4; - */ - const ATTACK_VECTOR_PHYSICAL = 4; - - private static $valueToName = [ - self::ATTACK_VECTOR_UNSPECIFIED => 'ATTACK_VECTOR_UNSPECIFIED', - self::ATTACK_VECTOR_NETWORK => 'ATTACK_VECTOR_NETWORK', - self::ATTACK_VECTOR_ADJACENT => 'ATTACK_VECTOR_ADJACENT', - self::ATTACK_VECTOR_LOCAL => 'ATTACK_VECTOR_LOCAL', - self::ATTACK_VECTOR_PHYSICAL => 'ATTACK_VECTOR_PHYSICAL', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AttackVector::class, \Google\Cloud\SecurityCenter\V1\Cvssv3_AttackVector::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/Impact.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/Impact.php deleted file mode 100644 index 027aced5e553..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/Impact.php +++ /dev/null @@ -1,73 +0,0 @@ -google.cloud.securitycenter.v1.Cvssv3.Impact - */ -class Impact -{ - /** - * Invalid value. - * - * Generated from protobuf enum IMPACT_UNSPECIFIED = 0; - */ - const IMPACT_UNSPECIFIED = 0; - /** - * High impact. - * - * Generated from protobuf enum IMPACT_HIGH = 1; - */ - const IMPACT_HIGH = 1; - /** - * Low impact. - * - * Generated from protobuf enum IMPACT_LOW = 2; - */ - const IMPACT_LOW = 2; - /** - * No impact. - * - * Generated from protobuf enum IMPACT_NONE = 3; - */ - const IMPACT_NONE = 3; - - private static $valueToName = [ - self::IMPACT_UNSPECIFIED => 'IMPACT_UNSPECIFIED', - self::IMPACT_HIGH => 'IMPACT_HIGH', - self::IMPACT_LOW => 'IMPACT_LOW', - self::IMPACT_NONE => 'IMPACT_NONE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Impact::class, \Google\Cloud\SecurityCenter\V1\Cvssv3_Impact::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/PrivilegesRequired.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/PrivilegesRequired.php deleted file mode 100644 index 29fef4718691..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/PrivilegesRequired.php +++ /dev/null @@ -1,79 +0,0 @@ -google.cloud.securitycenter.v1.Cvssv3.PrivilegesRequired - */ -class PrivilegesRequired -{ - /** - * Invalid value. - * - * Generated from protobuf enum PRIVILEGES_REQUIRED_UNSPECIFIED = 0; - */ - const PRIVILEGES_REQUIRED_UNSPECIFIED = 0; - /** - * The attacker is unauthorized prior to attack, and therefore does not - * require any access to settings or files of the vulnerable system to - * carry out an attack. - * - * Generated from protobuf enum PRIVILEGES_REQUIRED_NONE = 1; - */ - const PRIVILEGES_REQUIRED_NONE = 1; - /** - * The attacker requires privileges that provide basic user capabilities - * that could normally affect only settings and files owned by a user. - * Alternatively, an attacker with Low privileges has the ability to access - * only non-sensitive resources. - * - * Generated from protobuf enum PRIVILEGES_REQUIRED_LOW = 2; - */ - const PRIVILEGES_REQUIRED_LOW = 2; - /** - * The attacker requires privileges that provide significant (e.g., - * administrative) control over the vulnerable component allowing access to - * component-wide settings and files. - * - * Generated from protobuf enum PRIVILEGES_REQUIRED_HIGH = 3; - */ - const PRIVILEGES_REQUIRED_HIGH = 3; - - private static $valueToName = [ - self::PRIVILEGES_REQUIRED_UNSPECIFIED => 'PRIVILEGES_REQUIRED_UNSPECIFIED', - self::PRIVILEGES_REQUIRED_NONE => 'PRIVILEGES_REQUIRED_NONE', - self::PRIVILEGES_REQUIRED_LOW => 'PRIVILEGES_REQUIRED_LOW', - self::PRIVILEGES_REQUIRED_HIGH => 'PRIVILEGES_REQUIRED_HIGH', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PrivilegesRequired::class, \Google\Cloud\SecurityCenter\V1\Cvssv3_PrivilegesRequired::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/Scope.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/Scope.php deleted file mode 100644 index cb0e08038f76..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/Scope.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.securitycenter.v1.Cvssv3.Scope - */ -class Scope -{ - /** - * Invalid value. - * - * Generated from protobuf enum SCOPE_UNSPECIFIED = 0; - */ - const SCOPE_UNSPECIFIED = 0; - /** - * An exploited vulnerability can only affect resources managed by the same - * security authority. - * - * Generated from protobuf enum SCOPE_UNCHANGED = 1; - */ - const SCOPE_UNCHANGED = 1; - /** - * An exploited vulnerability can affect resources beyond the security scope - * managed by the security authority of the vulnerable component. - * - * Generated from protobuf enum SCOPE_CHANGED = 2; - */ - const SCOPE_CHANGED = 2; - - private static $valueToName = [ - self::SCOPE_UNSPECIFIED => 'SCOPE_UNSPECIFIED', - self::SCOPE_UNCHANGED => 'SCOPE_UNCHANGED', - self::SCOPE_CHANGED => 'SCOPE_CHANGED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Scope::class, \Google\Cloud\SecurityCenter\V1\Cvssv3_Scope::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/UserInteraction.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/UserInteraction.php deleted file mode 100644 index 305d85c574e2..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Cvssv3/UserInteraction.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.securitycenter.v1.Cvssv3.UserInteraction - */ -class UserInteraction -{ - /** - * Invalid value. - * - * Generated from protobuf enum USER_INTERACTION_UNSPECIFIED = 0; - */ - const USER_INTERACTION_UNSPECIFIED = 0; - /** - * The vulnerable system can be exploited without interaction from any user. - * - * Generated from protobuf enum USER_INTERACTION_NONE = 1; - */ - const USER_INTERACTION_NONE = 1; - /** - * Successful exploitation of this vulnerability requires a user to take - * some action before the vulnerability can be exploited. - * - * Generated from protobuf enum USER_INTERACTION_REQUIRED = 2; - */ - const USER_INTERACTION_REQUIRED = 2; - - private static $valueToName = [ - self::USER_INTERACTION_UNSPECIFIED => 'USER_INTERACTION_UNSPECIFIED', - self::USER_INTERACTION_NONE => 'USER_INTERACTION_NONE', - self::USER_INTERACTION_REQUIRED => 'USER_INTERACTION_REQUIRED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(UserInteraction::class, \Google\Cloud\SecurityCenter\V1\Cvssv3_UserInteraction::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Database.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Database.php deleted file mode 100644 index 832630602155..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Database.php +++ /dev/null @@ -1,287 +0,0 @@ -google.cloud.securitycenter.v1.Database - */ -class Database extends \Google\Protobuf\Internal\Message -{ - /** - * Some database resources may not have the [full resource - * name](https://google.aip.dev/122#full-resource-names) populated because - * these resource types are not yet supported by Cloud Asset Inventory (e.g. - * Cloud SQL databases). In these cases only the display name will be - * provided. - * The [full resource name](https://google.aip.dev/122#full-resource-names) of - * the database that the user connected to, if it is supported by Cloud Asset - * Inventory. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The human-readable name of the database that the user connected to. - * - * Generated from protobuf field string display_name = 2; - */ - protected $display_name = ''; - /** - * The username used to connect to the database. The username might not be an - * IAM principal and does not have a set format. - * - * Generated from protobuf field string user_name = 3; - */ - protected $user_name = ''; - /** - * The SQL statement that is associated with the database access. - * - * Generated from protobuf field string query = 4; - */ - protected $query = ''; - /** - * The target usernames, roles, or groups of an SQL privilege grant, which is - * not an IAM policy change. - * - * Generated from protobuf field repeated string grantees = 5; - */ - private $grantees; - /** - * The version of the database, for example, POSTGRES_14. - * See [the complete - * list](https://cloud.google.com/sql/docs/mysql/admin-api/rest/v1/SqlDatabaseVersion). - * - * Generated from protobuf field string version = 6; - */ - protected $version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Some database resources may not have the [full resource - * name](https://google.aip.dev/122#full-resource-names) populated because - * these resource types are not yet supported by Cloud Asset Inventory (e.g. - * Cloud SQL databases). In these cases only the display name will be - * provided. - * The [full resource name](https://google.aip.dev/122#full-resource-names) of - * the database that the user connected to, if it is supported by Cloud Asset - * Inventory. - * @type string $display_name - * The human-readable name of the database that the user connected to. - * @type string $user_name - * The username used to connect to the database. The username might not be an - * IAM principal and does not have a set format. - * @type string $query - * The SQL statement that is associated with the database access. - * @type array|\Google\Protobuf\Internal\RepeatedField $grantees - * The target usernames, roles, or groups of an SQL privilege grant, which is - * not an IAM policy change. - * @type string $version - * The version of the database, for example, POSTGRES_14. - * See [the complete - * list](https://cloud.google.com/sql/docs/mysql/admin-api/rest/v1/SqlDatabaseVersion). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Database::initOnce(); - parent::__construct($data); - } - - /** - * Some database resources may not have the [full resource - * name](https://google.aip.dev/122#full-resource-names) populated because - * these resource types are not yet supported by Cloud Asset Inventory (e.g. - * Cloud SQL databases). In these cases only the display name will be - * provided. - * The [full resource name](https://google.aip.dev/122#full-resource-names) of - * the database that the user connected to, if it is supported by Cloud Asset - * Inventory. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Some database resources may not have the [full resource - * name](https://google.aip.dev/122#full-resource-names) populated because - * these resource types are not yet supported by Cloud Asset Inventory (e.g. - * Cloud SQL databases). In these cases only the display name will be - * provided. - * The [full resource name](https://google.aip.dev/122#full-resource-names) of - * the database that the user connected to, if it is supported by Cloud Asset - * Inventory. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The human-readable name of the database that the user connected to. - * - * Generated from protobuf field string display_name = 2; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * The human-readable name of the database that the user connected to. - * - * Generated from protobuf field string display_name = 2; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * The username used to connect to the database. The username might not be an - * IAM principal and does not have a set format. - * - * Generated from protobuf field string user_name = 3; - * @return string - */ - public function getUserName() - { - return $this->user_name; - } - - /** - * The username used to connect to the database. The username might not be an - * IAM principal and does not have a set format. - * - * Generated from protobuf field string user_name = 3; - * @param string $var - * @return $this - */ - public function setUserName($var) - { - GPBUtil::checkString($var, True); - $this->user_name = $var; - - return $this; - } - - /** - * The SQL statement that is associated with the database access. - * - * Generated from protobuf field string query = 4; - * @return string - */ - public function getQuery() - { - return $this->query; - } - - /** - * The SQL statement that is associated with the database access. - * - * Generated from protobuf field string query = 4; - * @param string $var - * @return $this - */ - public function setQuery($var) - { - GPBUtil::checkString($var, True); - $this->query = $var; - - return $this; - } - - /** - * The target usernames, roles, or groups of an SQL privilege grant, which is - * not an IAM policy change. - * - * Generated from protobuf field repeated string grantees = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getGrantees() - { - return $this->grantees; - } - - /** - * The target usernames, roles, or groups of an SQL privilege grant, which is - * not an IAM policy change. - * - * Generated from protobuf field repeated string grantees = 5; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setGrantees($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->grantees = $arr; - - return $this; - } - - /** - * The version of the database, for example, POSTGRES_14. - * See [the complete - * list](https://cloud.google.com/sql/docs/mysql/admin-api/rest/v1/SqlDatabaseVersion). - * - * Generated from protobuf field string version = 6; - * @return string - */ - public function getVersion() - { - return $this->version; - } - - /** - * The version of the database, for example, POSTGRES_14. - * See [the complete - * list](https://cloud.google.com/sql/docs/mysql/admin-api/rest/v1/SqlDatabaseVersion). - * - * Generated from protobuf field string version = 6; - * @param string $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkString($var, True); - $this->version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteBigQueryExportRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteBigQueryExportRequest.php deleted file mode 100644 index 503020359328..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteBigQueryExportRequest.php +++ /dev/null @@ -1,96 +0,0 @@ -google.cloud.securitycenter.v1.DeleteBigQueryExportRequest - */ -class DeleteBigQueryExportRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the BigQuery export to delete. Its format is - * organizations/{organization}/bigQueryExports/{export_id}, - * folders/{folder}/bigQueryExports/{export_id}, or - * projects/{project}/bigQueryExports/{export_id} - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the BigQuery export to delete. Its format is - * organizations/{organization}/bigQueryExports/{export_id}, - * folders/{folder}/bigQueryExports/{export_id}, or - * projects/{project}/bigQueryExports/{export_id} - * Please see {@see SecurityCenterClient::bigQueryExportName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V1\DeleteBigQueryExportRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the BigQuery export to delete. Its format is - * organizations/{organization}/bigQueryExports/{export_id}, - * folders/{folder}/bigQueryExports/{export_id}, or - * projects/{project}/bigQueryExports/{export_id} - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the BigQuery export to delete. Its format is - * organizations/{organization}/bigQueryExports/{export_id}, - * folders/{folder}/bigQueryExports/{export_id}, or - * projects/{project}/bigQueryExports/{export_id} - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the BigQuery export to delete. Its format is - * organizations/{organization}/bigQueryExports/{export_id}, - * folders/{folder}/bigQueryExports/{export_id}, or - * projects/{project}/bigQueryExports/{export_id} - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteMuteConfigRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteMuteConfigRequest.php deleted file mode 100644 index a598b80efffb..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteMuteConfigRequest.php +++ /dev/null @@ -1,96 +0,0 @@ -google.cloud.securitycenter.v1.DeleteMuteConfigRequest - */ -class DeleteMuteConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the mute config to delete. Its format is - * organizations/{organization}/muteConfigs/{config_id}, - * folders/{folder}/muteConfigs/{config_id}, or - * projects/{project}/muteConfigs/{config_id} - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the mute config to delete. Its format is - * organizations/{organization}/muteConfigs/{config_id}, - * folders/{folder}/muteConfigs/{config_id}, or - * projects/{project}/muteConfigs/{config_id} - * Please see {@see SecurityCenterClient::muteConfigName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V1\DeleteMuteConfigRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the mute config to delete. Its format is - * organizations/{organization}/muteConfigs/{config_id}, - * folders/{folder}/muteConfigs/{config_id}, or - * projects/{project}/muteConfigs/{config_id} - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the mute config to delete. Its format is - * organizations/{organization}/muteConfigs/{config_id}, - * folders/{folder}/muteConfigs/{config_id}, or - * projects/{project}/muteConfigs/{config_id} - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the mute config to delete. Its format is - * organizations/{organization}/muteConfigs/{config_id}, - * folders/{folder}/muteConfigs/{config_id}, or - * projects/{project}/muteConfigs/{config_id} - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteNotificationConfigRequest.php deleted file mode 100644 index d08650df3d0f..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteNotificationConfigRequest.php +++ /dev/null @@ -1,96 +0,0 @@ -google.cloud.securitycenter.v1.DeleteNotificationConfigRequest - */ -class DeleteNotificationConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the notification config to delete. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]", - * "folders/[folder_id]/notificationConfigs/[config_id]", - * or "projects/[project_id]/notificationConfigs/[config_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the notification config to delete. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]", - * "folders/[folder_id]/notificationConfigs/[config_id]", - * or "projects/[project_id]/notificationConfigs/[config_id]". Please see - * {@see SecurityCenterClient::notificationConfigName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V1\DeleteNotificationConfigRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the notification config to delete. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]", - * "folders/[folder_id]/notificationConfigs/[config_id]", - * or "projects/[project_id]/notificationConfigs/[config_id]". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the notification config to delete. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]", - * "folders/[folder_id]/notificationConfigs/[config_id]", - * or "projects/[project_id]/notificationConfigs/[config_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the notification config to delete. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]", - * "folders/[folder_id]/notificationConfigs/[config_id]", - * or "projects/[project_id]/notificationConfigs/[config_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteSecurityHealthAnalyticsCustomModuleRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteSecurityHealthAnalyticsCustomModuleRequest.php deleted file mode 100644 index 60ddfdedb227..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/DeleteSecurityHealthAnalyticsCustomModuleRequest.php +++ /dev/null @@ -1,101 +0,0 @@ -google.cloud.securitycenter.v1.DeleteSecurityHealthAnalyticsCustomModuleRequest - */ -class DeleteSecurityHealthAnalyticsCustomModuleRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the custom module to delete. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", - * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the custom module to delete. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", - * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" - * Please see {@see SecurityCenterClient::securityHealthAnalyticsCustomModuleName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V1\DeleteSecurityHealthAnalyticsCustomModuleRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the custom module to delete. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", - * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the custom module to delete. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", - * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the custom module to delete. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", - * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EffectiveSecurityHealthAnalyticsCustomModule.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EffectiveSecurityHealthAnalyticsCustomModule.php deleted file mode 100644 index e16fe3e3ff88..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EffectiveSecurityHealthAnalyticsCustomModule.php +++ /dev/null @@ -1,223 +0,0 @@ -google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule - */ -class EffectiveSecurityHealthAnalyticsCustomModule extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of the custom module. - * Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * or - * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. The user-specified configuration for the module. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig custom_config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $custom_config = null; - /** - * Output only. The effective state of enablement for the module at the given - * level of the hierarchy. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule.EnablementState enablement_state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $enablement_state = 0; - /** - * Output only. The display name for the custom module. The name must be - * between 1 and 128 characters, start with a lowercase letter, and contain - * alphanumeric characters or underscores only. - * - * Generated from protobuf field string display_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $display_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of the custom module. - * Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * or - * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" - * @type \Google\Cloud\SecurityCenter\V1\CustomConfig $custom_config - * Output only. The user-specified configuration for the module. - * @type int $enablement_state - * Output only. The effective state of enablement for the module at the given - * level of the hierarchy. - * @type string $display_name - * Output only. The display name for the custom module. The name must be - * between 1 and 128 characters, start with a lowercase letter, and contain - * alphanumeric characters or underscores only. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\EffectiveSecurityHealthAnalyticsCustomModule::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of the custom module. - * Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * or - * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. The resource name of the custom module. - * Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * or - * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. The user-specified configuration for the module. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig custom_config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\SecurityCenter\V1\CustomConfig|null - */ - public function getCustomConfig() - { - return $this->custom_config; - } - - public function hasCustomConfig() - { - return isset($this->custom_config); - } - - public function clearCustomConfig() - { - unset($this->custom_config); - } - - /** - * Output only. The user-specified configuration for the module. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig custom_config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\SecurityCenter\V1\CustomConfig $var - * @return $this - */ - public function setCustomConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\CustomConfig::class); - $this->custom_config = $var; - - return $this; - } - - /** - * Output only. The effective state of enablement for the module at the given - * level of the hierarchy. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule.EnablementState enablement_state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getEnablementState() - { - return $this->enablement_state; - } - - /** - * Output only. The effective state of enablement for the module at the given - * level of the hierarchy. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule.EnablementState enablement_state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setEnablementState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\EffectiveSecurityHealthAnalyticsCustomModule\EnablementState::class); - $this->enablement_state = $var; - - return $this; - } - - /** - * Output only. The display name for the custom module. The name must be - * between 1 and 128 characters, start with a lowercase letter, and contain - * alphanumeric characters or underscores only. - * - * Generated from protobuf field string display_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Output only. The display name for the custom module. The name must be - * between 1 and 128 characters, start with a lowercase letter, and contain - * alphanumeric characters or underscores only. - * - * Generated from protobuf field string display_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EffectiveSecurityHealthAnalyticsCustomModule/EnablementState.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EffectiveSecurityHealthAnalyticsCustomModule/EnablementState.php deleted file mode 100644 index 8a5a60c564f6..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EffectiveSecurityHealthAnalyticsCustomModule/EnablementState.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule.EnablementState - */ -class EnablementState -{ - /** - * Unspecified enablement state. - * - * Generated from protobuf enum ENABLEMENT_STATE_UNSPECIFIED = 0; - */ - const ENABLEMENT_STATE_UNSPECIFIED = 0; - /** - * The module is enabled at the given level. - * - * Generated from protobuf enum ENABLED = 1; - */ - const ENABLED = 1; - /** - * The module is disabled at the given level. - * - * Generated from protobuf enum DISABLED = 2; - */ - const DISABLED = 2; - - private static $valueToName = [ - self::ENABLEMENT_STATE_UNSPECIFIED => 'ENABLEMENT_STATE_UNSPECIFIED', - self::ENABLED => 'ENABLED', - self::DISABLED => 'DISABLED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(EnablementState::class, \Google\Cloud\SecurityCenter\V1\EffectiveSecurityHealthAnalyticsCustomModule_EnablementState::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EnvironmentVariable.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EnvironmentVariable.php deleted file mode 100644 index fc98632adc3f..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/EnvironmentVariable.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.securitycenter.v1.EnvironmentVariable - */ -class EnvironmentVariable extends \Google\Protobuf\Internal\Message -{ - /** - * Environment variable name as a JSON encoded string. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Environment variable value as a JSON encoded string. - * - * Generated from protobuf field string val = 2; - */ - protected $val = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Environment variable name as a JSON encoded string. - * @type string $val - * Environment variable value as a JSON encoded string. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Process::initOnce(); - parent::__construct($data); - } - - /** - * Environment variable name as a JSON encoded string. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Environment variable name as a JSON encoded string. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Environment variable value as a JSON encoded string. - * - * Generated from protobuf field string val = 2; - * @return string - */ - public function getVal() - { - return $this->val; - } - - /** - * Environment variable value as a JSON encoded string. - * - * Generated from protobuf field string val = 2; - * @param string $var - * @return $this - */ - public function setVal($var) - { - GPBUtil::checkString($var, True); - $this->val = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExfilResource.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExfilResource.php deleted file mode 100644 index 830ad855f956..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExfilResource.php +++ /dev/null @@ -1,121 +0,0 @@ -google.cloud.securitycenter.v1.ExfilResource - */ -class ExfilResource extends \Google\Protobuf\Internal\Message -{ - /** - * The resource's [full resource - * name](https://cloud.google.com/apis/design/resource_names#full_resource_name). - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Subcomponents of the asset that was exfiltrated, like URIs used during - * exfiltration, table names, databases, and filenames. For example, multiple - * tables might have been exfiltrated from the same Cloud SQL instance, or - * multiple files might have been exfiltrated from the same Cloud Storage - * bucket. - * - * Generated from protobuf field repeated string components = 2; - */ - private $components; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The resource's [full resource - * name](https://cloud.google.com/apis/design/resource_names#full_resource_name). - * @type array|\Google\Protobuf\Internal\RepeatedField $components - * Subcomponents of the asset that was exfiltrated, like URIs used during - * exfiltration, table names, databases, and filenames. For example, multiple - * tables might have been exfiltrated from the same Cloud SQL instance, or - * multiple files might have been exfiltrated from the same Cloud Storage - * bucket. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Exfiltration::initOnce(); - parent::__construct($data); - } - - /** - * The resource's [full resource - * name](https://cloud.google.com/apis/design/resource_names#full_resource_name). - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The resource's [full resource - * name](https://cloud.google.com/apis/design/resource_names#full_resource_name). - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Subcomponents of the asset that was exfiltrated, like URIs used during - * exfiltration, table names, databases, and filenames. For example, multiple - * tables might have been exfiltrated from the same Cloud SQL instance, or - * multiple files might have been exfiltrated from the same Cloud Storage - * bucket. - * - * Generated from protobuf field repeated string components = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getComponents() - { - return $this->components; - } - - /** - * Subcomponents of the asset that was exfiltrated, like URIs used during - * exfiltration, table names, databases, and filenames. For example, multiple - * tables might have been exfiltrated from the same Cloud SQL instance, or - * multiple files might have been exfiltrated from the same Cloud Storage - * bucket. - * - * Generated from protobuf field repeated string components = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setComponents($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->components = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Exfiltration.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Exfiltration.php deleted file mode 100644 index a8e7f4621a2c..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Exfiltration.php +++ /dev/null @@ -1,150 +0,0 @@ -google.cloud.securitycenter.v1.Exfiltration - */ -class Exfiltration extends \Google\Protobuf\Internal\Message -{ - /** - * If there are multiple sources, then the data is considered "joined" between - * them. For instance, BigQuery can join multiple tables, and each - * table would be considered a source. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ExfilResource sources = 1; - */ - private $sources; - /** - * If there are multiple targets, each target would get a complete copy of the - * "joined" source data. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ExfilResource targets = 2; - */ - private $targets; - /** - * Total exfiltrated bytes processed for the entire job. - * - * Generated from protobuf field int64 total_exfiltrated_bytes = 3; - */ - protected $total_exfiltrated_bytes = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1\ExfilResource>|\Google\Protobuf\Internal\RepeatedField $sources - * If there are multiple sources, then the data is considered "joined" between - * them. For instance, BigQuery can join multiple tables, and each - * table would be considered a source. - * @type array<\Google\Cloud\SecurityCenter\V1\ExfilResource>|\Google\Protobuf\Internal\RepeatedField $targets - * If there are multiple targets, each target would get a complete copy of the - * "joined" source data. - * @type int|string $total_exfiltrated_bytes - * Total exfiltrated bytes processed for the entire job. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Exfiltration::initOnce(); - parent::__construct($data); - } - - /** - * If there are multiple sources, then the data is considered "joined" between - * them. For instance, BigQuery can join multiple tables, and each - * table would be considered a source. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ExfilResource sources = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSources() - { - return $this->sources; - } - - /** - * If there are multiple sources, then the data is considered "joined" between - * them. For instance, BigQuery can join multiple tables, and each - * table would be considered a source. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ExfilResource sources = 1; - * @param array<\Google\Cloud\SecurityCenter\V1\ExfilResource>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSources($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\ExfilResource::class); - $this->sources = $arr; - - return $this; - } - - /** - * If there are multiple targets, each target would get a complete copy of the - * "joined" source data. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ExfilResource targets = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTargets() - { - return $this->targets; - } - - /** - * If there are multiple targets, each target would get a complete copy of the - * "joined" source data. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ExfilResource targets = 2; - * @param array<\Google\Cloud\SecurityCenter\V1\ExfilResource>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTargets($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\ExfilResource::class); - $this->targets = $arr; - - return $this; - } - - /** - * Total exfiltrated bytes processed for the entire job. - * - * Generated from protobuf field int64 total_exfiltrated_bytes = 3; - * @return int|string - */ - public function getTotalExfiltratedBytes() - { - return $this->total_exfiltrated_bytes; - } - - /** - * Total exfiltrated bytes processed for the entire job. - * - * Generated from protobuf field int64 total_exfiltrated_bytes = 3; - * @param int|string $var - * @return $this - */ - public function setTotalExfiltratedBytes($var) - { - GPBUtil::checkInt64($var); - $this->total_exfiltrated_bytes = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExternalSystem.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExternalSystem.php deleted file mode 100644 index 345ab6fbe6d4..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExternalSystem.php +++ /dev/null @@ -1,485 +0,0 @@ -google.cloud.securitycenter.v1.ExternalSystem - */ -class ExternalSystem extends \Google\Protobuf\Internal\Message -{ - /** - * Full resource name of the external system, for example: - * "organizations/1234/sources/5678/findings/123456/externalSystems/jira", - * "folders/1234/sources/5678/findings/123456/externalSystems/jira", - * "projects/1234/sources/5678/findings/123456/externalSystems/jira" - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * References primary/secondary etc assignees in the external system. - * - * Generated from protobuf field repeated string assignees = 2; - */ - private $assignees; - /** - * The identifier that's used to track the finding's corresponding case in the - * external system. - * - * Generated from protobuf field string external_uid = 3; - */ - protected $external_uid = ''; - /** - * The most recent status of the finding's corresponding case, as reported by - * the external system. - * - * Generated from protobuf field string status = 4; - */ - protected $status = ''; - /** - * The time when the case was last updated, as reported by the external - * system. - * - * Generated from protobuf field .google.protobuf.Timestamp external_system_update_time = 5; - */ - protected $external_system_update_time = null; - /** - * The link to the finding's corresponding case in the external system. - * - * Generated from protobuf field string case_uri = 6; - */ - protected $case_uri = ''; - /** - * The priority of the finding's corresponding case in the external system. - * - * Generated from protobuf field string case_priority = 7; - */ - protected $case_priority = ''; - /** - * The SLA of the finding's corresponding case in the external system. - * - * Generated from protobuf field .google.protobuf.Timestamp case_sla = 9; - */ - protected $case_sla = null; - /** - * The time when the case was created, as reported by the external system. - * - * Generated from protobuf field .google.protobuf.Timestamp case_create_time = 10; - */ - protected $case_create_time = null; - /** - * The time when the case was closed, as reported by the external system. - * - * Generated from protobuf field .google.protobuf.Timestamp case_close_time = 11; - */ - protected $case_close_time = null; - /** - * Information about the ticket, if any, that is being used to track the - * resolution of the issue that is identified by this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.ExternalSystem.TicketInfo ticket_info = 8; - */ - protected $ticket_info = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Full resource name of the external system, for example: - * "organizations/1234/sources/5678/findings/123456/externalSystems/jira", - * "folders/1234/sources/5678/findings/123456/externalSystems/jira", - * "projects/1234/sources/5678/findings/123456/externalSystems/jira" - * @type array|\Google\Protobuf\Internal\RepeatedField $assignees - * References primary/secondary etc assignees in the external system. - * @type string $external_uid - * The identifier that's used to track the finding's corresponding case in the - * external system. - * @type string $status - * The most recent status of the finding's corresponding case, as reported by - * the external system. - * @type \Google\Protobuf\Timestamp $external_system_update_time - * The time when the case was last updated, as reported by the external - * system. - * @type string $case_uri - * The link to the finding's corresponding case in the external system. - * @type string $case_priority - * The priority of the finding's corresponding case in the external system. - * @type \Google\Protobuf\Timestamp $case_sla - * The SLA of the finding's corresponding case in the external system. - * @type \Google\Protobuf\Timestamp $case_create_time - * The time when the case was created, as reported by the external system. - * @type \Google\Protobuf\Timestamp $case_close_time - * The time when the case was closed, as reported by the external system. - * @type \Google\Cloud\SecurityCenter\V1\ExternalSystem\TicketInfo $ticket_info - * Information about the ticket, if any, that is being used to track the - * resolution of the issue that is identified by this finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\ExternalSystem::initOnce(); - parent::__construct($data); - } - - /** - * Full resource name of the external system, for example: - * "organizations/1234/sources/5678/findings/123456/externalSystems/jira", - * "folders/1234/sources/5678/findings/123456/externalSystems/jira", - * "projects/1234/sources/5678/findings/123456/externalSystems/jira" - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Full resource name of the external system, for example: - * "organizations/1234/sources/5678/findings/123456/externalSystems/jira", - * "folders/1234/sources/5678/findings/123456/externalSystems/jira", - * "projects/1234/sources/5678/findings/123456/externalSystems/jira" - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * References primary/secondary etc assignees in the external system. - * - * Generated from protobuf field repeated string assignees = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAssignees() - { - return $this->assignees; - } - - /** - * References primary/secondary etc assignees in the external system. - * - * Generated from protobuf field repeated string assignees = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAssignees($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->assignees = $arr; - - return $this; - } - - /** - * The identifier that's used to track the finding's corresponding case in the - * external system. - * - * Generated from protobuf field string external_uid = 3; - * @return string - */ - public function getExternalUid() - { - return $this->external_uid; - } - - /** - * The identifier that's used to track the finding's corresponding case in the - * external system. - * - * Generated from protobuf field string external_uid = 3; - * @param string $var - * @return $this - */ - public function setExternalUid($var) - { - GPBUtil::checkString($var, True); - $this->external_uid = $var; - - return $this; - } - - /** - * The most recent status of the finding's corresponding case, as reported by - * the external system. - * - * Generated from protobuf field string status = 4; - * @return string - */ - public function getStatus() - { - return $this->status; - } - - /** - * The most recent status of the finding's corresponding case, as reported by - * the external system. - * - * Generated from protobuf field string status = 4; - * @param string $var - * @return $this - */ - public function setStatus($var) - { - GPBUtil::checkString($var, True); - $this->status = $var; - - return $this; - } - - /** - * The time when the case was last updated, as reported by the external - * system. - * - * Generated from protobuf field .google.protobuf.Timestamp external_system_update_time = 5; - * @return \Google\Protobuf\Timestamp|null - */ - public function getExternalSystemUpdateTime() - { - return $this->external_system_update_time; - } - - public function hasExternalSystemUpdateTime() - { - return isset($this->external_system_update_time); - } - - public function clearExternalSystemUpdateTime() - { - unset($this->external_system_update_time); - } - - /** - * The time when the case was last updated, as reported by the external - * system. - * - * Generated from protobuf field .google.protobuf.Timestamp external_system_update_time = 5; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setExternalSystemUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->external_system_update_time = $var; - - return $this; - } - - /** - * The link to the finding's corresponding case in the external system. - * - * Generated from protobuf field string case_uri = 6; - * @return string - */ - public function getCaseUri() - { - return $this->case_uri; - } - - /** - * The link to the finding's corresponding case in the external system. - * - * Generated from protobuf field string case_uri = 6; - * @param string $var - * @return $this - */ - public function setCaseUri($var) - { - GPBUtil::checkString($var, True); - $this->case_uri = $var; - - return $this; - } - - /** - * The priority of the finding's corresponding case in the external system. - * - * Generated from protobuf field string case_priority = 7; - * @return string - */ - public function getCasePriority() - { - return $this->case_priority; - } - - /** - * The priority of the finding's corresponding case in the external system. - * - * Generated from protobuf field string case_priority = 7; - * @param string $var - * @return $this - */ - public function setCasePriority($var) - { - GPBUtil::checkString($var, True); - $this->case_priority = $var; - - return $this; - } - - /** - * The SLA of the finding's corresponding case in the external system. - * - * Generated from protobuf field .google.protobuf.Timestamp case_sla = 9; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCaseSla() - { - return $this->case_sla; - } - - public function hasCaseSla() - { - return isset($this->case_sla); - } - - public function clearCaseSla() - { - unset($this->case_sla); - } - - /** - * The SLA of the finding's corresponding case in the external system. - * - * Generated from protobuf field .google.protobuf.Timestamp case_sla = 9; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCaseSla($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->case_sla = $var; - - return $this; - } - - /** - * The time when the case was created, as reported by the external system. - * - * Generated from protobuf field .google.protobuf.Timestamp case_create_time = 10; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCaseCreateTime() - { - return $this->case_create_time; - } - - public function hasCaseCreateTime() - { - return isset($this->case_create_time); - } - - public function clearCaseCreateTime() - { - unset($this->case_create_time); - } - - /** - * The time when the case was created, as reported by the external system. - * - * Generated from protobuf field .google.protobuf.Timestamp case_create_time = 10; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCaseCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->case_create_time = $var; - - return $this; - } - - /** - * The time when the case was closed, as reported by the external system. - * - * Generated from protobuf field .google.protobuf.Timestamp case_close_time = 11; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCaseCloseTime() - { - return $this->case_close_time; - } - - public function hasCaseCloseTime() - { - return isset($this->case_close_time); - } - - public function clearCaseCloseTime() - { - unset($this->case_close_time); - } - - /** - * The time when the case was closed, as reported by the external system. - * - * Generated from protobuf field .google.protobuf.Timestamp case_close_time = 11; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCaseCloseTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->case_close_time = $var; - - return $this; - } - - /** - * Information about the ticket, if any, that is being used to track the - * resolution of the issue that is identified by this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.ExternalSystem.TicketInfo ticket_info = 8; - * @return \Google\Cloud\SecurityCenter\V1\ExternalSystem\TicketInfo|null - */ - public function getTicketInfo() - { - return $this->ticket_info; - } - - public function hasTicketInfo() - { - return isset($this->ticket_info); - } - - public function clearTicketInfo() - { - unset($this->ticket_info); - } - - /** - * Information about the ticket, if any, that is being used to track the - * resolution of the issue that is identified by this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.ExternalSystem.TicketInfo ticket_info = 8; - * @param \Google\Cloud\SecurityCenter\V1\ExternalSystem\TicketInfo $var - * @return $this - */ - public function setTicketInfo($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\ExternalSystem\TicketInfo::class); - $this->ticket_info = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExternalSystem/TicketInfo.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExternalSystem/TicketInfo.php deleted file mode 100644 index 5f07523664f1..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ExternalSystem/TicketInfo.php +++ /dev/null @@ -1,255 +0,0 @@ -google.cloud.securitycenter.v1.ExternalSystem.TicketInfo - */ -class TicketInfo extends \Google\Protobuf\Internal\Message -{ - /** - * The identifier of the ticket in the ticket system. - * - * Generated from protobuf field string id = 1; - */ - protected $id = ''; - /** - * The assignee of the ticket in the ticket system. - * - * Generated from protobuf field string assignee = 2; - */ - protected $assignee = ''; - /** - * The description of the ticket in the ticket system. - * - * Generated from protobuf field string description = 3; - */ - protected $description = ''; - /** - * The link to the ticket in the ticket system. - * - * Generated from protobuf field string uri = 4; - */ - protected $uri = ''; - /** - * The latest status of the ticket, as reported by the ticket system. - * - * Generated from protobuf field string status = 5; - */ - protected $status = ''; - /** - * The time when the ticket was last updated, as reported by the ticket - * system. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6; - */ - protected $update_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $id - * The identifier of the ticket in the ticket system. - * @type string $assignee - * The assignee of the ticket in the ticket system. - * @type string $description - * The description of the ticket in the ticket system. - * @type string $uri - * The link to the ticket in the ticket system. - * @type string $status - * The latest status of the ticket, as reported by the ticket system. - * @type \Google\Protobuf\Timestamp $update_time - * The time when the ticket was last updated, as reported by the ticket - * system. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\ExternalSystem::initOnce(); - parent::__construct($data); - } - - /** - * The identifier of the ticket in the ticket system. - * - * Generated from protobuf field string id = 1; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * The identifier of the ticket in the ticket system. - * - * Generated from protobuf field string id = 1; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - - /** - * The assignee of the ticket in the ticket system. - * - * Generated from protobuf field string assignee = 2; - * @return string - */ - public function getAssignee() - { - return $this->assignee; - } - - /** - * The assignee of the ticket in the ticket system. - * - * Generated from protobuf field string assignee = 2; - * @param string $var - * @return $this - */ - public function setAssignee($var) - { - GPBUtil::checkString($var, True); - $this->assignee = $var; - - return $this; - } - - /** - * The description of the ticket in the ticket system. - * - * Generated from protobuf field string description = 3; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * The description of the ticket in the ticket system. - * - * Generated from protobuf field string description = 3; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * The link to the ticket in the ticket system. - * - * Generated from protobuf field string uri = 4; - * @return string - */ - public function getUri() - { - return $this->uri; - } - - /** - * The link to the ticket in the ticket system. - * - * Generated from protobuf field string uri = 4; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->uri = $var; - - return $this; - } - - /** - * The latest status of the ticket, as reported by the ticket system. - * - * Generated from protobuf field string status = 5; - * @return string - */ - public function getStatus() - { - return $this->status; - } - - /** - * The latest status of the ticket, as reported by the ticket system. - * - * Generated from protobuf field string status = 5; - * @param string $var - * @return $this - */ - public function setStatus($var) - { - GPBUtil::checkString($var, True); - $this->status = $var; - - return $this; - } - - /** - * The time when the ticket was last updated, as reported by the ticket - * system. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * The time when the ticket was last updated, as reported by the ticket - * system. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(TicketInfo::class, \Google\Cloud\SecurityCenter\V1\ExternalSystem_TicketInfo::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/File.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/File.php deleted file mode 100644 index 060cfc9caf73..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/File.php +++ /dev/null @@ -1,298 +0,0 @@ -google.cloud.securitycenter.v1.File - */ -class File extends \Google\Protobuf\Internal\Message -{ - /** - * Absolute path of the file as a JSON encoded string. - * - * Generated from protobuf field string path = 1; - */ - protected $path = ''; - /** - * Size of the file in bytes. - * - * Generated from protobuf field int64 size = 2; - */ - protected $size = 0; - /** - * SHA256 hash of the first hashed_size bytes of the file encoded as a - * hex string. If hashed_size == size, sha256 represents the SHA256 hash - * of the entire file. - * - * Generated from protobuf field string sha256 = 3; - */ - protected $sha256 = ''; - /** - * The length in bytes of the file prefix that was hashed. If - * hashed_size == size, any hashes reported represent the entire - * file. - * - * Generated from protobuf field int64 hashed_size = 4; - */ - protected $hashed_size = 0; - /** - * True when the hash covers only a prefix of the file. - * - * Generated from protobuf field bool partially_hashed = 5; - */ - protected $partially_hashed = false; - /** - * Prefix of the file contents as a JSON-encoded string. - * - * Generated from protobuf field string contents = 6; - */ - protected $contents = ''; - /** - * Path of the file in terms of underlying disk/partition identifiers. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.File.DiskPath disk_path = 7; - */ - protected $disk_path = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $path - * Absolute path of the file as a JSON encoded string. - * @type int|string $size - * Size of the file in bytes. - * @type string $sha256 - * SHA256 hash of the first hashed_size bytes of the file encoded as a - * hex string. If hashed_size == size, sha256 represents the SHA256 hash - * of the entire file. - * @type int|string $hashed_size - * The length in bytes of the file prefix that was hashed. If - * hashed_size == size, any hashes reported represent the entire - * file. - * @type bool $partially_hashed - * True when the hash covers only a prefix of the file. - * @type string $contents - * Prefix of the file contents as a JSON-encoded string. - * @type \Google\Cloud\SecurityCenter\V1\File\DiskPath $disk_path - * Path of the file in terms of underlying disk/partition identifiers. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\File::initOnce(); - parent::__construct($data); - } - - /** - * Absolute path of the file as a JSON encoded string. - * - * Generated from protobuf field string path = 1; - * @return string - */ - public function getPath() - { - return $this->path; - } - - /** - * Absolute path of the file as a JSON encoded string. - * - * Generated from protobuf field string path = 1; - * @param string $var - * @return $this - */ - public function setPath($var) - { - GPBUtil::checkString($var, True); - $this->path = $var; - - return $this; - } - - /** - * Size of the file in bytes. - * - * Generated from protobuf field int64 size = 2; - * @return int|string - */ - public function getSize() - { - return $this->size; - } - - /** - * Size of the file in bytes. - * - * Generated from protobuf field int64 size = 2; - * @param int|string $var - * @return $this - */ - public function setSize($var) - { - GPBUtil::checkInt64($var); - $this->size = $var; - - return $this; - } - - /** - * SHA256 hash of the first hashed_size bytes of the file encoded as a - * hex string. If hashed_size == size, sha256 represents the SHA256 hash - * of the entire file. - * - * Generated from protobuf field string sha256 = 3; - * @return string - */ - public function getSha256() - { - return $this->sha256; - } - - /** - * SHA256 hash of the first hashed_size bytes of the file encoded as a - * hex string. If hashed_size == size, sha256 represents the SHA256 hash - * of the entire file. - * - * Generated from protobuf field string sha256 = 3; - * @param string $var - * @return $this - */ - public function setSha256($var) - { - GPBUtil::checkString($var, True); - $this->sha256 = $var; - - return $this; - } - - /** - * The length in bytes of the file prefix that was hashed. If - * hashed_size == size, any hashes reported represent the entire - * file. - * - * Generated from protobuf field int64 hashed_size = 4; - * @return int|string - */ - public function getHashedSize() - { - return $this->hashed_size; - } - - /** - * The length in bytes of the file prefix that was hashed. If - * hashed_size == size, any hashes reported represent the entire - * file. - * - * Generated from protobuf field int64 hashed_size = 4; - * @param int|string $var - * @return $this - */ - public function setHashedSize($var) - { - GPBUtil::checkInt64($var); - $this->hashed_size = $var; - - return $this; - } - - /** - * True when the hash covers only a prefix of the file. - * - * Generated from protobuf field bool partially_hashed = 5; - * @return bool - */ - public function getPartiallyHashed() - { - return $this->partially_hashed; - } - - /** - * True when the hash covers only a prefix of the file. - * - * Generated from protobuf field bool partially_hashed = 5; - * @param bool $var - * @return $this - */ - public function setPartiallyHashed($var) - { - GPBUtil::checkBool($var); - $this->partially_hashed = $var; - - return $this; - } - - /** - * Prefix of the file contents as a JSON-encoded string. - * - * Generated from protobuf field string contents = 6; - * @return string - */ - public function getContents() - { - return $this->contents; - } - - /** - * Prefix of the file contents as a JSON-encoded string. - * - * Generated from protobuf field string contents = 6; - * @param string $var - * @return $this - */ - public function setContents($var) - { - GPBUtil::checkString($var, True); - $this->contents = $var; - - return $this; - } - - /** - * Path of the file in terms of underlying disk/partition identifiers. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.File.DiskPath disk_path = 7; - * @return \Google\Cloud\SecurityCenter\V1\File\DiskPath|null - */ - public function getDiskPath() - { - return $this->disk_path; - } - - public function hasDiskPath() - { - return isset($this->disk_path); - } - - public function clearDiskPath() - { - unset($this->disk_path); - } - - /** - * Path of the file in terms of underlying disk/partition identifiers. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.File.DiskPath disk_path = 7; - * @param \Google\Cloud\SecurityCenter\V1\File\DiskPath $var - * @return $this - */ - public function setDiskPath($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\File\DiskPath::class); - $this->disk_path = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/File/DiskPath.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/File/DiskPath.php deleted file mode 100644 index ff77dd9eb7bf..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/File/DiskPath.php +++ /dev/null @@ -1,112 +0,0 @@ -google.cloud.securitycenter.v1.File.DiskPath - */ -class DiskPath extends \Google\Protobuf\Internal\Message -{ - /** - * UUID of the partition (format - * https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid) - * - * Generated from protobuf field string partition_uuid = 1; - */ - protected $partition_uuid = ''; - /** - * Relative path of the file in the partition as a JSON encoded string. - * Example: /home/user1/executable_file.sh - * - * Generated from protobuf field string relative_path = 2; - */ - protected $relative_path = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $partition_uuid - * UUID of the partition (format - * https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid) - * @type string $relative_path - * Relative path of the file in the partition as a JSON encoded string. - * Example: /home/user1/executable_file.sh - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\File::initOnce(); - parent::__construct($data); - } - - /** - * UUID of the partition (format - * https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid) - * - * Generated from protobuf field string partition_uuid = 1; - * @return string - */ - public function getPartitionUuid() - { - return $this->partition_uuid; - } - - /** - * UUID of the partition (format - * https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid) - * - * Generated from protobuf field string partition_uuid = 1; - * @param string $var - * @return $this - */ - public function setPartitionUuid($var) - { - GPBUtil::checkString($var, True); - $this->partition_uuid = $var; - - return $this; - } - - /** - * Relative path of the file in the partition as a JSON encoded string. - * Example: /home/user1/executable_file.sh - * - * Generated from protobuf field string relative_path = 2; - * @return string - */ - public function getRelativePath() - { - return $this->relative_path; - } - - /** - * Relative path of the file in the partition as a JSON encoded string. - * Example: /home/user1/executable_file.sh - * - * Generated from protobuf field string relative_path = 2; - * @param string $var - * @return $this - */ - public function setRelativePath($var) - { - GPBUtil::checkString($var, True); - $this->relative_path = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(DiskPath::class, \Google\Cloud\SecurityCenter\V1\File_DiskPath::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding.php deleted file mode 100644 index aaab60855177..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding.php +++ /dev/null @@ -1,2170 +0,0 @@ -google.cloud.securitycenter.v1.Finding - */ -class Finding extends \Google\Protobuf\Internal\Message -{ - /** - * The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", - * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The relative resource name of the source the finding belongs to. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * This field is immutable after creation time. - * For example: - * "organizations/{organization_id}/sources/{source_id}" - * - * Generated from protobuf field string parent = 2; - */ - protected $parent = ''; - /** - * For findings on Google Cloud resources, the full resource - * name of the Google Cloud resource this finding is for. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * When the finding is for a non-Google Cloud resource, the resourceName can - * be a customer or partner defined string. This field is immutable after - * creation time. - * - * Generated from protobuf field string resource_name = 3; - */ - protected $resource_name = ''; - /** - * The state of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.State state = 4; - */ - protected $state = 0; - /** - * The additional taxonomy group within findings from a given source. - * This field is immutable after creation time. - * Example: "XSS_FLASH_INJECTION" - * - * Generated from protobuf field string category = 5; - */ - protected $category = ''; - /** - * The URI that, if available, points to a web page outside of Security - * Command Center where additional information about the finding can be found. - * This field is guaranteed to be either empty or a well formed URL. - * - * Generated from protobuf field string external_uri = 6; - */ - protected $external_uri = ''; - /** - * Source specific properties. These properties are managed by the source - * that writes the finding. The key names in the source_properties map must be - * between 1 and 255 characters, and must start with a letter and contain - * alphanumeric characters or underscores only. - * - * Generated from protobuf field map source_properties = 7; - */ - private $source_properties; - /** - * Output only. User specified security marks. These marks are entirely - * managed by the user and come from the SecurityMarks resource that belongs - * to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityMarks security_marks = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $security_marks = null; - /** - * The time the finding was first detected. If an existing finding is updated, - * then this is the time the update occurred. - * For example, if the finding represents an open firewall, this property - * captures the time the detector believes the firewall became open. The - * accuracy is determined by the detector. If the finding is later resolved, - * then this time reflects when the finding was resolved. This must not - * be set to a value greater than the current timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp event_time = 9; - */ - protected $event_time = null; - /** - * The time at which the finding was created in Security Command Center. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 10; - */ - protected $create_time = null; - /** - * The severity of the finding. This field is managed by the source that - * writes the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.Severity severity = 12; - */ - protected $severity = 0; - /** - * The canonical name of the finding. It's either - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}" or - * "projects/{project_number}/sources/{source_id}/findings/{finding_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * - * Generated from protobuf field string canonical_name = 14; - */ - protected $canonical_name = ''; - /** - * Indicates the mute state of a finding (either muted, unmuted - * or undefined). Unlike other attributes of a finding, a finding provider - * shouldn't set the value of mute. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.Mute mute = 15; - */ - protected $mute = 0; - /** - * The class of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.FindingClass finding_class = 17; - */ - protected $finding_class = 0; - /** - * Represents what's commonly known as an *indicator of compromise* (IoC) in - * computer forensics. This is an artifact observed on a network or in an - * operating system that, with high confidence, indicates a computer - * intrusion. For more information, see [Indicator of - * compromise](https://en.wikipedia.org/wiki/Indicator_of_compromise). - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator indicator = 18; - */ - protected $indicator = null; - /** - * Represents vulnerability-specific fields like CVE and CVSS scores. - * CVE stands for Common Vulnerabilities and Exposures - * (https://cve.mitre.org/about/) - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Vulnerability vulnerability = 20; - */ - protected $vulnerability = null; - /** - * Output only. The most recent time this finding was muted or unmuted. - * - * Generated from protobuf field .google.protobuf.Timestamp mute_update_time = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $mute_update_time = null; - /** - * Output only. Third party SIEM/SOAR fields within SCC, contains external - * system information and external system finding fields. - * - * Generated from protobuf field map external_systems = 22 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $external_systems; - /** - * MITRE ATT&CK tactics and techniques related to this finding. - * See: https://attack.mitre.org - * - * Generated from protobuf field .google.cloud.securitycenter.v1.MitreAttack mitre_attack = 25; - */ - protected $mitre_attack = null; - /** - * Access details associated with the finding, such as more information on the - * caller, which method was accessed, and from where. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Access access = 26; - */ - protected $access = null; - /** - * Contains information about the IP connection associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Connection connections = 31; - */ - private $connections; - /** - * Records additional information about the mute operation, for example, the - * [mute configuration](/security-command-center/docs/how-to-mute-findings) - * that muted the finding and the user who muted the finding. - * - * Generated from protobuf field string mute_initiator = 28; - */ - protected $mute_initiator = ''; - /** - * Represents operating system processes associated with the Finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Process processes = 30; - */ - private $processes; - /** - * Output only. Map containing the points of contact for the given finding. - * The key represents the type of contact, while the value contains a list of - * all the contacts that pertain. Please refer to: - * https://cloud.google.com/resource-manager/docs/managing-notification-contacts#notification-categories - * { - * "security": { - * "contacts": [ - * { - * "email": "person1@company.com" - * }, - * { - * "email": "person2@company.com" - * } - * ] - * } - * } - * - * Generated from protobuf field map contacts = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $contacts; - /** - * Contains compliance information for security standards associated to the - * finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Compliance compliances = 34; - */ - private $compliances; - /** - * Output only. The human readable display name of the finding source such as - * "Event Threat Detection" or "Security Health Analytics". - * - * Generated from protobuf field string parent_display_name = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $parent_display_name = ''; - /** - * Contains more details about the finding. - * - * Generated from protobuf field string description = 37; - */ - protected $description = ''; - /** - * Represents exfiltrations associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Exfiltration exfiltration = 38; - */ - protected $exfiltration = null; - /** - * Represents IAM bindings associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.IamBinding iam_bindings = 39; - */ - private $iam_bindings; - /** - * Steps to address the finding. - * - * Generated from protobuf field string next_steps = 40; - */ - protected $next_steps = ''; - /** - * Unique identifier of the module which generated the finding. - * Example: - * folders/598186756061/securityHealthAnalyticsSettings/customModules/56799441161885 - * - * Generated from protobuf field string module_name = 41; - */ - protected $module_name = ''; - /** - * Containers associated with the finding. This field provides information for - * both Kubernetes and non-Kubernetes containers. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Container containers = 42; - */ - private $containers; - /** - * Kubernetes resources associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes kubernetes = 43; - */ - protected $kubernetes = null; - /** - * Database associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Database database = 44; - */ - protected $database = null; - /** - * File associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.File files = 46; - */ - private $files; - /** - * Cloud Data Loss Prevention (Cloud DLP) inspection results that are - * associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CloudDlpInspection cloud_dlp_inspection = 48; - */ - protected $cloud_dlp_inspection = null; - /** - * Cloud DLP data profile that is associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CloudDlpDataProfile cloud_dlp_data_profile = 49; - */ - protected $cloud_dlp_data_profile = null; - /** - * Signature of the kernel rootkit. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.KernelRootkit kernel_rootkit = 50; - */ - protected $kernel_rootkit = null; - /** - * Contains information about the org policies associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.OrgPolicy org_policies = 51; - */ - private $org_policies; - /** - * Represents an application associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Application application = 53; - */ - protected $application = null; - /** - * Fields related to Backup and DR findings. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.BackupDisasterRecovery backup_disaster_recovery = 55; - */ - protected $backup_disaster_recovery = null; - /** - * The security posture associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityPosture security_posture = 56; - */ - protected $security_posture = null; - /** - * Log entries that are relevant to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.LogEntry log_entries = 57; - */ - private $log_entries; - /** - * The load balancers associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.LoadBalancer load_balancers = 58; - */ - private $load_balancers; - /** - * Fields related to Cloud Armor findings. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CloudArmor cloud_armor = 59; - */ - protected $cloud_armor = null; - /** - * Notebook associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Notebook notebook = 63; - */ - protected $notebook = null; - /** - * Contains details about a group of security issues that, when the issues - * occur together, represent a greater risk than when the issues occur - * independently. A group of such issues is referred to as a toxic - * combination. - * This field cannot be updated. Its value is ignored in all update requests. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.ToxicCombination toxic_combination = 64; - */ - protected $toxic_combination = null; - /** - * Contains details about groups of which this finding is a member. A group is - * a collection of findings that are related in some way. - * This field cannot be updated. Its value is ignored in all update requests. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.GroupMembership group_memberships = 65; - */ - private $group_memberships; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", - * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". - * @type string $parent - * The relative resource name of the source the finding belongs to. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * This field is immutable after creation time. - * For example: - * "organizations/{organization_id}/sources/{source_id}" - * @type string $resource_name - * For findings on Google Cloud resources, the full resource - * name of the Google Cloud resource this finding is for. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * When the finding is for a non-Google Cloud resource, the resourceName can - * be a customer or partner defined string. This field is immutable after - * creation time. - * @type int $state - * The state of the finding. - * @type string $category - * The additional taxonomy group within findings from a given source. - * This field is immutable after creation time. - * Example: "XSS_FLASH_INJECTION" - * @type string $external_uri - * The URI that, if available, points to a web page outside of Security - * Command Center where additional information about the finding can be found. - * This field is guaranteed to be either empty or a well formed URL. - * @type array|\Google\Protobuf\Internal\MapField $source_properties - * Source specific properties. These properties are managed by the source - * that writes the finding. The key names in the source_properties map must be - * between 1 and 255 characters, and must start with a letter and contain - * alphanumeric characters or underscores only. - * @type \Google\Cloud\SecurityCenter\V1\SecurityMarks $security_marks - * Output only. User specified security marks. These marks are entirely - * managed by the user and come from the SecurityMarks resource that belongs - * to the finding. - * @type \Google\Protobuf\Timestamp $event_time - * The time the finding was first detected. If an existing finding is updated, - * then this is the time the update occurred. - * For example, if the finding represents an open firewall, this property - * captures the time the detector believes the firewall became open. The - * accuracy is determined by the detector. If the finding is later resolved, - * then this time reflects when the finding was resolved. This must not - * be set to a value greater than the current timestamp. - * @type \Google\Protobuf\Timestamp $create_time - * The time at which the finding was created in Security Command Center. - * @type int $severity - * The severity of the finding. This field is managed by the source that - * writes the finding. - * @type string $canonical_name - * The canonical name of the finding. It's either - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}" or - * "projects/{project_number}/sources/{source_id}/findings/{finding_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * @type int $mute - * Indicates the mute state of a finding (either muted, unmuted - * or undefined). Unlike other attributes of a finding, a finding provider - * shouldn't set the value of mute. - * @type int $finding_class - * The class of the finding. - * @type \Google\Cloud\SecurityCenter\V1\Indicator $indicator - * Represents what's commonly known as an *indicator of compromise* (IoC) in - * computer forensics. This is an artifact observed on a network or in an - * operating system that, with high confidence, indicates a computer - * intrusion. For more information, see [Indicator of - * compromise](https://en.wikipedia.org/wiki/Indicator_of_compromise). - * @type \Google\Cloud\SecurityCenter\V1\Vulnerability $vulnerability - * Represents vulnerability-specific fields like CVE and CVSS scores. - * CVE stands for Common Vulnerabilities and Exposures - * (https://cve.mitre.org/about/) - * @type \Google\Protobuf\Timestamp $mute_update_time - * Output only. The most recent time this finding was muted or unmuted. - * @type array|\Google\Protobuf\Internal\MapField $external_systems - * Output only. Third party SIEM/SOAR fields within SCC, contains external - * system information and external system finding fields. - * @type \Google\Cloud\SecurityCenter\V1\MitreAttack $mitre_attack - * MITRE ATT&CK tactics and techniques related to this finding. - * See: https://attack.mitre.org - * @type \Google\Cloud\SecurityCenter\V1\Access $access - * Access details associated with the finding, such as more information on the - * caller, which method was accessed, and from where. - * @type array<\Google\Cloud\SecurityCenter\V1\Connection>|\Google\Protobuf\Internal\RepeatedField $connections - * Contains information about the IP connection associated with the finding. - * @type string $mute_initiator - * Records additional information about the mute operation, for example, the - * [mute configuration](/security-command-center/docs/how-to-mute-findings) - * that muted the finding and the user who muted the finding. - * @type array<\Google\Cloud\SecurityCenter\V1\Process>|\Google\Protobuf\Internal\RepeatedField $processes - * Represents operating system processes associated with the Finding. - * @type array|\Google\Protobuf\Internal\MapField $contacts - * Output only. Map containing the points of contact for the given finding. - * The key represents the type of contact, while the value contains a list of - * all the contacts that pertain. Please refer to: - * https://cloud.google.com/resource-manager/docs/managing-notification-contacts#notification-categories - * { - * "security": { - * "contacts": [ - * { - * "email": "person1@company.com" - * }, - * { - * "email": "person2@company.com" - * } - * ] - * } - * } - * @type array<\Google\Cloud\SecurityCenter\V1\Compliance>|\Google\Protobuf\Internal\RepeatedField $compliances - * Contains compliance information for security standards associated to the - * finding. - * @type string $parent_display_name - * Output only. The human readable display name of the finding source such as - * "Event Threat Detection" or "Security Health Analytics". - * @type string $description - * Contains more details about the finding. - * @type \Google\Cloud\SecurityCenter\V1\Exfiltration $exfiltration - * Represents exfiltrations associated with the finding. - * @type array<\Google\Cloud\SecurityCenter\V1\IamBinding>|\Google\Protobuf\Internal\RepeatedField $iam_bindings - * Represents IAM bindings associated with the finding. - * @type string $next_steps - * Steps to address the finding. - * @type string $module_name - * Unique identifier of the module which generated the finding. - * Example: - * folders/598186756061/securityHealthAnalyticsSettings/customModules/56799441161885 - * @type array<\Google\Cloud\SecurityCenter\V1\Container>|\Google\Protobuf\Internal\RepeatedField $containers - * Containers associated with the finding. This field provides information for - * both Kubernetes and non-Kubernetes containers. - * @type \Google\Cloud\SecurityCenter\V1\Kubernetes $kubernetes - * Kubernetes resources associated with the finding. - * @type \Google\Cloud\SecurityCenter\V1\Database $database - * Database associated with the finding. - * @type array<\Google\Cloud\SecurityCenter\V1\File>|\Google\Protobuf\Internal\RepeatedField $files - * File associated with the finding. - * @type \Google\Cloud\SecurityCenter\V1\CloudDlpInspection $cloud_dlp_inspection - * Cloud Data Loss Prevention (Cloud DLP) inspection results that are - * associated with the finding. - * @type \Google\Cloud\SecurityCenter\V1\CloudDlpDataProfile $cloud_dlp_data_profile - * Cloud DLP data profile that is associated with the finding. - * @type \Google\Cloud\SecurityCenter\V1\KernelRootkit $kernel_rootkit - * Signature of the kernel rootkit. - * @type array<\Google\Cloud\SecurityCenter\V1\OrgPolicy>|\Google\Protobuf\Internal\RepeatedField $org_policies - * Contains information about the org policies associated with the finding. - * @type \Google\Cloud\SecurityCenter\V1\Application $application - * Represents an application associated with the finding. - * @type \Google\Cloud\SecurityCenter\V1\BackupDisasterRecovery $backup_disaster_recovery - * Fields related to Backup and DR findings. - * @type \Google\Cloud\SecurityCenter\V1\SecurityPosture $security_posture - * The security posture associated with the finding. - * @type array<\Google\Cloud\SecurityCenter\V1\LogEntry>|\Google\Protobuf\Internal\RepeatedField $log_entries - * Log entries that are relevant to the finding. - * @type array<\Google\Cloud\SecurityCenter\V1\LoadBalancer>|\Google\Protobuf\Internal\RepeatedField $load_balancers - * The load balancers associated with the finding. - * @type \Google\Cloud\SecurityCenter\V1\CloudArmor $cloud_armor - * Fields related to Cloud Armor findings. - * @type \Google\Cloud\SecurityCenter\V1\Notebook $notebook - * Notebook associated with the finding. - * @type \Google\Cloud\SecurityCenter\V1\ToxicCombination $toxic_combination - * Contains details about a group of security issues that, when the issues - * occur together, represent a greater risk than when the issues occur - * independently. A group of such issues is referred to as a toxic - * combination. - * This field cannot be updated. Its value is ignored in all update requests. - * @type array<\Google\Cloud\SecurityCenter\V1\GroupMembership>|\Google\Protobuf\Internal\RepeatedField $group_memberships - * Contains details about groups of which this finding is a member. A group is - * a collection of findings that are related in some way. - * This field cannot be updated. Its value is ignored in all update requests. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Finding::initOnce(); - parent::__construct($data); - } - - /** - * The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", - * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", - * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The relative resource name of the source the finding belongs to. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * This field is immutable after creation time. - * For example: - * "organizations/{organization_id}/sources/{source_id}" - * - * Generated from protobuf field string parent = 2; - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * The relative resource name of the source the finding belongs to. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * This field is immutable after creation time. - * For example: - * "organizations/{organization_id}/sources/{source_id}" - * - * Generated from protobuf field string parent = 2; - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * For findings on Google Cloud resources, the full resource - * name of the Google Cloud resource this finding is for. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * When the finding is for a non-Google Cloud resource, the resourceName can - * be a customer or partner defined string. This field is immutable after - * creation time. - * - * Generated from protobuf field string resource_name = 3; - * @return string - */ - public function getResourceName() - { - return $this->resource_name; - } - - /** - * For findings on Google Cloud resources, the full resource - * name of the Google Cloud resource this finding is for. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * When the finding is for a non-Google Cloud resource, the resourceName can - * be a customer or partner defined string. This field is immutable after - * creation time. - * - * Generated from protobuf field string resource_name = 3; - * @param string $var - * @return $this - */ - public function setResourceName($var) - { - GPBUtil::checkString($var, True); - $this->resource_name = $var; - - return $this; - } - - /** - * The state of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.State state = 4; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * The state of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.State state = 4; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Finding\State::class); - $this->state = $var; - - return $this; - } - - /** - * The additional taxonomy group within findings from a given source. - * This field is immutable after creation time. - * Example: "XSS_FLASH_INJECTION" - * - * Generated from protobuf field string category = 5; - * @return string - */ - public function getCategory() - { - return $this->category; - } - - /** - * The additional taxonomy group within findings from a given source. - * This field is immutable after creation time. - * Example: "XSS_FLASH_INJECTION" - * - * Generated from protobuf field string category = 5; - * @param string $var - * @return $this - */ - public function setCategory($var) - { - GPBUtil::checkString($var, True); - $this->category = $var; - - return $this; - } - - /** - * The URI that, if available, points to a web page outside of Security - * Command Center where additional information about the finding can be found. - * This field is guaranteed to be either empty or a well formed URL. - * - * Generated from protobuf field string external_uri = 6; - * @return string - */ - public function getExternalUri() - { - return $this->external_uri; - } - - /** - * The URI that, if available, points to a web page outside of Security - * Command Center where additional information about the finding can be found. - * This field is guaranteed to be either empty or a well formed URL. - * - * Generated from protobuf field string external_uri = 6; - * @param string $var - * @return $this - */ - public function setExternalUri($var) - { - GPBUtil::checkString($var, True); - $this->external_uri = $var; - - return $this; - } - - /** - * Source specific properties. These properties are managed by the source - * that writes the finding. The key names in the source_properties map must be - * between 1 and 255 characters, and must start with a letter and contain - * alphanumeric characters or underscores only. - * - * Generated from protobuf field map source_properties = 7; - * @return \Google\Protobuf\Internal\MapField - */ - public function getSourceProperties() - { - return $this->source_properties; - } - - /** - * Source specific properties. These properties are managed by the source - * that writes the finding. The key names in the source_properties map must be - * between 1 and 255 characters, and must start with a letter and contain - * alphanumeric characters or underscores only. - * - * Generated from protobuf field map source_properties = 7; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setSourceProperties($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Value::class); - $this->source_properties = $arr; - - return $this; - } - - /** - * Output only. User specified security marks. These marks are entirely - * managed by the user and come from the SecurityMarks resource that belongs - * to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityMarks security_marks = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\SecurityCenter\V1\SecurityMarks|null - */ - public function getSecurityMarks() - { - return $this->security_marks; - } - - public function hasSecurityMarks() - { - return isset($this->security_marks); - } - - public function clearSecurityMarks() - { - unset($this->security_marks); - } - - /** - * Output only. User specified security marks. These marks are entirely - * managed by the user and come from the SecurityMarks resource that belongs - * to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityMarks security_marks = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\SecurityCenter\V1\SecurityMarks $var - * @return $this - */ - public function setSecurityMarks($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SecurityMarks::class); - $this->security_marks = $var; - - return $this; - } - - /** - * The time the finding was first detected. If an existing finding is updated, - * then this is the time the update occurred. - * For example, if the finding represents an open firewall, this property - * captures the time the detector believes the firewall became open. The - * accuracy is determined by the detector. If the finding is later resolved, - * then this time reflects when the finding was resolved. This must not - * be set to a value greater than the current timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp event_time = 9; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEventTime() - { - return $this->event_time; - } - - public function hasEventTime() - { - return isset($this->event_time); - } - - public function clearEventTime() - { - unset($this->event_time); - } - - /** - * The time the finding was first detected. If an existing finding is updated, - * then this is the time the update occurred. - * For example, if the finding represents an open firewall, this property - * captures the time the detector believes the firewall became open. The - * accuracy is determined by the detector. If the finding is later resolved, - * then this time reflects when the finding was resolved. This must not - * be set to a value greater than the current timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp event_time = 9; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEventTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->event_time = $var; - - return $this; - } - - /** - * The time at which the finding was created in Security Command Center. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 10; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * The time at which the finding was created in Security Command Center. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 10; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * The severity of the finding. This field is managed by the source that - * writes the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.Severity severity = 12; - * @return int - */ - public function getSeverity() - { - return $this->severity; - } - - /** - * The severity of the finding. This field is managed by the source that - * writes the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.Severity severity = 12; - * @param int $var - * @return $this - */ - public function setSeverity($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Finding\Severity::class); - $this->severity = $var; - - return $this; - } - - /** - * The canonical name of the finding. It's either - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}" or - * "projects/{project_number}/sources/{source_id}/findings/{finding_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * - * Generated from protobuf field string canonical_name = 14; - * @return string - */ - public function getCanonicalName() - { - return $this->canonical_name; - } - - /** - * The canonical name of the finding. It's either - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}" or - * "projects/{project_number}/sources/{source_id}/findings/{finding_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * - * Generated from protobuf field string canonical_name = 14; - * @param string $var - * @return $this - */ - public function setCanonicalName($var) - { - GPBUtil::checkString($var, True); - $this->canonical_name = $var; - - return $this; - } - - /** - * Indicates the mute state of a finding (either muted, unmuted - * or undefined). Unlike other attributes of a finding, a finding provider - * shouldn't set the value of mute. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.Mute mute = 15; - * @return int - */ - public function getMute() - { - return $this->mute; - } - - /** - * Indicates the mute state of a finding (either muted, unmuted - * or undefined). Unlike other attributes of a finding, a finding provider - * shouldn't set the value of mute. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.Mute mute = 15; - * @param int $var - * @return $this - */ - public function setMute($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Finding\Mute::class); - $this->mute = $var; - - return $this; - } - - /** - * The class of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.FindingClass finding_class = 17; - * @return int - */ - public function getFindingClass() - { - return $this->finding_class; - } - - /** - * The class of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.FindingClass finding_class = 17; - * @param int $var - * @return $this - */ - public function setFindingClass($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Finding\FindingClass::class); - $this->finding_class = $var; - - return $this; - } - - /** - * Represents what's commonly known as an *indicator of compromise* (IoC) in - * computer forensics. This is an artifact observed on a network or in an - * operating system that, with high confidence, indicates a computer - * intrusion. For more information, see [Indicator of - * compromise](https://en.wikipedia.org/wiki/Indicator_of_compromise). - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator indicator = 18; - * @return \Google\Cloud\SecurityCenter\V1\Indicator|null - */ - public function getIndicator() - { - return $this->indicator; - } - - public function hasIndicator() - { - return isset($this->indicator); - } - - public function clearIndicator() - { - unset($this->indicator); - } - - /** - * Represents what's commonly known as an *indicator of compromise* (IoC) in - * computer forensics. This is an artifact observed on a network or in an - * operating system that, with high confidence, indicates a computer - * intrusion. For more information, see [Indicator of - * compromise](https://en.wikipedia.org/wiki/Indicator_of_compromise). - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator indicator = 18; - * @param \Google\Cloud\SecurityCenter\V1\Indicator $var - * @return $this - */ - public function setIndicator($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Indicator::class); - $this->indicator = $var; - - return $this; - } - - /** - * Represents vulnerability-specific fields like CVE and CVSS scores. - * CVE stands for Common Vulnerabilities and Exposures - * (https://cve.mitre.org/about/) - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Vulnerability vulnerability = 20; - * @return \Google\Cloud\SecurityCenter\V1\Vulnerability|null - */ - public function getVulnerability() - { - return $this->vulnerability; - } - - public function hasVulnerability() - { - return isset($this->vulnerability); - } - - public function clearVulnerability() - { - unset($this->vulnerability); - } - - /** - * Represents vulnerability-specific fields like CVE and CVSS scores. - * CVE stands for Common Vulnerabilities and Exposures - * (https://cve.mitre.org/about/) - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Vulnerability vulnerability = 20; - * @param \Google\Cloud\SecurityCenter\V1\Vulnerability $var - * @return $this - */ - public function setVulnerability($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Vulnerability::class); - $this->vulnerability = $var; - - return $this; - } - - /** - * Output only. The most recent time this finding was muted or unmuted. - * - * Generated from protobuf field .google.protobuf.Timestamp mute_update_time = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getMuteUpdateTime() - { - return $this->mute_update_time; - } - - public function hasMuteUpdateTime() - { - return isset($this->mute_update_time); - } - - public function clearMuteUpdateTime() - { - unset($this->mute_update_time); - } - - /** - * Output only. The most recent time this finding was muted or unmuted. - * - * Generated from protobuf field .google.protobuf.Timestamp mute_update_time = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setMuteUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->mute_update_time = $var; - - return $this; - } - - /** - * Output only. Third party SIEM/SOAR fields within SCC, contains external - * system information and external system finding fields. - * - * Generated from protobuf field map external_systems = 22 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getExternalSystems() - { - return $this->external_systems; - } - - /** - * Output only. Third party SIEM/SOAR fields within SCC, contains external - * system information and external system finding fields. - * - * Generated from protobuf field map external_systems = 22 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setExternalSystems($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\ExternalSystem::class); - $this->external_systems = $arr; - - return $this; - } - - /** - * MITRE ATT&CK tactics and techniques related to this finding. - * See: https://attack.mitre.org - * - * Generated from protobuf field .google.cloud.securitycenter.v1.MitreAttack mitre_attack = 25; - * @return \Google\Cloud\SecurityCenter\V1\MitreAttack|null - */ - public function getMitreAttack() - { - return $this->mitre_attack; - } - - public function hasMitreAttack() - { - return isset($this->mitre_attack); - } - - public function clearMitreAttack() - { - unset($this->mitre_attack); - } - - /** - * MITRE ATT&CK tactics and techniques related to this finding. - * See: https://attack.mitre.org - * - * Generated from protobuf field .google.cloud.securitycenter.v1.MitreAttack mitre_attack = 25; - * @param \Google\Cloud\SecurityCenter\V1\MitreAttack $var - * @return $this - */ - public function setMitreAttack($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\MitreAttack::class); - $this->mitre_attack = $var; - - return $this; - } - - /** - * Access details associated with the finding, such as more information on the - * caller, which method was accessed, and from where. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Access access = 26; - * @return \Google\Cloud\SecurityCenter\V1\Access|null - */ - public function getAccess() - { - return $this->access; - } - - public function hasAccess() - { - return isset($this->access); - } - - public function clearAccess() - { - unset($this->access); - } - - /** - * Access details associated with the finding, such as more information on the - * caller, which method was accessed, and from where. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Access access = 26; - * @param \Google\Cloud\SecurityCenter\V1\Access $var - * @return $this - */ - public function setAccess($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Access::class); - $this->access = $var; - - return $this; - } - - /** - * Contains information about the IP connection associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Connection connections = 31; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getConnections() - { - return $this->connections; - } - - /** - * Contains information about the IP connection associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Connection connections = 31; - * @param array<\Google\Cloud\SecurityCenter\V1\Connection>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setConnections($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Connection::class); - $this->connections = $arr; - - return $this; - } - - /** - * Records additional information about the mute operation, for example, the - * [mute configuration](/security-command-center/docs/how-to-mute-findings) - * that muted the finding and the user who muted the finding. - * - * Generated from protobuf field string mute_initiator = 28; - * @return string - */ - public function getMuteInitiator() - { - return $this->mute_initiator; - } - - /** - * Records additional information about the mute operation, for example, the - * [mute configuration](/security-command-center/docs/how-to-mute-findings) - * that muted the finding and the user who muted the finding. - * - * Generated from protobuf field string mute_initiator = 28; - * @param string $var - * @return $this - */ - public function setMuteInitiator($var) - { - GPBUtil::checkString($var, True); - $this->mute_initiator = $var; - - return $this; - } - - /** - * Represents operating system processes associated with the Finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Process processes = 30; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getProcesses() - { - return $this->processes; - } - - /** - * Represents operating system processes associated with the Finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Process processes = 30; - * @param array<\Google\Cloud\SecurityCenter\V1\Process>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setProcesses($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Process::class); - $this->processes = $arr; - - return $this; - } - - /** - * Output only. Map containing the points of contact for the given finding. - * The key represents the type of contact, while the value contains a list of - * all the contacts that pertain. Please refer to: - * https://cloud.google.com/resource-manager/docs/managing-notification-contacts#notification-categories - * { - * "security": { - * "contacts": [ - * { - * "email": "person1@company.com" - * }, - * { - * "email": "person2@company.com" - * } - * ] - * } - * } - * - * Generated from protobuf field map contacts = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getContacts() - { - return $this->contacts; - } - - /** - * Output only. Map containing the points of contact for the given finding. - * The key represents the type of contact, while the value contains a list of - * all the contacts that pertain. Please refer to: - * https://cloud.google.com/resource-manager/docs/managing-notification-contacts#notification-categories - * { - * "security": { - * "contacts": [ - * { - * "email": "person1@company.com" - * }, - * { - * "email": "person2@company.com" - * } - * ] - * } - * } - * - * Generated from protobuf field map contacts = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setContacts($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\ContactDetails::class); - $this->contacts = $arr; - - return $this; - } - - /** - * Contains compliance information for security standards associated to the - * finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Compliance compliances = 34; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getCompliances() - { - return $this->compliances; - } - - /** - * Contains compliance information for security standards associated to the - * finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Compliance compliances = 34; - * @param array<\Google\Cloud\SecurityCenter\V1\Compliance>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setCompliances($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Compliance::class); - $this->compliances = $arr; - - return $this; - } - - /** - * Output only. The human readable display name of the finding source such as - * "Event Threat Detection" or "Security Health Analytics". - * - * Generated from protobuf field string parent_display_name = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getParentDisplayName() - { - return $this->parent_display_name; - } - - /** - * Output only. The human readable display name of the finding source such as - * "Event Threat Detection" or "Security Health Analytics". - * - * Generated from protobuf field string parent_display_name = 36 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setParentDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->parent_display_name = $var; - - return $this; - } - - /** - * Contains more details about the finding. - * - * Generated from protobuf field string description = 37; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Contains more details about the finding. - * - * Generated from protobuf field string description = 37; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Represents exfiltrations associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Exfiltration exfiltration = 38; - * @return \Google\Cloud\SecurityCenter\V1\Exfiltration|null - */ - public function getExfiltration() - { - return $this->exfiltration; - } - - public function hasExfiltration() - { - return isset($this->exfiltration); - } - - public function clearExfiltration() - { - unset($this->exfiltration); - } - - /** - * Represents exfiltrations associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Exfiltration exfiltration = 38; - * @param \Google\Cloud\SecurityCenter\V1\Exfiltration $var - * @return $this - */ - public function setExfiltration($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Exfiltration::class); - $this->exfiltration = $var; - - return $this; - } - - /** - * Represents IAM bindings associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.IamBinding iam_bindings = 39; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getIamBindings() - { - return $this->iam_bindings; - } - - /** - * Represents IAM bindings associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.IamBinding iam_bindings = 39; - * @param array<\Google\Cloud\SecurityCenter\V1\IamBinding>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setIamBindings($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\IamBinding::class); - $this->iam_bindings = $arr; - - return $this; - } - - /** - * Steps to address the finding. - * - * Generated from protobuf field string next_steps = 40; - * @return string - */ - public function getNextSteps() - { - return $this->next_steps; - } - - /** - * Steps to address the finding. - * - * Generated from protobuf field string next_steps = 40; - * @param string $var - * @return $this - */ - public function setNextSteps($var) - { - GPBUtil::checkString($var, True); - $this->next_steps = $var; - - return $this; - } - - /** - * Unique identifier of the module which generated the finding. - * Example: - * folders/598186756061/securityHealthAnalyticsSettings/customModules/56799441161885 - * - * Generated from protobuf field string module_name = 41; - * @return string - */ - public function getModuleName() - { - return $this->module_name; - } - - /** - * Unique identifier of the module which generated the finding. - * Example: - * folders/598186756061/securityHealthAnalyticsSettings/customModules/56799441161885 - * - * Generated from protobuf field string module_name = 41; - * @param string $var - * @return $this - */ - public function setModuleName($var) - { - GPBUtil::checkString($var, True); - $this->module_name = $var; - - return $this; - } - - /** - * Containers associated with the finding. This field provides information for - * both Kubernetes and non-Kubernetes containers. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Container containers = 42; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getContainers() - { - return $this->containers; - } - - /** - * Containers associated with the finding. This field provides information for - * both Kubernetes and non-Kubernetes containers. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Container containers = 42; - * @param array<\Google\Cloud\SecurityCenter\V1\Container>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setContainers($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Container::class); - $this->containers = $arr; - - return $this; - } - - /** - * Kubernetes resources associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes kubernetes = 43; - * @return \Google\Cloud\SecurityCenter\V1\Kubernetes|null - */ - public function getKubernetes() - { - return $this->kubernetes; - } - - public function hasKubernetes() - { - return isset($this->kubernetes); - } - - public function clearKubernetes() - { - unset($this->kubernetes); - } - - /** - * Kubernetes resources associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes kubernetes = 43; - * @param \Google\Cloud\SecurityCenter\V1\Kubernetes $var - * @return $this - */ - public function setKubernetes($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Kubernetes::class); - $this->kubernetes = $var; - - return $this; - } - - /** - * Database associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Database database = 44; - * @return \Google\Cloud\SecurityCenter\V1\Database|null - */ - public function getDatabase() - { - return $this->database; - } - - public function hasDatabase() - { - return isset($this->database); - } - - public function clearDatabase() - { - unset($this->database); - } - - /** - * Database associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Database database = 44; - * @param \Google\Cloud\SecurityCenter\V1\Database $var - * @return $this - */ - public function setDatabase($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Database::class); - $this->database = $var; - - return $this; - } - - /** - * File associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.File files = 46; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFiles() - { - return $this->files; - } - - /** - * File associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.File files = 46; - * @param array<\Google\Cloud\SecurityCenter\V1\File>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFiles($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\File::class); - $this->files = $arr; - - return $this; - } - - /** - * Cloud Data Loss Prevention (Cloud DLP) inspection results that are - * associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CloudDlpInspection cloud_dlp_inspection = 48; - * @return \Google\Cloud\SecurityCenter\V1\CloudDlpInspection|null - */ - public function getCloudDlpInspection() - { - return $this->cloud_dlp_inspection; - } - - public function hasCloudDlpInspection() - { - return isset($this->cloud_dlp_inspection); - } - - public function clearCloudDlpInspection() - { - unset($this->cloud_dlp_inspection); - } - - /** - * Cloud Data Loss Prevention (Cloud DLP) inspection results that are - * associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CloudDlpInspection cloud_dlp_inspection = 48; - * @param \Google\Cloud\SecurityCenter\V1\CloudDlpInspection $var - * @return $this - */ - public function setCloudDlpInspection($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\CloudDlpInspection::class); - $this->cloud_dlp_inspection = $var; - - return $this; - } - - /** - * Cloud DLP data profile that is associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CloudDlpDataProfile cloud_dlp_data_profile = 49; - * @return \Google\Cloud\SecurityCenter\V1\CloudDlpDataProfile|null - */ - public function getCloudDlpDataProfile() - { - return $this->cloud_dlp_data_profile; - } - - public function hasCloudDlpDataProfile() - { - return isset($this->cloud_dlp_data_profile); - } - - public function clearCloudDlpDataProfile() - { - unset($this->cloud_dlp_data_profile); - } - - /** - * Cloud DLP data profile that is associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CloudDlpDataProfile cloud_dlp_data_profile = 49; - * @param \Google\Cloud\SecurityCenter\V1\CloudDlpDataProfile $var - * @return $this - */ - public function setCloudDlpDataProfile($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\CloudDlpDataProfile::class); - $this->cloud_dlp_data_profile = $var; - - return $this; - } - - /** - * Signature of the kernel rootkit. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.KernelRootkit kernel_rootkit = 50; - * @return \Google\Cloud\SecurityCenter\V1\KernelRootkit|null - */ - public function getKernelRootkit() - { - return $this->kernel_rootkit; - } - - public function hasKernelRootkit() - { - return isset($this->kernel_rootkit); - } - - public function clearKernelRootkit() - { - unset($this->kernel_rootkit); - } - - /** - * Signature of the kernel rootkit. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.KernelRootkit kernel_rootkit = 50; - * @param \Google\Cloud\SecurityCenter\V1\KernelRootkit $var - * @return $this - */ - public function setKernelRootkit($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\KernelRootkit::class); - $this->kernel_rootkit = $var; - - return $this; - } - - /** - * Contains information about the org policies associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.OrgPolicy org_policies = 51; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getOrgPolicies() - { - return $this->org_policies; - } - - /** - * Contains information about the org policies associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.OrgPolicy org_policies = 51; - * @param array<\Google\Cloud\SecurityCenter\V1\OrgPolicy>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setOrgPolicies($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\OrgPolicy::class); - $this->org_policies = $arr; - - return $this; - } - - /** - * Represents an application associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Application application = 53; - * @return \Google\Cloud\SecurityCenter\V1\Application|null - */ - public function getApplication() - { - return $this->application; - } - - public function hasApplication() - { - return isset($this->application); - } - - public function clearApplication() - { - unset($this->application); - } - - /** - * Represents an application associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Application application = 53; - * @param \Google\Cloud\SecurityCenter\V1\Application $var - * @return $this - */ - public function setApplication($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Application::class); - $this->application = $var; - - return $this; - } - - /** - * Fields related to Backup and DR findings. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.BackupDisasterRecovery backup_disaster_recovery = 55; - * @return \Google\Cloud\SecurityCenter\V1\BackupDisasterRecovery|null - */ - public function getBackupDisasterRecovery() - { - return $this->backup_disaster_recovery; - } - - public function hasBackupDisasterRecovery() - { - return isset($this->backup_disaster_recovery); - } - - public function clearBackupDisasterRecovery() - { - unset($this->backup_disaster_recovery); - } - - /** - * Fields related to Backup and DR findings. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.BackupDisasterRecovery backup_disaster_recovery = 55; - * @param \Google\Cloud\SecurityCenter\V1\BackupDisasterRecovery $var - * @return $this - */ - public function setBackupDisasterRecovery($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\BackupDisasterRecovery::class); - $this->backup_disaster_recovery = $var; - - return $this; - } - - /** - * The security posture associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityPosture security_posture = 56; - * @return \Google\Cloud\SecurityCenter\V1\SecurityPosture|null - */ - public function getSecurityPosture() - { - return $this->security_posture; - } - - public function hasSecurityPosture() - { - return isset($this->security_posture); - } - - public function clearSecurityPosture() - { - unset($this->security_posture); - } - - /** - * The security posture associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityPosture security_posture = 56; - * @param \Google\Cloud\SecurityCenter\V1\SecurityPosture $var - * @return $this - */ - public function setSecurityPosture($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SecurityPosture::class); - $this->security_posture = $var; - - return $this; - } - - /** - * Log entries that are relevant to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.LogEntry log_entries = 57; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLogEntries() - { - return $this->log_entries; - } - - /** - * Log entries that are relevant to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.LogEntry log_entries = 57; - * @param array<\Google\Cloud\SecurityCenter\V1\LogEntry>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLogEntries($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\LogEntry::class); - $this->log_entries = $arr; - - return $this; - } - - /** - * The load balancers associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.LoadBalancer load_balancers = 58; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLoadBalancers() - { - return $this->load_balancers; - } - - /** - * The load balancers associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.LoadBalancer load_balancers = 58; - * @param array<\Google\Cloud\SecurityCenter\V1\LoadBalancer>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLoadBalancers($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\LoadBalancer::class); - $this->load_balancers = $arr; - - return $this; - } - - /** - * Fields related to Cloud Armor findings. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CloudArmor cloud_armor = 59; - * @return \Google\Cloud\SecurityCenter\V1\CloudArmor|null - */ - public function getCloudArmor() - { - return $this->cloud_armor; - } - - public function hasCloudArmor() - { - return isset($this->cloud_armor); - } - - public function clearCloudArmor() - { - unset($this->cloud_armor); - } - - /** - * Fields related to Cloud Armor findings. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CloudArmor cloud_armor = 59; - * @param \Google\Cloud\SecurityCenter\V1\CloudArmor $var - * @return $this - */ - public function setCloudArmor($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\CloudArmor::class); - $this->cloud_armor = $var; - - return $this; - } - - /** - * Notebook associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Notebook notebook = 63; - * @return \Google\Cloud\SecurityCenter\V1\Notebook|null - */ - public function getNotebook() - { - return $this->notebook; - } - - public function hasNotebook() - { - return isset($this->notebook); - } - - public function clearNotebook() - { - unset($this->notebook); - } - - /** - * Notebook associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Notebook notebook = 63; - * @param \Google\Cloud\SecurityCenter\V1\Notebook $var - * @return $this - */ - public function setNotebook($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Notebook::class); - $this->notebook = $var; - - return $this; - } - - /** - * Contains details about a group of security issues that, when the issues - * occur together, represent a greater risk than when the issues occur - * independently. A group of such issues is referred to as a toxic - * combination. - * This field cannot be updated. Its value is ignored in all update requests. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.ToxicCombination toxic_combination = 64; - * @return \Google\Cloud\SecurityCenter\V1\ToxicCombination|null - */ - public function getToxicCombination() - { - return $this->toxic_combination; - } - - public function hasToxicCombination() - { - return isset($this->toxic_combination); - } - - public function clearToxicCombination() - { - unset($this->toxic_combination); - } - - /** - * Contains details about a group of security issues that, when the issues - * occur together, represent a greater risk than when the issues occur - * independently. A group of such issues is referred to as a toxic - * combination. - * This field cannot be updated. Its value is ignored in all update requests. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.ToxicCombination toxic_combination = 64; - * @param \Google\Cloud\SecurityCenter\V1\ToxicCombination $var - * @return $this - */ - public function setToxicCombination($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\ToxicCombination::class); - $this->toxic_combination = $var; - - return $this; - } - - /** - * Contains details about groups of which this finding is a member. A group is - * a collection of findings that are related in some way. - * This field cannot be updated. Its value is ignored in all update requests. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.GroupMembership group_memberships = 65; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getGroupMemberships() - { - return $this->group_memberships; - } - - /** - * Contains details about groups of which this finding is a member. A group is - * a collection of findings that are related in some way. - * This field cannot be updated. Its value is ignored in all update requests. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.GroupMembership group_memberships = 65; - * @param array<\Google\Cloud\SecurityCenter\V1\GroupMembership>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setGroupMemberships($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\GroupMembership::class); - $this->group_memberships = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/FindingClass.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/FindingClass.php deleted file mode 100644 index d26244482636..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/FindingClass.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.securitycenter.v1.Finding.FindingClass - */ -class FindingClass -{ - /** - * Unspecified finding class. - * - * Generated from protobuf enum FINDING_CLASS_UNSPECIFIED = 0; - */ - const FINDING_CLASS_UNSPECIFIED = 0; - /** - * Describes unwanted or malicious activity. - * - * Generated from protobuf enum THREAT = 1; - */ - const THREAT = 1; - /** - * Describes a potential weakness in software that increases risk to - * Confidentiality & Integrity & Availability. - * - * Generated from protobuf enum VULNERABILITY = 2; - */ - const VULNERABILITY = 2; - /** - * Describes a potential weakness in cloud resource/asset configuration that - * increases risk. - * - * Generated from protobuf enum MISCONFIGURATION = 3; - */ - const MISCONFIGURATION = 3; - /** - * Describes a security observation that is for informational purposes. - * - * Generated from protobuf enum OBSERVATION = 4; - */ - const OBSERVATION = 4; - /** - * Describes an error that prevents some SCC functionality. - * - * Generated from protobuf enum SCC_ERROR = 5; - */ - const SCC_ERROR = 5; - /** - * Describes a potential security risk due to a change in the security - * posture. - * - * Generated from protobuf enum POSTURE_VIOLATION = 6; - */ - const POSTURE_VIOLATION = 6; - /** - * Describes a group of security issues that, when the issues - * occur together, represent a greater risk than when the issues occur - * independently. A group of such issues is referred to as a toxic - * combination. - * - * Generated from protobuf enum TOXIC_COMBINATION = 7; - */ - const TOXIC_COMBINATION = 7; - - private static $valueToName = [ - self::FINDING_CLASS_UNSPECIFIED => 'FINDING_CLASS_UNSPECIFIED', - self::THREAT => 'THREAT', - self::VULNERABILITY => 'VULNERABILITY', - self::MISCONFIGURATION => 'MISCONFIGURATION', - self::OBSERVATION => 'OBSERVATION', - self::SCC_ERROR => 'SCC_ERROR', - self::POSTURE_VIOLATION => 'POSTURE_VIOLATION', - self::TOXIC_COMBINATION => 'TOXIC_COMBINATION', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(FindingClass::class, \Google\Cloud\SecurityCenter\V1\Finding_FindingClass::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/Mute.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/Mute.php deleted file mode 100644 index 8e7576dc4a0e..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/Mute.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.securitycenter.v1.Finding.Mute - */ -class Mute -{ - /** - * Unspecified. - * - * Generated from protobuf enum MUTE_UNSPECIFIED = 0; - */ - const MUTE_UNSPECIFIED = 0; - /** - * Finding has been muted. - * - * Generated from protobuf enum MUTED = 1; - */ - const MUTED = 1; - /** - * Finding has been unmuted. - * - * Generated from protobuf enum UNMUTED = 2; - */ - const UNMUTED = 2; - /** - * Finding has never been muted/unmuted. - * - * Generated from protobuf enum UNDEFINED = 4; - */ - const UNDEFINED = 4; - - private static $valueToName = [ - self::MUTE_UNSPECIFIED => 'MUTE_UNSPECIFIED', - self::MUTED => 'MUTED', - self::UNMUTED => 'UNMUTED', - self::UNDEFINED => 'UNDEFINED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Mute::class, \Google\Cloud\SecurityCenter\V1\Finding_Mute::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/Severity.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/Severity.php deleted file mode 100644 index e25546a23b7e..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/Severity.php +++ /dev/null @@ -1,116 +0,0 @@ -google.cloud.securitycenter.v1.Finding.Severity - */ -class Severity -{ - /** - * This value is used for findings when a source doesn't write a severity - * value. - * - * Generated from protobuf enum SEVERITY_UNSPECIFIED = 0; - */ - const SEVERITY_UNSPECIFIED = 0; - /** - * Vulnerability: - * A critical vulnerability is easily discoverable by an external actor, - * exploitable, and results in the direct ability to execute arbitrary code, - * exfiltrate data, and otherwise gain additional access and privileges to - * cloud resources and workloads. Examples include publicly accessible - * unprotected user data and public SSH access with weak or no - * passwords. - * Threat: - * Indicates a threat that is able to access, modify, or delete data or - * execute unauthorized code within existing resources. - * - * Generated from protobuf enum CRITICAL = 1; - */ - const CRITICAL = 1; - /** - * Vulnerability: - * A high risk vulnerability can be easily discovered and exploited in - * combination with other vulnerabilities in order to gain direct access and - * the ability to execute arbitrary code, exfiltrate data, and otherwise - * gain additional access and privileges to cloud resources and workloads. - * An example is a database with weak or no passwords that is only - * accessible internally. This database could easily be compromised by an - * actor that had access to the internal network. - * Threat: - * Indicates a threat that is able to create new computational resources in - * an environment but not able to access data or execute code in existing - * resources. - * - * Generated from protobuf enum HIGH = 2; - */ - const HIGH = 2; - /** - * Vulnerability: - * A medium risk vulnerability could be used by an actor to gain access to - * resources or privileges that enable them to eventually (through multiple - * steps or a complex exploit) gain access and the ability to execute - * arbitrary code or exfiltrate data. An example is a service account with - * access to more projects than it should have. If an actor gains access to - * the service account, they could potentially use that access to manipulate - * a project the service account was not intended to. - * Threat: - * Indicates a threat that is able to cause operational impact but may not - * access data or execute unauthorized code. - * - * Generated from protobuf enum MEDIUM = 3; - */ - const MEDIUM = 3; - /** - * Vulnerability: - * A low risk vulnerability hampers a security organization's ability to - * detect vulnerabilities or active threats in their deployment, or prevents - * the root cause investigation of security issues. An example is monitoring - * and logs being disabled for resource configurations and access. - * Threat: - * Indicates a threat that has obtained minimal access to an environment but - * is not able to access data, execute code, or create resources. - * - * Generated from protobuf enum LOW = 4; - */ - const LOW = 4; - - private static $valueToName = [ - self::SEVERITY_UNSPECIFIED => 'SEVERITY_UNSPECIFIED', - self::CRITICAL => 'CRITICAL', - self::HIGH => 'HIGH', - self::MEDIUM => 'MEDIUM', - self::LOW => 'LOW', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Severity::class, \Google\Cloud\SecurityCenter\V1\Finding_Severity::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/State.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/State.php deleted file mode 100644 index c1d5b5aa3bf5..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Finding/State.php +++ /dev/null @@ -1,65 +0,0 @@ -google.cloud.securitycenter.v1.Finding.State - */ -class State -{ - /** - * Unspecified state. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The finding requires attention and has not been addressed yet. - * - * Generated from protobuf enum ACTIVE = 1; - */ - const ACTIVE = 1; - /** - * The finding has been fixed, triaged as a non-issue or otherwise addressed - * and is no longer active. - * - * Generated from protobuf enum INACTIVE = 2; - */ - const INACTIVE = 2; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - self::INACTIVE => 'INACTIVE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\SecurityCenter\V1\Finding_State::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Folder.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Folder.php deleted file mode 100644 index ae3dee022d24..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Folder.php +++ /dev/null @@ -1,106 +0,0 @@ -google.cloud.securitycenter.v1.Folder - */ -class Folder extends \Google\Protobuf\Internal\Message -{ - /** - * Full resource name of this folder. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_folder = 1; - */ - protected $resource_folder = ''; - /** - * The user defined display name for this folder. - * - * Generated from protobuf field string resource_folder_display_name = 2; - */ - protected $resource_folder_display_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $resource_folder - * Full resource name of this folder. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * @type string $resource_folder_display_name - * The user defined display name for this folder. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Folder::initOnce(); - parent::__construct($data); - } - - /** - * Full resource name of this folder. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_folder = 1; - * @return string - */ - public function getResourceFolder() - { - return $this->resource_folder; - } - - /** - * Full resource name of this folder. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_folder = 1; - * @param string $var - * @return $this - */ - public function setResourceFolder($var) - { - GPBUtil::checkString($var, True); - $this->resource_folder = $var; - - return $this; - } - - /** - * The user defined display name for this folder. - * - * Generated from protobuf field string resource_folder_display_name = 2; - * @return string - */ - public function getResourceFolderDisplayName() - { - return $this->resource_folder_display_name; - } - - /** - * The user defined display name for this folder. - * - * Generated from protobuf field string resource_folder_display_name = 2; - * @param string $var - * @return $this - */ - public function setResourceFolderDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->resource_folder_display_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Geolocation.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Geolocation.php deleted file mode 100644 index 840ddadf3caf..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Geolocation.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.securitycenter.v1.Geolocation - */ -class Geolocation extends \Google\Protobuf\Internal\Message -{ - /** - * A CLDR. - * - * Generated from protobuf field string region_code = 1; - */ - protected $region_code = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $region_code - * A CLDR. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Access::initOnce(); - parent::__construct($data); - } - - /** - * A CLDR. - * - * Generated from protobuf field string region_code = 1; - * @return string - */ - public function getRegionCode() - { - return $this->region_code; - } - - /** - * A CLDR. - * - * Generated from protobuf field string region_code = 1; - * @param string $var - * @return $this - */ - public function setRegionCode($var) - { - GPBUtil::checkString($var, True); - $this->region_code = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetBigQueryExportRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetBigQueryExportRequest.php deleted file mode 100644 index 70e467e86dea..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetBigQueryExportRequest.php +++ /dev/null @@ -1,96 +0,0 @@ -google.cloud.securitycenter.v1.GetBigQueryExportRequest - */ -class GetBigQueryExportRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the BigQuery export to retrieve. Its format is - * organizations/{organization}/bigQueryExports/{export_id}, - * folders/{folder}/bigQueryExports/{export_id}, or - * projects/{project}/bigQueryExports/{export_id} - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the BigQuery export to retrieve. Its format is - * organizations/{organization}/bigQueryExports/{export_id}, - * folders/{folder}/bigQueryExports/{export_id}, or - * projects/{project}/bigQueryExports/{export_id} - * Please see {@see SecurityCenterClient::bigQueryExportName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V1\GetBigQueryExportRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the BigQuery export to retrieve. Its format is - * organizations/{organization}/bigQueryExports/{export_id}, - * folders/{folder}/bigQueryExports/{export_id}, or - * projects/{project}/bigQueryExports/{export_id} - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the BigQuery export to retrieve. Its format is - * organizations/{organization}/bigQueryExports/{export_id}, - * folders/{folder}/bigQueryExports/{export_id}, or - * projects/{project}/bigQueryExports/{export_id} - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the BigQuery export to retrieve. Its format is - * organizations/{organization}/bigQueryExports/{export_id}, - * folders/{folder}/bigQueryExports/{export_id}, or - * projects/{project}/bigQueryExports/{export_id} - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetEffectiveSecurityHealthAnalyticsCustomModuleRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetEffectiveSecurityHealthAnalyticsCustomModuleRequest.php deleted file mode 100644 index b2ca49a8c08d..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetEffectiveSecurityHealthAnalyticsCustomModuleRequest.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.securitycenter.v1.GetEffectiveSecurityHealthAnalyticsCustomModuleRequest - */ -class GetEffectiveSecurityHealthAnalyticsCustomModuleRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the effective custom module to get. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the effective custom module to get. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" - * Please see {@see SecurityCenterClient::effectiveSecurityHealthAnalyticsCustomModuleName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V1\GetEffectiveSecurityHealthAnalyticsCustomModuleRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the effective custom module to get. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the effective custom module to get. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the effective custom module to get. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetMuteConfigRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetMuteConfigRequest.php deleted file mode 100644 index 06f01976795e..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetMuteConfigRequest.php +++ /dev/null @@ -1,96 +0,0 @@ -google.cloud.securitycenter.v1.GetMuteConfigRequest - */ -class GetMuteConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the mute config to retrieve. Its format is - * organizations/{organization}/muteConfigs/{config_id}, - * folders/{folder}/muteConfigs/{config_id}, or - * projects/{project}/muteConfigs/{config_id} - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the mute config to retrieve. Its format is - * organizations/{organization}/muteConfigs/{config_id}, - * folders/{folder}/muteConfigs/{config_id}, or - * projects/{project}/muteConfigs/{config_id} - * Please see {@see SecurityCenterClient::muteConfigName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V1\GetMuteConfigRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the mute config to retrieve. Its format is - * organizations/{organization}/muteConfigs/{config_id}, - * folders/{folder}/muteConfigs/{config_id}, or - * projects/{project}/muteConfigs/{config_id} - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the mute config to retrieve. Its format is - * organizations/{organization}/muteConfigs/{config_id}, - * folders/{folder}/muteConfigs/{config_id}, or - * projects/{project}/muteConfigs/{config_id} - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the mute config to retrieve. Its format is - * organizations/{organization}/muteConfigs/{config_id}, - * folders/{folder}/muteConfigs/{config_id}, or - * projects/{project}/muteConfigs/{config_id} - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetNotificationConfigRequest.php deleted file mode 100644 index 5df4aa389dca..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetNotificationConfigRequest.php +++ /dev/null @@ -1,96 +0,0 @@ -google.cloud.securitycenter.v1.GetNotificationConfigRequest - */ -class GetNotificationConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the notification config to get. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]", - * "folders/[folder_id]/notificationConfigs/[config_id]", - * or "projects/[project_id]/notificationConfigs/[config_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the notification config to get. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]", - * "folders/[folder_id]/notificationConfigs/[config_id]", - * or "projects/[project_id]/notificationConfigs/[config_id]". Please see - * {@see SecurityCenterClient::notificationConfigName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V1\GetNotificationConfigRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the notification config to get. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]", - * "folders/[folder_id]/notificationConfigs/[config_id]", - * or "projects/[project_id]/notificationConfigs/[config_id]". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the notification config to get. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]", - * "folders/[folder_id]/notificationConfigs/[config_id]", - * or "projects/[project_id]/notificationConfigs/[config_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the notification config to get. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]", - * "folders/[folder_id]/notificationConfigs/[config_id]", - * or "projects/[project_id]/notificationConfigs/[config_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetOrganizationSettingsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetOrganizationSettingsRequest.php deleted file mode 100644 index d1e930b5e466..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetOrganizationSettingsRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.securitycenter.v1.GetOrganizationSettingsRequest - */ -class GetOrganizationSettingsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the organization to get organization settings for. Its - * format is "organizations/[organization_id]/organizationSettings". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the organization to get organization settings for. Its - * format is "organizations/[organization_id]/organizationSettings". Please see - * {@see SecurityCenterClient::organizationSettingsName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V1\GetOrganizationSettingsRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the organization to get organization settings for. Its - * format is "organizations/[organization_id]/organizationSettings". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the organization to get organization settings for. Its - * format is "organizations/[organization_id]/organizationSettings". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the organization to get organization settings for. Its - * format is "organizations/[organization_id]/organizationSettings". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetSecurityHealthAnalyticsCustomModuleRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetSecurityHealthAnalyticsCustomModuleRequest.php deleted file mode 100644 index a5f7fb16a6fd..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetSecurityHealthAnalyticsCustomModuleRequest.php +++ /dev/null @@ -1,101 +0,0 @@ -google.cloud.securitycenter.v1.GetSecurityHealthAnalyticsCustomModuleRequest - */ -class GetSecurityHealthAnalyticsCustomModuleRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the custom module to get. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", - * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the custom module to get. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", - * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" - * Please see {@see SecurityCenterClient::securityHealthAnalyticsCustomModuleName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V1\GetSecurityHealthAnalyticsCustomModuleRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the custom module to get. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", - * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the custom module to get. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", - * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the custom module to get. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", - * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetSourceRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetSourceRequest.php deleted file mode 100644 index 20815c4a1e55..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GetSourceRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.securitycenter.v1.GetSourceRequest - */ -class GetSourceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Relative resource name of the source. Its format is - * "organizations/[organization_id]/source/[source_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Relative resource name of the source. Its format is - * "organizations/[organization_id]/source/[source_id]". Please see - * {@see SecurityCenterClient::sourceName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V1\GetSourceRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Relative resource name of the source. Its format is - * "organizations/[organization_id]/source/[source_id]". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Relative resource name of the source. Its format is - * "organizations/[organization_id]/source/[source_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Relative resource name of the source. Its format is - * "organizations/[organization_id]/source/[source_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupAssetsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupAssetsRequest.php deleted file mode 100644 index 5414cdfb275b..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupAssetsRequest.php +++ /dev/null @@ -1,643 +0,0 @@ -google.cloud.securitycenter.v1.GroupAssetsRequest - */ -class GroupAssetsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the parent to group the assets by. Its format is - * "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * For example, `resource_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * - * Generated from protobuf field string filter = 2; - */ - protected $filter = ''; - /** - * Required. Expression that defines what assets fields to use for grouping. - * The string value should follow SQL syntax: comma separated list of fields. - * For example: - * "security_center_properties.resource_project,security_center_properties.project". - * The following fields are supported when compare_duration is not set: - * * security_center_properties.resource_project - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_type - * * security_center_properties.resource_parent - * * security_center_properties.resource_parent_display_name - * The following fields are supported when compare_duration is set: - * * security_center_properties.resource_type - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_parent_display_name - * - * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $group_by = ''; - /** - * When compare_duration is set, the GroupResult's "state_change" property is - * updated to indicate whether the asset was added, removed, or remained - * present during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * Possible "state_change" values when compare_duration is specified: - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at reference_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at reference_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and reference_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 4; - */ - protected $compare_duration = null; - /** - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 5; - */ - protected $read_time = null; - /** - * The value returned by the last `GroupAssetsResponse`; indicates - * that this is a continuation of a prior `GroupAssets` call, and that the - * system should return the next page of data. - * - * Generated from protobuf field string page_token = 7; - */ - protected $page_token = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 8; - */ - protected $page_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The name of the parent to group the assets by. Its format is - * "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * @type string $filter - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * For example, `resource_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * @type string $group_by - * Required. Expression that defines what assets fields to use for grouping. - * The string value should follow SQL syntax: comma separated list of fields. - * For example: - * "security_center_properties.resource_project,security_center_properties.project". - * The following fields are supported when compare_duration is not set: - * * security_center_properties.resource_project - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_type - * * security_center_properties.resource_parent - * * security_center_properties.resource_parent_display_name - * The following fields are supported when compare_duration is set: - * * security_center_properties.resource_type - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_parent_display_name - * @type \Google\Protobuf\Duration $compare_duration - * When compare_duration is set, the GroupResult's "state_change" property is - * updated to indicate whether the asset was added, removed, or remained - * present during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * Possible "state_change" values when compare_duration is specified: - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at reference_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at reference_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and reference_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * @type \Google\Protobuf\Timestamp $read_time - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * @type string $page_token - * The value returned by the last `GroupAssetsResponse`; indicates - * that this is a continuation of a prior `GroupAssets` call, and that the - * system should return the next page of data. - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the parent to group the assets by. Its format is - * "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The name of the parent to group the assets by. Its format is - * "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * For example, `resource_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * - * Generated from protobuf field string filter = 2; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * For example, `resource_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * - * Generated from protobuf field string filter = 2; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Required. Expression that defines what assets fields to use for grouping. - * The string value should follow SQL syntax: comma separated list of fields. - * For example: - * "security_center_properties.resource_project,security_center_properties.project". - * The following fields are supported when compare_duration is not set: - * * security_center_properties.resource_project - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_type - * * security_center_properties.resource_parent - * * security_center_properties.resource_parent_display_name - * The following fields are supported when compare_duration is set: - * * security_center_properties.resource_type - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_parent_display_name - * - * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getGroupBy() - { - return $this->group_by; - } - - /** - * Required. Expression that defines what assets fields to use for grouping. - * The string value should follow SQL syntax: comma separated list of fields. - * For example: - * "security_center_properties.resource_project,security_center_properties.project". - * The following fields are supported when compare_duration is not set: - * * security_center_properties.resource_project - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_type - * * security_center_properties.resource_parent - * * security_center_properties.resource_parent_display_name - * The following fields are supported when compare_duration is set: - * * security_center_properties.resource_type - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_parent_display_name - * - * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setGroupBy($var) - { - GPBUtil::checkString($var, True); - $this->group_by = $var; - - return $this; - } - - /** - * When compare_duration is set, the GroupResult's "state_change" property is - * updated to indicate whether the asset was added, removed, or remained - * present during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * Possible "state_change" values when compare_duration is specified: - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at reference_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at reference_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and reference_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 4; - * @return \Google\Protobuf\Duration|null - */ - public function getCompareDuration() - { - return $this->compare_duration; - } - - public function hasCompareDuration() - { - return isset($this->compare_duration); - } - - public function clearCompareDuration() - { - unset($this->compare_duration); - } - - /** - * When compare_duration is set, the GroupResult's "state_change" property is - * updated to indicate whether the asset was added, removed, or remained - * present during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * Possible "state_change" values when compare_duration is specified: - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at reference_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at reference_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and reference_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 4; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setCompareDuration($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->compare_duration = $var; - - return $this; - } - - /** - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 5; - * @return \Google\Protobuf\Timestamp|null - */ - public function getReadTime() - { - return $this->read_time; - } - - public function hasReadTime() - { - return isset($this->read_time); - } - - public function clearReadTime() - { - unset($this->read_time); - } - - /** - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 5; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setReadTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->read_time = $var; - - return $this; - } - - /** - * The value returned by the last `GroupAssetsResponse`; indicates - * that this is a continuation of a prior `GroupAssets` call, and that the - * system should return the next page of data. - * - * Generated from protobuf field string page_token = 7; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `GroupAssetsResponse`; indicates - * that this is a continuation of a prior `GroupAssets` call, and that the - * system should return the next page of data. - * - * Generated from protobuf field string page_token = 7; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 8; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 8; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupAssetsResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupAssetsResponse.php deleted file mode 100644 index 22c92dbe38ec..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupAssetsResponse.php +++ /dev/null @@ -1,191 +0,0 @@ -google.cloud.securitycenter.v1.GroupAssetsResponse - */ -class GroupAssetsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.GroupResult group_by_results = 1; - */ - private $group_by_results; - /** - * Time used for executing the groupBy request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - */ - protected $read_time = null; - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - */ - protected $next_page_token = ''; - /** - * The total number of results matching the query. - * - * Generated from protobuf field int32 total_size = 4; - */ - protected $total_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1\GroupResult>|\Google\Protobuf\Internal\RepeatedField $group_by_results - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * @type \Google\Protobuf\Timestamp $read_time - * Time used for executing the groupBy request. - * @type string $next_page_token - * Token to retrieve the next page of results, or empty if there are no more - * results. - * @type int $total_size - * The total number of results matching the query. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.GroupResult group_by_results = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getGroupByResults() - { - return $this->group_by_results; - } - - /** - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.GroupResult group_by_results = 1; - * @param array<\Google\Cloud\SecurityCenter\V1\GroupResult>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setGroupByResults($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\GroupResult::class); - $this->group_by_results = $arr; - - return $this; - } - - /** - * Time used for executing the groupBy request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getReadTime() - { - return $this->read_time; - } - - public function hasReadTime() - { - return isset($this->read_time); - } - - public function clearReadTime() - { - unset($this->read_time); - } - - /** - * Time used for executing the groupBy request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setReadTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->read_time = $var; - - return $this; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * The total number of results matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @return int - */ - public function getTotalSize() - { - return $this->total_size; - } - - /** - * The total number of results matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @param int $var - * @return $this - */ - public function setTotalSize($var) - { - GPBUtil::checkInt32($var); - $this->total_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupFindingsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupFindingsRequest.php deleted file mode 100644 index 65a1af3a2ad5..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupFindingsRequest.php +++ /dev/null @@ -1,695 +0,0 @@ -google.cloud.securitycenter.v1.GroupFindingsRequest - */ -class GroupFindingsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the source to groupBy. Its format is - * "organizations/[organization_id]/sources/[source_id]", - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]. To groupBy across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, - * or projects/{project_id}/sources/- - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * severity: `=`, `:` - * * workflow_state: `=`, `:` - * * security_marks.marks: `=`, `:` - * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * For example, `source_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * * resource: - * * resource.name: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.type: `=`, `:` - * - * Generated from protobuf field string filter = 2; - */ - protected $filter = ''; - /** - * Required. Expression that defines what assets fields to use for grouping - * (including `state_change`). The string value should follow SQL syntax: - * comma separated list of fields. For example: "parent,resource_name". - * The following fields are supported: - * * resource_name - * * category - * * state - * * parent - * * severity - * The following fields are supported when compare_duration is set: - * * state_change - * - * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $group_by = ''; - /** - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; - */ - protected $read_time = null; - /** - * When compare_duration is set, the GroupResult's "state_change" attribute is - * updated to indicate whether the finding had its state changed, the - * finding's state remained unchanged, or if the finding was added during the - * compare_duration period of time that precedes the read_time. This is the - * time between (read_time - compare_duration) and read_time. - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * Possible "state_change" values when compare_duration is specified: - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present - * at read_time. - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; - */ - protected $compare_duration = null; - /** - * The value returned by the last `GroupFindingsResponse`; indicates - * that this is a continuation of a prior `GroupFindings` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 7; - */ - protected $page_token = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 8; - */ - protected $page_size = 0; - - /** - * @param string $parent Required. Name of the source to groupBy. Its format is - * "organizations/[organization_id]/sources/[source_id]", - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]. To groupBy across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, - * or projects/{project_id}/sources/- - * Please see {@see SecurityCenterClient::sourceName()} for help formatting this field. - * @param string $groupBy Required. Expression that defines what assets fields to use for grouping - * (including `state_change`). The string value should follow SQL syntax: - * comma separated list of fields. For example: "parent,resource_name". - * - * The following fields are supported: - * - * * resource_name - * * category - * * state - * * parent - * * severity - * - * The following fields are supported when compare_duration is set: - * - * * state_change - * - * @return \Google\Cloud\SecurityCenter\V1\GroupFindingsRequest - * - * @experimental - */ - public static function build(string $parent, string $groupBy): self - { - return (new self()) - ->setParent($parent) - ->setGroupBy($groupBy); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Name of the source to groupBy. Its format is - * "organizations/[organization_id]/sources/[source_id]", - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]. To groupBy across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, - * or projects/{project_id}/sources/- - * @type string $filter - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * severity: `=`, `:` - * * workflow_state: `=`, `:` - * * security_marks.marks: `=`, `:` - * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * For example, `source_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * * resource: - * * resource.name: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.type: `=`, `:` - * @type string $group_by - * Required. Expression that defines what assets fields to use for grouping - * (including `state_change`). The string value should follow SQL syntax: - * comma separated list of fields. For example: "parent,resource_name". - * The following fields are supported: - * * resource_name - * * category - * * state - * * parent - * * severity - * The following fields are supported when compare_duration is set: - * * state_change - * @type \Google\Protobuf\Timestamp $read_time - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * @type \Google\Protobuf\Duration $compare_duration - * When compare_duration is set, the GroupResult's "state_change" attribute is - * updated to indicate whether the finding had its state changed, the - * finding's state remained unchanged, or if the finding was added during the - * compare_duration period of time that precedes the read_time. This is the - * time between (read_time - compare_duration) and read_time. - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * Possible "state_change" values when compare_duration is specified: - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present - * at read_time. - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * @type string $page_token - * The value returned by the last `GroupFindingsResponse`; indicates - * that this is a continuation of a prior `GroupFindings` call, and - * that the system should return the next page of data. - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the source to groupBy. Its format is - * "organizations/[organization_id]/sources/[source_id]", - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]. To groupBy across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, - * or projects/{project_id}/sources/- - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Name of the source to groupBy. Its format is - * "organizations/[organization_id]/sources/[source_id]", - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]. To groupBy across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, - * or projects/{project_id}/sources/- - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * severity: `=`, `:` - * * workflow_state: `=`, `:` - * * security_marks.marks: `=`, `:` - * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * For example, `source_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * * resource: - * * resource.name: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.type: `=`, `:` - * - * Generated from protobuf field string filter = 2; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * severity: `=`, `:` - * * workflow_state: `=`, `:` - * * security_marks.marks: `=`, `:` - * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * For example, `source_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * * resource: - * * resource.name: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.type: `=`, `:` - * - * Generated from protobuf field string filter = 2; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Required. Expression that defines what assets fields to use for grouping - * (including `state_change`). The string value should follow SQL syntax: - * comma separated list of fields. For example: "parent,resource_name". - * The following fields are supported: - * * resource_name - * * category - * * state - * * parent - * * severity - * The following fields are supported when compare_duration is set: - * * state_change - * - * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getGroupBy() - { - return $this->group_by; - } - - /** - * Required. Expression that defines what assets fields to use for grouping - * (including `state_change`). The string value should follow SQL syntax: - * comma separated list of fields. For example: "parent,resource_name". - * The following fields are supported: - * * resource_name - * * category - * * state - * * parent - * * severity - * The following fields are supported when compare_duration is set: - * * state_change - * - * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setGroupBy($var) - { - GPBUtil::checkString($var, True); - $this->group_by = $var; - - return $this; - } - - /** - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; - * @return \Google\Protobuf\Timestamp|null - */ - public function getReadTime() - { - return $this->read_time; - } - - public function hasReadTime() - { - return isset($this->read_time); - } - - public function clearReadTime() - { - unset($this->read_time); - } - - /** - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setReadTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->read_time = $var; - - return $this; - } - - /** - * When compare_duration is set, the GroupResult's "state_change" attribute is - * updated to indicate whether the finding had its state changed, the - * finding's state remained unchanged, or if the finding was added during the - * compare_duration period of time that precedes the read_time. This is the - * time between (read_time - compare_duration) and read_time. - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * Possible "state_change" values when compare_duration is specified: - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present - * at read_time. - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; - * @return \Google\Protobuf\Duration|null - */ - public function getCompareDuration() - { - return $this->compare_duration; - } - - public function hasCompareDuration() - { - return isset($this->compare_duration); - } - - public function clearCompareDuration() - { - unset($this->compare_duration); - } - - /** - * When compare_duration is set, the GroupResult's "state_change" attribute is - * updated to indicate whether the finding had its state changed, the - * finding's state remained unchanged, or if the finding was added during the - * compare_duration period of time that precedes the read_time. This is the - * time between (read_time - compare_duration) and read_time. - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * Possible "state_change" values when compare_duration is specified: - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present - * at read_time. - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setCompareDuration($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->compare_duration = $var; - - return $this; - } - - /** - * The value returned by the last `GroupFindingsResponse`; indicates - * that this is a continuation of a prior `GroupFindings` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 7; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `GroupFindingsResponse`; indicates - * that this is a continuation of a prior `GroupFindings` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 7; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 8; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 8; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupFindingsResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupFindingsResponse.php deleted file mode 100644 index fdda76699257..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupFindingsResponse.php +++ /dev/null @@ -1,191 +0,0 @@ -google.cloud.securitycenter.v1.GroupFindingsResponse - */ -class GroupFindingsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.GroupResult group_by_results = 1; - */ - private $group_by_results; - /** - * Time used for executing the groupBy request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - */ - protected $read_time = null; - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - */ - protected $next_page_token = ''; - /** - * The total number of results matching the query. - * - * Generated from protobuf field int32 total_size = 4; - */ - protected $total_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1\GroupResult>|\Google\Protobuf\Internal\RepeatedField $group_by_results - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * @type \Google\Protobuf\Timestamp $read_time - * Time used for executing the groupBy request. - * @type string $next_page_token - * Token to retrieve the next page of results, or empty if there are no more - * results. - * @type int $total_size - * The total number of results matching the query. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.GroupResult group_by_results = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getGroupByResults() - { - return $this->group_by_results; - } - - /** - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.GroupResult group_by_results = 1; - * @param array<\Google\Cloud\SecurityCenter\V1\GroupResult>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setGroupByResults($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\GroupResult::class); - $this->group_by_results = $arr; - - return $this; - } - - /** - * Time used for executing the groupBy request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getReadTime() - { - return $this->read_time; - } - - public function hasReadTime() - { - return isset($this->read_time); - } - - public function clearReadTime() - { - unset($this->read_time); - } - - /** - * Time used for executing the groupBy request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setReadTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->read_time = $var; - - return $this; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * The total number of results matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @return int - */ - public function getTotalSize() - { - return $this->total_size; - } - - /** - * The total number of results matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @param int $var - * @return $this - */ - public function setTotalSize($var) - { - GPBUtil::checkInt32($var); - $this->total_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupMembership.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupMembership.php deleted file mode 100644 index 144725fbd37f..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupMembership.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.securitycenter.v1.GroupMembership - */ -class GroupMembership extends \Google\Protobuf\Internal\Message -{ - /** - * Type of group. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.GroupMembership.GroupType group_type = 1; - */ - protected $group_type = 0; - /** - * ID of the group. - * - * Generated from protobuf field string group_id = 2; - */ - protected $group_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $group_type - * Type of group. - * @type string $group_id - * ID of the group. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\GroupMembership::initOnce(); - parent::__construct($data); - } - - /** - * Type of group. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.GroupMembership.GroupType group_type = 1; - * @return int - */ - public function getGroupType() - { - return $this->group_type; - } - - /** - * Type of group. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.GroupMembership.GroupType group_type = 1; - * @param int $var - * @return $this - */ - public function setGroupType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\GroupMembership\GroupType::class); - $this->group_type = $var; - - return $this; - } - - /** - * ID of the group. - * - * Generated from protobuf field string group_id = 2; - * @return string - */ - public function getGroupId() - { - return $this->group_id; - } - - /** - * ID of the group. - * - * Generated from protobuf field string group_id = 2; - * @param string $var - * @return $this - */ - public function setGroupId($var) - { - GPBUtil::checkString($var, True); - $this->group_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupMembership/GroupType.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupMembership/GroupType.php deleted file mode 100644 index 1aba0208c8ac..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupMembership/GroupType.php +++ /dev/null @@ -1,57 +0,0 @@ -google.cloud.securitycenter.v1.GroupMembership.GroupType - */ -class GroupType -{ - /** - * Default value. - * - * Generated from protobuf enum GROUP_TYPE_UNSPECIFIED = 0; - */ - const GROUP_TYPE_UNSPECIFIED = 0; - /** - * Group represents a toxic combination. - * - * Generated from protobuf enum GROUP_TYPE_TOXIC_COMBINATION = 1; - */ - const GROUP_TYPE_TOXIC_COMBINATION = 1; - - private static $valueToName = [ - self::GROUP_TYPE_UNSPECIFIED => 'GROUP_TYPE_UNSPECIFIED', - self::GROUP_TYPE_TOXIC_COMBINATION => 'GROUP_TYPE_TOXIC_COMBINATION', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(GroupType::class, \Google\Cloud\SecurityCenter\V1\GroupMembership_GroupType::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupResult.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupResult.php deleted file mode 100644 index a4e254e07323..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/GroupResult.php +++ /dev/null @@ -1,101 +0,0 @@ -google.cloud.securitycenter.v1.GroupResult - */ -class GroupResult extends \Google\Protobuf\Internal\Message -{ - /** - * Properties matching the groupBy fields in the request. - * - * Generated from protobuf field map properties = 1; - */ - private $properties; - /** - * Total count of resources for the given properties. - * - * Generated from protobuf field int64 count = 2; - */ - protected $count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\MapField $properties - * Properties matching the groupBy fields in the request. - * @type int|string $count - * Total count of resources for the given properties. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Properties matching the groupBy fields in the request. - * - * Generated from protobuf field map properties = 1; - * @return \Google\Protobuf\Internal\MapField - */ - public function getProperties() - { - return $this->properties; - } - - /** - * Properties matching the groupBy fields in the request. - * - * Generated from protobuf field map properties = 1; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setProperties($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Value::class); - $this->properties = $arr; - - return $this; - } - - /** - * Total count of resources for the given properties. - * - * Generated from protobuf field int64 count = 2; - * @return int|string - */ - public function getCount() - { - return $this->count; - } - - /** - * Total count of resources for the given properties. - * - * Generated from protobuf field int64 count = 2; - * @param int|string $var - * @return $this - */ - public function setCount($var) - { - GPBUtil::checkInt64($var); - $this->count = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/IamBinding.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/IamBinding.php deleted file mode 100644 index 38408c425841..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/IamBinding.php +++ /dev/null @@ -1,144 +0,0 @@ -google.cloud.securitycenter.v1.IamBinding - */ -class IamBinding extends \Google\Protobuf\Internal\Message -{ - /** - * The action that was performed on a Binding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.IamBinding.Action action = 1; - */ - protected $action = 0; - /** - * Role that is assigned to "members". - * For example, "roles/viewer", "roles/editor", or "roles/owner". - * - * Generated from protobuf field string role = 2; - */ - protected $role = ''; - /** - * A single identity requesting access for a Cloud Platform resource, for - * example, "foo@google.com". - * - * Generated from protobuf field string member = 3; - */ - protected $member = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $action - * The action that was performed on a Binding. - * @type string $role - * Role that is assigned to "members". - * For example, "roles/viewer", "roles/editor", or "roles/owner". - * @type string $member - * A single identity requesting access for a Cloud Platform resource, for - * example, "foo@google.com". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\IamBinding::initOnce(); - parent::__construct($data); - } - - /** - * The action that was performed on a Binding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.IamBinding.Action action = 1; - * @return int - */ - public function getAction() - { - return $this->action; - } - - /** - * The action that was performed on a Binding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.IamBinding.Action action = 1; - * @param int $var - * @return $this - */ - public function setAction($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\IamBinding\Action::class); - $this->action = $var; - - return $this; - } - - /** - * Role that is assigned to "members". - * For example, "roles/viewer", "roles/editor", or "roles/owner". - * - * Generated from protobuf field string role = 2; - * @return string - */ - public function getRole() - { - return $this->role; - } - - /** - * Role that is assigned to "members". - * For example, "roles/viewer", "roles/editor", or "roles/owner". - * - * Generated from protobuf field string role = 2; - * @param string $var - * @return $this - */ - public function setRole($var) - { - GPBUtil::checkString($var, True); - $this->role = $var; - - return $this; - } - - /** - * A single identity requesting access for a Cloud Platform resource, for - * example, "foo@google.com". - * - * Generated from protobuf field string member = 3; - * @return string - */ - public function getMember() - { - return $this->member; - } - - /** - * A single identity requesting access for a Cloud Platform resource, for - * example, "foo@google.com". - * - * Generated from protobuf field string member = 3; - * @param string $var - * @return $this - */ - public function setMember($var) - { - GPBUtil::checkString($var, True); - $this->member = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/IamBinding/Action.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/IamBinding/Action.php deleted file mode 100644 index f846cd97254a..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/IamBinding/Action.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.securitycenter.v1.IamBinding.Action - */ -class Action -{ - /** - * Unspecified. - * - * Generated from protobuf enum ACTION_UNSPECIFIED = 0; - */ - const ACTION_UNSPECIFIED = 0; - /** - * Addition of a Binding. - * - * Generated from protobuf enum ADD = 1; - */ - const ADD = 1; - /** - * Removal of a Binding. - * - * Generated from protobuf enum REMOVE = 2; - */ - const REMOVE = 2; - - private static $valueToName = [ - self::ACTION_UNSPECIFIED => 'ACTION_UNSPECIFIED', - self::ADD => 'ADD', - self::REMOVE => 'REMOVE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Action::class, \Google\Cloud\SecurityCenter\V1\IamBinding_Action::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator.php deleted file mode 100644 index 04556501988b..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator.php +++ /dev/null @@ -1,177 +0,0 @@ -google.cloud.securitycenter.v1.Indicator - */ -class Indicator extends \Google\Protobuf\Internal\Message -{ - /** - * The list of IP addresses that are associated with the finding. - * - * Generated from protobuf field repeated string ip_addresses = 1; - */ - private $ip_addresses; - /** - * List of domains associated to the Finding. - * - * Generated from protobuf field repeated string domains = 2; - */ - private $domains; - /** - * The list of matched signatures indicating that the given - * process is present in the environment. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Indicator.ProcessSignature signatures = 3; - */ - private $signatures; - /** - * The list of URIs associated to the Findings. - * - * Generated from protobuf field repeated string uris = 4; - */ - private $uris; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $ip_addresses - * The list of IP addresses that are associated with the finding. - * @type array|\Google\Protobuf\Internal\RepeatedField $domains - * List of domains associated to the Finding. - * @type array<\Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature>|\Google\Protobuf\Internal\RepeatedField $signatures - * The list of matched signatures indicating that the given - * process is present in the environment. - * @type array|\Google\Protobuf\Internal\RepeatedField $uris - * The list of URIs associated to the Findings. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Indicator::initOnce(); - parent::__construct($data); - } - - /** - * The list of IP addresses that are associated with the finding. - * - * Generated from protobuf field repeated string ip_addresses = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getIpAddresses() - { - return $this->ip_addresses; - } - - /** - * The list of IP addresses that are associated with the finding. - * - * Generated from protobuf field repeated string ip_addresses = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setIpAddresses($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->ip_addresses = $arr; - - return $this; - } - - /** - * List of domains associated to the Finding. - * - * Generated from protobuf field repeated string domains = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDomains() - { - return $this->domains; - } - - /** - * List of domains associated to the Finding. - * - * Generated from protobuf field repeated string domains = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDomains($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->domains = $arr; - - return $this; - } - - /** - * The list of matched signatures indicating that the given - * process is present in the environment. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Indicator.ProcessSignature signatures = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSignatures() - { - return $this->signatures; - } - - /** - * The list of matched signatures indicating that the given - * process is present in the environment. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Indicator.ProcessSignature signatures = 3; - * @param array<\Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSignatures($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature::class); - $this->signatures = $arr; - - return $this; - } - - /** - * The list of URIs associated to the Findings. - * - * Generated from protobuf field repeated string uris = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUris() - { - return $this->uris; - } - - /** - * The list of URIs associated to the Findings. - * - * Generated from protobuf field repeated string uris = 4; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUris($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->uris = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature.php deleted file mode 100644 index 017e6785809f..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature.php +++ /dev/null @@ -1,145 +0,0 @@ -google.cloud.securitycenter.v1.Indicator.ProcessSignature - */ -class ProcessSignature extends \Google\Protobuf\Internal\Message -{ - /** - * Describes the type of resource associated with the signature. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator.ProcessSignature.SignatureType signature_type = 8; - */ - protected $signature_type = 0; - protected $signature; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\MemoryHashSignature $memory_hash_signature - * Signature indicating that a binary family was matched. - * @type \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\YaraRuleSignature $yara_rule_signature - * Signature indicating that a YARA rule was matched. - * @type int $signature_type - * Describes the type of resource associated with the signature. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Indicator::initOnce(); - parent::__construct($data); - } - - /** - * Signature indicating that a binary family was matched. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator.ProcessSignature.MemoryHashSignature memory_hash_signature = 6; - * @return \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\MemoryHashSignature|null - */ - public function getMemoryHashSignature() - { - return $this->readOneof(6); - } - - public function hasMemoryHashSignature() - { - return $this->hasOneof(6); - } - - /** - * Signature indicating that a binary family was matched. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator.ProcessSignature.MemoryHashSignature memory_hash_signature = 6; - * @param \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\MemoryHashSignature $var - * @return $this - */ - public function setMemoryHashSignature($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\MemoryHashSignature::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * Signature indicating that a YARA rule was matched. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator.ProcessSignature.YaraRuleSignature yara_rule_signature = 7; - * @return \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\YaraRuleSignature|null - */ - public function getYaraRuleSignature() - { - return $this->readOneof(7); - } - - public function hasYaraRuleSignature() - { - return $this->hasOneof(7); - } - - /** - * Signature indicating that a YARA rule was matched. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator.ProcessSignature.YaraRuleSignature yara_rule_signature = 7; - * @param \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\YaraRuleSignature $var - * @return $this - */ - public function setYaraRuleSignature($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\YaraRuleSignature::class); - $this->writeOneof(7, $var); - - return $this; - } - - /** - * Describes the type of resource associated with the signature. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator.ProcessSignature.SignatureType signature_type = 8; - * @return int - */ - public function getSignatureType() - { - return $this->signature_type; - } - - /** - * Describes the type of resource associated with the signature. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Indicator.ProcessSignature.SignatureType signature_type = 8; - * @param int $var - * @return $this - */ - public function setSignatureType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\SignatureType::class); - $this->signature_type = $var; - - return $this; - } - - /** - * @return string - */ - public function getSignature() - { - return $this->whichOneof("signature"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ProcessSignature::class, \Google\Cloud\SecurityCenter\V1\Indicator_ProcessSignature::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/MemoryHashSignature.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/MemoryHashSignature.php deleted file mode 100644 index 11476d5b7ad9..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/MemoryHashSignature.php +++ /dev/null @@ -1,108 +0,0 @@ -google.cloud.securitycenter.v1.Indicator.ProcessSignature.MemoryHashSignature - */ -class MemoryHashSignature extends \Google\Protobuf\Internal\Message -{ - /** - * The binary family. - * - * Generated from protobuf field string binary_family = 1; - */ - protected $binary_family = ''; - /** - * The list of memory hash detections contributing to the binary family - * match. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Indicator.ProcessSignature.MemoryHashSignature.Detection detections = 4; - */ - private $detections; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $binary_family - * The binary family. - * @type array<\Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\MemoryHashSignature\Detection>|\Google\Protobuf\Internal\RepeatedField $detections - * The list of memory hash detections contributing to the binary family - * match. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Indicator::initOnce(); - parent::__construct($data); - } - - /** - * The binary family. - * - * Generated from protobuf field string binary_family = 1; - * @return string - */ - public function getBinaryFamily() - { - return $this->binary_family; - } - - /** - * The binary family. - * - * Generated from protobuf field string binary_family = 1; - * @param string $var - * @return $this - */ - public function setBinaryFamily($var) - { - GPBUtil::checkString($var, True); - $this->binary_family = $var; - - return $this; - } - - /** - * The list of memory hash detections contributing to the binary family - * match. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Indicator.ProcessSignature.MemoryHashSignature.Detection detections = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDetections() - { - return $this->detections; - } - - /** - * The list of memory hash detections contributing to the binary family - * match. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Indicator.ProcessSignature.MemoryHashSignature.Detection detections = 4; - * @param array<\Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\MemoryHashSignature\Detection>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDetections($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Indicator\ProcessSignature\MemoryHashSignature\Detection::class); - $this->detections = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(MemoryHashSignature::class, \Google\Cloud\SecurityCenter\V1\Indicator_ProcessSignature_MemoryHashSignature::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/MemoryHashSignature/Detection.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/MemoryHashSignature/Detection.php deleted file mode 100644 index 5ffcc1036014..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/MemoryHashSignature/Detection.php +++ /dev/null @@ -1,112 +0,0 @@ -google.cloud.securitycenter.v1.Indicator.ProcessSignature.MemoryHashSignature.Detection - */ -class Detection extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the binary associated with the memory hash - * signature detection. - * - * Generated from protobuf field string binary = 2; - */ - protected $binary = ''; - /** - * The percentage of memory page hashes in the signature - * that were matched. - * - * Generated from protobuf field double percent_pages_matched = 3; - */ - protected $percent_pages_matched = 0.0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $binary - * The name of the binary associated with the memory hash - * signature detection. - * @type float $percent_pages_matched - * The percentage of memory page hashes in the signature - * that were matched. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Indicator::initOnce(); - parent::__construct($data); - } - - /** - * The name of the binary associated with the memory hash - * signature detection. - * - * Generated from protobuf field string binary = 2; - * @return string - */ - public function getBinary() - { - return $this->binary; - } - - /** - * The name of the binary associated with the memory hash - * signature detection. - * - * Generated from protobuf field string binary = 2; - * @param string $var - * @return $this - */ - public function setBinary($var) - { - GPBUtil::checkString($var, True); - $this->binary = $var; - - return $this; - } - - /** - * The percentage of memory page hashes in the signature - * that were matched. - * - * Generated from protobuf field double percent_pages_matched = 3; - * @return float - */ - public function getPercentPagesMatched() - { - return $this->percent_pages_matched; - } - - /** - * The percentage of memory page hashes in the signature - * that were matched. - * - * Generated from protobuf field double percent_pages_matched = 3; - * @param float $var - * @return $this - */ - public function setPercentPagesMatched($var) - { - GPBUtil::checkDouble($var); - $this->percent_pages_matched = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Detection::class, \Google\Cloud\SecurityCenter\V1\Indicator_ProcessSignature_MemoryHashSignature_Detection::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/SignatureType.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/SignatureType.php deleted file mode 100644 index 02d1ec800c07..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/SignatureType.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.securitycenter.v1.Indicator.ProcessSignature.SignatureType - */ -class SignatureType -{ - /** - * The default signature type. - * - * Generated from protobuf enum SIGNATURE_TYPE_UNSPECIFIED = 0; - */ - const SIGNATURE_TYPE_UNSPECIFIED = 0; - /** - * Used for signatures concerning processes. - * - * Generated from protobuf enum SIGNATURE_TYPE_PROCESS = 1; - */ - const SIGNATURE_TYPE_PROCESS = 1; - /** - * Used for signatures concerning disks. - * - * Generated from protobuf enum SIGNATURE_TYPE_FILE = 2; - */ - const SIGNATURE_TYPE_FILE = 2; - - private static $valueToName = [ - self::SIGNATURE_TYPE_UNSPECIFIED => 'SIGNATURE_TYPE_UNSPECIFIED', - self::SIGNATURE_TYPE_PROCESS => 'SIGNATURE_TYPE_PROCESS', - self::SIGNATURE_TYPE_FILE => 'SIGNATURE_TYPE_FILE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SignatureType::class, \Google\Cloud\SecurityCenter\V1\Indicator_ProcessSignature_SignatureType::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/YaraRuleSignature.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/YaraRuleSignature.php deleted file mode 100644 index 2b26a610f499..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Indicator/ProcessSignature/YaraRuleSignature.php +++ /dev/null @@ -1,70 +0,0 @@ -google.cloud.securitycenter.v1.Indicator.ProcessSignature.YaraRuleSignature - */ -class YaraRuleSignature extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the YARA rule. - * - * Generated from protobuf field string yara_rule = 5; - */ - protected $yara_rule = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $yara_rule - * The name of the YARA rule. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Indicator::initOnce(); - parent::__construct($data); - } - - /** - * The name of the YARA rule. - * - * Generated from protobuf field string yara_rule = 5; - * @return string - */ - public function getYaraRule() - { - return $this->yara_rule; - } - - /** - * The name of the YARA rule. - * - * Generated from protobuf field string yara_rule = 5; - * @param string $var - * @return $this - */ - public function setYaraRule($var) - { - GPBUtil::checkString($var, True); - $this->yara_rule = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(YaraRuleSignature::class, \Google\Cloud\SecurityCenter\V1\Indicator_ProcessSignature_YaraRuleSignature::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/KernelRootkit.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/KernelRootkit.php deleted file mode 100644 index 6909bf3ddd8c..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/KernelRootkit.php +++ /dev/null @@ -1,367 +0,0 @@ -google.cloud.securitycenter.v1.KernelRootkit - */ -class KernelRootkit extends \Google\Protobuf\Internal\Message -{ - /** - * Rootkit name, when available. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * True if unexpected modifications of kernel code memory are present. - * - * Generated from protobuf field bool unexpected_code_modification = 2; - */ - protected $unexpected_code_modification = false; - /** - * True if unexpected modifications of kernel read-only data memory are - * present. - * - * Generated from protobuf field bool unexpected_read_only_data_modification = 3; - */ - protected $unexpected_read_only_data_modification = false; - /** - * True if `ftrace` points are present with callbacks pointing to regions - * that are not in the expected kernel or module code range. - * - * Generated from protobuf field bool unexpected_ftrace_handler = 4; - */ - protected $unexpected_ftrace_handler = false; - /** - * True if `kprobe` points are present with callbacks pointing to regions - * that are not in the expected kernel or module code range. - * - * Generated from protobuf field bool unexpected_kprobe_handler = 5; - */ - protected $unexpected_kprobe_handler = false; - /** - * True if kernel code pages that are not in the expected kernel or module - * code regions are present. - * - * Generated from protobuf field bool unexpected_kernel_code_pages = 6; - */ - protected $unexpected_kernel_code_pages = false; - /** - * True if system call handlers that are are not in the expected kernel or - * module code regions are present. - * - * Generated from protobuf field bool unexpected_system_call_handler = 7; - */ - protected $unexpected_system_call_handler = false; - /** - * True if interrupt handlers that are are not in the expected kernel or - * module code regions are present. - * - * Generated from protobuf field bool unexpected_interrupt_handler = 8; - */ - protected $unexpected_interrupt_handler = false; - /** - * True if unexpected processes in the scheduler run queue are present. Such - * processes are in the run queue, but not in the process task list. - * - * Generated from protobuf field bool unexpected_processes_in_runqueue = 9; - */ - protected $unexpected_processes_in_runqueue = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Rootkit name, when available. - * @type bool $unexpected_code_modification - * True if unexpected modifications of kernel code memory are present. - * @type bool $unexpected_read_only_data_modification - * True if unexpected modifications of kernel read-only data memory are - * present. - * @type bool $unexpected_ftrace_handler - * True if `ftrace` points are present with callbacks pointing to regions - * that are not in the expected kernel or module code range. - * @type bool $unexpected_kprobe_handler - * True if `kprobe` points are present with callbacks pointing to regions - * that are not in the expected kernel or module code range. - * @type bool $unexpected_kernel_code_pages - * True if kernel code pages that are not in the expected kernel or module - * code regions are present. - * @type bool $unexpected_system_call_handler - * True if system call handlers that are are not in the expected kernel or - * module code regions are present. - * @type bool $unexpected_interrupt_handler - * True if interrupt handlers that are are not in the expected kernel or - * module code regions are present. - * @type bool $unexpected_processes_in_runqueue - * True if unexpected processes in the scheduler run queue are present. Such - * processes are in the run queue, but not in the process task list. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\KernelRootkit::initOnce(); - parent::__construct($data); - } - - /** - * Rootkit name, when available. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Rootkit name, when available. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * True if unexpected modifications of kernel code memory are present. - * - * Generated from protobuf field bool unexpected_code_modification = 2; - * @return bool - */ - public function getUnexpectedCodeModification() - { - return $this->unexpected_code_modification; - } - - /** - * True if unexpected modifications of kernel code memory are present. - * - * Generated from protobuf field bool unexpected_code_modification = 2; - * @param bool $var - * @return $this - */ - public function setUnexpectedCodeModification($var) - { - GPBUtil::checkBool($var); - $this->unexpected_code_modification = $var; - - return $this; - } - - /** - * True if unexpected modifications of kernel read-only data memory are - * present. - * - * Generated from protobuf field bool unexpected_read_only_data_modification = 3; - * @return bool - */ - public function getUnexpectedReadOnlyDataModification() - { - return $this->unexpected_read_only_data_modification; - } - - /** - * True if unexpected modifications of kernel read-only data memory are - * present. - * - * Generated from protobuf field bool unexpected_read_only_data_modification = 3; - * @param bool $var - * @return $this - */ - public function setUnexpectedReadOnlyDataModification($var) - { - GPBUtil::checkBool($var); - $this->unexpected_read_only_data_modification = $var; - - return $this; - } - - /** - * True if `ftrace` points are present with callbacks pointing to regions - * that are not in the expected kernel or module code range. - * - * Generated from protobuf field bool unexpected_ftrace_handler = 4; - * @return bool - */ - public function getUnexpectedFtraceHandler() - { - return $this->unexpected_ftrace_handler; - } - - /** - * True if `ftrace` points are present with callbacks pointing to regions - * that are not in the expected kernel or module code range. - * - * Generated from protobuf field bool unexpected_ftrace_handler = 4; - * @param bool $var - * @return $this - */ - public function setUnexpectedFtraceHandler($var) - { - GPBUtil::checkBool($var); - $this->unexpected_ftrace_handler = $var; - - return $this; - } - - /** - * True if `kprobe` points are present with callbacks pointing to regions - * that are not in the expected kernel or module code range. - * - * Generated from protobuf field bool unexpected_kprobe_handler = 5; - * @return bool - */ - public function getUnexpectedKprobeHandler() - { - return $this->unexpected_kprobe_handler; - } - - /** - * True if `kprobe` points are present with callbacks pointing to regions - * that are not in the expected kernel or module code range. - * - * Generated from protobuf field bool unexpected_kprobe_handler = 5; - * @param bool $var - * @return $this - */ - public function setUnexpectedKprobeHandler($var) - { - GPBUtil::checkBool($var); - $this->unexpected_kprobe_handler = $var; - - return $this; - } - - /** - * True if kernel code pages that are not in the expected kernel or module - * code regions are present. - * - * Generated from protobuf field bool unexpected_kernel_code_pages = 6; - * @return bool - */ - public function getUnexpectedKernelCodePages() - { - return $this->unexpected_kernel_code_pages; - } - - /** - * True if kernel code pages that are not in the expected kernel or module - * code regions are present. - * - * Generated from protobuf field bool unexpected_kernel_code_pages = 6; - * @param bool $var - * @return $this - */ - public function setUnexpectedKernelCodePages($var) - { - GPBUtil::checkBool($var); - $this->unexpected_kernel_code_pages = $var; - - return $this; - } - - /** - * True if system call handlers that are are not in the expected kernel or - * module code regions are present. - * - * Generated from protobuf field bool unexpected_system_call_handler = 7; - * @return bool - */ - public function getUnexpectedSystemCallHandler() - { - return $this->unexpected_system_call_handler; - } - - /** - * True if system call handlers that are are not in the expected kernel or - * module code regions are present. - * - * Generated from protobuf field bool unexpected_system_call_handler = 7; - * @param bool $var - * @return $this - */ - public function setUnexpectedSystemCallHandler($var) - { - GPBUtil::checkBool($var); - $this->unexpected_system_call_handler = $var; - - return $this; - } - - /** - * True if interrupt handlers that are are not in the expected kernel or - * module code regions are present. - * - * Generated from protobuf field bool unexpected_interrupt_handler = 8; - * @return bool - */ - public function getUnexpectedInterruptHandler() - { - return $this->unexpected_interrupt_handler; - } - - /** - * True if interrupt handlers that are are not in the expected kernel or - * module code regions are present. - * - * Generated from protobuf field bool unexpected_interrupt_handler = 8; - * @param bool $var - * @return $this - */ - public function setUnexpectedInterruptHandler($var) - { - GPBUtil::checkBool($var); - $this->unexpected_interrupt_handler = $var; - - return $this; - } - - /** - * True if unexpected processes in the scheduler run queue are present. Such - * processes are in the run queue, but not in the process task list. - * - * Generated from protobuf field bool unexpected_processes_in_runqueue = 9; - * @return bool - */ - public function getUnexpectedProcessesInRunqueue() - { - return $this->unexpected_processes_in_runqueue; - } - - /** - * True if unexpected processes in the scheduler run queue are present. Such - * processes are in the run queue, but not in the process task list. - * - * Generated from protobuf field bool unexpected_processes_in_runqueue = 9; - * @param bool $var - * @return $this - */ - public function setUnexpectedProcessesInRunqueue($var) - { - GPBUtil::checkBool($var); - $this->unexpected_processes_in_runqueue = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes.php deleted file mode 100644 index 0422e87eb6f5..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes.php +++ /dev/null @@ -1,319 +0,0 @@ -google.cloud.securitycenter.v1.Kubernetes - */ -class Kubernetes extends \Google\Protobuf\Internal\Message -{ - /** - * Kubernetes - * [Pods](https://cloud.google.com/kubernetes-engine/docs/concepts/pod) - * associated with the finding. This field contains Pod records for each - * container that is owned by a Pod. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Pod pods = 1; - */ - private $pods; - /** - * Provides Kubernetes - * [node](https://cloud.google.com/kubernetes-engine/docs/concepts/cluster-architecture#nodes) - * information. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Node nodes = 2; - */ - private $nodes; - /** - * GKE [node - * pools](https://cloud.google.com/kubernetes-engine/docs/concepts/node-pools) - * associated with the finding. This field contains node pool information for - * each node, when it is available. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.NodePool node_pools = 3; - */ - private $node_pools; - /** - * Provides Kubernetes role information for findings that involve [Roles or - * ClusterRoles](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Role roles = 4; - */ - private $roles; - /** - * Provides Kubernetes role binding information for findings that involve - * [RoleBindings or - * ClusterRoleBindings](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Binding bindings = 5; - */ - private $bindings; - /** - * Provides information on any Kubernetes access reviews (privilege checks) - * relevant to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.AccessReview access_reviews = 6; - */ - private $access_reviews; - /** - * Kubernetes objects related to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Object objects = 7; - */ - private $objects; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Pod>|\Google\Protobuf\Internal\RepeatedField $pods - * Kubernetes - * [Pods](https://cloud.google.com/kubernetes-engine/docs/concepts/pod) - * associated with the finding. This field contains Pod records for each - * container that is owned by a Pod. - * @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Node>|\Google\Protobuf\Internal\RepeatedField $nodes - * Provides Kubernetes - * [node](https://cloud.google.com/kubernetes-engine/docs/concepts/cluster-architecture#nodes) - * information. - * @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\NodePool>|\Google\Protobuf\Internal\RepeatedField $node_pools - * GKE [node - * pools](https://cloud.google.com/kubernetes-engine/docs/concepts/node-pools) - * associated with the finding. This field contains node pool information for - * each node, when it is available. - * @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Role>|\Google\Protobuf\Internal\RepeatedField $roles - * Provides Kubernetes role information for findings that involve [Roles or - * ClusterRoles](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). - * @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Binding>|\Google\Protobuf\Internal\RepeatedField $bindings - * Provides Kubernetes role binding information for findings that involve - * [RoleBindings or - * ClusterRoleBindings](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). - * @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\AccessReview>|\Google\Protobuf\Internal\RepeatedField $access_reviews - * Provides information on any Kubernetes access reviews (privilege checks) - * relevant to the finding. - * @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Object>|\Google\Protobuf\Internal\RepeatedField $objects - * Kubernetes objects related to the finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Kubernetes::initOnce(); - parent::__construct($data); - } - - /** - * Kubernetes - * [Pods](https://cloud.google.com/kubernetes-engine/docs/concepts/pod) - * associated with the finding. This field contains Pod records for each - * container that is owned by a Pod. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Pod pods = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPods() - { - return $this->pods; - } - - /** - * Kubernetes - * [Pods](https://cloud.google.com/kubernetes-engine/docs/concepts/pod) - * associated with the finding. This field contains Pod records for each - * container that is owned by a Pod. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Pod pods = 1; - * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Pod>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPods($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\Pod::class); - $this->pods = $arr; - - return $this; - } - - /** - * Provides Kubernetes - * [node](https://cloud.google.com/kubernetes-engine/docs/concepts/cluster-architecture#nodes) - * information. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Node nodes = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNodes() - { - return $this->nodes; - } - - /** - * Provides Kubernetes - * [node](https://cloud.google.com/kubernetes-engine/docs/concepts/cluster-architecture#nodes) - * information. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Node nodes = 2; - * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Node>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNodes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\Node::class); - $this->nodes = $arr; - - return $this; - } - - /** - * GKE [node - * pools](https://cloud.google.com/kubernetes-engine/docs/concepts/node-pools) - * associated with the finding. This field contains node pool information for - * each node, when it is available. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.NodePool node_pools = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNodePools() - { - return $this->node_pools; - } - - /** - * GKE [node - * pools](https://cloud.google.com/kubernetes-engine/docs/concepts/node-pools) - * associated with the finding. This field contains node pool information for - * each node, when it is available. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.NodePool node_pools = 3; - * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\NodePool>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNodePools($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\NodePool::class); - $this->node_pools = $arr; - - return $this; - } - - /** - * Provides Kubernetes role information for findings that involve [Roles or - * ClusterRoles](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Role roles = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRoles() - { - return $this->roles; - } - - /** - * Provides Kubernetes role information for findings that involve [Roles or - * ClusterRoles](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Role roles = 4; - * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Role>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRoles($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\Role::class); - $this->roles = $arr; - - return $this; - } - - /** - * Provides Kubernetes role binding information for findings that involve - * [RoleBindings or - * ClusterRoleBindings](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Binding bindings = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getBindings() - { - return $this->bindings; - } - - /** - * Provides Kubernetes role binding information for findings that involve - * [RoleBindings or - * ClusterRoleBindings](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Binding bindings = 5; - * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Binding>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setBindings($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\Binding::class); - $this->bindings = $arr; - - return $this; - } - - /** - * Provides information on any Kubernetes access reviews (privilege checks) - * relevant to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.AccessReview access_reviews = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAccessReviews() - { - return $this->access_reviews; - } - - /** - * Provides information on any Kubernetes access reviews (privilege checks) - * relevant to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.AccessReview access_reviews = 6; - * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\AccessReview>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAccessReviews($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\AccessReview::class); - $this->access_reviews = $arr; - - return $this; - } - - /** - * Kubernetes objects related to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Object objects = 7; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getObjects() - { - return $this->objects; - } - - /** - * Kubernetes objects related to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Object objects = 7; - * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Object>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setObjects($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\Object::class); - $this->objects = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/AccessReview.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/AccessReview.php deleted file mode 100644 index 7cfb6f5427f6..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/AccessReview.php +++ /dev/null @@ -1,289 +0,0 @@ -google.cloud.securitycenter.v1.Kubernetes.AccessReview - */ -class AccessReview extends \Google\Protobuf\Internal\Message -{ - /** - * The API group of the resource. "*" means all. - * - * Generated from protobuf field string group = 1; - */ - protected $group = ''; - /** - * Namespace of the action being requested. Currently, there is no - * distinction between no namespace and all namespaces. Both - * are represented by "" (empty). - * - * Generated from protobuf field string ns = 2; - */ - protected $ns = ''; - /** - * The name of the resource being requested. Empty means all. - * - * Generated from protobuf field string name = 3; - */ - protected $name = ''; - /** - * The optional resource type requested. "*" means all. - * - * Generated from protobuf field string resource = 4; - */ - protected $resource = ''; - /** - * The optional subresource type. - * - * Generated from protobuf field string subresource = 5; - */ - protected $subresource = ''; - /** - * A Kubernetes resource API verb, like get, list, watch, create, update, - * delete, proxy. "*" means all. - * - * Generated from protobuf field string verb = 6; - */ - protected $verb = ''; - /** - * The API version of the resource. "*" means all. - * - * Generated from protobuf field string version = 7; - */ - protected $version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $group - * The API group of the resource. "*" means all. - * @type string $ns - * Namespace of the action being requested. Currently, there is no - * distinction between no namespace and all namespaces. Both - * are represented by "" (empty). - * @type string $name - * The name of the resource being requested. Empty means all. - * @type string $resource - * The optional resource type requested. "*" means all. - * @type string $subresource - * The optional subresource type. - * @type string $verb - * A Kubernetes resource API verb, like get, list, watch, create, update, - * delete, proxy. "*" means all. - * @type string $version - * The API version of the resource. "*" means all. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Kubernetes::initOnce(); - parent::__construct($data); - } - - /** - * The API group of the resource. "*" means all. - * - * Generated from protobuf field string group = 1; - * @return string - */ - public function getGroup() - { - return $this->group; - } - - /** - * The API group of the resource. "*" means all. - * - * Generated from protobuf field string group = 1; - * @param string $var - * @return $this - */ - public function setGroup($var) - { - GPBUtil::checkString($var, True); - $this->group = $var; - - return $this; - } - - /** - * Namespace of the action being requested. Currently, there is no - * distinction between no namespace and all namespaces. Both - * are represented by "" (empty). - * - * Generated from protobuf field string ns = 2; - * @return string - */ - public function getNs() - { - return $this->ns; - } - - /** - * Namespace of the action being requested. Currently, there is no - * distinction between no namespace and all namespaces. Both - * are represented by "" (empty). - * - * Generated from protobuf field string ns = 2; - * @param string $var - * @return $this - */ - public function setNs($var) - { - GPBUtil::checkString($var, True); - $this->ns = $var; - - return $this; - } - - /** - * The name of the resource being requested. Empty means all. - * - * Generated from protobuf field string name = 3; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the resource being requested. Empty means all. - * - * Generated from protobuf field string name = 3; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The optional resource type requested. "*" means all. - * - * Generated from protobuf field string resource = 4; - * @return string - */ - public function getResource() - { - return $this->resource; - } - - /** - * The optional resource type requested. "*" means all. - * - * Generated from protobuf field string resource = 4; - * @param string $var - * @return $this - */ - public function setResource($var) - { - GPBUtil::checkString($var, True); - $this->resource = $var; - - return $this; - } - - /** - * The optional subresource type. - * - * Generated from protobuf field string subresource = 5; - * @return string - */ - public function getSubresource() - { - return $this->subresource; - } - - /** - * The optional subresource type. - * - * Generated from protobuf field string subresource = 5; - * @param string $var - * @return $this - */ - public function setSubresource($var) - { - GPBUtil::checkString($var, True); - $this->subresource = $var; - - return $this; - } - - /** - * A Kubernetes resource API verb, like get, list, watch, create, update, - * delete, proxy. "*" means all. - * - * Generated from protobuf field string verb = 6; - * @return string - */ - public function getVerb() - { - return $this->verb; - } - - /** - * A Kubernetes resource API verb, like get, list, watch, create, update, - * delete, proxy. "*" means all. - * - * Generated from protobuf field string verb = 6; - * @param string $var - * @return $this - */ - public function setVerb($var) - { - GPBUtil::checkString($var, True); - $this->verb = $var; - - return $this; - } - - /** - * The API version of the resource. "*" means all. - * - * Generated from protobuf field string version = 7; - * @return string - */ - public function getVersion() - { - return $this->version; - } - - /** - * The API version of the resource. "*" means all. - * - * Generated from protobuf field string version = 7; - * @param string $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkString($var, True); - $this->version = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AccessReview::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_AccessReview::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Binding.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Binding.php deleted file mode 100644 index 9751ec36d355..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Binding.php +++ /dev/null @@ -1,186 +0,0 @@ -google.cloud.securitycenter.v1.Kubernetes.Binding - */ -class Binding extends \Google\Protobuf\Internal\Message -{ - /** - * Namespace for the binding. - * - * Generated from protobuf field string ns = 1; - */ - protected $ns = ''; - /** - * Name for the binding. - * - * Generated from protobuf field string name = 2; - */ - protected $name = ''; - /** - * The Role or ClusterRole referenced by the binding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes.Role role = 3; - */ - protected $role = null; - /** - * Represents one or more subjects that are bound to the role. Not always - * available for PATCH requests. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Subject subjects = 4; - */ - private $subjects; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $ns - * Namespace for the binding. - * @type string $name - * Name for the binding. - * @type \Google\Cloud\SecurityCenter\V1\Kubernetes\Role $role - * The Role or ClusterRole referenced by the binding. - * @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Subject>|\Google\Protobuf\Internal\RepeatedField $subjects - * Represents one or more subjects that are bound to the role. Not always - * available for PATCH requests. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Kubernetes::initOnce(); - parent::__construct($data); - } - - /** - * Namespace for the binding. - * - * Generated from protobuf field string ns = 1; - * @return string - */ - public function getNs() - { - return $this->ns; - } - - /** - * Namespace for the binding. - * - * Generated from protobuf field string ns = 1; - * @param string $var - * @return $this - */ - public function setNs($var) - { - GPBUtil::checkString($var, True); - $this->ns = $var; - - return $this; - } - - /** - * Name for the binding. - * - * Generated from protobuf field string name = 2; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Name for the binding. - * - * Generated from protobuf field string name = 2; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The Role or ClusterRole referenced by the binding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes.Role role = 3; - * @return \Google\Cloud\SecurityCenter\V1\Kubernetes\Role|null - */ - public function getRole() - { - return $this->role; - } - - public function hasRole() - { - return isset($this->role); - } - - public function clearRole() - { - unset($this->role); - } - - /** - * The Role or ClusterRole referenced by the binding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes.Role role = 3; - * @param \Google\Cloud\SecurityCenter\V1\Kubernetes\Role $var - * @return $this - */ - public function setRole($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Kubernetes\Role::class); - $this->role = $var; - - return $this; - } - - /** - * Represents one or more subjects that are bound to the role. Not always - * available for PATCH requests. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Subject subjects = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSubjects() - { - return $this->subjects; - } - - /** - * Represents one or more subjects that are bound to the role. Not always - * available for PATCH requests. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Subject subjects = 4; - * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Subject>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSubjects($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\Subject::class); - $this->subjects = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Binding::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_Binding::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Node.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Node.php deleted file mode 100644 index edb8e19d7661..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Node.php +++ /dev/null @@ -1,74 +0,0 @@ -google.cloud.securitycenter.v1.Kubernetes.Node - */ -class Node extends \Google\Protobuf\Internal\Message -{ - /** - * [Full resource name](https://google.aip.dev/122#full-resource-names) of - * the Compute Engine VM running the cluster node. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * [Full resource name](https://google.aip.dev/122#full-resource-names) of - * the Compute Engine VM running the cluster node. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Kubernetes::initOnce(); - parent::__construct($data); - } - - /** - * [Full resource name](https://google.aip.dev/122#full-resource-names) of - * the Compute Engine VM running the cluster node. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * [Full resource name](https://google.aip.dev/122#full-resource-names) of - * the Compute Engine VM running the cluster node. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Node::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_Node::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/NodePool.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/NodePool.php deleted file mode 100644 index cf2dce61c43f..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/NodePool.php +++ /dev/null @@ -1,104 +0,0 @@ -google.cloud.securitycenter.v1.Kubernetes.NodePool - */ -class NodePool extends \Google\Protobuf\Internal\Message -{ - /** - * Kubernetes node pool name. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Nodes associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Node nodes = 2; - */ - private $nodes; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Kubernetes node pool name. - * @type array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Node>|\Google\Protobuf\Internal\RepeatedField $nodes - * Nodes associated with the finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Kubernetes::initOnce(); - parent::__construct($data); - } - - /** - * Kubernetes node pool name. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Kubernetes node pool name. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Nodes associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Node nodes = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNodes() - { - return $this->nodes; - } - - /** - * Nodes associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Kubernetes.Node nodes = 2; - * @param array<\Google\Cloud\SecurityCenter\V1\Kubernetes\Node>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNodes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Kubernetes\Node::class); - $this->nodes = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(NodePool::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_NodePool::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Object.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Object.php deleted file mode 100644 index ecdff6fb8032..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Object.php +++ /dev/null @@ -1,220 +0,0 @@ -google.cloud.securitycenter.v1.Kubernetes.Object - */ -class Object extends \Google\Protobuf\Internal\Message -{ - /** - * Kubernetes object group, such as "policy.k8s.io/v1". - * - * Generated from protobuf field string group = 1; - */ - protected $group = ''; - /** - * Kubernetes object kind, such as "Namespace". - * - * Generated from protobuf field string kind = 2; - */ - protected $kind = ''; - /** - * Kubernetes object namespace. Must be a valid DNS label. Named - * "ns" to avoid collision with C++ namespace keyword. For details see - * https://kubernetes.io/docs/tasks/administer-cluster/namespaces/. - * - * Generated from protobuf field string ns = 3; - */ - protected $ns = ''; - /** - * Kubernetes object name. For details see - * https://kubernetes.io/docs/concepts/overview/working-with-objects/names/. - * - * Generated from protobuf field string name = 4; - */ - protected $name = ''; - /** - * Pod containers associated with this finding, if any. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Container containers = 5; - */ - private $containers; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $group - * Kubernetes object group, such as "policy.k8s.io/v1". - * @type string $kind - * Kubernetes object kind, such as "Namespace". - * @type string $ns - * Kubernetes object namespace. Must be a valid DNS label. Named - * "ns" to avoid collision with C++ namespace keyword. For details see - * https://kubernetes.io/docs/tasks/administer-cluster/namespaces/. - * @type string $name - * Kubernetes object name. For details see - * https://kubernetes.io/docs/concepts/overview/working-with-objects/names/. - * @type array<\Google\Cloud\SecurityCenter\V1\Container>|\Google\Protobuf\Internal\RepeatedField $containers - * Pod containers associated with this finding, if any. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Kubernetes::initOnce(); - parent::__construct($data); - } - - /** - * Kubernetes object group, such as "policy.k8s.io/v1". - * - * Generated from protobuf field string group = 1; - * @return string - */ - public function getGroup() - { - return $this->group; - } - - /** - * Kubernetes object group, such as "policy.k8s.io/v1". - * - * Generated from protobuf field string group = 1; - * @param string $var - * @return $this - */ - public function setGroup($var) - { - GPBUtil::checkString($var, True); - $this->group = $var; - - return $this; - } - - /** - * Kubernetes object kind, such as "Namespace". - * - * Generated from protobuf field string kind = 2; - * @return string - */ - public function getKind() - { - return $this->kind; - } - - /** - * Kubernetes object kind, such as "Namespace". - * - * Generated from protobuf field string kind = 2; - * @param string $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkString($var, True); - $this->kind = $var; - - return $this; - } - - /** - * Kubernetes object namespace. Must be a valid DNS label. Named - * "ns" to avoid collision with C++ namespace keyword. For details see - * https://kubernetes.io/docs/tasks/administer-cluster/namespaces/. - * - * Generated from protobuf field string ns = 3; - * @return string - */ - public function getNs() - { - return $this->ns; - } - - /** - * Kubernetes object namespace. Must be a valid DNS label. Named - * "ns" to avoid collision with C++ namespace keyword. For details see - * https://kubernetes.io/docs/tasks/administer-cluster/namespaces/. - * - * Generated from protobuf field string ns = 3; - * @param string $var - * @return $this - */ - public function setNs($var) - { - GPBUtil::checkString($var, True); - $this->ns = $var; - - return $this; - } - - /** - * Kubernetes object name. For details see - * https://kubernetes.io/docs/concepts/overview/working-with-objects/names/. - * - * Generated from protobuf field string name = 4; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Kubernetes object name. For details see - * https://kubernetes.io/docs/concepts/overview/working-with-objects/names/. - * - * Generated from protobuf field string name = 4; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Pod containers associated with this finding, if any. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Container containers = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getContainers() - { - return $this->containers; - } - - /** - * Pod containers associated with this finding, if any. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Container containers = 5; - * @param array<\Google\Cloud\SecurityCenter\V1\Container>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setContainers($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Container::class); - $this->containers = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Object::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_Object::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Pod.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Pod.php deleted file mode 100644 index 7d051a9a87a0..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Pod.php +++ /dev/null @@ -1,176 +0,0 @@ -google.cloud.securitycenter.v1.Kubernetes.Pod - */ -class Pod extends \Google\Protobuf\Internal\Message -{ - /** - * Kubernetes Pod namespace. - * - * Generated from protobuf field string ns = 1; - */ - protected $ns = ''; - /** - * Kubernetes Pod name. - * - * Generated from protobuf field string name = 2; - */ - protected $name = ''; - /** - * Pod labels. For Kubernetes containers, these are applied to the - * container. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Label labels = 3; - */ - private $labels; - /** - * Pod containers associated with this finding, if any. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Container containers = 4; - */ - private $containers; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $ns - * Kubernetes Pod namespace. - * @type string $name - * Kubernetes Pod name. - * @type array<\Google\Cloud\SecurityCenter\V1\Label>|\Google\Protobuf\Internal\RepeatedField $labels - * Pod labels. For Kubernetes containers, these are applied to the - * container. - * @type array<\Google\Cloud\SecurityCenter\V1\Container>|\Google\Protobuf\Internal\RepeatedField $containers - * Pod containers associated with this finding, if any. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Kubernetes::initOnce(); - parent::__construct($data); - } - - /** - * Kubernetes Pod namespace. - * - * Generated from protobuf field string ns = 1; - * @return string - */ - public function getNs() - { - return $this->ns; - } - - /** - * Kubernetes Pod namespace. - * - * Generated from protobuf field string ns = 1; - * @param string $var - * @return $this - */ - public function setNs($var) - { - GPBUtil::checkString($var, True); - $this->ns = $var; - - return $this; - } - - /** - * Kubernetes Pod name. - * - * Generated from protobuf field string name = 2; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Kubernetes Pod name. - * - * Generated from protobuf field string name = 2; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Pod labels. For Kubernetes containers, these are applied to the - * container. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Label labels = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Pod labels. For Kubernetes containers, these are applied to the - * container. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Label labels = 3; - * @param array<\Google\Cloud\SecurityCenter\V1\Label>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Label::class); - $this->labels = $arr; - - return $this; - } - - /** - * Pod containers associated with this finding, if any. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Container containers = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getContainers() - { - return $this->containers; - } - - /** - * Pod containers associated with this finding, if any. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Container containers = 4; - * @param array<\Google\Cloud\SecurityCenter\V1\Container>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setContainers($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Container::class); - $this->containers = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Pod::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_Pod::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Role.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Role.php deleted file mode 100644 index 87c452fbdc16..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Role.php +++ /dev/null @@ -1,138 +0,0 @@ -google.cloud.securitycenter.v1.Kubernetes.Role - */ -class Role extends \Google\Protobuf\Internal\Message -{ - /** - * Role type. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes.Role.Kind kind = 1; - */ - protected $kind = 0; - /** - * Role namespace. - * - * Generated from protobuf field string ns = 2; - */ - protected $ns = ''; - /** - * Role name. - * - * Generated from protobuf field string name = 3; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $kind - * Role type. - * @type string $ns - * Role namespace. - * @type string $name - * Role name. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Kubernetes::initOnce(); - parent::__construct($data); - } - - /** - * Role type. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes.Role.Kind kind = 1; - * @return int - */ - public function getKind() - { - return $this->kind; - } - - /** - * Role type. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes.Role.Kind kind = 1; - * @param int $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Kubernetes\Role\Kind::class); - $this->kind = $var; - - return $this; - } - - /** - * Role namespace. - * - * Generated from protobuf field string ns = 2; - * @return string - */ - public function getNs() - { - return $this->ns; - } - - /** - * Role namespace. - * - * Generated from protobuf field string ns = 2; - * @param string $var - * @return $this - */ - public function setNs($var) - { - GPBUtil::checkString($var, True); - $this->ns = $var; - - return $this; - } - - /** - * Role name. - * - * Generated from protobuf field string name = 3; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Role name. - * - * Generated from protobuf field string name = 3; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Role::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_Role::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Role/Kind.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Role/Kind.php deleted file mode 100644 index 36dd17cbb47b..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Role/Kind.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.securitycenter.v1.Kubernetes.Role.Kind - */ -class Kind -{ - /** - * Role type is not specified. - * - * Generated from protobuf enum KIND_UNSPECIFIED = 0; - */ - const KIND_UNSPECIFIED = 0; - /** - * Kubernetes Role. - * - * Generated from protobuf enum ROLE = 1; - */ - const ROLE = 1; - /** - * Kubernetes ClusterRole. - * - * Generated from protobuf enum CLUSTER_ROLE = 2; - */ - const CLUSTER_ROLE = 2; - - private static $valueToName = [ - self::KIND_UNSPECIFIED => 'KIND_UNSPECIFIED', - self::ROLE => 'ROLE', - self::CLUSTER_ROLE => 'CLUSTER_ROLE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Kind::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_Role_Kind::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Subject.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Subject.php deleted file mode 100644 index a23b790cbed7..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Subject.php +++ /dev/null @@ -1,138 +0,0 @@ -google.cloud.securitycenter.v1.Kubernetes.Subject - */ -class Subject extends \Google\Protobuf\Internal\Message -{ - /** - * Authentication type for the subject. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes.Subject.AuthType kind = 1; - */ - protected $kind = 0; - /** - * Namespace for the subject. - * - * Generated from protobuf field string ns = 2; - */ - protected $ns = ''; - /** - * Name for the subject. - * - * Generated from protobuf field string name = 3; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $kind - * Authentication type for the subject. - * @type string $ns - * Namespace for the subject. - * @type string $name - * Name for the subject. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Kubernetes::initOnce(); - parent::__construct($data); - } - - /** - * Authentication type for the subject. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes.Subject.AuthType kind = 1; - * @return int - */ - public function getKind() - { - return $this->kind; - } - - /** - * Authentication type for the subject. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Kubernetes.Subject.AuthType kind = 1; - * @param int $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Kubernetes\Subject\AuthType::class); - $this->kind = $var; - - return $this; - } - - /** - * Namespace for the subject. - * - * Generated from protobuf field string ns = 2; - * @return string - */ - public function getNs() - { - return $this->ns; - } - - /** - * Namespace for the subject. - * - * Generated from protobuf field string ns = 2; - * @param string $var - * @return $this - */ - public function setNs($var) - { - GPBUtil::checkString($var, True); - $this->ns = $var; - - return $this; - } - - /** - * Name for the subject. - * - * Generated from protobuf field string name = 3; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Name for the subject. - * - * Generated from protobuf field string name = 3; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Subject::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_Subject::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Subject/AuthType.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Subject/AuthType.php deleted file mode 100644 index 0b3c6046a837..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Kubernetes/Subject/AuthType.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.securitycenter.v1.Kubernetes.Subject.AuthType - */ -class AuthType -{ - /** - * Authentication is not specified. - * - * Generated from protobuf enum AUTH_TYPE_UNSPECIFIED = 0; - */ - const AUTH_TYPE_UNSPECIFIED = 0; - /** - * User with valid certificate. - * - * Generated from protobuf enum USER = 1; - */ - const USER = 1; - /** - * Users managed by Kubernetes API with credentials stored as secrets. - * - * Generated from protobuf enum SERVICEACCOUNT = 2; - */ - const SERVICEACCOUNT = 2; - /** - * Collection of users. - * - * Generated from protobuf enum GROUP = 3; - */ - const GROUP = 3; - - private static $valueToName = [ - self::AUTH_TYPE_UNSPECIFIED => 'AUTH_TYPE_UNSPECIFIED', - self::USER => 'USER', - self::SERVICEACCOUNT => 'SERVICEACCOUNT', - self::GROUP => 'GROUP', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AuthType::class, \Google\Cloud\SecurityCenter\V1\Kubernetes_Subject_AuthType::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Label.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Label.php deleted file mode 100644 index 20cb2f555c39..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Label.php +++ /dev/null @@ -1,104 +0,0 @@ -google.cloud.securitycenter.v1.Label - */ -class Label extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the label. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Value that corresponds to the label's name. - * - * Generated from protobuf field string value = 2; - */ - protected $value = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Name of the label. - * @type string $value - * Value that corresponds to the label's name. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Label::initOnce(); - parent::__construct($data); - } - - /** - * Name of the label. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Name of the label. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Value that corresponds to the label's name. - * - * Generated from protobuf field string value = 2; - * @return string - */ - public function getValue() - { - return $this->value; - } - - /** - * Value that corresponds to the label's name. - * - * Generated from protobuf field string value = 2; - * @param string $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkString($var, True); - $this->value = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsRequest.php deleted file mode 100644 index 0601a927e3bc..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsRequest.php +++ /dev/null @@ -1,719 +0,0 @@ -google.cloud.securitycenter.v1.ListAssetsRequest - */ -class ListAssetsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the parent resource that contains the assets. The - * value that you can specify on parent depends on the method in which you - * specify parent. You can specify one of the following values: - * "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following are the allowed field and operator combinations: - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * For example, `resource_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * - * Generated from protobuf field string filter = 2; - */ - protected $filter = ''; - /** - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,resource_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,resource_properties.a_property" and " - * name desc , resource_properties.a_property " are equivalent. - * The following fields are supported: - * name - * update_time - * resource_properties - * security_marks.marks - * security_center_properties.resource_name - * security_center_properties.resource_display_name - * security_center_properties.resource_parent - * security_center_properties.resource_parent_display_name - * security_center_properties.resource_project - * security_center_properties.resource_project_display_name - * security_center_properties.resource_type - * - * Generated from protobuf field string order_by = 3; - */ - protected $order_by = ''; - /** - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; - */ - protected $read_time = null; - /** - * When compare_duration is set, the ListAssetsResult's "state_change" - * attribute is updated to indicate whether the asset was added, removed, or - * remained present during the compare_duration period of time that precedes - * the read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state_change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * Possible "state_change" values when compare_duration is specified: - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at read_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at read_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; - */ - protected $compare_duration = null; - /** - * A field mask to specify the ListAssetsResult fields to be listed in the - * response. - * An empty field mask will list all fields. - * - * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; - */ - protected $field_mask = null; - /** - * The value returned by the last `ListAssetsResponse`; indicates - * that this is a continuation of a prior `ListAssets` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 8; - */ - protected $page_token = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 9; - */ - protected $page_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The name of the parent resource that contains the assets. The - * value that you can specify on parent depends on the method in which you - * specify parent. You can specify one of the following values: - * "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * @type string $filter - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following are the allowed field and operator combinations: - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * For example, `resource_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * @type string $order_by - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,resource_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,resource_properties.a_property" and " - * name desc , resource_properties.a_property " are equivalent. - * The following fields are supported: - * name - * update_time - * resource_properties - * security_marks.marks - * security_center_properties.resource_name - * security_center_properties.resource_display_name - * security_center_properties.resource_parent - * security_center_properties.resource_parent_display_name - * security_center_properties.resource_project - * security_center_properties.resource_project_display_name - * security_center_properties.resource_type - * @type \Google\Protobuf\Timestamp $read_time - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * @type \Google\Protobuf\Duration $compare_duration - * When compare_duration is set, the ListAssetsResult's "state_change" - * attribute is updated to indicate whether the asset was added, removed, or - * remained present during the compare_duration period of time that precedes - * the read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state_change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * Possible "state_change" values when compare_duration is specified: - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at read_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at read_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * @type \Google\Protobuf\FieldMask $field_mask - * A field mask to specify the ListAssetsResult fields to be listed in the - * response. - * An empty field mask will list all fields. - * @type string $page_token - * The value returned by the last `ListAssetsResponse`; indicates - * that this is a continuation of a prior `ListAssets` call, and - * that the system should return the next page of data. - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the parent resource that contains the assets. The - * value that you can specify on parent depends on the method in which you - * specify parent. You can specify one of the following values: - * "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The name of the parent resource that contains the assets. The - * value that you can specify on parent depends on the method in which you - * specify parent. You can specify one of the following values: - * "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following are the allowed field and operator combinations: - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * For example, `resource_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * - * Generated from protobuf field string filter = 2; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following are the allowed field and operator combinations: - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * For example, `resource_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * - * Generated from protobuf field string filter = 2; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,resource_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,resource_properties.a_property" and " - * name desc , resource_properties.a_property " are equivalent. - * The following fields are supported: - * name - * update_time - * resource_properties - * security_marks.marks - * security_center_properties.resource_name - * security_center_properties.resource_display_name - * security_center_properties.resource_parent - * security_center_properties.resource_parent_display_name - * security_center_properties.resource_project - * security_center_properties.resource_project_display_name - * security_center_properties.resource_type - * - * Generated from protobuf field string order_by = 3; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,resource_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,resource_properties.a_property" and " - * name desc , resource_properties.a_property " are equivalent. - * The following fields are supported: - * name - * update_time - * resource_properties - * security_marks.marks - * security_center_properties.resource_name - * security_center_properties.resource_display_name - * security_center_properties.resource_parent - * security_center_properties.resource_parent_display_name - * security_center_properties.resource_project - * security_center_properties.resource_project_display_name - * security_center_properties.resource_type - * - * Generated from protobuf field string order_by = 3; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - - /** - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; - * @return \Google\Protobuf\Timestamp|null - */ - public function getReadTime() - { - return $this->read_time; - } - - public function hasReadTime() - { - return isset($this->read_time); - } - - public function clearReadTime() - { - unset($this->read_time); - } - - /** - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setReadTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->read_time = $var; - - return $this; - } - - /** - * When compare_duration is set, the ListAssetsResult's "state_change" - * attribute is updated to indicate whether the asset was added, removed, or - * remained present during the compare_duration period of time that precedes - * the read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state_change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * Possible "state_change" values when compare_duration is specified: - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at read_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at read_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; - * @return \Google\Protobuf\Duration|null - */ - public function getCompareDuration() - { - return $this->compare_duration; - } - - public function hasCompareDuration() - { - return isset($this->compare_duration); - } - - public function clearCompareDuration() - { - unset($this->compare_duration); - } - - /** - * When compare_duration is set, the ListAssetsResult's "state_change" - * attribute is updated to indicate whether the asset was added, removed, or - * remained present during the compare_duration period of time that precedes - * the read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state_change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * Possible "state_change" values when compare_duration is specified: - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at read_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at read_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setCompareDuration($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->compare_duration = $var; - - return $this; - } - - /** - * A field mask to specify the ListAssetsResult fields to be listed in the - * response. - * An empty field mask will list all fields. - * - * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; - * @return \Google\Protobuf\FieldMask|null - */ - public function getFieldMask() - { - return $this->field_mask; - } - - public function hasFieldMask() - { - return isset($this->field_mask); - } - - public function clearFieldMask() - { - unset($this->field_mask); - } - - /** - * A field mask to specify the ListAssetsResult fields to be listed in the - * response. - * An empty field mask will list all fields. - * - * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setFieldMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->field_mask = $var; - - return $this; - } - - /** - * The value returned by the last `ListAssetsResponse`; indicates - * that this is a continuation of a prior `ListAssets` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 8; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListAssetsResponse`; indicates - * that this is a continuation of a prior `ListAssets` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 8; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 9; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 9; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse.php deleted file mode 100644 index 0628a39e7ed7..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse.php +++ /dev/null @@ -1,183 +0,0 @@ -google.cloud.securitycenter.v1.ListAssetsResponse - */ -class ListAssetsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Assets matching the list request. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult list_assets_results = 1; - */ - private $list_assets_results; - /** - * Time used for executing the list request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - */ - protected $read_time = null; - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - */ - protected $next_page_token = ''; - /** - * The total number of assets matching the query. - * - * Generated from protobuf field int32 total_size = 4; - */ - protected $total_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1\ListAssetsResponse\ListAssetsResult>|\Google\Protobuf\Internal\RepeatedField $list_assets_results - * Assets matching the list request. - * @type \Google\Protobuf\Timestamp $read_time - * Time used for executing the list request. - * @type string $next_page_token - * Token to retrieve the next page of results, or empty if there are no more - * results. - * @type int $total_size - * The total number of assets matching the query. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Assets matching the list request. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult list_assets_results = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getListAssetsResults() - { - return $this->list_assets_results; - } - - /** - * Assets matching the list request. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult list_assets_results = 1; - * @param array<\Google\Cloud\SecurityCenter\V1\ListAssetsResponse\ListAssetsResult>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setListAssetsResults($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\ListAssetsResponse\ListAssetsResult::class); - $this->list_assets_results = $arr; - - return $this; - } - - /** - * Time used for executing the list request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getReadTime() - { - return $this->read_time; - } - - public function hasReadTime() - { - return isset($this->read_time); - } - - public function clearReadTime() - { - unset($this->read_time); - } - - /** - * Time used for executing the list request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setReadTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->read_time = $var; - - return $this; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * The total number of assets matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @return int - */ - public function getTotalSize() - { - return $this->total_size; - } - - /** - * The total number of assets matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @param int $var - * @return $this - */ - public function setTotalSize($var) - { - GPBUtil::checkInt32($var); - $this->total_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse/ListAssetsResult.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse/ListAssetsResult.php deleted file mode 100644 index 32294763c7cc..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse/ListAssetsResult.php +++ /dev/null @@ -1,114 +0,0 @@ -google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult - */ -class ListAssetsResult extends \Google\Protobuf\Internal\Message -{ - /** - * Asset matching the search request. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Asset asset = 1; - */ - protected $asset = null; - /** - * State change of the asset between the points in time. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult.StateChange state_change = 2; - */ - protected $state_change = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1\Asset $asset - * Asset matching the search request. - * @type int $state_change - * State change of the asset between the points in time. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Asset matching the search request. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Asset asset = 1; - * @return \Google\Cloud\SecurityCenter\V1\Asset|null - */ - public function getAsset() - { - return $this->asset; - } - - public function hasAsset() - { - return isset($this->asset); - } - - public function clearAsset() - { - unset($this->asset); - } - - /** - * Asset matching the search request. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Asset asset = 1; - * @param \Google\Cloud\SecurityCenter\V1\Asset $var - * @return $this - */ - public function setAsset($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Asset::class); - $this->asset = $var; - - return $this; - } - - /** - * State change of the asset between the points in time. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult.StateChange state_change = 2; - * @return int - */ - public function getStateChange() - { - return $this->state_change; - } - - /** - * State change of the asset between the points in time. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult.StateChange state_change = 2; - * @param int $var - * @return $this - */ - public function setStateChange($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\ListAssetsResponse\ListAssetsResult\StateChange::class); - $this->state_change = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ListAssetsResult::class, \Google\Cloud\SecurityCenter\V1\ListAssetsResponse_ListAssetsResult::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse/ListAssetsResult/StateChange.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse/ListAssetsResult/StateChange.php deleted file mode 100644 index 54ae768528cb..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListAssetsResponse/ListAssetsResult/StateChange.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.securitycenter.v1.ListAssetsResponse.ListAssetsResult.StateChange - */ -class StateChange -{ - /** - * State change is unused, this is the canonical default for this enum. - * - * Generated from protobuf enum UNUSED = 0; - */ - const UNUSED = 0; - /** - * Asset was added between the points in time. - * - * Generated from protobuf enum ADDED = 1; - */ - const ADDED = 1; - /** - * Asset was removed between the points in time. - * - * Generated from protobuf enum REMOVED = 2; - */ - const REMOVED = 2; - /** - * Asset was present at both point(s) in time. - * - * Generated from protobuf enum ACTIVE = 3; - */ - const ACTIVE = 3; - - private static $valueToName = [ - self::UNUSED => 'UNUSED', - self::ADDED => 'ADDED', - self::REMOVED => 'REMOVED', - self::ACTIVE => 'ACTIVE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(StateChange::class, \Google\Cloud\SecurityCenter\V1\ListAssetsResponse_ListAssetsResult_StateChange::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListBigQueryExportsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListBigQueryExportsRequest.php deleted file mode 100644 index eef9cf7d0748..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListBigQueryExportsRequest.php +++ /dev/null @@ -1,184 +0,0 @@ -google.cloud.securitycenter.v1.ListBigQueryExportsRequest - */ -class ListBigQueryExportsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent, which owns the collection of BigQuery exports. Its - * format is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListBigQueryExports` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListBigQueryExports` - * must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. The parent, which owns the collection of BigQuery exports. Its - * format is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]". Please see - * {@see SecurityCenterClient::projectName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V1\ListBigQueryExportsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent, which owns the collection of BigQuery exports. Its - * format is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]". - * @type int $page_size - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * @type string $page_token - * A page token, received from a previous `ListBigQueryExports` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListBigQueryExports` - * must match the call that provided the page token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent, which owns the collection of BigQuery exports. Its - * format is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent, which owns the collection of BigQuery exports. Its - * format is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * A page token, received from a previous `ListBigQueryExports` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListBigQueryExports` - * must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A page token, received from a previous `ListBigQueryExports` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListBigQueryExports` - * must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListBigQueryExportsResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListBigQueryExportsResponse.php deleted file mode 100644 index 6a4c6adae970..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListBigQueryExportsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.securitycenter.v1.ListBigQueryExportsResponse - */ -class ListBigQueryExportsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The BigQuery exports from the specified parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.BigQueryExport big_query_exports = 1; - */ - private $big_query_exports; - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1\BigQueryExport>|\Google\Protobuf\Internal\RepeatedField $big_query_exports - * The BigQuery exports from the specified parent. - * @type string $next_page_token - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * The BigQuery exports from the specified parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.BigQueryExport big_query_exports = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getBigQueryExports() - { - return $this->big_query_exports; - } - - /** - * The BigQuery exports from the specified parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.BigQueryExport big_query_exports = 1; - * @param array<\Google\Cloud\SecurityCenter\V1\BigQueryExport>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setBigQueryExports($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\BigQueryExport::class); - $this->big_query_exports = $arr; - - return $this; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListDescendantSecurityHealthAnalyticsCustomModulesRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListDescendantSecurityHealthAnalyticsCustomModulesRequest.php deleted file mode 100644 index cea1a56e75a1..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListDescendantSecurityHealthAnalyticsCustomModulesRequest.php +++ /dev/null @@ -1,169 +0,0 @@ -google.cloud.securitycenter.v1.ListDescendantSecurityHealthAnalyticsCustomModulesRequest - */ -class ListDescendantSecurityHealthAnalyticsCustomModulesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of parent to list descendant custom modules. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The value returned by the last call indicating a continuation - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. Name of parent to list descendant custom modules. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * Please see {@see SecurityCenterClient::securityHealthAnalyticsSettingsName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V1\ListDescendantSecurityHealthAnalyticsCustomModulesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Name of parent to list descendant custom modules. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * @type string $page_token - * The value returned by the last call indicating a continuation - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of parent to list descendant custom modules. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Name of parent to list descendant custom modules. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The value returned by the last call indicating a continuation - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last call indicating a continuation - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListDescendantSecurityHealthAnalyticsCustomModulesResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListDescendantSecurityHealthAnalyticsCustomModulesResponse.php deleted file mode 100644 index 765ae2dcf51f..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListDescendantSecurityHealthAnalyticsCustomModulesResponse.php +++ /dev/null @@ -1,106 +0,0 @@ -google.cloud.securitycenter.v1.ListDescendantSecurityHealthAnalyticsCustomModulesResponse - */ -class ListDescendantSecurityHealthAnalyticsCustomModulesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Custom modules belonging to the requested parent and its descendants. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_modules = 1; - */ - private $security_health_analytics_custom_modules; - /** - * If not empty, indicates that there may be more custom modules to be - * returned. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule>|\Google\Protobuf\Internal\RepeatedField $security_health_analytics_custom_modules - * Custom modules belonging to the requested parent and its descendants. - * @type string $next_page_token - * If not empty, indicates that there may be more custom modules to be - * returned. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Custom modules belonging to the requested parent and its descendants. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_modules = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSecurityHealthAnalyticsCustomModules() - { - return $this->security_health_analytics_custom_modules; - } - - /** - * Custom modules belonging to the requested parent and its descendants. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_modules = 1; - * @param array<\Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSecurityHealthAnalyticsCustomModules($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule::class); - $this->security_health_analytics_custom_modules = $arr; - - return $this; - } - - /** - * If not empty, indicates that there may be more custom modules to be - * returned. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If not empty, indicates that there may be more custom modules to be - * returned. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListEffectiveSecurityHealthAnalyticsCustomModulesRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListEffectiveSecurityHealthAnalyticsCustomModulesRequest.php deleted file mode 100644 index b1f166b2b70a..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListEffectiveSecurityHealthAnalyticsCustomModulesRequest.php +++ /dev/null @@ -1,169 +0,0 @@ -google.cloud.securitycenter.v1.ListEffectiveSecurityHealthAnalyticsCustomModulesRequest - */ -class ListEffectiveSecurityHealthAnalyticsCustomModulesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of parent to list effective custom modules. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The value returned by the last call indicating a continuation - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. Name of parent to list effective custom modules. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * Please see {@see SecurityCenterClient::securityHealthAnalyticsSettingsName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V1\ListEffectiveSecurityHealthAnalyticsCustomModulesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Name of parent to list effective custom modules. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * @type string $page_token - * The value returned by the last call indicating a continuation - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of parent to list effective custom modules. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Name of parent to list effective custom modules. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The value returned by the last call indicating a continuation - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last call indicating a continuation - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListEffectiveSecurityHealthAnalyticsCustomModulesResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListEffectiveSecurityHealthAnalyticsCustomModulesResponse.php deleted file mode 100644 index 5a7206c77cdb..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListEffectiveSecurityHealthAnalyticsCustomModulesResponse.php +++ /dev/null @@ -1,106 +0,0 @@ -google.cloud.securitycenter.v1.ListEffectiveSecurityHealthAnalyticsCustomModulesResponse - */ -class ListEffectiveSecurityHealthAnalyticsCustomModulesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Effective custom modules belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule effective_security_health_analytics_custom_modules = 1; - */ - private $effective_security_health_analytics_custom_modules; - /** - * If not empty, indicates that there may be more effective custom modules to - * be returned. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1\EffectiveSecurityHealthAnalyticsCustomModule>|\Google\Protobuf\Internal\RepeatedField $effective_security_health_analytics_custom_modules - * Effective custom modules belonging to the requested parent. - * @type string $next_page_token - * If not empty, indicates that there may be more effective custom modules to - * be returned. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Effective custom modules belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule effective_security_health_analytics_custom_modules = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getEffectiveSecurityHealthAnalyticsCustomModules() - { - return $this->effective_security_health_analytics_custom_modules; - } - - /** - * Effective custom modules belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.EffectiveSecurityHealthAnalyticsCustomModule effective_security_health_analytics_custom_modules = 1; - * @param array<\Google\Cloud\SecurityCenter\V1\EffectiveSecurityHealthAnalyticsCustomModule>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setEffectiveSecurityHealthAnalyticsCustomModules($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\EffectiveSecurityHealthAnalyticsCustomModule::class); - $this->effective_security_health_analytics_custom_modules = $arr; - - return $this; - } - - /** - * If not empty, indicates that there may be more effective custom modules to - * be returned. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If not empty, indicates that there may be more effective custom modules to - * be returned. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsRequest.php deleted file mode 100644 index 20a7ef23ff7f..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsRequest.php +++ /dev/null @@ -1,735 +0,0 @@ -google.cloud.securitycenter.v1.ListFindingsRequest - */ -class ListFindingsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the source the findings belong to. Its format is - * "organizations/[organization_id]/sources/[source_id], - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]". To list across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or - * projects/{projects_id}/sources/- - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * severity: `=`, `:` - * * workflow_state: `=`, `:` - * * security_marks.marks: `=`, `:` - * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * For example, `source_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * * resource: - * * resource.name: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.type: `=`, `:` - * * resource.folders.resource_folder: `=`, `:` - * * resource.display_name: `=`, `:` - * - * Generated from protobuf field string filter = 2; - */ - protected $filter = ''; - /** - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,source_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,source_properties.a_property" and " - * name desc , source_properties.a_property " are equivalent. - * The following fields are supported: - * name - * parent - * state - * category - * resource_name - * event_time - * source_properties - * security_marks.marks - * - * Generated from protobuf field string order_by = 3; - */ - protected $order_by = ''; - /** - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; - */ - protected $read_time = null; - /** - * When compare_duration is set, the ListFindingsResult's "state_change" - * attribute is updated to indicate whether the finding had its state changed, - * the finding's state remained unchanged, or if the finding was added in any - * state during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * Possible "state_change" values when compare_duration is specified: - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present at - * read_time. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; - */ - protected $compare_duration = null; - /** - * A field mask to specify the Finding fields to be listed in the response. - * An empty field mask will list all fields. - * - * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; - */ - protected $field_mask = null; - /** - * The value returned by the last `ListFindingsResponse`; indicates - * that this is a continuation of a prior `ListFindings` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 8; - */ - protected $page_token = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 9; - */ - protected $page_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Name of the source the findings belong to. Its format is - * "organizations/[organization_id]/sources/[source_id], - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]". To list across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or - * projects/{projects_id}/sources/- - * @type string $filter - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * severity: `=`, `:` - * * workflow_state: `=`, `:` - * * security_marks.marks: `=`, `:` - * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * For example, `source_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * * resource: - * * resource.name: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.type: `=`, `:` - * * resource.folders.resource_folder: `=`, `:` - * * resource.display_name: `=`, `:` - * @type string $order_by - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,source_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,source_properties.a_property" and " - * name desc , source_properties.a_property " are equivalent. - * The following fields are supported: - * name - * parent - * state - * category - * resource_name - * event_time - * source_properties - * security_marks.marks - * @type \Google\Protobuf\Timestamp $read_time - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * @type \Google\Protobuf\Duration $compare_duration - * When compare_duration is set, the ListFindingsResult's "state_change" - * attribute is updated to indicate whether the finding had its state changed, - * the finding's state remained unchanged, or if the finding was added in any - * state during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * Possible "state_change" values when compare_duration is specified: - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present at - * read_time. - * @type \Google\Protobuf\FieldMask $field_mask - * A field mask to specify the Finding fields to be listed in the response. - * An empty field mask will list all fields. - * @type string $page_token - * The value returned by the last `ListFindingsResponse`; indicates - * that this is a continuation of a prior `ListFindings` call, and - * that the system should return the next page of data. - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the source the findings belong to. Its format is - * "organizations/[organization_id]/sources/[source_id], - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]". To list across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or - * projects/{projects_id}/sources/- - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Name of the source the findings belong to. Its format is - * "organizations/[organization_id]/sources/[source_id], - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]". To list across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or - * projects/{projects_id}/sources/- - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * severity: `=`, `:` - * * workflow_state: `=`, `:` - * * security_marks.marks: `=`, `:` - * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * For example, `source_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * * resource: - * * resource.name: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.type: `=`, `:` - * * resource.folders.resource_folder: `=`, `:` - * * resource.display_name: `=`, `:` - * - * Generated from protobuf field string filter = 2; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * severity: `=`, `:` - * * workflow_state: `=`, `:` - * * security_marks.marks: `=`, `:` - * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * For example, `source_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * * resource: - * * resource.name: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.type: `=`, `:` - * * resource.folders.resource_folder: `=`, `:` - * * resource.display_name: `=`, `:` - * - * Generated from protobuf field string filter = 2; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,source_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,source_properties.a_property" and " - * name desc , source_properties.a_property " are equivalent. - * The following fields are supported: - * name - * parent - * state - * category - * resource_name - * event_time - * source_properties - * security_marks.marks - * - * Generated from protobuf field string order_by = 3; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,source_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,source_properties.a_property" and " - * name desc , source_properties.a_property " are equivalent. - * The following fields are supported: - * name - * parent - * state - * category - * resource_name - * event_time - * source_properties - * security_marks.marks - * - * Generated from protobuf field string order_by = 3; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - - /** - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; - * @return \Google\Protobuf\Timestamp|null - */ - public function getReadTime() - { - return $this->read_time; - } - - public function hasReadTime() - { - return isset($this->read_time); - } - - public function clearReadTime() - { - unset($this->read_time); - } - - /** - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setReadTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->read_time = $var; - - return $this; - } - - /** - * When compare_duration is set, the ListFindingsResult's "state_change" - * attribute is updated to indicate whether the finding had its state changed, - * the finding's state remained unchanged, or if the finding was added in any - * state during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * Possible "state_change" values when compare_duration is specified: - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present at - * read_time. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; - * @return \Google\Protobuf\Duration|null - */ - public function getCompareDuration() - { - return $this->compare_duration; - } - - public function hasCompareDuration() - { - return isset($this->compare_duration); - } - - public function clearCompareDuration() - { - unset($this->compare_duration); - } - - /** - * When compare_duration is set, the ListFindingsResult's "state_change" - * attribute is updated to indicate whether the finding had its state changed, - * the finding's state remained unchanged, or if the finding was added in any - * state during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * Possible "state_change" values when compare_duration is specified: - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present at - * read_time. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setCompareDuration($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->compare_duration = $var; - - return $this; - } - - /** - * A field mask to specify the Finding fields to be listed in the response. - * An empty field mask will list all fields. - * - * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; - * @return \Google\Protobuf\FieldMask|null - */ - public function getFieldMask() - { - return $this->field_mask; - } - - public function hasFieldMask() - { - return isset($this->field_mask); - } - - public function clearFieldMask() - { - unset($this->field_mask); - } - - /** - * A field mask to specify the Finding fields to be listed in the response. - * An empty field mask will list all fields. - * - * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setFieldMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->field_mask = $var; - - return $this; - } - - /** - * The value returned by the last `ListFindingsResponse`; indicates - * that this is a continuation of a prior `ListFindings` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 8; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListFindingsResponse`; indicates - * that this is a continuation of a prior `ListFindings` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 8; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 9; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 9; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse.php deleted file mode 100644 index f0f409419e18..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse.php +++ /dev/null @@ -1,183 +0,0 @@ -google.cloud.securitycenter.v1.ListFindingsResponse - */ -class ListFindingsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Findings matching the list request. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult list_findings_results = 1; - */ - private $list_findings_results; - /** - * Time used for executing the list request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - */ - protected $read_time = null; - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - */ - protected $next_page_token = ''; - /** - * The total number of findings matching the query. - * - * Generated from protobuf field int32 total_size = 4; - */ - protected $total_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1\ListFindingsResponse\ListFindingsResult>|\Google\Protobuf\Internal\RepeatedField $list_findings_results - * Findings matching the list request. - * @type \Google\Protobuf\Timestamp $read_time - * Time used for executing the list request. - * @type string $next_page_token - * Token to retrieve the next page of results, or empty if there are no more - * results. - * @type int $total_size - * The total number of findings matching the query. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Findings matching the list request. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult list_findings_results = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getListFindingsResults() - { - return $this->list_findings_results; - } - - /** - * Findings matching the list request. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult list_findings_results = 1; - * @param array<\Google\Cloud\SecurityCenter\V1\ListFindingsResponse\ListFindingsResult>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setListFindingsResults($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\ListFindingsResponse\ListFindingsResult::class); - $this->list_findings_results = $arr; - - return $this; - } - - /** - * Time used for executing the list request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getReadTime() - { - return $this->read_time; - } - - public function hasReadTime() - { - return isset($this->read_time); - } - - public function clearReadTime() - { - unset($this->read_time); - } - - /** - * Time used for executing the list request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setReadTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->read_time = $var; - - return $this; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * The total number of findings matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @return int - */ - public function getTotalSize() - { - return $this->total_size; - } - - /** - * The total number of findings matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @param int $var - * @return $this - */ - public function setTotalSize($var) - { - GPBUtil::checkInt32($var); - $this->total_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult.php deleted file mode 100644 index f24a6f2dedd5..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult.php +++ /dev/null @@ -1,158 +0,0 @@ -google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult - */ -class ListFindingsResult extends \Google\Protobuf\Internal\Message -{ - /** - * Finding matching the search request. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 1; - */ - protected $finding = null; - /** - * State change of the finding between the points in time. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.StateChange state_change = 2; - */ - protected $state_change = 0; - /** - * Output only. Resource that is associated with this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.Resource resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $resource = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1\Finding $finding - * Finding matching the search request. - * @type int $state_change - * State change of the finding between the points in time. - * @type \Google\Cloud\SecurityCenter\V1\ListFindingsResponse\ListFindingsResult\Resource $resource - * Output only. Resource that is associated with this finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Finding matching the search request. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 1; - * @return \Google\Cloud\SecurityCenter\V1\Finding|null - */ - public function getFinding() - { - return $this->finding; - } - - public function hasFinding() - { - return isset($this->finding); - } - - public function clearFinding() - { - unset($this->finding); - } - - /** - * Finding matching the search request. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 1; - * @param \Google\Cloud\SecurityCenter\V1\Finding $var - * @return $this - */ - public function setFinding($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Finding::class); - $this->finding = $var; - - return $this; - } - - /** - * State change of the finding between the points in time. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.StateChange state_change = 2; - * @return int - */ - public function getStateChange() - { - return $this->state_change; - } - - /** - * State change of the finding between the points in time. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.StateChange state_change = 2; - * @param int $var - * @return $this - */ - public function setStateChange($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\ListFindingsResponse\ListFindingsResult\StateChange::class); - $this->state_change = $var; - - return $this; - } - - /** - * Output only. Resource that is associated with this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.Resource resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\SecurityCenter\V1\ListFindingsResponse\ListFindingsResult\Resource|null - */ - public function getResource() - { - return $this->resource; - } - - public function hasResource() - { - return isset($this->resource); - } - - public function clearResource() - { - unset($this->resource); - } - - /** - * Output only. Resource that is associated with this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.Resource resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\SecurityCenter\V1\ListFindingsResponse\ListFindingsResult\Resource $var - * @return $this - */ - public function setResource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\ListFindingsResponse\ListFindingsResult\Resource::class); - $this->resource = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ListFindingsResult::class, \Google\Cloud\SecurityCenter\V1\ListFindingsResponse_ListFindingsResult::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult/Resource.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult/Resource.php deleted file mode 100644 index be2d2d246150..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult/Resource.php +++ /dev/null @@ -1,321 +0,0 @@ -google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.Resource - */ -class Resource extends \Google\Protobuf\Internal\Message -{ - /** - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The human readable name of the resource. - * - * Generated from protobuf field string display_name = 8; - */ - protected $display_name = ''; - /** - * The full resource type of the resource. - * - * Generated from protobuf field string type = 6; - */ - protected $type = ''; - /** - * The full resource name of project that the resource belongs to. - * - * Generated from protobuf field string project_name = 2; - */ - protected $project_name = ''; - /** - * The project ID that the resource belongs to. - * - * Generated from protobuf field string project_display_name = 3; - */ - protected $project_display_name = ''; - /** - * The full resource name of resource's parent. - * - * Generated from protobuf field string parent_name = 4; - */ - protected $parent_name = ''; - /** - * The human readable name of resource's parent. - * - * Generated from protobuf field string parent_display_name = 5; - */ - protected $parent_display_name = ''; - /** - * Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is - * the folder directly under the Organization. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Folder folders = 7; - */ - private $folders; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * @type string $display_name - * The human readable name of the resource. - * @type string $type - * The full resource type of the resource. - * @type string $project_name - * The full resource name of project that the resource belongs to. - * @type string $project_display_name - * The project ID that the resource belongs to. - * @type string $parent_name - * The full resource name of resource's parent. - * @type string $parent_display_name - * The human readable name of resource's parent. - * @type array<\Google\Cloud\SecurityCenter\V1\Folder>|\Google\Protobuf\Internal\RepeatedField $folders - * Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is - * the folder directly under the Organization. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The human readable name of the resource. - * - * Generated from protobuf field string display_name = 8; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * The human readable name of the resource. - * - * Generated from protobuf field string display_name = 8; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * The full resource type of the resource. - * - * Generated from protobuf field string type = 6; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * The full resource type of the resource. - * - * Generated from protobuf field string type = 6; - * @param string $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkString($var, True); - $this->type = $var; - - return $this; - } - - /** - * The full resource name of project that the resource belongs to. - * - * Generated from protobuf field string project_name = 2; - * @return string - */ - public function getProjectName() - { - return $this->project_name; - } - - /** - * The full resource name of project that the resource belongs to. - * - * Generated from protobuf field string project_name = 2; - * @param string $var - * @return $this - */ - public function setProjectName($var) - { - GPBUtil::checkString($var, True); - $this->project_name = $var; - - return $this; - } - - /** - * The project ID that the resource belongs to. - * - * Generated from protobuf field string project_display_name = 3; - * @return string - */ - public function getProjectDisplayName() - { - return $this->project_display_name; - } - - /** - * The project ID that the resource belongs to. - * - * Generated from protobuf field string project_display_name = 3; - * @param string $var - * @return $this - */ - public function setProjectDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->project_display_name = $var; - - return $this; - } - - /** - * The full resource name of resource's parent. - * - * Generated from protobuf field string parent_name = 4; - * @return string - */ - public function getParentName() - { - return $this->parent_name; - } - - /** - * The full resource name of resource's parent. - * - * Generated from protobuf field string parent_name = 4; - * @param string $var - * @return $this - */ - public function setParentName($var) - { - GPBUtil::checkString($var, True); - $this->parent_name = $var; - - return $this; - } - - /** - * The human readable name of resource's parent. - * - * Generated from protobuf field string parent_display_name = 5; - * @return string - */ - public function getParentDisplayName() - { - return $this->parent_display_name; - } - - /** - * The human readable name of resource's parent. - * - * Generated from protobuf field string parent_display_name = 5; - * @param string $var - * @return $this - */ - public function setParentDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->parent_display_name = $var; - - return $this; - } - - /** - * Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is - * the folder directly under the Organization. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Folder folders = 7; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFolders() - { - return $this->folders; - } - - /** - * Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is - * the folder directly under the Organization. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Folder folders = 7; - * @param array<\Google\Cloud\SecurityCenter\V1\Folder>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFolders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Folder::class); - $this->folders = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Resource::class, \Google\Cloud\SecurityCenter\V1\ListFindingsResponse_ListFindingsResult_Resource::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult/StateChange.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult/StateChange.php deleted file mode 100644 index f723d59d4747..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListFindingsResponse/ListFindingsResult/StateChange.php +++ /dev/null @@ -1,87 +0,0 @@ -google.cloud.securitycenter.v1.ListFindingsResponse.ListFindingsResult.StateChange - */ -class StateChange -{ - /** - * State change is unused, this is the canonical default for this enum. - * - * Generated from protobuf enum UNUSED = 0; - */ - const UNUSED = 0; - /** - * The finding has changed state in some way between the points in time - * and existed at both points. - * - * Generated from protobuf enum CHANGED = 1; - */ - const CHANGED = 1; - /** - * The finding has not changed state between the points in time and - * existed at both points. - * - * Generated from protobuf enum UNCHANGED = 2; - */ - const UNCHANGED = 2; - /** - * The finding was created between the points in time. - * - * Generated from protobuf enum ADDED = 3; - */ - const ADDED = 3; - /** - * The finding at timestamp does not match the filter specified, but it - * did at timestamp - compare_duration. - * - * Generated from protobuf enum REMOVED = 4; - */ - const REMOVED = 4; - - private static $valueToName = [ - self::UNUSED => 'UNUSED', - self::CHANGED => 'CHANGED', - self::UNCHANGED => 'UNCHANGED', - self::ADDED => 'ADDED', - self::REMOVED => 'REMOVED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(StateChange::class, \Google\Cloud\SecurityCenter\V1\ListFindingsResponse_ListFindingsResult_StateChange::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListMuteConfigsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListMuteConfigsRequest.php deleted file mode 100644 index 9fd7c1ca01cc..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListMuteConfigsRequest.php +++ /dev/null @@ -1,184 +0,0 @@ -google.cloud.securitycenter.v1.ListMuteConfigsRequest - */ -class ListMuteConfigsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent, which owns the collection of mute configs. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListMuteConfigs` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListMuteConfigs` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. The parent, which owns the collection of mute configs. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]". Please see - * {@see SecurityCenterClient::projectName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V1\ListMuteConfigsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent, which owns the collection of mute configs. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]". - * @type int $page_size - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * @type string $page_token - * A page token, received from a previous `ListMuteConfigs` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListMuteConfigs` must - * match the call that provided the page token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent, which owns the collection of mute configs. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent, which owns the collection of mute configs. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * A page token, received from a previous `ListMuteConfigs` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListMuteConfigs` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A page token, received from a previous `ListMuteConfigs` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListMuteConfigs` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListMuteConfigsResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListMuteConfigsResponse.php deleted file mode 100644 index 31b493a80a68..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListMuteConfigsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.securitycenter.v1.ListMuteConfigsResponse - */ -class ListMuteConfigsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The mute configs from the specified parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MuteConfig mute_configs = 1; - */ - private $mute_configs; - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1\MuteConfig>|\Google\Protobuf\Internal\RepeatedField $mute_configs - * The mute configs from the specified parent. - * @type string $next_page_token - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * The mute configs from the specified parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MuteConfig mute_configs = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMuteConfigs() - { - return $this->mute_configs; - } - - /** - * The mute configs from the specified parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MuteConfig mute_configs = 1; - * @param array<\Google\Cloud\SecurityCenter\V1\MuteConfig>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMuteConfigs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\MuteConfig::class); - $this->mute_configs = $arr; - - return $this; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListNotificationConfigsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListNotificationConfigsRequest.php deleted file mode 100644 index 185cfdac2f68..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListNotificationConfigsRequest.php +++ /dev/null @@ -1,171 +0,0 @@ -google.cloud.securitycenter.v1.ListNotificationConfigsRequest - */ -class ListNotificationConfigsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the parent in which to list the notification - * configurations. Its format is "organizations/[organization_id]", - * "folders/[folder_id]", or "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The value returned by the last `ListNotificationConfigsResponse`; indicates - * that this is a continuation of a prior `ListNotificationConfigs` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 2; - */ - protected $page_token = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 3; - */ - protected $page_size = 0; - - /** - * @param string $parent Required. The name of the parent in which to list the notification - * configurations. Its format is "organizations/[organization_id]", - * "folders/[folder_id]", or "projects/[project_id]". Please see - * {@see SecurityCenterClient::projectName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V1\ListNotificationConfigsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The name of the parent in which to list the notification - * configurations. Its format is "organizations/[organization_id]", - * "folders/[folder_id]", or "projects/[project_id]". - * @type string $page_token - * The value returned by the last `ListNotificationConfigsResponse`; indicates - * that this is a continuation of a prior `ListNotificationConfigs` call, and - * that the system should return the next page of data. - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the parent in which to list the notification - * configurations. Its format is "organizations/[organization_id]", - * "folders/[folder_id]", or "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The name of the parent in which to list the notification - * configurations. Its format is "organizations/[organization_id]", - * "folders/[folder_id]", or "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The value returned by the last `ListNotificationConfigsResponse`; indicates - * that this is a continuation of a prior `ListNotificationConfigs` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 2; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListNotificationConfigsResponse`; indicates - * that this is a continuation of a prior `ListNotificationConfigs` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 2; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 3; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListNotificationConfigsResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListNotificationConfigsResponse.php deleted file mode 100644 index a6fa6d4a15b2..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListNotificationConfigsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.securitycenter.v1.ListNotificationConfigsResponse - */ -class ListNotificationConfigsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Notification configs belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.NotificationConfig notification_configs = 1; - */ - private $notification_configs; - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1\NotificationConfig>|\Google\Protobuf\Internal\RepeatedField $notification_configs - * Notification configs belonging to the requested parent. - * @type string $next_page_token - * Token to retrieve the next page of results, or empty if there are no more - * results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Notification configs belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.NotificationConfig notification_configs = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNotificationConfigs() - { - return $this->notification_configs; - } - - /** - * Notification configs belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.NotificationConfig notification_configs = 1; - * @param array<\Google\Cloud\SecurityCenter\V1\NotificationConfig>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNotificationConfigs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\NotificationConfig::class); - $this->notification_configs = $arr; - - return $this; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSecurityHealthAnalyticsCustomModulesRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSecurityHealthAnalyticsCustomModulesRequest.php deleted file mode 100644 index de60b910d294..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSecurityHealthAnalyticsCustomModulesRequest.php +++ /dev/null @@ -1,168 +0,0 @@ -google.cloud.securitycenter.v1.ListSecurityHealthAnalyticsCustomModulesRequest - */ -class ListSecurityHealthAnalyticsCustomModulesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of parent to list custom modules. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * The value returned by the last call indicating a continuation - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. Name of parent to list custom modules. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * Please see {@see SecurityCenterClient::securityHealthAnalyticsSettingsName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V1\ListSecurityHealthAnalyticsCustomModulesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Name of parent to list custom modules. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * @type string $page_token - * The value returned by the last call indicating a continuation - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of parent to list custom modules. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Name of parent to list custom modules. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * The value returned by the last call indicating a continuation - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last call indicating a continuation - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSecurityHealthAnalyticsCustomModulesResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSecurityHealthAnalyticsCustomModulesResponse.php deleted file mode 100644 index 7b27b9e9c9d1..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSecurityHealthAnalyticsCustomModulesResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.securitycenter.v1.ListSecurityHealthAnalyticsCustomModulesResponse - */ -class ListSecurityHealthAnalyticsCustomModulesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Custom modules belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_modules = 1; - */ - private $security_health_analytics_custom_modules; - /** - * If not empty, indicates that there may be more custom modules to be - * returned. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule>|\Google\Protobuf\Internal\RepeatedField $security_health_analytics_custom_modules - * Custom modules belonging to the requested parent. - * @type string $next_page_token - * If not empty, indicates that there may be more custom modules to be - * returned. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Custom modules belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_modules = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSecurityHealthAnalyticsCustomModules() - { - return $this->security_health_analytics_custom_modules; - } - - /** - * Custom modules belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_modules = 1; - * @param array<\Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSecurityHealthAnalyticsCustomModules($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule::class); - $this->security_health_analytics_custom_modules = $arr; - - return $this; - } - - /** - * If not empty, indicates that there may be more custom modules to be - * returned. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * If not empty, indicates that there may be more custom modules to be - * returned. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSourcesRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSourcesRequest.php deleted file mode 100644 index 48a8424926c5..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSourcesRequest.php +++ /dev/null @@ -1,171 +0,0 @@ -google.cloud.securitycenter.v1.ListSourcesRequest - */ -class ListSourcesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the parent of sources to list. Its format should - * be "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The value returned by the last `ListSourcesResponse`; indicates - * that this is a continuation of a prior `ListSources` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 2; - */ - protected $page_token = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 7; - */ - protected $page_size = 0; - - /** - * @param string $parent Required. Resource name of the parent of sources to list. Its format should - * be "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". Please see - * {@see SecurityCenterClient::projectName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V1\ListSourcesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the parent of sources to list. Its format should - * be "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * @type string $page_token - * The value returned by the last `ListSourcesResponse`; indicates - * that this is a continuation of a prior `ListSources` call, and - * that the system should return the next page of data. - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the parent of sources to list. Its format should - * be "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the parent of sources to list. Its format should - * be "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The value returned by the last `ListSourcesResponse`; indicates - * that this is a continuation of a prior `ListSources` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 2; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListSourcesResponse`; indicates - * that this is a continuation of a prior `ListSources` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 2; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 7; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 7; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSourcesResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSourcesResponse.php deleted file mode 100644 index 97309f3b340f..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ListSourcesResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.securitycenter.v1.ListSourcesResponse - */ -class ListSourcesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Sources belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Source sources = 1; - */ - private $sources; - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1\Source>|\Google\Protobuf\Internal\RepeatedField $sources - * Sources belonging to the requested parent. - * @type string $next_page_token - * Token to retrieve the next page of results, or empty if there are no more - * results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Sources belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Source sources = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSources() - { - return $this->sources; - } - - /** - * Sources belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Source sources = 1; - * @param array<\Google\Cloud\SecurityCenter\V1\Source>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSources($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Source::class); - $this->sources = $arr; - - return $this; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/LoadBalancer.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/LoadBalancer.php deleted file mode 100644 index b67df9f32eeb..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/LoadBalancer.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.securitycenter.v1.LoadBalancer - */ -class LoadBalancer extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the load balancer associated with the finding. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the load balancer associated with the finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\LoadBalancer::initOnce(); - parent::__construct($data); - } - - /** - * The name of the load balancer associated with the finding. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the load balancer associated with the finding. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/LogEntry.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/LogEntry.php deleted file mode 100644 index 474562b7ae80..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/LogEntry.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.securitycenter.v1.LogEntry - */ -class LogEntry extends \Google\Protobuf\Internal\Message -{ - protected $log_entry; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1\CloudLoggingEntry $cloud_logging_entry - * An individual entry in a log stored in Cloud Logging. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\LogEntry::initOnce(); - parent::__construct($data); - } - - /** - * An individual entry in a log stored in Cloud Logging. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CloudLoggingEntry cloud_logging_entry = 1; - * @return \Google\Cloud\SecurityCenter\V1\CloudLoggingEntry|null - */ - public function getCloudLoggingEntry() - { - return $this->readOneof(1); - } - - public function hasCloudLoggingEntry() - { - return $this->hasOneof(1); - } - - /** - * An individual entry in a log stored in Cloud Logging. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CloudLoggingEntry cloud_logging_entry = 1; - * @param \Google\Cloud\SecurityCenter\V1\CloudLoggingEntry $var - * @return $this - */ - public function setCloudLoggingEntry($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\CloudLoggingEntry::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getLogEntry() - { - return $this->whichOneof("log_entry"); - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack.php deleted file mode 100644 index 77ad4a2a0770..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack.php +++ /dev/null @@ -1,228 +0,0 @@ -google.cloud.securitycenter.v1.MitreAttack - */ -class MitreAttack extends \Google\Protobuf\Internal\Message -{ - /** - * The MITRE ATT&CK tactic most closely represented by this finding, if any. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.MitreAttack.Tactic primary_tactic = 1; - */ - protected $primary_tactic = 0; - /** - * The MITRE ATT&CK technique most closely represented by this finding, if - * any. primary_techniques is a repeated field because there are multiple - * levels of MITRE ATT&CK techniques. If the technique most closely - * represented by this finding is a sub-technique (e.g. `SCANNING_IP_BLOCKS`), - * both the sub-technique and its parent technique(s) will be listed (e.g. - * `SCANNING_IP_BLOCKS`, `ACTIVE_SCANNING`). - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MitreAttack.Technique primary_techniques = 2; - */ - private $primary_techniques; - /** - * Additional MITRE ATT&CK tactics related to this finding, if any. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MitreAttack.Tactic additional_tactics = 3; - */ - private $additional_tactics; - /** - * Additional MITRE ATT&CK techniques related to this finding, if any, along - * with any of their respective parent techniques. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MitreAttack.Technique additional_techniques = 4; - */ - private $additional_techniques; - /** - * The MITRE ATT&CK version referenced by the above fields. E.g. "8". - * - * Generated from protobuf field string version = 5; - */ - protected $version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $primary_tactic - * The MITRE ATT&CK tactic most closely represented by this finding, if any. - * @type array|\Google\Protobuf\Internal\RepeatedField $primary_techniques - * The MITRE ATT&CK technique most closely represented by this finding, if - * any. primary_techniques is a repeated field because there are multiple - * levels of MITRE ATT&CK techniques. If the technique most closely - * represented by this finding is a sub-technique (e.g. `SCANNING_IP_BLOCKS`), - * both the sub-technique and its parent technique(s) will be listed (e.g. - * `SCANNING_IP_BLOCKS`, `ACTIVE_SCANNING`). - * @type array|\Google\Protobuf\Internal\RepeatedField $additional_tactics - * Additional MITRE ATT&CK tactics related to this finding, if any. - * @type array|\Google\Protobuf\Internal\RepeatedField $additional_techniques - * Additional MITRE ATT&CK techniques related to this finding, if any, along - * with any of their respective parent techniques. - * @type string $version - * The MITRE ATT&CK version referenced by the above fields. E.g. "8". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\MitreAttack::initOnce(); - parent::__construct($data); - } - - /** - * The MITRE ATT&CK tactic most closely represented by this finding, if any. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.MitreAttack.Tactic primary_tactic = 1; - * @return int - */ - public function getPrimaryTactic() - { - return $this->primary_tactic; - } - - /** - * The MITRE ATT&CK tactic most closely represented by this finding, if any. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.MitreAttack.Tactic primary_tactic = 1; - * @param int $var - * @return $this - */ - public function setPrimaryTactic($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\MitreAttack\Tactic::class); - $this->primary_tactic = $var; - - return $this; - } - - /** - * The MITRE ATT&CK technique most closely represented by this finding, if - * any. primary_techniques is a repeated field because there are multiple - * levels of MITRE ATT&CK techniques. If the technique most closely - * represented by this finding is a sub-technique (e.g. `SCANNING_IP_BLOCKS`), - * both the sub-technique and its parent technique(s) will be listed (e.g. - * `SCANNING_IP_BLOCKS`, `ACTIVE_SCANNING`). - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MitreAttack.Technique primary_techniques = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPrimaryTechniques() - { - return $this->primary_techniques; - } - - /** - * The MITRE ATT&CK technique most closely represented by this finding, if - * any. primary_techniques is a repeated field because there are multiple - * levels of MITRE ATT&CK techniques. If the technique most closely - * represented by this finding is a sub-technique (e.g. `SCANNING_IP_BLOCKS`), - * both the sub-technique and its parent technique(s) will be listed (e.g. - * `SCANNING_IP_BLOCKS`, `ACTIVE_SCANNING`). - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MitreAttack.Technique primary_techniques = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPrimaryTechniques($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\SecurityCenter\V1\MitreAttack\Technique::class); - $this->primary_techniques = $arr; - - return $this; - } - - /** - * Additional MITRE ATT&CK tactics related to this finding, if any. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MitreAttack.Tactic additional_tactics = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAdditionalTactics() - { - return $this->additional_tactics; - } - - /** - * Additional MITRE ATT&CK tactics related to this finding, if any. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MitreAttack.Tactic additional_tactics = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAdditionalTactics($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\SecurityCenter\V1\MitreAttack\Tactic::class); - $this->additional_tactics = $arr; - - return $this; - } - - /** - * Additional MITRE ATT&CK techniques related to this finding, if any, along - * with any of their respective parent techniques. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MitreAttack.Technique additional_techniques = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAdditionalTechniques() - { - return $this->additional_techniques; - } - - /** - * Additional MITRE ATT&CK techniques related to this finding, if any, along - * with any of their respective parent techniques. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.MitreAttack.Technique additional_techniques = 4; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAdditionalTechniques($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\SecurityCenter\V1\MitreAttack\Technique::class); - $this->additional_techniques = $arr; - - return $this; - } - - /** - * The MITRE ATT&CK version referenced by the above fields. E.g. "8". - * - * Generated from protobuf field string version = 5; - * @return string - */ - public function getVersion() - { - return $this->version; - } - - /** - * The MITRE ATT&CK version referenced by the above fields. E.g. "8". - * - * Generated from protobuf field string version = 5; - * @param string $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkString($var, True); - $this->version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack/Tactic.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack/Tactic.php deleted file mode 100644 index d59277981594..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack/Tactic.php +++ /dev/null @@ -1,149 +0,0 @@ -google.cloud.securitycenter.v1.MitreAttack.Tactic - */ -class Tactic -{ - /** - * Unspecified value. - * - * Generated from protobuf enum TACTIC_UNSPECIFIED = 0; - */ - const TACTIC_UNSPECIFIED = 0; - /** - * TA0043 - * - * Generated from protobuf enum RECONNAISSANCE = 1; - */ - const RECONNAISSANCE = 1; - /** - * TA0042 - * - * Generated from protobuf enum RESOURCE_DEVELOPMENT = 2; - */ - const RESOURCE_DEVELOPMENT = 2; - /** - * TA0001 - * - * Generated from protobuf enum INITIAL_ACCESS = 5; - */ - const INITIAL_ACCESS = 5; - /** - * TA0002 - * - * Generated from protobuf enum EXECUTION = 3; - */ - const EXECUTION = 3; - /** - * TA0003 - * - * Generated from protobuf enum PERSISTENCE = 6; - */ - const PERSISTENCE = 6; - /** - * TA0004 - * - * Generated from protobuf enum PRIVILEGE_ESCALATION = 8; - */ - const PRIVILEGE_ESCALATION = 8; - /** - * TA0005 - * - * Generated from protobuf enum DEFENSE_EVASION = 7; - */ - const DEFENSE_EVASION = 7; - /** - * TA0006 - * - * Generated from protobuf enum CREDENTIAL_ACCESS = 9; - */ - const CREDENTIAL_ACCESS = 9; - /** - * TA0007 - * - * Generated from protobuf enum DISCOVERY = 10; - */ - const DISCOVERY = 10; - /** - * TA0008 - * - * Generated from protobuf enum LATERAL_MOVEMENT = 11; - */ - const LATERAL_MOVEMENT = 11; - /** - * TA0009 - * - * Generated from protobuf enum COLLECTION = 12; - */ - const COLLECTION = 12; - /** - * TA0011 - * - * Generated from protobuf enum COMMAND_AND_CONTROL = 4; - */ - const COMMAND_AND_CONTROL = 4; - /** - * TA0010 - * - * Generated from protobuf enum EXFILTRATION = 13; - */ - const EXFILTRATION = 13; - /** - * TA0040 - * - * Generated from protobuf enum IMPACT = 14; - */ - const IMPACT = 14; - - private static $valueToName = [ - self::TACTIC_UNSPECIFIED => 'TACTIC_UNSPECIFIED', - self::RECONNAISSANCE => 'RECONNAISSANCE', - self::RESOURCE_DEVELOPMENT => 'RESOURCE_DEVELOPMENT', - self::INITIAL_ACCESS => 'INITIAL_ACCESS', - self::EXECUTION => 'EXECUTION', - self::PERSISTENCE => 'PERSISTENCE', - self::PRIVILEGE_ESCALATION => 'PRIVILEGE_ESCALATION', - self::DEFENSE_EVASION => 'DEFENSE_EVASION', - self::CREDENTIAL_ACCESS => 'CREDENTIAL_ACCESS', - self::DISCOVERY => 'DISCOVERY', - self::LATERAL_MOVEMENT => 'LATERAL_MOVEMENT', - self::COLLECTION => 'COLLECTION', - self::COMMAND_AND_CONTROL => 'COMMAND_AND_CONTROL', - self::EXFILTRATION => 'EXFILTRATION', - self::IMPACT => 'IMPACT', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Tactic::class, \Google\Cloud\SecurityCenter\V1\MitreAttack_Tactic::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack/Technique.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack/Technique.php deleted file mode 100644 index 967ff400fc7e..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MitreAttack/Technique.php +++ /dev/null @@ -1,458 +0,0 @@ -google.cloud.securitycenter.v1.MitreAttack.Technique - */ -class Technique -{ - /** - * Unspecified value. - * - * Generated from protobuf enum TECHNIQUE_UNSPECIFIED = 0; - */ - const TECHNIQUE_UNSPECIFIED = 0; - /** - * T1036 - * - * Generated from protobuf enum MASQUERADING = 49; - */ - const MASQUERADING = 49; - /** - * T1036.005 - * - * Generated from protobuf enum MATCH_LEGITIMATE_NAME_OR_LOCATION = 50; - */ - const MATCH_LEGITIMATE_NAME_OR_LOCATION = 50; - /** - * T1037 - * - * Generated from protobuf enum BOOT_OR_LOGON_INITIALIZATION_SCRIPTS = 37; - */ - const BOOT_OR_LOGON_INITIALIZATION_SCRIPTS = 37; - /** - * T1037.005 - * - * Generated from protobuf enum STARTUP_ITEMS = 38; - */ - const STARTUP_ITEMS = 38; - /** - * T1046 - * - * Generated from protobuf enum NETWORK_SERVICE_DISCOVERY = 32; - */ - const NETWORK_SERVICE_DISCOVERY = 32; - /** - * T1057 - * - * Generated from protobuf enum PROCESS_DISCOVERY = 56; - */ - const PROCESS_DISCOVERY = 56; - /** - * T1059 - * - * Generated from protobuf enum COMMAND_AND_SCRIPTING_INTERPRETER = 6; - */ - const COMMAND_AND_SCRIPTING_INTERPRETER = 6; - /** - * T1059.004 - * - * Generated from protobuf enum UNIX_SHELL = 7; - */ - const UNIX_SHELL = 7; - /** - * T1069 - * - * Generated from protobuf enum PERMISSION_GROUPS_DISCOVERY = 18; - */ - const PERMISSION_GROUPS_DISCOVERY = 18; - /** - * T1069.003 - * - * Generated from protobuf enum CLOUD_GROUPS = 19; - */ - const CLOUD_GROUPS = 19; - /** - * T1071 - * - * Generated from protobuf enum APPLICATION_LAYER_PROTOCOL = 45; - */ - const APPLICATION_LAYER_PROTOCOL = 45; - /** - * T1071.004 - * - * Generated from protobuf enum DNS = 46; - */ - const DNS = 46; - /** - * T1072 - * - * Generated from protobuf enum SOFTWARE_DEPLOYMENT_TOOLS = 47; - */ - const SOFTWARE_DEPLOYMENT_TOOLS = 47; - /** - * T1078 - * - * Generated from protobuf enum VALID_ACCOUNTS = 14; - */ - const VALID_ACCOUNTS = 14; - /** - * T1078.001 - * - * Generated from protobuf enum DEFAULT_ACCOUNTS = 35; - */ - const DEFAULT_ACCOUNTS = 35; - /** - * T1078.003 - * - * Generated from protobuf enum LOCAL_ACCOUNTS = 15; - */ - const LOCAL_ACCOUNTS = 15; - /** - * T1078.004 - * - * Generated from protobuf enum CLOUD_ACCOUNTS = 16; - */ - const CLOUD_ACCOUNTS = 16; - /** - * T1090 - * - * Generated from protobuf enum PROXY = 9; - */ - const PROXY = 9; - /** - * T1090.002 - * - * Generated from protobuf enum EXTERNAL_PROXY = 10; - */ - const EXTERNAL_PROXY = 10; - /** - * T1090.003 - * - * Generated from protobuf enum MULTI_HOP_PROXY = 11; - */ - const MULTI_HOP_PROXY = 11; - /** - * T1098 - * - * Generated from protobuf enum ACCOUNT_MANIPULATION = 22; - */ - const ACCOUNT_MANIPULATION = 22; - /** - * T1098.001 - * - * Generated from protobuf enum ADDITIONAL_CLOUD_CREDENTIALS = 40; - */ - const ADDITIONAL_CLOUD_CREDENTIALS = 40; - /** - * T1098.004 - * - * Generated from protobuf enum SSH_AUTHORIZED_KEYS = 23; - */ - const SSH_AUTHORIZED_KEYS = 23; - /** - * T1098.006 - * - * Generated from protobuf enum ADDITIONAL_CONTAINER_CLUSTER_ROLES = 58; - */ - const ADDITIONAL_CONTAINER_CLUSTER_ROLES = 58; - /** - * T1105 - * - * Generated from protobuf enum INGRESS_TOOL_TRANSFER = 3; - */ - const INGRESS_TOOL_TRANSFER = 3; - /** - * T1106 - * - * Generated from protobuf enum NATIVE_API = 4; - */ - const NATIVE_API = 4; - /** - * T1110 - * - * Generated from protobuf enum BRUTE_FORCE = 44; - */ - const BRUTE_FORCE = 44; - /** - * T1129 - * - * Generated from protobuf enum SHARED_MODULES = 5; - */ - const SHARED_MODULES = 5; - /** - * T1134 - * - * Generated from protobuf enum ACCESS_TOKEN_MANIPULATION = 33; - */ - const ACCESS_TOKEN_MANIPULATION = 33; - /** - * T1134.001 - * - * Generated from protobuf enum TOKEN_IMPERSONATION_OR_THEFT = 39; - */ - const TOKEN_IMPERSONATION_OR_THEFT = 39; - /** - * T1190 - * - * Generated from protobuf enum EXPLOIT_PUBLIC_FACING_APPLICATION = 27; - */ - const EXPLOIT_PUBLIC_FACING_APPLICATION = 27; - /** - * T1484 - * - * Generated from protobuf enum DOMAIN_POLICY_MODIFICATION = 30; - */ - const DOMAIN_POLICY_MODIFICATION = 30; - /** - * T1485 - * - * Generated from protobuf enum DATA_DESTRUCTION = 29; - */ - const DATA_DESTRUCTION = 29; - /** - * T1489 - * - * Generated from protobuf enum SERVICE_STOP = 52; - */ - const SERVICE_STOP = 52; - /** - * T1490 - * - * Generated from protobuf enum INHIBIT_SYSTEM_RECOVERY = 36; - */ - const INHIBIT_SYSTEM_RECOVERY = 36; - /** - * T1496 - * - * Generated from protobuf enum RESOURCE_HIJACKING = 8; - */ - const RESOURCE_HIJACKING = 8; - /** - * T1498 - * - * Generated from protobuf enum NETWORK_DENIAL_OF_SERVICE = 17; - */ - const NETWORK_DENIAL_OF_SERVICE = 17; - /** - * T1526 - * - * Generated from protobuf enum CLOUD_SERVICE_DISCOVERY = 48; - */ - const CLOUD_SERVICE_DISCOVERY = 48; - /** - * T1528 - * - * Generated from protobuf enum STEAL_APPLICATION_ACCESS_TOKEN = 42; - */ - const STEAL_APPLICATION_ACCESS_TOKEN = 42; - /** - * T1531 - * - * Generated from protobuf enum ACCOUNT_ACCESS_REMOVAL = 51; - */ - const ACCOUNT_ACCESS_REMOVAL = 51; - /** - * T1539 - * - * Generated from protobuf enum STEAL_WEB_SESSION_COOKIE = 25; - */ - const STEAL_WEB_SESSION_COOKIE = 25; - /** - * T1543 - * - * Generated from protobuf enum CREATE_OR_MODIFY_SYSTEM_PROCESS = 24; - */ - const CREATE_OR_MODIFY_SYSTEM_PROCESS = 24; - /** - * T1548 - * - * Generated from protobuf enum ABUSE_ELEVATION_CONTROL_MECHANISM = 34; - */ - const ABUSE_ELEVATION_CONTROL_MECHANISM = 34; - /** - * T1552 - * - * Generated from protobuf enum UNSECURED_CREDENTIALS = 13; - */ - const UNSECURED_CREDENTIALS = 13; - /** - * T1556 - * - * Generated from protobuf enum MODIFY_AUTHENTICATION_PROCESS = 28; - */ - const MODIFY_AUTHENTICATION_PROCESS = 28; - /** - * T1562 - * - * Generated from protobuf enum IMPAIR_DEFENSES = 31; - */ - const IMPAIR_DEFENSES = 31; - /** - * T1562.001 - * - * Generated from protobuf enum DISABLE_OR_MODIFY_TOOLS = 55; - */ - const DISABLE_OR_MODIFY_TOOLS = 55; - /** - * T1567 - * - * Generated from protobuf enum EXFILTRATION_OVER_WEB_SERVICE = 20; - */ - const EXFILTRATION_OVER_WEB_SERVICE = 20; - /** - * T1567.002 - * - * Generated from protobuf enum EXFILTRATION_TO_CLOUD_STORAGE = 21; - */ - const EXFILTRATION_TO_CLOUD_STORAGE = 21; - /** - * T1568 - * - * Generated from protobuf enum DYNAMIC_RESOLUTION = 12; - */ - const DYNAMIC_RESOLUTION = 12; - /** - * T1570 - * - * Generated from protobuf enum LATERAL_TOOL_TRANSFER = 41; - */ - const LATERAL_TOOL_TRANSFER = 41; - /** - * T1578 - * - * Generated from protobuf enum MODIFY_CLOUD_COMPUTE_INFRASTRUCTURE = 26; - */ - const MODIFY_CLOUD_COMPUTE_INFRASTRUCTURE = 26; - /** - * T1578.001 - * - * Generated from protobuf enum CREATE_SNAPSHOT = 54; - */ - const CREATE_SNAPSHOT = 54; - /** - * T1580 - * - * Generated from protobuf enum CLOUD_INFRASTRUCTURE_DISCOVERY = 53; - */ - const CLOUD_INFRASTRUCTURE_DISCOVERY = 53; - /** - * T1588 - * - * Generated from protobuf enum OBTAIN_CAPABILITIES = 43; - */ - const OBTAIN_CAPABILITIES = 43; - /** - * T1595 - * - * Generated from protobuf enum ACTIVE_SCANNING = 1; - */ - const ACTIVE_SCANNING = 1; - /** - * T1595.001 - * - * Generated from protobuf enum SCANNING_IP_BLOCKS = 2; - */ - const SCANNING_IP_BLOCKS = 2; - /** - * T1613 - * - * Generated from protobuf enum CONTAINER_AND_RESOURCE_DISCOVERY = 57; - */ - const CONTAINER_AND_RESOURCE_DISCOVERY = 57; - - private static $valueToName = [ - self::TECHNIQUE_UNSPECIFIED => 'TECHNIQUE_UNSPECIFIED', - self::MASQUERADING => 'MASQUERADING', - self::MATCH_LEGITIMATE_NAME_OR_LOCATION => 'MATCH_LEGITIMATE_NAME_OR_LOCATION', - self::BOOT_OR_LOGON_INITIALIZATION_SCRIPTS => 'BOOT_OR_LOGON_INITIALIZATION_SCRIPTS', - self::STARTUP_ITEMS => 'STARTUP_ITEMS', - self::NETWORK_SERVICE_DISCOVERY => 'NETWORK_SERVICE_DISCOVERY', - self::PROCESS_DISCOVERY => 'PROCESS_DISCOVERY', - self::COMMAND_AND_SCRIPTING_INTERPRETER => 'COMMAND_AND_SCRIPTING_INTERPRETER', - self::UNIX_SHELL => 'UNIX_SHELL', - self::PERMISSION_GROUPS_DISCOVERY => 'PERMISSION_GROUPS_DISCOVERY', - self::CLOUD_GROUPS => 'CLOUD_GROUPS', - self::APPLICATION_LAYER_PROTOCOL => 'APPLICATION_LAYER_PROTOCOL', - self::DNS => 'DNS', - self::SOFTWARE_DEPLOYMENT_TOOLS => 'SOFTWARE_DEPLOYMENT_TOOLS', - self::VALID_ACCOUNTS => 'VALID_ACCOUNTS', - self::DEFAULT_ACCOUNTS => 'DEFAULT_ACCOUNTS', - self::LOCAL_ACCOUNTS => 'LOCAL_ACCOUNTS', - self::CLOUD_ACCOUNTS => 'CLOUD_ACCOUNTS', - self::PROXY => 'PROXY', - self::EXTERNAL_PROXY => 'EXTERNAL_PROXY', - self::MULTI_HOP_PROXY => 'MULTI_HOP_PROXY', - self::ACCOUNT_MANIPULATION => 'ACCOUNT_MANIPULATION', - self::ADDITIONAL_CLOUD_CREDENTIALS => 'ADDITIONAL_CLOUD_CREDENTIALS', - self::SSH_AUTHORIZED_KEYS => 'SSH_AUTHORIZED_KEYS', - self::ADDITIONAL_CONTAINER_CLUSTER_ROLES => 'ADDITIONAL_CONTAINER_CLUSTER_ROLES', - self::INGRESS_TOOL_TRANSFER => 'INGRESS_TOOL_TRANSFER', - self::NATIVE_API => 'NATIVE_API', - self::BRUTE_FORCE => 'BRUTE_FORCE', - self::SHARED_MODULES => 'SHARED_MODULES', - self::ACCESS_TOKEN_MANIPULATION => 'ACCESS_TOKEN_MANIPULATION', - self::TOKEN_IMPERSONATION_OR_THEFT => 'TOKEN_IMPERSONATION_OR_THEFT', - self::EXPLOIT_PUBLIC_FACING_APPLICATION => 'EXPLOIT_PUBLIC_FACING_APPLICATION', - self::DOMAIN_POLICY_MODIFICATION => 'DOMAIN_POLICY_MODIFICATION', - self::DATA_DESTRUCTION => 'DATA_DESTRUCTION', - self::SERVICE_STOP => 'SERVICE_STOP', - self::INHIBIT_SYSTEM_RECOVERY => 'INHIBIT_SYSTEM_RECOVERY', - self::RESOURCE_HIJACKING => 'RESOURCE_HIJACKING', - self::NETWORK_DENIAL_OF_SERVICE => 'NETWORK_DENIAL_OF_SERVICE', - self::CLOUD_SERVICE_DISCOVERY => 'CLOUD_SERVICE_DISCOVERY', - self::STEAL_APPLICATION_ACCESS_TOKEN => 'STEAL_APPLICATION_ACCESS_TOKEN', - self::ACCOUNT_ACCESS_REMOVAL => 'ACCOUNT_ACCESS_REMOVAL', - self::STEAL_WEB_SESSION_COOKIE => 'STEAL_WEB_SESSION_COOKIE', - self::CREATE_OR_MODIFY_SYSTEM_PROCESS => 'CREATE_OR_MODIFY_SYSTEM_PROCESS', - self::ABUSE_ELEVATION_CONTROL_MECHANISM => 'ABUSE_ELEVATION_CONTROL_MECHANISM', - self::UNSECURED_CREDENTIALS => 'UNSECURED_CREDENTIALS', - self::MODIFY_AUTHENTICATION_PROCESS => 'MODIFY_AUTHENTICATION_PROCESS', - self::IMPAIR_DEFENSES => 'IMPAIR_DEFENSES', - self::DISABLE_OR_MODIFY_TOOLS => 'DISABLE_OR_MODIFY_TOOLS', - self::EXFILTRATION_OVER_WEB_SERVICE => 'EXFILTRATION_OVER_WEB_SERVICE', - self::EXFILTRATION_TO_CLOUD_STORAGE => 'EXFILTRATION_TO_CLOUD_STORAGE', - self::DYNAMIC_RESOLUTION => 'DYNAMIC_RESOLUTION', - self::LATERAL_TOOL_TRANSFER => 'LATERAL_TOOL_TRANSFER', - self::MODIFY_CLOUD_COMPUTE_INFRASTRUCTURE => 'MODIFY_CLOUD_COMPUTE_INFRASTRUCTURE', - self::CREATE_SNAPSHOT => 'CREATE_SNAPSHOT', - self::CLOUD_INFRASTRUCTURE_DISCOVERY => 'CLOUD_INFRASTRUCTURE_DISCOVERY', - self::OBTAIN_CAPABILITIES => 'OBTAIN_CAPABILITIES', - self::ACTIVE_SCANNING => 'ACTIVE_SCANNING', - self::SCANNING_IP_BLOCKS => 'SCANNING_IP_BLOCKS', - self::CONTAINER_AND_RESOURCE_DISCOVERY => 'CONTAINER_AND_RESOURCE_DISCOVERY', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Technique::class, \Google\Cloud\SecurityCenter\V1\MitreAttack_Technique::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MuteConfig.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MuteConfig.php deleted file mode 100644 index 98d8cb519340..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/MuteConfig.php +++ /dev/null @@ -1,401 +0,0 @@ -google.cloud.securitycenter.v1.MuteConfig - */ -class MuteConfig extends \Google\Protobuf\Internal\Message -{ - /** - * This field will be ignored if provided on config creation. Format - * "organizations/{organization}/muteConfigs/{mute_config}" - * "folders/{folder}/muteConfigs/{mute_config}" - * "projects/{project}/muteConfigs/{mute_config}" - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The human readable name to be displayed for the mute config. - * - * Generated from protobuf field string display_name = 2 [deprecated = true]; - * @deprecated - */ - protected $display_name = ''; - /** - * A description of the mute config. - * - * Generated from protobuf field string description = 3; - */ - protected $description = ''; - /** - * Required. An expression that defines the filter to apply across - * create/update events of findings. While creating a filter string, be - * mindful of the scope in which the mute configuration is being created. - * E.g., If a filter contains project = X but is created under the project = Y - * scope, it might not match any findings. - * The following field and operator combinations are supported: - * * severity: `=`, `:` - * * category: `=`, `:` - * * resource.name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.folders.resource_folder: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.type: `=`, `:` - * * finding_class: `=`, `:` - * * indicator.ip_addresses: `=`, `:` - * * indicator.domains: `=`, `:` - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $filter = ''; - /** - * Output only. The time at which the mute config was created. - * This field is set by the server and will be ignored if provided on config - * creation. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The most recent time at which the mute config was updated. - * This field is set by the server and will be ignored if provided on config - * creation or update. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. Email address of the user who last edited the mute config. - * This field is set by the server and will be ignored if provided on config - * creation or update. - * - * Generated from protobuf field string most_recent_editor = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $most_recent_editor = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * This field will be ignored if provided on config creation. Format - * "organizations/{organization}/muteConfigs/{mute_config}" - * "folders/{folder}/muteConfigs/{mute_config}" - * "projects/{project}/muteConfigs/{mute_config}" - * @type string $display_name - * The human readable name to be displayed for the mute config. - * @type string $description - * A description of the mute config. - * @type string $filter - * Required. An expression that defines the filter to apply across - * create/update events of findings. While creating a filter string, be - * mindful of the scope in which the mute configuration is being created. - * E.g., If a filter contains project = X but is created under the project = Y - * scope, it might not match any findings. - * The following field and operator combinations are supported: - * * severity: `=`, `:` - * * category: `=`, `:` - * * resource.name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.folders.resource_folder: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.type: `=`, `:` - * * finding_class: `=`, `:` - * * indicator.ip_addresses: `=`, `:` - * * indicator.domains: `=`, `:` - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time at which the mute config was created. - * This field is set by the server and will be ignored if provided on config - * creation. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The most recent time at which the mute config was updated. - * This field is set by the server and will be ignored if provided on config - * creation or update. - * @type string $most_recent_editor - * Output only. Email address of the user who last edited the mute config. - * This field is set by the server and will be ignored if provided on config - * creation or update. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\MuteConfig::initOnce(); - parent::__construct($data); - } - - /** - * This field will be ignored if provided on config creation. Format - * "organizations/{organization}/muteConfigs/{mute_config}" - * "folders/{folder}/muteConfigs/{mute_config}" - * "projects/{project}/muteConfigs/{mute_config}" - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * This field will be ignored if provided on config creation. Format - * "organizations/{organization}/muteConfigs/{mute_config}" - * "folders/{folder}/muteConfigs/{mute_config}" - * "projects/{project}/muteConfigs/{mute_config}" - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The human readable name to be displayed for the mute config. - * - * Generated from protobuf field string display_name = 2 [deprecated = true]; - * @return string - * @deprecated - */ - public function getDisplayName() - { - @trigger_error('display_name is deprecated.', E_USER_DEPRECATED); - return $this->display_name; - } - - /** - * The human readable name to be displayed for the mute config. - * - * Generated from protobuf field string display_name = 2 [deprecated = true]; - * @param string $var - * @return $this - * @deprecated - */ - public function setDisplayName($var) - { - @trigger_error('display_name is deprecated.', E_USER_DEPRECATED); - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * A description of the mute config. - * - * Generated from protobuf field string description = 3; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * A description of the mute config. - * - * Generated from protobuf field string description = 3; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Required. An expression that defines the filter to apply across - * create/update events of findings. While creating a filter string, be - * mindful of the scope in which the mute configuration is being created. - * E.g., If a filter contains project = X but is created under the project = Y - * scope, it might not match any findings. - * The following field and operator combinations are supported: - * * severity: `=`, `:` - * * category: `=`, `:` - * * resource.name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.folders.resource_folder: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.type: `=`, `:` - * * finding_class: `=`, `:` - * * indicator.ip_addresses: `=`, `:` - * * indicator.domains: `=`, `:` - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Required. An expression that defines the filter to apply across - * create/update events of findings. While creating a filter string, be - * mindful of the scope in which the mute configuration is being created. - * E.g., If a filter contains project = X but is created under the project = Y - * scope, it might not match any findings. - * The following field and operator combinations are supported: - * * severity: `=`, `:` - * * category: `=`, `:` - * * resource.name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.folders.resource_folder: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.type: `=`, `:` - * * finding_class: `=`, `:` - * * indicator.ip_addresses: `=`, `:` - * * indicator.domains: `=`, `:` - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Output only. The time at which the mute config was created. - * This field is set by the server and will be ignored if provided on config - * creation. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The time at which the mute config was created. - * This field is set by the server and will be ignored if provided on config - * creation. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The most recent time at which the mute config was updated. - * This field is set by the server and will be ignored if provided on config - * creation or update. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. The most recent time at which the mute config was updated. - * This field is set by the server and will be ignored if provided on config - * creation or update. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Output only. Email address of the user who last edited the mute config. - * This field is set by the server and will be ignored if provided on config - * creation or update. - * - * Generated from protobuf field string most_recent_editor = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getMostRecentEditor() - { - return $this->most_recent_editor; - } - - /** - * Output only. Email address of the user who last edited the mute config. - * This field is set by the server and will be ignored if provided on config - * creation or update. - * - * Generated from protobuf field string most_recent_editor = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setMostRecentEditor($var) - { - GPBUtil::checkString($var, True); - $this->most_recent_editor = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Notebook.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Notebook.php deleted file mode 100644 index 3aec64dfc6a6..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Notebook.php +++ /dev/null @@ -1,181 +0,0 @@ -google.cloud.securitycenter.v1.Notebook - */ -class Notebook extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the notebook. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The source notebook service, for example, "Colab Enterprise". - * - * Generated from protobuf field string service = 2; - */ - protected $service = ''; - /** - * The user ID of the latest author to modify the notebook. - * - * Generated from protobuf field string last_author = 3; - */ - protected $last_author = ''; - /** - * The most recent time the notebook was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp notebook_update_time = 4; - */ - protected $notebook_update_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the notebook. - * @type string $service - * The source notebook service, for example, "Colab Enterprise". - * @type string $last_author - * The user ID of the latest author to modify the notebook. - * @type \Google\Protobuf\Timestamp $notebook_update_time - * The most recent time the notebook was updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Notebook::initOnce(); - parent::__construct($data); - } - - /** - * The name of the notebook. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the notebook. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The source notebook service, for example, "Colab Enterprise". - * - * Generated from protobuf field string service = 2; - * @return string - */ - public function getService() - { - return $this->service; - } - - /** - * The source notebook service, for example, "Colab Enterprise". - * - * Generated from protobuf field string service = 2; - * @param string $var - * @return $this - */ - public function setService($var) - { - GPBUtil::checkString($var, True); - $this->service = $var; - - return $this; - } - - /** - * The user ID of the latest author to modify the notebook. - * - * Generated from protobuf field string last_author = 3; - * @return string - */ - public function getLastAuthor() - { - return $this->last_author; - } - - /** - * The user ID of the latest author to modify the notebook. - * - * Generated from protobuf field string last_author = 3; - * @param string $var - * @return $this - */ - public function setLastAuthor($var) - { - GPBUtil::checkString($var, True); - $this->last_author = $var; - - return $this; - } - - /** - * The most recent time the notebook was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp notebook_update_time = 4; - * @return \Google\Protobuf\Timestamp|null - */ - public function getNotebookUpdateTime() - { - return $this->notebook_update_time; - } - - public function hasNotebookUpdateTime() - { - return isset($this->notebook_update_time); - } - - public function clearNotebookUpdateTime() - { - unset($this->notebook_update_time); - } - - /** - * The most recent time the notebook was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp notebook_update_time = 4; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setNotebookUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->notebook_update_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationConfig.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationConfig.php deleted file mode 100644 index 5638bbb45c82..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationConfig.php +++ /dev/null @@ -1,241 +0,0 @@ -google.cloud.securitycenter.v1.NotificationConfig - */ -class NotificationConfig extends \Google\Protobuf\Internal\Message -{ - /** - * The relative resource name of this notification config. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/notificationConfigs/notify_public_bucket", - * "folders/{folder_id}/notificationConfigs/notify_public_bucket", - * or "projects/{project_id}/notificationConfigs/notify_public_bucket". - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The description of the notification config (max of 1024 characters). - * - * Generated from protobuf field string description = 2; - */ - protected $description = ''; - /** - * The Pub/Sub topic to send notifications to. Its format is - * "projects/[project_id]/topics/[topic]". - * - * Generated from protobuf field string pubsub_topic = 3 [(.google.api.resource_reference) = { - */ - protected $pubsub_topic = ''; - /** - * Output only. The service account that needs "pubsub.topics.publish" - * permission to publish to the Pub/Sub topic. - * - * Generated from protobuf field string service_account = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $service_account = ''; - protected $notify_config; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The relative resource name of this notification config. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/notificationConfigs/notify_public_bucket", - * "folders/{folder_id}/notificationConfigs/notify_public_bucket", - * or "projects/{project_id}/notificationConfigs/notify_public_bucket". - * @type string $description - * The description of the notification config (max of 1024 characters). - * @type string $pubsub_topic - * The Pub/Sub topic to send notifications to. Its format is - * "projects/[project_id]/topics/[topic]". - * @type string $service_account - * Output only. The service account that needs "pubsub.topics.publish" - * permission to publish to the Pub/Sub topic. - * @type \Google\Cloud\SecurityCenter\V1\NotificationConfig\StreamingConfig $streaming_config - * The config for triggering streaming-based notifications. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\NotificationConfig::initOnce(); - parent::__construct($data); - } - - /** - * The relative resource name of this notification config. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/notificationConfigs/notify_public_bucket", - * "folders/{folder_id}/notificationConfigs/notify_public_bucket", - * or "projects/{project_id}/notificationConfigs/notify_public_bucket". - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The relative resource name of this notification config. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/notificationConfigs/notify_public_bucket", - * "folders/{folder_id}/notificationConfigs/notify_public_bucket", - * or "projects/{project_id}/notificationConfigs/notify_public_bucket". - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The description of the notification config (max of 1024 characters). - * - * Generated from protobuf field string description = 2; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * The description of the notification config (max of 1024 characters). - * - * Generated from protobuf field string description = 2; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * The Pub/Sub topic to send notifications to. Its format is - * "projects/[project_id]/topics/[topic]". - * - * Generated from protobuf field string pubsub_topic = 3 [(.google.api.resource_reference) = { - * @return string - */ - public function getPubsubTopic() - { - return $this->pubsub_topic; - } - - /** - * The Pub/Sub topic to send notifications to. Its format is - * "projects/[project_id]/topics/[topic]". - * - * Generated from protobuf field string pubsub_topic = 3 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setPubsubTopic($var) - { - GPBUtil::checkString($var, True); - $this->pubsub_topic = $var; - - return $this; - } - - /** - * Output only. The service account that needs "pubsub.topics.publish" - * permission to publish to the Pub/Sub topic. - * - * Generated from protobuf field string service_account = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getServiceAccount() - { - return $this->service_account; - } - - /** - * Output only. The service account that needs "pubsub.topics.publish" - * permission to publish to the Pub/Sub topic. - * - * Generated from protobuf field string service_account = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setServiceAccount($var) - { - GPBUtil::checkString($var, True); - $this->service_account = $var; - - return $this; - } - - /** - * The config for triggering streaming-based notifications. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.NotificationConfig.StreamingConfig streaming_config = 5; - * @return \Google\Cloud\SecurityCenter\V1\NotificationConfig\StreamingConfig|null - */ - public function getStreamingConfig() - { - return $this->readOneof(5); - } - - public function hasStreamingConfig() - { - return $this->hasOneof(5); - } - - /** - * The config for triggering streaming-based notifications. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.NotificationConfig.StreamingConfig streaming_config = 5; - * @param \Google\Cloud\SecurityCenter\V1\NotificationConfig\StreamingConfig $var - * @return $this - */ - public function setStreamingConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\NotificationConfig\StreamingConfig::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * @return string - */ - public function getNotifyConfig() - { - return $this->whichOneof("notify_config"); - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationConfig/StreamingConfig.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationConfig/StreamingConfig.php deleted file mode 100644 index 7f332dbc44a0..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationConfig/StreamingConfig.php +++ /dev/null @@ -1,131 +0,0 @@ -google.cloud.securitycenter.v1.NotificationConfig.StreamingConfig - */ -class StreamingConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Expression that defines the filter to apply across create/update events - * of assets or findings as specified by the event type. The expression is a - * list of zero or more restrictions combined via logical operators `AND` - * and `OR`. Parentheses are supported, and `OR` has higher precedence than - * `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 1; - */ - protected $filter = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $filter - * Expression that defines the filter to apply across create/update events - * of assets or findings as specified by the event type. The expression is a - * list of zero or more restrictions combined via logical operators `AND` - * and `OR`. Parentheses are supported, and `OR` has higher precedence than - * `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\NotificationConfig::initOnce(); - parent::__construct($data); - } - - /** - * Expression that defines the filter to apply across create/update events - * of assets or findings as specified by the event type. The expression is a - * list of zero or more restrictions combined via logical operators `AND` - * and `OR`. Parentheses are supported, and `OR` has higher precedence than - * `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 1; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Expression that defines the filter to apply across create/update events - * of assets or findings as specified by the event type. The expression is a - * list of zero or more restrictions combined via logical operators `AND` - * and `OR`. Parentheses are supported, and `OR` has higher precedence than - * `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 1; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(StreamingConfig::class, \Google\Cloud\SecurityCenter\V1\NotificationConfig_StreamingConfig::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationMessage.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationMessage.php deleted file mode 100644 index cbec635bd336..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/NotificationMessage.php +++ /dev/null @@ -1,156 +0,0 @@ -google.cloud.securitycenter.v1.NotificationMessage - */ -class NotificationMessage extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the notification config that generated current notification. - * - * Generated from protobuf field string notification_config_name = 1; - */ - protected $notification_config_name = ''; - /** - * The Cloud resource tied to this notification's Finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Resource resource = 3; - */ - protected $resource = null; - protected $event; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $notification_config_name - * Name of the notification config that generated current notification. - * @type \Google\Cloud\SecurityCenter\V1\Finding $finding - * If it's a Finding based notification config, this field will be - * populated. - * @type \Google\Cloud\SecurityCenter\V1\Resource $resource - * The Cloud resource tied to this notification's Finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\NotificationMessage::initOnce(); - parent::__construct($data); - } - - /** - * Name of the notification config that generated current notification. - * - * Generated from protobuf field string notification_config_name = 1; - * @return string - */ - public function getNotificationConfigName() - { - return $this->notification_config_name; - } - - /** - * Name of the notification config that generated current notification. - * - * Generated from protobuf field string notification_config_name = 1; - * @param string $var - * @return $this - */ - public function setNotificationConfigName($var) - { - GPBUtil::checkString($var, True); - $this->notification_config_name = $var; - - return $this; - } - - /** - * If it's a Finding based notification config, this field will be - * populated. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 2; - * @return \Google\Cloud\SecurityCenter\V1\Finding|null - */ - public function getFinding() - { - return $this->readOneof(2); - } - - public function hasFinding() - { - return $this->hasOneof(2); - } - - /** - * If it's a Finding based notification config, this field will be - * populated. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 2; - * @param \Google\Cloud\SecurityCenter\V1\Finding $var - * @return $this - */ - public function setFinding($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Finding::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The Cloud resource tied to this notification's Finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Resource resource = 3; - * @return \Google\Cloud\SecurityCenter\V1\Resource|null - */ - public function getResource() - { - return $this->resource; - } - - public function hasResource() - { - return isset($this->resource); - } - - public function clearResource() - { - unset($this->resource); - } - - /** - * The Cloud resource tied to this notification's Finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Resource resource = 3; - * @param \Google\Cloud\SecurityCenter\V1\Resource $var - * @return $this - */ - public function setResource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Resource::class); - $this->resource = $var; - - return $this; - } - - /** - * @return string - */ - public function getEvent() - { - return $this->whichOneof("event"); - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrgPolicy.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrgPolicy.php deleted file mode 100644 index 0da4e2cafc7b..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrgPolicy.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.securitycenter.v1.OrgPolicy - */ -class OrgPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * The resource name of the org policy. - * Example: - * "organizations/{organization_id}/policies/{constraint_name}" - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The resource name of the org policy. - * Example: - * "organizations/{organization_id}/policies/{constraint_name}" - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\OrgPolicy::initOnce(); - parent::__construct($data); - } - - /** - * The resource name of the org policy. - * Example: - * "organizations/{organization_id}/policies/{constraint_name}" - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The resource name of the org policy. - * Example: - * "organizations/{organization_id}/policies/{constraint_name}" - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings.php deleted file mode 100644 index ae410fea0a5a..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings.php +++ /dev/null @@ -1,170 +0,0 @@ -google.cloud.securitycenter.v1.OrganizationSettings - */ -class OrganizationSettings extends \Google\Protobuf\Internal\Message -{ - /** - * The relative resource name of the settings. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/organizationSettings". - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * A flag that indicates if Asset Discovery should be enabled. If the flag is - * set to `true`, then discovery of assets will occur. If it is set to - * `false`, all historical assets will remain, but discovery of future assets - * will not occur. - * - * Generated from protobuf field bool enable_asset_discovery = 2; - */ - protected $enable_asset_discovery = false; - /** - * The configuration used for Asset Discovery runs. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.OrganizationSettings.AssetDiscoveryConfig asset_discovery_config = 3; - */ - protected $asset_discovery_config = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The relative resource name of the settings. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/organizationSettings". - * @type bool $enable_asset_discovery - * A flag that indicates if Asset Discovery should be enabled. If the flag is - * set to `true`, then discovery of assets will occur. If it is set to - * `false`, all historical assets will remain, but discovery of future assets - * will not occur. - * @type \Google\Cloud\SecurityCenter\V1\OrganizationSettings\AssetDiscoveryConfig $asset_discovery_config - * The configuration used for Asset Discovery runs. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\OrganizationSettings::initOnce(); - parent::__construct($data); - } - - /** - * The relative resource name of the settings. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/organizationSettings". - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The relative resource name of the settings. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/organizationSettings". - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * A flag that indicates if Asset Discovery should be enabled. If the flag is - * set to `true`, then discovery of assets will occur. If it is set to - * `false`, all historical assets will remain, but discovery of future assets - * will not occur. - * - * Generated from protobuf field bool enable_asset_discovery = 2; - * @return bool - */ - public function getEnableAssetDiscovery() - { - return $this->enable_asset_discovery; - } - - /** - * A flag that indicates if Asset Discovery should be enabled. If the flag is - * set to `true`, then discovery of assets will occur. If it is set to - * `false`, all historical assets will remain, but discovery of future assets - * will not occur. - * - * Generated from protobuf field bool enable_asset_discovery = 2; - * @param bool $var - * @return $this - */ - public function setEnableAssetDiscovery($var) - { - GPBUtil::checkBool($var); - $this->enable_asset_discovery = $var; - - return $this; - } - - /** - * The configuration used for Asset Discovery runs. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.OrganizationSettings.AssetDiscoveryConfig asset_discovery_config = 3; - * @return \Google\Cloud\SecurityCenter\V1\OrganizationSettings\AssetDiscoveryConfig|null - */ - public function getAssetDiscoveryConfig() - { - return $this->asset_discovery_config; - } - - public function hasAssetDiscoveryConfig() - { - return isset($this->asset_discovery_config); - } - - public function clearAssetDiscoveryConfig() - { - unset($this->asset_discovery_config); - } - - /** - * The configuration used for Asset Discovery runs. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.OrganizationSettings.AssetDiscoveryConfig asset_discovery_config = 3; - * @param \Google\Cloud\SecurityCenter\V1\OrganizationSettings\AssetDiscoveryConfig $var - * @return $this - */ - public function setAssetDiscoveryConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\OrganizationSettings\AssetDiscoveryConfig::class); - $this->asset_discovery_config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings/AssetDiscoveryConfig.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings/AssetDiscoveryConfig.php deleted file mode 100644 index bfa7935a6f48..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings/AssetDiscoveryConfig.php +++ /dev/null @@ -1,142 +0,0 @@ -google.cloud.securitycenter.v1.OrganizationSettings.AssetDiscoveryConfig - */ -class AssetDiscoveryConfig extends \Google\Protobuf\Internal\Message -{ - /** - * The project ids to use for filtering asset discovery. - * - * Generated from protobuf field repeated string project_ids = 1; - */ - private $project_ids; - /** - * The mode to use for filtering asset discovery. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.OrganizationSettings.AssetDiscoveryConfig.InclusionMode inclusion_mode = 2; - */ - protected $inclusion_mode = 0; - /** - * The folder ids to use for filtering asset discovery. - * It consists of only digits, e.g., 756619654966. - * - * Generated from protobuf field repeated string folder_ids = 3; - */ - private $folder_ids; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $project_ids - * The project ids to use for filtering asset discovery. - * @type int $inclusion_mode - * The mode to use for filtering asset discovery. - * @type array|\Google\Protobuf\Internal\RepeatedField $folder_ids - * The folder ids to use for filtering asset discovery. - * It consists of only digits, e.g., 756619654966. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\OrganizationSettings::initOnce(); - parent::__construct($data); - } - - /** - * The project ids to use for filtering asset discovery. - * - * Generated from protobuf field repeated string project_ids = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getProjectIds() - { - return $this->project_ids; - } - - /** - * The project ids to use for filtering asset discovery. - * - * Generated from protobuf field repeated string project_ids = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setProjectIds($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->project_ids = $arr; - - return $this; - } - - /** - * The mode to use for filtering asset discovery. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.OrganizationSettings.AssetDiscoveryConfig.InclusionMode inclusion_mode = 2; - * @return int - */ - public function getInclusionMode() - { - return $this->inclusion_mode; - } - - /** - * The mode to use for filtering asset discovery. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.OrganizationSettings.AssetDiscoveryConfig.InclusionMode inclusion_mode = 2; - * @param int $var - * @return $this - */ - public function setInclusionMode($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\OrganizationSettings\AssetDiscoveryConfig\InclusionMode::class); - $this->inclusion_mode = $var; - - return $this; - } - - /** - * The folder ids to use for filtering asset discovery. - * It consists of only digits, e.g., 756619654966. - * - * Generated from protobuf field repeated string folder_ids = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFolderIds() - { - return $this->folder_ids; - } - - /** - * The folder ids to use for filtering asset discovery. - * It consists of only digits, e.g., 756619654966. - * - * Generated from protobuf field repeated string folder_ids = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFolderIds($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->folder_ids = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AssetDiscoveryConfig::class, \Google\Cloud\SecurityCenter\V1\OrganizationSettings_AssetDiscoveryConfig::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings/AssetDiscoveryConfig/InclusionMode.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings/AssetDiscoveryConfig/InclusionMode.php deleted file mode 100644 index 33dd51cd818b..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/OrganizationSettings/AssetDiscoveryConfig/InclusionMode.php +++ /dev/null @@ -1,74 +0,0 @@ -google.cloud.securitycenter.v1.OrganizationSettings.AssetDiscoveryConfig.InclusionMode - */ -class InclusionMode -{ - /** - * Unspecified. Setting the mode with this value will disable - * inclusion/exclusion filtering for Asset Discovery. - * - * Generated from protobuf enum INCLUSION_MODE_UNSPECIFIED = 0; - */ - const INCLUSION_MODE_UNSPECIFIED = 0; - /** - * Asset Discovery will capture only the resources within the projects - * specified. All other resources will be ignored. - * - * Generated from protobuf enum INCLUDE_ONLY = 1; - */ - const INCLUDE_ONLY = 1; - /** - * Asset Discovery will ignore all resources under the projects specified. - * All other resources will be retrieved. - * - * Generated from protobuf enum EXCLUDE = 2; - */ - const EXCLUDE = 2; - - private static $valueToName = [ - self::INCLUSION_MODE_UNSPECIFIED => 'INCLUSION_MODE_UNSPECIFIED', - self::INCLUDE_ONLY => 'INCLUDE_ONLY', - self::EXCLUDE => 'EXCLUDE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(InclusionMode::class, \Google\Cloud\SecurityCenter\V1\OrganizationSettings_AssetDiscoveryConfig_InclusionMode::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Package.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Package.php deleted file mode 100644 index 99df9caedfb8..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Package.php +++ /dev/null @@ -1,169 +0,0 @@ -google.cloud.securitycenter.v1.Package - */ -class Package extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the package where the vulnerability was detected. - * - * Generated from protobuf field string package_name = 1; - */ - protected $package_name = ''; - /** - * The CPE URI where the vulnerability was detected. - * - * Generated from protobuf field string cpe_uri = 2; - */ - protected $cpe_uri = ''; - /** - * Type of package, for example, os, maven, or go. - * - * Generated from protobuf field string package_type = 3; - */ - protected $package_type = ''; - /** - * The version of the package. - * - * Generated from protobuf field string package_version = 4; - */ - protected $package_version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $package_name - * The name of the package where the vulnerability was detected. - * @type string $cpe_uri - * The CPE URI where the vulnerability was detected. - * @type string $package_type - * Type of package, for example, os, maven, or go. - * @type string $package_version - * The version of the package. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Vulnerability::initOnce(); - parent::__construct($data); - } - - /** - * The name of the package where the vulnerability was detected. - * - * Generated from protobuf field string package_name = 1; - * @return string - */ - public function getPackageName() - { - return $this->package_name; - } - - /** - * The name of the package where the vulnerability was detected. - * - * Generated from protobuf field string package_name = 1; - * @param string $var - * @return $this - */ - public function setPackageName($var) - { - GPBUtil::checkString($var, True); - $this->package_name = $var; - - return $this; - } - - /** - * The CPE URI where the vulnerability was detected. - * - * Generated from protobuf field string cpe_uri = 2; - * @return string - */ - public function getCpeUri() - { - return $this->cpe_uri; - } - - /** - * The CPE URI where the vulnerability was detected. - * - * Generated from protobuf field string cpe_uri = 2; - * @param string $var - * @return $this - */ - public function setCpeUri($var) - { - GPBUtil::checkString($var, True); - $this->cpe_uri = $var; - - return $this; - } - - /** - * Type of package, for example, os, maven, or go. - * - * Generated from protobuf field string package_type = 3; - * @return string - */ - public function getPackageType() - { - return $this->package_type; - } - - /** - * Type of package, for example, os, maven, or go. - * - * Generated from protobuf field string package_type = 3; - * @param string $var - * @return $this - */ - public function setPackageType($var) - { - GPBUtil::checkString($var, True); - $this->package_type = $var; - - return $this; - } - - /** - * The version of the package. - * - * Generated from protobuf field string package_version = 4; - * @return string - */ - public function getPackageVersion() - { - return $this->package_version; - } - - /** - * The version of the package. - * - * Generated from protobuf field string package_version = 4; - * @param string $var - * @return $this - */ - public function setPackageVersion($var) - { - GPBUtil::checkString($var, True); - $this->package_version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Process.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Process.php deleted file mode 100644 index 56de3cc68d1b..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Process.php +++ /dev/null @@ -1,409 +0,0 @@ -google.cloud.securitycenter.v1.Process - */ -class Process extends \Google\Protobuf\Internal\Message -{ - /** - * The process name, as displayed in utilities like `top` and `ps`. This name - * can be accessed through `/proc/[pid]/comm` and changed with - * `prctl(PR_SET_NAME)`. - * - * Generated from protobuf field string name = 12; - */ - protected $name = ''; - /** - * File information for the process executable. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.File binary = 3; - */ - protected $binary = null; - /** - * File information for libraries loaded by the process. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.File libraries = 4; - */ - private $libraries; - /** - * When the process represents the invocation of a script, `binary` provides - * information about the interpreter, while `script` provides information - * about the script file provided to the interpreter. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.File script = 5; - */ - protected $script = null; - /** - * Process arguments as JSON encoded strings. - * - * Generated from protobuf field repeated string args = 6; - */ - private $args; - /** - * True if `args` is incomplete. - * - * Generated from protobuf field bool arguments_truncated = 7; - */ - protected $arguments_truncated = false; - /** - * Process environment variables. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.EnvironmentVariable env_variables = 8; - */ - private $env_variables; - /** - * True if `env_variables` is incomplete. - * - * Generated from protobuf field bool env_variables_truncated = 9; - */ - protected $env_variables_truncated = false; - /** - * The process ID. - * - * Generated from protobuf field int64 pid = 10; - */ - protected $pid = 0; - /** - * The parent process ID. - * - * Generated from protobuf field int64 parent_pid = 11; - */ - protected $parent_pid = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The process name, as displayed in utilities like `top` and `ps`. This name - * can be accessed through `/proc/[pid]/comm` and changed with - * `prctl(PR_SET_NAME)`. - * @type \Google\Cloud\SecurityCenter\V1\File $binary - * File information for the process executable. - * @type array<\Google\Cloud\SecurityCenter\V1\File>|\Google\Protobuf\Internal\RepeatedField $libraries - * File information for libraries loaded by the process. - * @type \Google\Cloud\SecurityCenter\V1\File $script - * When the process represents the invocation of a script, `binary` provides - * information about the interpreter, while `script` provides information - * about the script file provided to the interpreter. - * @type array|\Google\Protobuf\Internal\RepeatedField $args - * Process arguments as JSON encoded strings. - * @type bool $arguments_truncated - * True if `args` is incomplete. - * @type array<\Google\Cloud\SecurityCenter\V1\EnvironmentVariable>|\Google\Protobuf\Internal\RepeatedField $env_variables - * Process environment variables. - * @type bool $env_variables_truncated - * True if `env_variables` is incomplete. - * @type int|string $pid - * The process ID. - * @type int|string $parent_pid - * The parent process ID. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Process::initOnce(); - parent::__construct($data); - } - - /** - * The process name, as displayed in utilities like `top` and `ps`. This name - * can be accessed through `/proc/[pid]/comm` and changed with - * `prctl(PR_SET_NAME)`. - * - * Generated from protobuf field string name = 12; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The process name, as displayed in utilities like `top` and `ps`. This name - * can be accessed through `/proc/[pid]/comm` and changed with - * `prctl(PR_SET_NAME)`. - * - * Generated from protobuf field string name = 12; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * File information for the process executable. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.File binary = 3; - * @return \Google\Cloud\SecurityCenter\V1\File|null - */ - public function getBinary() - { - return $this->binary; - } - - public function hasBinary() - { - return isset($this->binary); - } - - public function clearBinary() - { - unset($this->binary); - } - - /** - * File information for the process executable. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.File binary = 3; - * @param \Google\Cloud\SecurityCenter\V1\File $var - * @return $this - */ - public function setBinary($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\File::class); - $this->binary = $var; - - return $this; - } - - /** - * File information for libraries loaded by the process. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.File libraries = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLibraries() - { - return $this->libraries; - } - - /** - * File information for libraries loaded by the process. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.File libraries = 4; - * @param array<\Google\Cloud\SecurityCenter\V1\File>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLibraries($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\File::class); - $this->libraries = $arr; - - return $this; - } - - /** - * When the process represents the invocation of a script, `binary` provides - * information about the interpreter, while `script` provides information - * about the script file provided to the interpreter. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.File script = 5; - * @return \Google\Cloud\SecurityCenter\V1\File|null - */ - public function getScript() - { - return $this->script; - } - - public function hasScript() - { - return isset($this->script); - } - - public function clearScript() - { - unset($this->script); - } - - /** - * When the process represents the invocation of a script, `binary` provides - * information about the interpreter, while `script` provides information - * about the script file provided to the interpreter. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.File script = 5; - * @param \Google\Cloud\SecurityCenter\V1\File $var - * @return $this - */ - public function setScript($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\File::class); - $this->script = $var; - - return $this; - } - - /** - * Process arguments as JSON encoded strings. - * - * Generated from protobuf field repeated string args = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getArgs() - { - return $this->args; - } - - /** - * Process arguments as JSON encoded strings. - * - * Generated from protobuf field repeated string args = 6; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setArgs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->args = $arr; - - return $this; - } - - /** - * True if `args` is incomplete. - * - * Generated from protobuf field bool arguments_truncated = 7; - * @return bool - */ - public function getArgumentsTruncated() - { - return $this->arguments_truncated; - } - - /** - * True if `args` is incomplete. - * - * Generated from protobuf field bool arguments_truncated = 7; - * @param bool $var - * @return $this - */ - public function setArgumentsTruncated($var) - { - GPBUtil::checkBool($var); - $this->arguments_truncated = $var; - - return $this; - } - - /** - * Process environment variables. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.EnvironmentVariable env_variables = 8; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getEnvVariables() - { - return $this->env_variables; - } - - /** - * Process environment variables. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.EnvironmentVariable env_variables = 8; - * @param array<\Google\Cloud\SecurityCenter\V1\EnvironmentVariable>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setEnvVariables($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\EnvironmentVariable::class); - $this->env_variables = $arr; - - return $this; - } - - /** - * True if `env_variables` is incomplete. - * - * Generated from protobuf field bool env_variables_truncated = 9; - * @return bool - */ - public function getEnvVariablesTruncated() - { - return $this->env_variables_truncated; - } - - /** - * True if `env_variables` is incomplete. - * - * Generated from protobuf field bool env_variables_truncated = 9; - * @param bool $var - * @return $this - */ - public function setEnvVariablesTruncated($var) - { - GPBUtil::checkBool($var); - $this->env_variables_truncated = $var; - - return $this; - } - - /** - * The process ID. - * - * Generated from protobuf field int64 pid = 10; - * @return int|string - */ - public function getPid() - { - return $this->pid; - } - - /** - * The process ID. - * - * Generated from protobuf field int64 pid = 10; - * @param int|string $var - * @return $this - */ - public function setPid($var) - { - GPBUtil::checkInt64($var); - $this->pid = $var; - - return $this; - } - - /** - * The parent process ID. - * - * Generated from protobuf field int64 parent_pid = 11; - * @return int|string - */ - public function getParentPid() - { - return $this->parent_pid; - } - - /** - * The parent process ID. - * - * Generated from protobuf field int64 parent_pid = 11; - * @param int|string $var - * @return $this - */ - public function setParentPid($var) - { - GPBUtil::checkInt64($var); - $this->parent_pid = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Reference.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Reference.php deleted file mode 100644 index 0dead12073c9..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Reference.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.securitycenter.v1.Reference - */ -class Reference extends \Google\Protobuf\Internal\Message -{ - /** - * Source of the reference e.g. NVD - * - * Generated from protobuf field string source = 1; - */ - protected $source = ''; - /** - * Uri for the mentioned source e.g. - * https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527. - * - * Generated from protobuf field string uri = 2; - */ - protected $uri = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $source - * Source of the reference e.g. NVD - * @type string $uri - * Uri for the mentioned source e.g. - * https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Vulnerability::initOnce(); - parent::__construct($data); - } - - /** - * Source of the reference e.g. NVD - * - * Generated from protobuf field string source = 1; - * @return string - */ - public function getSource() - { - return $this->source; - } - - /** - * Source of the reference e.g. NVD - * - * Generated from protobuf field string source = 1; - * @param string $var - * @return $this - */ - public function setSource($var) - { - GPBUtil::checkString($var, True); - $this->source = $var; - - return $this; - } - - /** - * Uri for the mentioned source e.g. - * https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527. - * - * Generated from protobuf field string uri = 2; - * @return string - */ - public function getUri() - { - return $this->uri; - } - - /** - * Uri for the mentioned source e.g. - * https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527. - * - * Generated from protobuf field string uri = 2; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->uri = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Requests.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Requests.php deleted file mode 100644 index f8903e49e17f..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Requests.php +++ /dev/null @@ -1,177 +0,0 @@ -google.cloud.securitycenter.v1.Requests - */ -class Requests extends \Google\Protobuf\Internal\Message -{ - /** - * For 'Increasing deny ratio', the ratio is the denied traffic divided by the - * allowed traffic. For 'Allowed traffic spike', the ratio is the allowed - * traffic in the short term divided by allowed traffic in the long term. - * - * Generated from protobuf field double ratio = 1; - */ - protected $ratio = 0.0; - /** - * Allowed RPS (requests per second) in the short term. - * - * Generated from protobuf field int32 short_term_allowed = 2; - */ - protected $short_term_allowed = 0; - /** - * Allowed RPS (requests per second) over the long term. - * - * Generated from protobuf field int32 long_term_allowed = 3; - */ - protected $long_term_allowed = 0; - /** - * Denied RPS (requests per second) over the long term. - * - * Generated from protobuf field int32 long_term_denied = 4; - */ - protected $long_term_denied = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type float $ratio - * For 'Increasing deny ratio', the ratio is the denied traffic divided by the - * allowed traffic. For 'Allowed traffic spike', the ratio is the allowed - * traffic in the short term divided by allowed traffic in the long term. - * @type int $short_term_allowed - * Allowed RPS (requests per second) in the short term. - * @type int $long_term_allowed - * Allowed RPS (requests per second) over the long term. - * @type int $long_term_denied - * Denied RPS (requests per second) over the long term. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\CloudArmor::initOnce(); - parent::__construct($data); - } - - /** - * For 'Increasing deny ratio', the ratio is the denied traffic divided by the - * allowed traffic. For 'Allowed traffic spike', the ratio is the allowed - * traffic in the short term divided by allowed traffic in the long term. - * - * Generated from protobuf field double ratio = 1; - * @return float - */ - public function getRatio() - { - return $this->ratio; - } - - /** - * For 'Increasing deny ratio', the ratio is the denied traffic divided by the - * allowed traffic. For 'Allowed traffic spike', the ratio is the allowed - * traffic in the short term divided by allowed traffic in the long term. - * - * Generated from protobuf field double ratio = 1; - * @param float $var - * @return $this - */ - public function setRatio($var) - { - GPBUtil::checkDouble($var); - $this->ratio = $var; - - return $this; - } - - /** - * Allowed RPS (requests per second) in the short term. - * - * Generated from protobuf field int32 short_term_allowed = 2; - * @return int - */ - public function getShortTermAllowed() - { - return $this->short_term_allowed; - } - - /** - * Allowed RPS (requests per second) in the short term. - * - * Generated from protobuf field int32 short_term_allowed = 2; - * @param int $var - * @return $this - */ - public function setShortTermAllowed($var) - { - GPBUtil::checkInt32($var); - $this->short_term_allowed = $var; - - return $this; - } - - /** - * Allowed RPS (requests per second) over the long term. - * - * Generated from protobuf field int32 long_term_allowed = 3; - * @return int - */ - public function getLongTermAllowed() - { - return $this->long_term_allowed; - } - - /** - * Allowed RPS (requests per second) over the long term. - * - * Generated from protobuf field int32 long_term_allowed = 3; - * @param int $var - * @return $this - */ - public function setLongTermAllowed($var) - { - GPBUtil::checkInt32($var); - $this->long_term_allowed = $var; - - return $this; - } - - /** - * Denied RPS (requests per second) over the long term. - * - * Generated from protobuf field int32 long_term_denied = 4; - * @return int - */ - public function getLongTermDenied() - { - return $this->long_term_denied; - } - - /** - * Denied RPS (requests per second) over the long term. - * - * Generated from protobuf field int32 long_term_denied = 4; - * @param int $var - * @return $this - */ - public function setLongTermDenied($var) - { - GPBUtil::checkInt32($var); - $this->long_term_denied = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Resource.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Resource.php deleted file mode 100644 index 44f8ef85d5ed..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Resource.php +++ /dev/null @@ -1,317 +0,0 @@ -google.cloud.securitycenter.v1.Resource - */ -class Resource extends \Google\Protobuf\Internal\Message -{ - /** - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The human readable name of the resource. - * - * Generated from protobuf field string display_name = 8; - */ - protected $display_name = ''; - /** - * The full resource type of the resource. - * - * Generated from protobuf field string type = 6; - */ - protected $type = ''; - /** - * The full resource name of project that the resource belongs to. - * - * Generated from protobuf field string project = 2; - */ - protected $project = ''; - /** - * The project ID that the resource belongs to. - * - * Generated from protobuf field string project_display_name = 3; - */ - protected $project_display_name = ''; - /** - * The full resource name of resource's parent. - * - * Generated from protobuf field string parent = 4; - */ - protected $parent = ''; - /** - * The human readable name of resource's parent. - * - * Generated from protobuf field string parent_display_name = 5; - */ - protected $parent_display_name = ''; - /** - * Output only. Contains a Folder message for each folder in the assets - * ancestry. The first folder is the deepest nested folder, and the last - * folder is the folder directly under the Organization. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Folder folders = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $folders; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * @type string $display_name - * The human readable name of the resource. - * @type string $type - * The full resource type of the resource. - * @type string $project - * The full resource name of project that the resource belongs to. - * @type string $project_display_name - * The project ID that the resource belongs to. - * @type string $parent - * The full resource name of resource's parent. - * @type string $parent_display_name - * The human readable name of resource's parent. - * @type array<\Google\Cloud\SecurityCenter\V1\Folder>|\Google\Protobuf\Internal\RepeatedField $folders - * Output only. Contains a Folder message for each folder in the assets - * ancestry. The first folder is the deepest nested folder, and the last - * folder is the folder directly under the Organization. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Resource::initOnce(); - parent::__construct($data); - } - - /** - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The human readable name of the resource. - * - * Generated from protobuf field string display_name = 8; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * The human readable name of the resource. - * - * Generated from protobuf field string display_name = 8; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * The full resource type of the resource. - * - * Generated from protobuf field string type = 6; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * The full resource type of the resource. - * - * Generated from protobuf field string type = 6; - * @param string $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkString($var, True); - $this->type = $var; - - return $this; - } - - /** - * The full resource name of project that the resource belongs to. - * - * Generated from protobuf field string project = 2; - * @return string - */ - public function getProject() - { - return $this->project; - } - - /** - * The full resource name of project that the resource belongs to. - * - * Generated from protobuf field string project = 2; - * @param string $var - * @return $this - */ - public function setProject($var) - { - GPBUtil::checkString($var, True); - $this->project = $var; - - return $this; - } - - /** - * The project ID that the resource belongs to. - * - * Generated from protobuf field string project_display_name = 3; - * @return string - */ - public function getProjectDisplayName() - { - return $this->project_display_name; - } - - /** - * The project ID that the resource belongs to. - * - * Generated from protobuf field string project_display_name = 3; - * @param string $var - * @return $this - */ - public function setProjectDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->project_display_name = $var; - - return $this; - } - - /** - * The full resource name of resource's parent. - * - * Generated from protobuf field string parent = 4; - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * The full resource name of resource's parent. - * - * Generated from protobuf field string parent = 4; - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The human readable name of resource's parent. - * - * Generated from protobuf field string parent_display_name = 5; - * @return string - */ - public function getParentDisplayName() - { - return $this->parent_display_name; - } - - /** - * The human readable name of resource's parent. - * - * Generated from protobuf field string parent_display_name = 5; - * @param string $var - * @return $this - */ - public function setParentDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->parent_display_name = $var; - - return $this; - } - - /** - * Output only. Contains a Folder message for each folder in the assets - * ancestry. The first folder is the deepest nested folder, and the last - * folder is the folder directly under the Organization. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Folder folders = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFolders() - { - return $this->folders; - } - - /** - * Output only. Contains a Folder message for each folder in the assets - * ancestry. The first folder is the deepest nested folder, and the last - * folder is the folder directly under the Organization. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.Folder folders = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array<\Google\Cloud\SecurityCenter\V1\Folder>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFolders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\Folder::class); - $this->folders = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryRequest.php deleted file mode 100644 index a8601f52cc00..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.securitycenter.v1.RunAssetDiscoveryRequest - */ -class RunAssetDiscoveryRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the organization to run asset discovery for. Its format - * is "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - - /** - * @param string $parent Required. Name of the organization to run asset discovery for. Its format - * is "organizations/[organization_id]". Please see - * {@see SecurityCenterClient::organizationName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V1\RunAssetDiscoveryRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Name of the organization to run asset discovery for. Its format - * is "organizations/[organization_id]". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the organization to run asset discovery for. Its format - * is "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Name of the organization to run asset discovery for. Its format - * is "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryResponse.php deleted file mode 100644 index ff4858d1b647..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryResponse.php +++ /dev/null @@ -1,111 +0,0 @@ -google.cloud.securitycenter.v1.RunAssetDiscoveryResponse - */ -class RunAssetDiscoveryResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The state of an asset discovery run. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.RunAssetDiscoveryResponse.State state = 1; - */ - protected $state = 0; - /** - * The duration between asset discovery run start and end - * - * Generated from protobuf field .google.protobuf.Duration duration = 2; - */ - protected $duration = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $state - * The state of an asset discovery run. - * @type \Google\Protobuf\Duration $duration - * The duration between asset discovery run start and end - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\RunAssetDiscoveryResponse::initOnce(); - parent::__construct($data); - } - - /** - * The state of an asset discovery run. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.RunAssetDiscoveryResponse.State state = 1; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * The state of an asset discovery run. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.RunAssetDiscoveryResponse.State state = 1; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\RunAssetDiscoveryResponse\State::class); - $this->state = $var; - - return $this; - } - - /** - * The duration between asset discovery run start and end - * - * Generated from protobuf field .google.protobuf.Duration duration = 2; - * @return \Google\Protobuf\Duration|null - */ - public function getDuration() - { - return $this->duration; - } - - public function hasDuration() - { - return isset($this->duration); - } - - public function clearDuration() - { - unset($this->duration); - } - - /** - * The duration between asset discovery run start and end - * - * Generated from protobuf field .google.protobuf.Duration duration = 2; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setDuration($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->duration = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryResponse/State.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryResponse/State.php deleted file mode 100644 index 51273e889fe3..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/RunAssetDiscoveryResponse/State.php +++ /dev/null @@ -1,72 +0,0 @@ -google.cloud.securitycenter.v1.RunAssetDiscoveryResponse.State - */ -class State -{ - /** - * Asset discovery run state was unspecified. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * Asset discovery run completed successfully. - * - * Generated from protobuf enum COMPLETED = 1; - */ - const COMPLETED = 1; - /** - * Asset discovery run was cancelled with tasks still pending, as another - * run for the same organization was started with a higher priority. - * - * Generated from protobuf enum SUPERSEDED = 2; - */ - const SUPERSEDED = 2; - /** - * Asset discovery run was killed and terminated. - * - * Generated from protobuf enum TERMINATED = 3; - */ - const TERMINATED = 3; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::COMPLETED => 'COMPLETED', - self::SUPERSEDED => 'SUPERSEDED', - self::TERMINATED => 'TERMINATED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\SecurityCenter\V1\RunAssetDiscoveryResponse_State::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityBulletin.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityBulletin.php deleted file mode 100644 index 44d92323ed02..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityBulletin.php +++ /dev/null @@ -1,149 +0,0 @@ -google.cloud.securitycenter.v1.SecurityBulletin - */ -class SecurityBulletin extends \Google\Protobuf\Internal\Message -{ - /** - * ID of the bulletin corresponding to the vulnerability. - * - * Generated from protobuf field string bulletin_id = 1; - */ - protected $bulletin_id = ''; - /** - * Submission time of this Security Bulletin. - * - * Generated from protobuf field .google.protobuf.Timestamp submission_time = 2; - */ - protected $submission_time = null; - /** - * This represents a version that the cluster receiving this notification - * should be upgraded to, based on its current version. For example, 1.15.0 - * - * Generated from protobuf field string suggested_upgrade_version = 3; - */ - protected $suggested_upgrade_version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $bulletin_id - * ID of the bulletin corresponding to the vulnerability. - * @type \Google\Protobuf\Timestamp $submission_time - * Submission time of this Security Bulletin. - * @type string $suggested_upgrade_version - * This represents a version that the cluster receiving this notification - * should be upgraded to, based on its current version. For example, 1.15.0 - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Vulnerability::initOnce(); - parent::__construct($data); - } - - /** - * ID of the bulletin corresponding to the vulnerability. - * - * Generated from protobuf field string bulletin_id = 1; - * @return string - */ - public function getBulletinId() - { - return $this->bulletin_id; - } - - /** - * ID of the bulletin corresponding to the vulnerability. - * - * Generated from protobuf field string bulletin_id = 1; - * @param string $var - * @return $this - */ - public function setBulletinId($var) - { - GPBUtil::checkString($var, True); - $this->bulletin_id = $var; - - return $this; - } - - /** - * Submission time of this Security Bulletin. - * - * Generated from protobuf field .google.protobuf.Timestamp submission_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getSubmissionTime() - { - return $this->submission_time; - } - - public function hasSubmissionTime() - { - return isset($this->submission_time); - } - - public function clearSubmissionTime() - { - unset($this->submission_time); - } - - /** - * Submission time of this Security Bulletin. - * - * Generated from protobuf field .google.protobuf.Timestamp submission_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setSubmissionTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->submission_time = $var; - - return $this; - } - - /** - * This represents a version that the cluster receiving this notification - * should be upgraded to, based on its current version. For example, 1.15.0 - * - * Generated from protobuf field string suggested_upgrade_version = 3; - * @return string - */ - public function getSuggestedUpgradeVersion() - { - return $this->suggested_upgrade_version; - } - - /** - * This represents a version that the cluster receiving this notification - * should be upgraded to, based on its current version. For example, 1.15.0 - * - * Generated from protobuf field string suggested_upgrade_version = 3; - * @param string $var - * @return $this - */ - public function setSuggestedUpgradeVersion($var) - { - GPBUtil::checkString($var, True); - $this->suggested_upgrade_version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityHealthAnalyticsCustomModule.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityHealthAnalyticsCustomModule.php deleted file mode 100644 index 27bd1aefd400..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityHealthAnalyticsCustomModule.php +++ /dev/null @@ -1,355 +0,0 @@ -google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule - */ -class SecurityHealthAnalyticsCustomModule extends \Google\Protobuf\Internal\Message -{ - /** - * Immutable. The resource name of the custom module. - * Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" - * The id {customModule} is server-generated and is not user settable. - * It will be a numeric id containing 1-20 digits. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; - */ - protected $name = ''; - /** - * The display name of the Security Health Analytics custom module. This - * display name becomes the finding category for all findings that are - * returned by this custom module. The display name must be between 1 and - * 128 characters, start with a lowercase letter, and contain alphanumeric - * characters or underscores only. - * - * Generated from protobuf field string display_name = 2; - */ - protected $display_name = ''; - /** - * The enablement state of the custom module. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule.EnablementState enablement_state = 4; - */ - protected $enablement_state = 0; - /** - * Output only. The time at which the custom module was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. The editor that last updated the custom module. - * - * Generated from protobuf field string last_editor = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $last_editor = ''; - /** - * Output only. If empty, indicates that the custom module was created in the - * organization, folder, or project in which you are viewing the custom - * module. Otherwise, `ancestor_module` specifies the organization or folder - * from which the custom module is inherited. - * - * Generated from protobuf field string ancestor_module = 7 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - */ - protected $ancestor_module = ''; - /** - * The user specified custom configuration for the module. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig custom_config = 8; - */ - protected $custom_config = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Immutable. The resource name of the custom module. - * Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" - * The id {customModule} is server-generated and is not user settable. - * It will be a numeric id containing 1-20 digits. - * @type string $display_name - * The display name of the Security Health Analytics custom module. This - * display name becomes the finding category for all findings that are - * returned by this custom module. The display name must be between 1 and - * 128 characters, start with a lowercase letter, and contain alphanumeric - * characters or underscores only. - * @type int $enablement_state - * The enablement state of the custom module. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The time at which the custom module was last updated. - * @type string $last_editor - * Output only. The editor that last updated the custom module. - * @type string $ancestor_module - * Output only. If empty, indicates that the custom module was created in the - * organization, folder, or project in which you are viewing the custom - * module. Otherwise, `ancestor_module` specifies the organization or folder - * from which the custom module is inherited. - * @type \Google\Cloud\SecurityCenter\V1\CustomConfig $custom_config - * The user specified custom configuration for the module. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecurityHealthAnalyticsCustomModule::initOnce(); - parent::__construct($data); - } - - /** - * Immutable. The resource name of the custom module. - * Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" - * The id {customModule} is server-generated and is not user settable. - * It will be a numeric id containing 1-20 digits. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Immutable. The resource name of the custom module. - * Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" - * The id {customModule} is server-generated and is not user settable. - * It will be a numeric id containing 1-20 digits. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The display name of the Security Health Analytics custom module. This - * display name becomes the finding category for all findings that are - * returned by this custom module. The display name must be between 1 and - * 128 characters, start with a lowercase letter, and contain alphanumeric - * characters or underscores only. - * - * Generated from protobuf field string display_name = 2; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * The display name of the Security Health Analytics custom module. This - * display name becomes the finding category for all findings that are - * returned by this custom module. The display name must be between 1 and - * 128 characters, start with a lowercase letter, and contain alphanumeric - * characters or underscores only. - * - * Generated from protobuf field string display_name = 2; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * The enablement state of the custom module. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule.EnablementState enablement_state = 4; - * @return int - */ - public function getEnablementState() - { - return $this->enablement_state; - } - - /** - * The enablement state of the custom module. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule.EnablementState enablement_state = 4; - * @param int $var - * @return $this - */ - public function setEnablementState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule\EnablementState::class); - $this->enablement_state = $var; - - return $this; - } - - /** - * Output only. The time at which the custom module was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. The time at which the custom module was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Output only. The editor that last updated the custom module. - * - * Generated from protobuf field string last_editor = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getLastEditor() - { - return $this->last_editor; - } - - /** - * Output only. The editor that last updated the custom module. - * - * Generated from protobuf field string last_editor = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setLastEditor($var) - { - GPBUtil::checkString($var, True); - $this->last_editor = $var; - - return $this; - } - - /** - * Output only. If empty, indicates that the custom module was created in the - * organization, folder, or project in which you are viewing the custom - * module. Otherwise, `ancestor_module` specifies the organization or folder - * from which the custom module is inherited. - * - * Generated from protobuf field string ancestor_module = 7 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @return string - */ - public function getAncestorModule() - { - return $this->ancestor_module; - } - - /** - * Output only. If empty, indicates that the custom module was created in the - * organization, folder, or project in which you are viewing the custom - * module. Otherwise, `ancestor_module` specifies the organization or folder - * from which the custom module is inherited. - * - * Generated from protobuf field string ancestor_module = 7 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setAncestorModule($var) - { - GPBUtil::checkString($var, True); - $this->ancestor_module = $var; - - return $this; - } - - /** - * The user specified custom configuration for the module. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig custom_config = 8; - * @return \Google\Cloud\SecurityCenter\V1\CustomConfig|null - */ - public function getCustomConfig() - { - return $this->custom_config; - } - - public function hasCustomConfig() - { - return isset($this->custom_config); - } - - public function clearCustomConfig() - { - unset($this->custom_config); - } - - /** - * The user specified custom configuration for the module. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig custom_config = 8; - * @param \Google\Cloud\SecurityCenter\V1\CustomConfig $var - * @return $this - */ - public function setCustomConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\CustomConfig::class); - $this->custom_config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityHealthAnalyticsCustomModule/EnablementState.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityHealthAnalyticsCustomModule/EnablementState.php deleted file mode 100644 index 918e7ee654bf..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityHealthAnalyticsCustomModule/EnablementState.php +++ /dev/null @@ -1,73 +0,0 @@ -google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule.EnablementState - */ -class EnablementState -{ - /** - * Unspecified enablement state. - * - * Generated from protobuf enum ENABLEMENT_STATE_UNSPECIFIED = 0; - */ - const ENABLEMENT_STATE_UNSPECIFIED = 0; - /** - * The module is enabled at the given CRM resource. - * - * Generated from protobuf enum ENABLED = 1; - */ - const ENABLED = 1; - /** - * The module is disabled at the given CRM resource. - * - * Generated from protobuf enum DISABLED = 2; - */ - const DISABLED = 2; - /** - * State is inherited from an ancestor module. The module will either - * be effectively ENABLED or DISABLED based on its closest non-inherited - * ancestor module in the CRM hierarchy. - * - * Generated from protobuf enum INHERITED = 3; - */ - const INHERITED = 3; - - private static $valueToName = [ - self::ENABLEMENT_STATE_UNSPECIFIED => 'ENABLEMENT_STATE_UNSPECIFIED', - self::ENABLED => 'ENABLED', - self::DISABLED => 'DISABLED', - self::INHERITED => 'INHERITED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(EnablementState::class, \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule_EnablementState::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityMarks.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityMarks.php deleted file mode 100644 index d5a9c82d0fbc..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityMarks.php +++ /dev/null @@ -1,206 +0,0 @@ -google.cloud.securitycenter.v1.SecurityMarks - */ -class SecurityMarks extends \Google\Protobuf\Internal\Message -{ - /** - * The relative resource name of the SecurityMarks. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Examples: - * "organizations/{organization_id}/assets/{asset_id}/securityMarks" - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks". - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Mutable user specified security marks belonging to the parent resource. - * Constraints are as follows: - * * Keys and values are treated as case insensitive - * * Keys must be between 1 - 256 characters (inclusive) - * * Keys must be letters, numbers, underscores, or dashes - * * Values have leading and trailing whitespace trimmed, remaining - * characters must be between 1 - 4096 characters (inclusive) - * - * Generated from protobuf field map marks = 2; - */ - private $marks; - /** - * The canonical name of the marks. - * Examples: - * "organizations/{organization_id}/assets/{asset_id}/securityMarks" - * "folders/{folder_id}/assets/{asset_id}/securityMarks" - * "projects/{project_number}/assets/{asset_id}/securityMarks" - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks" - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks" - * "projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks" - * - * Generated from protobuf field string canonical_name = 3; - */ - protected $canonical_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The relative resource name of the SecurityMarks. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Examples: - * "organizations/{organization_id}/assets/{asset_id}/securityMarks" - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks". - * @type array|\Google\Protobuf\Internal\MapField $marks - * Mutable user specified security marks belonging to the parent resource. - * Constraints are as follows: - * * Keys and values are treated as case insensitive - * * Keys must be between 1 - 256 characters (inclusive) - * * Keys must be letters, numbers, underscores, or dashes - * * Values have leading and trailing whitespace trimmed, remaining - * characters must be between 1 - 4096 characters (inclusive) - * @type string $canonical_name - * The canonical name of the marks. - * Examples: - * "organizations/{organization_id}/assets/{asset_id}/securityMarks" - * "folders/{folder_id}/assets/{asset_id}/securityMarks" - * "projects/{project_number}/assets/{asset_id}/securityMarks" - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks" - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks" - * "projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks" - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecurityMarks::initOnce(); - parent::__construct($data); - } - - /** - * The relative resource name of the SecurityMarks. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Examples: - * "organizations/{organization_id}/assets/{asset_id}/securityMarks" - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks". - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The relative resource name of the SecurityMarks. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Examples: - * "organizations/{organization_id}/assets/{asset_id}/securityMarks" - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks". - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Mutable user specified security marks belonging to the parent resource. - * Constraints are as follows: - * * Keys and values are treated as case insensitive - * * Keys must be between 1 - 256 characters (inclusive) - * * Keys must be letters, numbers, underscores, or dashes - * * Values have leading and trailing whitespace trimmed, remaining - * characters must be between 1 - 4096 characters (inclusive) - * - * Generated from protobuf field map marks = 2; - * @return \Google\Protobuf\Internal\MapField - */ - public function getMarks() - { - return $this->marks; - } - - /** - * Mutable user specified security marks belonging to the parent resource. - * Constraints are as follows: - * * Keys and values are treated as case insensitive - * * Keys must be between 1 - 256 characters (inclusive) - * * Keys must be letters, numbers, underscores, or dashes - * * Values have leading and trailing whitespace trimmed, remaining - * characters must be between 1 - 4096 characters (inclusive) - * - * Generated from protobuf field map marks = 2; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setMarks($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->marks = $arr; - - return $this; - } - - /** - * The canonical name of the marks. - * Examples: - * "organizations/{organization_id}/assets/{asset_id}/securityMarks" - * "folders/{folder_id}/assets/{asset_id}/securityMarks" - * "projects/{project_number}/assets/{asset_id}/securityMarks" - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks" - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks" - * "projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks" - * - * Generated from protobuf field string canonical_name = 3; - * @return string - */ - public function getCanonicalName() - { - return $this->canonical_name; - } - - /** - * The canonical name of the marks. - * Examples: - * "organizations/{organization_id}/assets/{asset_id}/securityMarks" - * "folders/{folder_id}/assets/{asset_id}/securityMarks" - * "projects/{project_number}/assets/{asset_id}/securityMarks" - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks" - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks" - * "projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks" - * - * Generated from protobuf field string canonical_name = 3; - * @param string $var - * @return $this - */ - public function setCanonicalName($var) - { - GPBUtil::checkString($var, True); - $this->canonical_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPolicy.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPolicy.php deleted file mode 100644 index e08925f0b5a0..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPolicy.php +++ /dev/null @@ -1,149 +0,0 @@ -google.cloud.securitycenter.v1.SecurityPolicy - */ -class SecurityPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the Google Cloud Armor security policy, for example, - * "my-security-policy". - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The type of Google Cloud Armor security policy for example, ‘backend - * security policy’, ‘edge security policy’, ‘network edge security policy’, - * or ‘always-on DDoS protection’. - * - * Generated from protobuf field string type = 2; - */ - protected $type = ''; - /** - * Whether or not the associated rule or policy is in preview mode. - * - * Generated from protobuf field bool preview = 3; - */ - protected $preview = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the Google Cloud Armor security policy, for example, - * "my-security-policy". - * @type string $type - * The type of Google Cloud Armor security policy for example, ‘backend - * security policy’, ‘edge security policy’, ‘network edge security policy’, - * or ‘always-on DDoS protection’. - * @type bool $preview - * Whether or not the associated rule or policy is in preview mode. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\CloudArmor::initOnce(); - parent::__construct($data); - } - - /** - * The name of the Google Cloud Armor security policy, for example, - * "my-security-policy". - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the Google Cloud Armor security policy, for example, - * "my-security-policy". - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The type of Google Cloud Armor security policy for example, ‘backend - * security policy’, ‘edge security policy’, ‘network edge security policy’, - * or ‘always-on DDoS protection’. - * - * Generated from protobuf field string type = 2; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * The type of Google Cloud Armor security policy for example, ‘backend - * security policy’, ‘edge security policy’, ‘network edge security policy’, - * or ‘always-on DDoS protection’. - * - * Generated from protobuf field string type = 2; - * @param string $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkString($var, True); - $this->type = $var; - - return $this; - } - - /** - * Whether or not the associated rule or policy is in preview mode. - * - * Generated from protobuf field bool preview = 3; - * @return bool - */ - public function getPreview() - { - return $this->preview; - } - - /** - * Whether or not the associated rule or policy is in preview mode. - * - * Generated from protobuf field bool preview = 3; - * @param bool $var - * @return $this - */ - public function setPreview($var) - { - GPBUtil::checkBool($var); - $this->preview = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPosture.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPosture.php deleted file mode 100644 index 76779c96b647..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPosture.php +++ /dev/null @@ -1,325 +0,0 @@ -google.cloud.securitycenter.v1.SecurityPosture - */ -class SecurityPosture extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the posture, for example, `CIS-Posture`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The version of the posture, for example, `c7cfa2a8`. - * - * Generated from protobuf field string revision_id = 2; - */ - protected $revision_id = ''; - /** - * The project, folder, or organization on which the posture is deployed, - * for example, `projects/{project_number}`. - * - * Generated from protobuf field string posture_deployment_resource = 3; - */ - protected $posture_deployment_resource = ''; - /** - * The name of the posture deployment, for example, - * `organizations/{org_id}/posturedeployments/{posture_deployment_id}`. - * - * Generated from protobuf field string posture_deployment = 4; - */ - protected $posture_deployment = ''; - /** - * The name of the updated policy, for example, - * `projects/{project_id}/policies/{constraint_name}`. - * - * Generated from protobuf field string changed_policy = 5; - */ - protected $changed_policy = ''; - /** - * The name of the updated policyset, for example, `cis-policyset`. - * - * Generated from protobuf field string policy_set = 6; - */ - protected $policy_set = ''; - /** - * The ID of the updated policy, for example, `compute-policy-1`. - * - * Generated from protobuf field string policy = 7; - */ - protected $policy = ''; - /** - * The details about a change in an updated policy that violates the deployed - * posture. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.SecurityPosture.PolicyDriftDetails policy_drift_details = 8; - */ - private $policy_drift_details; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Name of the posture, for example, `CIS-Posture`. - * @type string $revision_id - * The version of the posture, for example, `c7cfa2a8`. - * @type string $posture_deployment_resource - * The project, folder, or organization on which the posture is deployed, - * for example, `projects/{project_number}`. - * @type string $posture_deployment - * The name of the posture deployment, for example, - * `organizations/{org_id}/posturedeployments/{posture_deployment_id}`. - * @type string $changed_policy - * The name of the updated policy, for example, - * `projects/{project_id}/policies/{constraint_name}`. - * @type string $policy_set - * The name of the updated policyset, for example, `cis-policyset`. - * @type string $policy - * The ID of the updated policy, for example, `compute-policy-1`. - * @type array<\Google\Cloud\SecurityCenter\V1\SecurityPosture\PolicyDriftDetails>|\Google\Protobuf\Internal\RepeatedField $policy_drift_details - * The details about a change in an updated policy that violates the deployed - * posture. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecurityPosture::initOnce(); - parent::__construct($data); - } - - /** - * Name of the posture, for example, `CIS-Posture`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Name of the posture, for example, `CIS-Posture`. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The version of the posture, for example, `c7cfa2a8`. - * - * Generated from protobuf field string revision_id = 2; - * @return string - */ - public function getRevisionId() - { - return $this->revision_id; - } - - /** - * The version of the posture, for example, `c7cfa2a8`. - * - * Generated from protobuf field string revision_id = 2; - * @param string $var - * @return $this - */ - public function setRevisionId($var) - { - GPBUtil::checkString($var, True); - $this->revision_id = $var; - - return $this; - } - - /** - * The project, folder, or organization on which the posture is deployed, - * for example, `projects/{project_number}`. - * - * Generated from protobuf field string posture_deployment_resource = 3; - * @return string - */ - public function getPostureDeploymentResource() - { - return $this->posture_deployment_resource; - } - - /** - * The project, folder, or organization on which the posture is deployed, - * for example, `projects/{project_number}`. - * - * Generated from protobuf field string posture_deployment_resource = 3; - * @param string $var - * @return $this - */ - public function setPostureDeploymentResource($var) - { - GPBUtil::checkString($var, True); - $this->posture_deployment_resource = $var; - - return $this; - } - - /** - * The name of the posture deployment, for example, - * `organizations/{org_id}/posturedeployments/{posture_deployment_id}`. - * - * Generated from protobuf field string posture_deployment = 4; - * @return string - */ - public function getPostureDeployment() - { - return $this->posture_deployment; - } - - /** - * The name of the posture deployment, for example, - * `organizations/{org_id}/posturedeployments/{posture_deployment_id}`. - * - * Generated from protobuf field string posture_deployment = 4; - * @param string $var - * @return $this - */ - public function setPostureDeployment($var) - { - GPBUtil::checkString($var, True); - $this->posture_deployment = $var; - - return $this; - } - - /** - * The name of the updated policy, for example, - * `projects/{project_id}/policies/{constraint_name}`. - * - * Generated from protobuf field string changed_policy = 5; - * @return string - */ - public function getChangedPolicy() - { - return $this->changed_policy; - } - - /** - * The name of the updated policy, for example, - * `projects/{project_id}/policies/{constraint_name}`. - * - * Generated from protobuf field string changed_policy = 5; - * @param string $var - * @return $this - */ - public function setChangedPolicy($var) - { - GPBUtil::checkString($var, True); - $this->changed_policy = $var; - - return $this; - } - - /** - * The name of the updated policyset, for example, `cis-policyset`. - * - * Generated from protobuf field string policy_set = 6; - * @return string - */ - public function getPolicySet() - { - return $this->policy_set; - } - - /** - * The name of the updated policyset, for example, `cis-policyset`. - * - * Generated from protobuf field string policy_set = 6; - * @param string $var - * @return $this - */ - public function setPolicySet($var) - { - GPBUtil::checkString($var, True); - $this->policy_set = $var; - - return $this; - } - - /** - * The ID of the updated policy, for example, `compute-policy-1`. - * - * Generated from protobuf field string policy = 7; - * @return string - */ - public function getPolicy() - { - return $this->policy; - } - - /** - * The ID of the updated policy, for example, `compute-policy-1`. - * - * Generated from protobuf field string policy = 7; - * @param string $var - * @return $this - */ - public function setPolicy($var) - { - GPBUtil::checkString($var, True); - $this->policy = $var; - - return $this; - } - - /** - * The details about a change in an updated policy that violates the deployed - * posture. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.SecurityPosture.PolicyDriftDetails policy_drift_details = 8; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPolicyDriftDetails() - { - return $this->policy_drift_details; - } - - /** - * The details about a change in an updated policy that violates the deployed - * posture. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1.SecurityPosture.PolicyDriftDetails policy_drift_details = 8; - * @param array<\Google\Cloud\SecurityCenter\V1\SecurityPosture\PolicyDriftDetails>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPolicyDriftDetails($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1\SecurityPosture\PolicyDriftDetails::class); - $this->policy_drift_details = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPosture/PolicyDriftDetails.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPosture/PolicyDriftDetails.php deleted file mode 100644 index 991b3c1a83e4..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SecurityPosture/PolicyDriftDetails.php +++ /dev/null @@ -1,151 +0,0 @@ -google.cloud.securitycenter.v1.SecurityPosture.PolicyDriftDetails - */ -class PolicyDriftDetails extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the updated field, for example - * constraint.implementation.policy_rules[0].enforce - * - * Generated from protobuf field string field = 1; - */ - protected $field = ''; - /** - * The value of this field that was configured in a posture, for example, - * `true` or `allowed_values={"projects/29831892"}`. - * - * Generated from protobuf field string expected_value = 2; - */ - protected $expected_value = ''; - /** - * The detected value that violates the deployed posture, for example, - * `false` or `allowed_values={"projects/22831892"}`. - * - * Generated from protobuf field string detected_value = 3; - */ - protected $detected_value = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $field - * The name of the updated field, for example - * constraint.implementation.policy_rules[0].enforce - * @type string $expected_value - * The value of this field that was configured in a posture, for example, - * `true` or `allowed_values={"projects/29831892"}`. - * @type string $detected_value - * The detected value that violates the deployed posture, for example, - * `false` or `allowed_values={"projects/22831892"}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecurityPosture::initOnce(); - parent::__construct($data); - } - - /** - * The name of the updated field, for example - * constraint.implementation.policy_rules[0].enforce - * - * Generated from protobuf field string field = 1; - * @return string - */ - public function getField() - { - return $this->field; - } - - /** - * The name of the updated field, for example - * constraint.implementation.policy_rules[0].enforce - * - * Generated from protobuf field string field = 1; - * @param string $var - * @return $this - */ - public function setField($var) - { - GPBUtil::checkString($var, True); - $this->field = $var; - - return $this; - } - - /** - * The value of this field that was configured in a posture, for example, - * `true` or `allowed_values={"projects/29831892"}`. - * - * Generated from protobuf field string expected_value = 2; - * @return string - */ - public function getExpectedValue() - { - return $this->expected_value; - } - - /** - * The value of this field that was configured in a posture, for example, - * `true` or `allowed_values={"projects/29831892"}`. - * - * Generated from protobuf field string expected_value = 2; - * @param string $var - * @return $this - */ - public function setExpectedValue($var) - { - GPBUtil::checkString($var, True); - $this->expected_value = $var; - - return $this; - } - - /** - * The detected value that violates the deployed posture, for example, - * `false` or `allowed_values={"projects/22831892"}`. - * - * Generated from protobuf field string detected_value = 3; - * @return string - */ - public function getDetectedValue() - { - return $this->detected_value; - } - - /** - * The detected value that violates the deployed posture, for example, - * `false` or `allowed_values={"projects/22831892"}`. - * - * Generated from protobuf field string detected_value = 3; - * @param string $var - * @return $this - */ - public function setDetectedValue($var) - { - GPBUtil::checkString($var, True); - $this->detected_value = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PolicyDriftDetails::class, \Google\Cloud\SecurityCenter\V1\SecurityPosture_PolicyDriftDetails::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ServiceAccountDelegationInfo.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ServiceAccountDelegationInfo.php deleted file mode 100644 index d6cb5540abbe..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ServiceAccountDelegationInfo.php +++ /dev/null @@ -1,125 +0,0 @@ -google.cloud.securitycenter.v1.ServiceAccountDelegationInfo - */ -class ServiceAccountDelegationInfo extends \Google\Protobuf\Internal\Message -{ - /** - * The email address of a Google account. - * - * Generated from protobuf field string principal_email = 1; - */ - protected $principal_email = ''; - /** - * A string representing the principal_subject associated with the identity. - * As compared to `principal_email`, supports principals that aren't - * associated with email addresses, such as third party principals. For most - * identities, the format will be `principal://iam.googleapis.com/{identity - * pool name}/subjects/{subject}` except for some GKE identities - * (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy - * format `serviceAccount:{identity pool name}[{subject}]` - * - * Generated from protobuf field string principal_subject = 2; - */ - protected $principal_subject = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $principal_email - * The email address of a Google account. - * @type string $principal_subject - * A string representing the principal_subject associated with the identity. - * As compared to `principal_email`, supports principals that aren't - * associated with email addresses, such as third party principals. For most - * identities, the format will be `principal://iam.googleapis.com/{identity - * pool name}/subjects/{subject}` except for some GKE identities - * (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy - * format `serviceAccount:{identity pool name}[{subject}]` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Access::initOnce(); - parent::__construct($data); - } - - /** - * The email address of a Google account. - * - * Generated from protobuf field string principal_email = 1; - * @return string - */ - public function getPrincipalEmail() - { - return $this->principal_email; - } - - /** - * The email address of a Google account. - * - * Generated from protobuf field string principal_email = 1; - * @param string $var - * @return $this - */ - public function setPrincipalEmail($var) - { - GPBUtil::checkString($var, True); - $this->principal_email = $var; - - return $this; - } - - /** - * A string representing the principal_subject associated with the identity. - * As compared to `principal_email`, supports principals that aren't - * associated with email addresses, such as third party principals. For most - * identities, the format will be `principal://iam.googleapis.com/{identity - * pool name}/subjects/{subject}` except for some GKE identities - * (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy - * format `serviceAccount:{identity pool name}[{subject}]` - * - * Generated from protobuf field string principal_subject = 2; - * @return string - */ - public function getPrincipalSubject() - { - return $this->principal_subject; - } - - /** - * A string representing the principal_subject associated with the identity. - * As compared to `principal_email`, supports principals that aren't - * associated with email addresses, such as third party principals. For most - * identities, the format will be `principal://iam.googleapis.com/{identity - * pool name}/subjects/{subject}` except for some GKE identities - * (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy - * format `serviceAccount:{identity pool name}[{subject}]` - * - * Generated from protobuf field string principal_subject = 2; - * @param string $var - * @return $this - */ - public function setPrincipalSubject($var) - { - GPBUtil::checkString($var, True); - $this->principal_subject = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SetFindingStateRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SetFindingStateRequest.php deleted file mode 100644 index afc55508447e..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SetFindingStateRequest.php +++ /dev/null @@ -1,189 +0,0 @@ -google.cloud.securitycenter.v1.SetFindingStateRequest - */ -class SetFindingStateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", - * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. The desired State of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.State state = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $state = 0; - /** - * Required. The time at which the updated state takes effect. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $start_time = null; - - /** - * @param string $name Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", - * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". Please see - * {@see SecurityCenterClient::findingName()} for help formatting this field. - * @param int $state Required. The desired State of the finding. - * For allowed values, use constants defined on {@see \Google\Cloud\SecurityCenter\V1\Finding\State} - * @param \Google\Protobuf\Timestamp $startTime Required. The time at which the updated state takes effect. - * - * @return \Google\Cloud\SecurityCenter\V1\SetFindingStateRequest - * - * @experimental - */ - public static function build(string $name, int $state, \Google\Protobuf\Timestamp $startTime): self - { - return (new self()) - ->setName($name) - ->setState($state) - ->setStartTime($startTime); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", - * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". - * @type int $state - * Required. The desired State of the finding. - * @type \Google\Protobuf\Timestamp $start_time - * Required. The time at which the updated state takes effect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", - * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", - * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. The desired State of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.State state = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Required. The desired State of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.State state = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Finding\State::class); - $this->state = $var; - - return $this; - } - - /** - * Required. The time at which the updated state takes effect. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getStartTime() - { - return $this->start_time; - } - - public function hasStartTime() - { - return isset($this->start_time); - } - - public function clearStartTime() - { - unset($this->start_time); - } - - /** - * Required. The time at which the updated state takes effect. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setStartTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->start_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SetMuteRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SetMuteRequest.php deleted file mode 100644 index e94e58b515f0..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SetMuteRequest.php +++ /dev/null @@ -1,143 +0,0 @@ -google.cloud.securitycenter.v1.SetMuteRequest - */ -class SetMuteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", - * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. The desired state of the Mute. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.Mute mute = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $mute = 0; - - /** - * @param string $name Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", - * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". Please see - * {@see SecurityCenterClient::findingName()} for help formatting this field. - * @param int $mute Required. The desired state of the Mute. - * For allowed values, use constants defined on {@see \Google\Cloud\SecurityCenter\V1\Finding\Mute} - * - * @return \Google\Cloud\SecurityCenter\V1\SetMuteRequest - * - * @experimental - */ - public static function build(string $name, int $mute): self - { - return (new self()) - ->setName($name) - ->setMute($mute); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", - * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". - * @type int $mute - * Required. The desired state of the Mute. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", - * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", - * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. The desired state of the Mute. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.Mute mute = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getMute() - { - return $this->mute; - } - - /** - * Required. The desired state of the Mute. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding.Mute mute = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setMute($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1\Finding\Mute::class); - $this->mute = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleRequest.php deleted file mode 100644 index 3bc4c0ad7ffd..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleRequest.php +++ /dev/null @@ -1,193 +0,0 @@ -google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleRequest - */ -class SimulateSecurityHealthAnalyticsCustomModuleRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The relative resource name of the organization, project, or - * folder. For more information about relative resource names, see [Relative - * Resource - * Name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * Example: `organizations/{organization_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $parent = ''; - /** - * Required. The custom configuration that you need to test. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig custom_config = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $custom_config = null; - /** - * Required. Resource data to simulate custom module against. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleRequest.SimulatedResource resource = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $resource = null; - - /** - * @param string $parent Required. The relative resource name of the organization, project, or - * folder. For more information about relative resource names, see [Relative - * Resource - * Name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * Example: `organizations/{organization_id}` - * @param \Google\Cloud\SecurityCenter\V1\CustomConfig $customConfig Required. The custom configuration that you need to test. - * @param \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleRequest\SimulatedResource $resource Required. Resource data to simulate custom module against. - * - * @return \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\SecurityCenter\V1\CustomConfig $customConfig, \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleRequest\SimulatedResource $resource): self - { - return (new self()) - ->setParent($parent) - ->setCustomConfig($customConfig) - ->setResource($resource); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The relative resource name of the organization, project, or - * folder. For more information about relative resource names, see [Relative - * Resource - * Name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * Example: `organizations/{organization_id}` - * @type \Google\Cloud\SecurityCenter\V1\CustomConfig $custom_config - * Required. The custom configuration that you need to test. - * @type \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleRequest\SimulatedResource $resource - * Required. Resource data to simulate custom module against. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The relative resource name of the organization, project, or - * folder. For more information about relative resource names, see [Relative - * Resource - * Name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * Example: `organizations/{organization_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The relative resource name of the organization, project, or - * folder. For more information about relative resource names, see [Relative - * Resource - * Name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * Example: `organizations/{organization_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The custom configuration that you need to test. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig custom_config = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1\CustomConfig|null - */ - public function getCustomConfig() - { - return $this->custom_config; - } - - public function hasCustomConfig() - { - return isset($this->custom_config); - } - - public function clearCustomConfig() - { - unset($this->custom_config); - } - - /** - * Required. The custom configuration that you need to test. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.CustomConfig custom_config = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1\CustomConfig $var - * @return $this - */ - public function setCustomConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\CustomConfig::class); - $this->custom_config = $var; - - return $this; - } - - /** - * Required. Resource data to simulate custom module against. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleRequest.SimulatedResource resource = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleRequest\SimulatedResource|null - */ - public function getResource() - { - return $this->resource; - } - - public function hasResource() - { - return isset($this->resource); - } - - public function clearResource() - { - unset($this->resource); - } - - /** - * Required. Resource data to simulate custom module against. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleRequest.SimulatedResource resource = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleRequest\SimulatedResource $var - * @return $this - */ - public function setResource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleRequest\SimulatedResource::class); - $this->resource = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleRequest/SimulatedResource.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleRequest/SimulatedResource.php deleted file mode 100644 index 07b581a0ffb0..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleRequest/SimulatedResource.php +++ /dev/null @@ -1,168 +0,0 @@ -google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleRequest.SimulatedResource - */ -class SimulatedResource extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The type of the resource, for example, - * `compute.googleapis.com/Disk`. - * - * Generated from protobuf field string resource_type = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $resource_type = ''; - /** - * Optional. A representation of the Google Cloud resource. Should match the - * Google Cloud resource JSON format. - * - * Generated from protobuf field .google.protobuf.Struct resource_data = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $resource_data = null; - /** - * Optional. A representation of the IAM policy. - * - * Generated from protobuf field .google.iam.v1.Policy iam_policy_data = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $iam_policy_data = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $resource_type - * Required. The type of the resource, for example, - * `compute.googleapis.com/Disk`. - * @type \Google\Protobuf\Struct $resource_data - * Optional. A representation of the Google Cloud resource. Should match the - * Google Cloud resource JSON format. - * @type \Google\Cloud\Iam\V1\Policy $iam_policy_data - * Optional. A representation of the IAM policy. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The type of the resource, for example, - * `compute.googleapis.com/Disk`. - * - * Generated from protobuf field string resource_type = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getResourceType() - { - return $this->resource_type; - } - - /** - * Required. The type of the resource, for example, - * `compute.googleapis.com/Disk`. - * - * Generated from protobuf field string resource_type = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setResourceType($var) - { - GPBUtil::checkString($var, True); - $this->resource_type = $var; - - return $this; - } - - /** - * Optional. A representation of the Google Cloud resource. Should match the - * Google Cloud resource JSON format. - * - * Generated from protobuf field .google.protobuf.Struct resource_data = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Struct|null - */ - public function getResourceData() - { - return $this->resource_data; - } - - public function hasResourceData() - { - return isset($this->resource_data); - } - - public function clearResourceData() - { - unset($this->resource_data); - } - - /** - * Optional. A representation of the Google Cloud resource. Should match the - * Google Cloud resource JSON format. - * - * Generated from protobuf field .google.protobuf.Struct resource_data = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Struct $var - * @return $this - */ - public function setResourceData($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); - $this->resource_data = $var; - - return $this; - } - - /** - * Optional. A representation of the IAM policy. - * - * Generated from protobuf field .google.iam.v1.Policy iam_policy_data = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Iam\V1\Policy|null - */ - public function getIamPolicyData() - { - return $this->iam_policy_data; - } - - public function hasIamPolicyData() - { - return isset($this->iam_policy_data); - } - - public function clearIamPolicyData() - { - unset($this->iam_policy_data); - } - - /** - * Optional. A representation of the IAM policy. - * - * Generated from protobuf field .google.iam.v1.Policy iam_policy_data = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Iam\V1\Policy $var - * @return $this - */ - public function setIamPolicyData($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Iam\V1\Policy::class); - $this->iam_policy_data = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SimulatedResource::class, \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleRequest_SimulatedResource::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleResponse.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleResponse.php deleted file mode 100644 index 6418daab5b4d..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleResponse.php +++ /dev/null @@ -1,78 +0,0 @@ -google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleResponse - */ -class SimulateSecurityHealthAnalyticsCustomModuleResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Result for test case in the corresponding request. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleResponse.SimulatedResult result = 1; - */ - protected $result = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleResponse\SimulatedResult $result - * Result for test case in the corresponding request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Result for test case in the corresponding request. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleResponse.SimulatedResult result = 1; - * @return \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleResponse\SimulatedResult|null - */ - public function getResult() - { - return $this->result; - } - - public function hasResult() - { - return isset($this->result); - } - - public function clearResult() - { - unset($this->result); - } - - /** - * Result for test case in the corresponding request. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleResponse.SimulatedResult result = 1; - * @param \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleResponse\SimulatedResult $var - * @return $this - */ - public function setResult($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleResponse\SimulatedResult::class); - $this->result = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleResponse/SimulatedResult.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleResponse/SimulatedResult.php deleted file mode 100644 index 4c191593a2ee..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/SimulateSecurityHealthAnalyticsCustomModuleResponse/SimulatedResult.php +++ /dev/null @@ -1,147 +0,0 @@ -google.cloud.securitycenter.v1.SimulateSecurityHealthAnalyticsCustomModuleResponse.SimulatedResult - */ -class SimulatedResult extends \Google\Protobuf\Internal\Message -{ - protected $result; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1\Finding $finding - * Finding that would be published for the test case, - * if a violation is detected. - * @type \Google\Protobuf\GPBEmpty $no_violation - * Indicates that the test case does not trigger any violation. - * @type \Google\Rpc\Status $error - * Error encountered during the test. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Finding that would be published for the test case, - * if a violation is detected. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 1; - * @return \Google\Cloud\SecurityCenter\V1\Finding|null - */ - public function getFinding() - { - return $this->readOneof(1); - } - - public function hasFinding() - { - return $this->hasOneof(1); - } - - /** - * Finding that would be published for the test case, - * if a violation is detected. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 1; - * @param \Google\Cloud\SecurityCenter\V1\Finding $var - * @return $this - */ - public function setFinding($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Finding::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Indicates that the test case does not trigger any violation. - * - * Generated from protobuf field .google.protobuf.Empty no_violation = 2; - * @return \Google\Protobuf\GPBEmpty|null - */ - public function getNoViolation() - { - return $this->readOneof(2); - } - - public function hasNoViolation() - { - return $this->hasOneof(2); - } - - /** - * Indicates that the test case does not trigger any violation. - * - * Generated from protobuf field .google.protobuf.Empty no_violation = 2; - * @param \Google\Protobuf\GPBEmpty $var - * @return $this - */ - public function setNoViolation($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\GPBEmpty::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Error encountered during the test. - * - * Generated from protobuf field .google.rpc.Status error = 3; - * @return \Google\Rpc\Status|null - */ - public function getError() - { - return $this->readOneof(3); - } - - public function hasError() - { - return $this->hasOneof(3); - } - - /** - * Error encountered during the test. - * - * Generated from protobuf field .google.rpc.Status error = 3; - * @param \Google\Rpc\Status $var - * @return $this - */ - public function setError($var) - { - GPBUtil::checkMessage($var, \Google\Rpc\Status::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * @return string - */ - public function getResult() - { - return $this->whichOneof("result"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SimulatedResult::class, \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleResponse_SimulatedResult::class); - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Source.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Source.php deleted file mode 100644 index e97bce183d3c..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Source.php +++ /dev/null @@ -1,244 +0,0 @@ -google.cloud.securitycenter.v1.Source - */ -class Source extends \Google\Protobuf\Internal\Message -{ - /** - * The relative resource name of this source. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}" - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The source's display name. - * A source's display name must be unique amongst its siblings, for example, - * two sources with the same parent can't share the same display name. - * The display name must have a length between 1 and 64 characters - * (inclusive). - * - * Generated from protobuf field string display_name = 2; - */ - protected $display_name = ''; - /** - * The description of the source (max of 1024 characters). - * Example: - * "Web Security Scanner is a web security scanner for common - * vulnerabilities in App Engine applications. It can automatically - * scan and detect four common vulnerabilities, including cross-site-scripting - * (XSS), Flash injection, mixed content (HTTP in HTTPS), and - * outdated or insecure libraries." - * - * Generated from protobuf field string description = 3; - */ - protected $description = ''; - /** - * The canonical name of the finding source. It's either - * "organizations/{organization_id}/sources/{source_id}", - * "folders/{folder_id}/sources/{source_id}", or - * "projects/{project_number}/sources/{source_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * - * Generated from protobuf field string canonical_name = 14; - */ - protected $canonical_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The relative resource name of this source. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}" - * @type string $display_name - * The source's display name. - * A source's display name must be unique amongst its siblings, for example, - * two sources with the same parent can't share the same display name. - * The display name must have a length between 1 and 64 characters - * (inclusive). - * @type string $description - * The description of the source (max of 1024 characters). - * Example: - * "Web Security Scanner is a web security scanner for common - * vulnerabilities in App Engine applications. It can automatically - * scan and detect four common vulnerabilities, including cross-site-scripting - * (XSS), Flash injection, mixed content (HTTP in HTTPS), and - * outdated or insecure libraries." - * @type string $canonical_name - * The canonical name of the finding source. It's either - * "organizations/{organization_id}/sources/{source_id}", - * "folders/{folder_id}/sources/{source_id}", or - * "projects/{project_number}/sources/{source_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Source::initOnce(); - parent::__construct($data); - } - - /** - * The relative resource name of this source. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}" - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The relative resource name of this source. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}" - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The source's display name. - * A source's display name must be unique amongst its siblings, for example, - * two sources with the same parent can't share the same display name. - * The display name must have a length between 1 and 64 characters - * (inclusive). - * - * Generated from protobuf field string display_name = 2; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * The source's display name. - * A source's display name must be unique amongst its siblings, for example, - * two sources with the same parent can't share the same display name. - * The display name must have a length between 1 and 64 characters - * (inclusive). - * - * Generated from protobuf field string display_name = 2; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * The description of the source (max of 1024 characters). - * Example: - * "Web Security Scanner is a web security scanner for common - * vulnerabilities in App Engine applications. It can automatically - * scan and detect four common vulnerabilities, including cross-site-scripting - * (XSS), Flash injection, mixed content (HTTP in HTTPS), and - * outdated or insecure libraries." - * - * Generated from protobuf field string description = 3; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * The description of the source (max of 1024 characters). - * Example: - * "Web Security Scanner is a web security scanner for common - * vulnerabilities in App Engine applications. It can automatically - * scan and detect four common vulnerabilities, including cross-site-scripting - * (XSS), Flash injection, mixed content (HTTP in HTTPS), and - * outdated or insecure libraries." - * - * Generated from protobuf field string description = 3; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * The canonical name of the finding source. It's either - * "organizations/{organization_id}/sources/{source_id}", - * "folders/{folder_id}/sources/{source_id}", or - * "projects/{project_number}/sources/{source_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * - * Generated from protobuf field string canonical_name = 14; - * @return string - */ - public function getCanonicalName() - { - return $this->canonical_name; - } - - /** - * The canonical name of the finding source. It's either - * "organizations/{organization_id}/sources/{source_id}", - * "folders/{folder_id}/sources/{source_id}", or - * "projects/{project_number}/sources/{source_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * - * Generated from protobuf field string canonical_name = 14; - * @param string $var - * @return $this - */ - public function setCanonicalName($var) - { - GPBUtil::checkString($var, True); - $this->canonical_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ToxicCombination.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ToxicCombination.php deleted file mode 100644 index 23d845ebfdd7..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/ToxicCombination.php +++ /dev/null @@ -1,123 +0,0 @@ -google.cloud.securitycenter.v1.ToxicCombination - */ -class ToxicCombination extends \Google\Protobuf\Internal\Message -{ - /** - * The - * [Attack exposure - * score](https://cloud.google.com/security-command-center/docs/attack-exposure-learn#attack_exposure_scores) - * of this toxic combination. The score is a measure of how much this toxic - * combination exposes one or more high-value resources to potential attack. - * - * Generated from protobuf field double attack_exposure_score = 1; - */ - protected $attack_exposure_score = 0.0; - /** - * List of resource names of findings associated with this toxic combination. - * For example, `organizations/123/sources/456/findings/789`. - * - * Generated from protobuf field repeated string related_findings = 2; - */ - private $related_findings; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type float $attack_exposure_score - * The - * [Attack exposure - * score](https://cloud.google.com/security-command-center/docs/attack-exposure-learn#attack_exposure_scores) - * of this toxic combination. The score is a measure of how much this toxic - * combination exposes one or more high-value resources to potential attack. - * @type array|\Google\Protobuf\Internal\RepeatedField $related_findings - * List of resource names of findings associated with this toxic combination. - * For example, `organizations/123/sources/456/findings/789`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\ToxicCombination::initOnce(); - parent::__construct($data); - } - - /** - * The - * [Attack exposure - * score](https://cloud.google.com/security-command-center/docs/attack-exposure-learn#attack_exposure_scores) - * of this toxic combination. The score is a measure of how much this toxic - * combination exposes one or more high-value resources to potential attack. - * - * Generated from protobuf field double attack_exposure_score = 1; - * @return float - */ - public function getAttackExposureScore() - { - return $this->attack_exposure_score; - } - - /** - * The - * [Attack exposure - * score](https://cloud.google.com/security-command-center/docs/attack-exposure-learn#attack_exposure_scores) - * of this toxic combination. The score is a measure of how much this toxic - * combination exposes one or more high-value resources to potential attack. - * - * Generated from protobuf field double attack_exposure_score = 1; - * @param float $var - * @return $this - */ - public function setAttackExposureScore($var) - { - GPBUtil::checkDouble($var); - $this->attack_exposure_score = $var; - - return $this; - } - - /** - * List of resource names of findings associated with this toxic combination. - * For example, `organizations/123/sources/456/findings/789`. - * - * Generated from protobuf field repeated string related_findings = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRelatedFindings() - { - return $this->related_findings; - } - - /** - * List of resource names of findings associated with this toxic combination. - * For example, `organizations/123/sources/456/findings/789`. - * - * Generated from protobuf field repeated string related_findings = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRelatedFindings($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->related_findings = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateBigQueryExportRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateBigQueryExportRequest.php deleted file mode 100644 index 5242f30292f0..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateBigQueryExportRequest.php +++ /dev/null @@ -1,141 +0,0 @@ -google.cloud.securitycenter.v1.UpdateBigQueryExportRequest - */ -class UpdateBigQueryExportRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The BigQuery export being updated. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.BigQueryExport big_query_export = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $big_query_export = null; - /** - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\SecurityCenter\V1\BigQueryExport $bigQueryExport Required. The BigQuery export being updated. - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. - * If empty all mutable fields will be updated. - * - * @return \Google\Cloud\SecurityCenter\V1\UpdateBigQueryExportRequest - * - * @experimental - */ - public static function build(\Google\Cloud\SecurityCenter\V1\BigQueryExport $bigQueryExport, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setBigQueryExport($bigQueryExport) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1\BigQueryExport $big_query_export - * Required. The BigQuery export being updated. - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The BigQuery export being updated. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.BigQueryExport big_query_export = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1\BigQueryExport|null - */ - public function getBigQueryExport() - { - return $this->big_query_export; - } - - public function hasBigQueryExport() - { - return isset($this->big_query_export); - } - - public function clearBigQueryExport() - { - unset($this->big_query_export); - } - - /** - * Required. The BigQuery export being updated. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.BigQueryExport big_query_export = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1\BigQueryExport $var - * @return $this - */ - public function setBigQueryExport($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\BigQueryExport::class); - $this->big_query_export = $var; - - return $this; - } - - /** - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateExternalSystemRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateExternalSystemRequest.php deleted file mode 100644 index ceaa44f6abf7..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateExternalSystemRequest.php +++ /dev/null @@ -1,142 +0,0 @@ -google.cloud.securitycenter.v1.UpdateExternalSystemRequest - */ -class UpdateExternalSystemRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The external system resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.ExternalSystem external_system = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $external_system = null; - /** - * The FieldMask to use when updating the external system resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\SecurityCenter\V1\ExternalSystem $externalSystem Required. The external system resource to update. - * @param \Google\Protobuf\FieldMask $updateMask The FieldMask to use when updating the external system resource. - * - * If empty all mutable fields will be updated. - * - * @return \Google\Cloud\SecurityCenter\V1\UpdateExternalSystemRequest - * - * @experimental - */ - public static function build(\Google\Cloud\SecurityCenter\V1\ExternalSystem $externalSystem, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setExternalSystem($externalSystem) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1\ExternalSystem $external_system - * Required. The external system resource to update. - * @type \Google\Protobuf\FieldMask $update_mask - * The FieldMask to use when updating the external system resource. - * If empty all mutable fields will be updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The external system resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.ExternalSystem external_system = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1\ExternalSystem|null - */ - public function getExternalSystem() - { - return $this->external_system; - } - - public function hasExternalSystem() - { - return isset($this->external_system); - } - - public function clearExternalSystem() - { - unset($this->external_system); - } - - /** - * Required. The external system resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.ExternalSystem external_system = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1\ExternalSystem $var - * @return $this - */ - public function setExternalSystem($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\ExternalSystem::class); - $this->external_system = $var; - - return $this; - } - - /** - * The FieldMask to use when updating the external system resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The FieldMask to use when updating the external system resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateFindingRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateFindingRequest.php deleted file mode 100644 index 365c64c12143..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateFindingRequest.php +++ /dev/null @@ -1,175 +0,0 @@ -google.cloud.securitycenter.v1.UpdateFindingRequest - */ -class UpdateFindingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The finding resource to update or create if it does not already - * exist. parent, security_marks, and update_time will be ignored. - * In the case of creation, the finding id portion of the name must be - * alphanumeric and less than or equal to 32 characters and greater than 0 - * characters in length. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $finding = null; - /** - * The FieldMask to use when updating the finding resource. This field should - * not be specified when creating a finding. - * When updating a finding, an empty mask is treated as updating all mutable - * fields and replacing source_properties. Individual source_properties can - * be added/updated by using "source_properties." in the field - * mask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\SecurityCenter\V1\Finding $finding Required. The finding resource to update or create if it does not already - * exist. parent, security_marks, and update_time will be ignored. - * - * In the case of creation, the finding id portion of the name must be - * alphanumeric and less than or equal to 32 characters and greater than 0 - * characters in length. - * - * @return \Google\Cloud\SecurityCenter\V1\UpdateFindingRequest - * - * @experimental - */ - public static function build(\Google\Cloud\SecurityCenter\V1\Finding $finding): self - { - return (new self()) - ->setFinding($finding); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1\Finding $finding - * Required. The finding resource to update or create if it does not already - * exist. parent, security_marks, and update_time will be ignored. - * In the case of creation, the finding id portion of the name must be - * alphanumeric and less than or equal to 32 characters and greater than 0 - * characters in length. - * @type \Google\Protobuf\FieldMask $update_mask - * The FieldMask to use when updating the finding resource. This field should - * not be specified when creating a finding. - * When updating a finding, an empty mask is treated as updating all mutable - * fields and replacing source_properties. Individual source_properties can - * be added/updated by using "source_properties." in the field - * mask. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The finding resource to update or create if it does not already - * exist. parent, security_marks, and update_time will be ignored. - * In the case of creation, the finding id portion of the name must be - * alphanumeric and less than or equal to 32 characters and greater than 0 - * characters in length. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1\Finding|null - */ - public function getFinding() - { - return $this->finding; - } - - public function hasFinding() - { - return isset($this->finding); - } - - public function clearFinding() - { - unset($this->finding); - } - - /** - * Required. The finding resource to update or create if it does not already - * exist. parent, security_marks, and update_time will be ignored. - * In the case of creation, the finding id portion of the name must be - * alphanumeric and less than or equal to 32 characters and greater than 0 - * characters in length. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Finding finding = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1\Finding $var - * @return $this - */ - public function setFinding($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Finding::class); - $this->finding = $var; - - return $this; - } - - /** - * The FieldMask to use when updating the finding resource. This field should - * not be specified when creating a finding. - * When updating a finding, an empty mask is treated as updating all mutable - * fields and replacing source_properties. Individual source_properties can - * be added/updated by using "source_properties." in the field - * mask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The FieldMask to use when updating the finding resource. This field should - * not be specified when creating a finding. - * When updating a finding, an empty mask is treated as updating all mutable - * fields and replacing source_properties. Individual source_properties can - * be added/updated by using "source_properties." in the field - * mask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateMuteConfigRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateMuteConfigRequest.php deleted file mode 100644 index deae46e7e6ac..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateMuteConfigRequest.php +++ /dev/null @@ -1,141 +0,0 @@ -google.cloud.securitycenter.v1.UpdateMuteConfigRequest - */ -class UpdateMuteConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The mute config being updated. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.MuteConfig mute_config = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $mute_config = null; - /** - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\SecurityCenter\V1\MuteConfig $muteConfig Required. The mute config being updated. - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. - * If empty all mutable fields will be updated. - * - * @return \Google\Cloud\SecurityCenter\V1\UpdateMuteConfigRequest - * - * @experimental - */ - public static function build(\Google\Cloud\SecurityCenter\V1\MuteConfig $muteConfig, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setMuteConfig($muteConfig) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1\MuteConfig $mute_config - * Required. The mute config being updated. - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The mute config being updated. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.MuteConfig mute_config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1\MuteConfig|null - */ - public function getMuteConfig() - { - return $this->mute_config; - } - - public function hasMuteConfig() - { - return isset($this->mute_config); - } - - public function clearMuteConfig() - { - unset($this->mute_config); - } - - /** - * Required. The mute config being updated. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.MuteConfig mute_config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1\MuteConfig $var - * @return $this - */ - public function setMuteConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\MuteConfig::class); - $this->mute_config = $var; - - return $this; - } - - /** - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateNotificationConfigRequest.php deleted file mode 100644 index 2fd6dd439c34..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateNotificationConfigRequest.php +++ /dev/null @@ -1,155 +0,0 @@ -google.cloud.securitycenter.v1.UpdateNotificationConfigRequest - */ -class UpdateNotificationConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The notification config to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.NotificationConfig notification_config = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $notification_config = null; - /** - * The FieldMask to use when updating the notification config. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\SecurityCenter\V1\NotificationConfig $notificationConfig Required. The notification config to update. - * - * @return \Google\Cloud\SecurityCenter\V1\UpdateNotificationConfigRequest - * - * @experimental - */ - public static function build(\Google\Cloud\SecurityCenter\V1\NotificationConfig $notificationConfig): self - { - return (new self()) - ->setNotificationConfig($notificationConfig); - } - - /** - * @param \Google\Cloud\SecurityCenter\V1\NotificationConfig $notificationConfig Required. The notification config to update. - * @param \Google\Protobuf\FieldMask $updateMask The FieldMask to use when updating the notification config. - * - * If empty all mutable fields will be updated. - * - * @return \Google\Cloud\SecurityCenter\V1\UpdateNotificationConfigRequest - * - * @experimental - */ - public static function buildFromNotificationConfigUpdateMask(\Google\Cloud\SecurityCenter\V1\NotificationConfig $notificationConfig, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setNotificationConfig($notificationConfig) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1\NotificationConfig $notification_config - * Required. The notification config to update. - * @type \Google\Protobuf\FieldMask $update_mask - * The FieldMask to use when updating the notification config. - * If empty all mutable fields will be updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The notification config to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.NotificationConfig notification_config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1\NotificationConfig|null - */ - public function getNotificationConfig() - { - return $this->notification_config; - } - - public function hasNotificationConfig() - { - return isset($this->notification_config); - } - - public function clearNotificationConfig() - { - unset($this->notification_config); - } - - /** - * Required. The notification config to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.NotificationConfig notification_config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1\NotificationConfig $var - * @return $this - */ - public function setNotificationConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\NotificationConfig::class); - $this->notification_config = $var; - - return $this; - } - - /** - * The FieldMask to use when updating the notification config. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The FieldMask to use when updating the notification config. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateOrganizationSettingsRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateOrganizationSettingsRequest.php deleted file mode 100644 index 57cf776c0bef..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateOrganizationSettingsRequest.php +++ /dev/null @@ -1,138 +0,0 @@ -google.cloud.securitycenter.v1.UpdateOrganizationSettingsRequest - */ -class UpdateOrganizationSettingsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The organization settings resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.OrganizationSettings organization_settings = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $organization_settings = null; - /** - * The FieldMask to use when updating the settings resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\SecurityCenter\V1\OrganizationSettings $organizationSettings Required. The organization settings resource to update. - * - * @return \Google\Cloud\SecurityCenter\V1\UpdateOrganizationSettingsRequest - * - * @experimental - */ - public static function build(\Google\Cloud\SecurityCenter\V1\OrganizationSettings $organizationSettings): self - { - return (new self()) - ->setOrganizationSettings($organizationSettings); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1\OrganizationSettings $organization_settings - * Required. The organization settings resource to update. - * @type \Google\Protobuf\FieldMask $update_mask - * The FieldMask to use when updating the settings resource. - * If empty all mutable fields will be updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The organization settings resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.OrganizationSettings organization_settings = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1\OrganizationSettings|null - */ - public function getOrganizationSettings() - { - return $this->organization_settings; - } - - public function hasOrganizationSettings() - { - return isset($this->organization_settings); - } - - public function clearOrganizationSettings() - { - unset($this->organization_settings); - } - - /** - * Required. The organization settings resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.OrganizationSettings organization_settings = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1\OrganizationSettings $var - * @return $this - */ - public function setOrganizationSettings($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\OrganizationSettings::class); - $this->organization_settings = $var; - - return $this; - } - - /** - * The FieldMask to use when updating the settings resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The FieldMask to use when updating the settings resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSecurityHealthAnalyticsCustomModuleRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSecurityHealthAnalyticsCustomModuleRequest.php deleted file mode 100644 index 5d08afcbd681..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSecurityHealthAnalyticsCustomModuleRequest.php +++ /dev/null @@ -1,136 +0,0 @@ -google.cloud.securitycenter.v1.UpdateSecurityHealthAnalyticsCustomModuleRequest - */ -class UpdateSecurityHealthAnalyticsCustomModuleRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The SecurityHealthAnalytics custom module to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_module = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $security_health_analytics_custom_module = null; - /** - * The list of fields to update. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule $securityHealthAnalyticsCustomModule Required. The SecurityHealthAnalytics custom module to update. - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to update. - * - * @return \Google\Cloud\SecurityCenter\V1\UpdateSecurityHealthAnalyticsCustomModuleRequest - * - * @experimental - */ - public static function build(\Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule $securityHealthAnalyticsCustomModule, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule $security_health_analytics_custom_module - * Required. The SecurityHealthAnalytics custom module to update. - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to update. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The SecurityHealthAnalytics custom module to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_module = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule|null - */ - public function getSecurityHealthAnalyticsCustomModule() - { - return $this->security_health_analytics_custom_module; - } - - public function hasSecurityHealthAnalyticsCustomModule() - { - return isset($this->security_health_analytics_custom_module); - } - - public function clearSecurityHealthAnalyticsCustomModule() - { - unset($this->security_health_analytics_custom_module); - } - - /** - * Required. The SecurityHealthAnalytics custom module to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityHealthAnalyticsCustomModule security_health_analytics_custom_module = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule $var - * @return $this - */ - public function setSecurityHealthAnalyticsCustomModule($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule::class); - $this->security_health_analytics_custom_module = $var; - - return $this; - } - - /** - * The list of fields to update. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The list of fields to update. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSecurityMarksRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSecurityMarksRequest.php deleted file mode 100644 index 25ecb2d7b10e..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSecurityMarksRequest.php +++ /dev/null @@ -1,202 +0,0 @@ -google.cloud.securitycenter.v1.UpdateSecurityMarksRequest - */ -class UpdateSecurityMarksRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The security marks resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityMarks security_marks = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $security_marks = null; - /** - * The FieldMask to use when updating the security marks resource. - * The field mask must not contain duplicate fields. - * If empty or set to "marks", all marks will be replaced. Individual - * marks can be updated using "marks.". - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - /** - * The time at which the updated SecurityMarks take effect. - * If not set uses current server time. Updates will be applied to the - * SecurityMarks that are active immediately preceding this time. Must be - * earlier or equal to the server time. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 3; - */ - protected $start_time = null; - - /** - * @param \Google\Cloud\SecurityCenter\V1\SecurityMarks $securityMarks Required. The security marks resource to update. - * - * @return \Google\Cloud\SecurityCenter\V1\UpdateSecurityMarksRequest - * - * @experimental - */ - public static function build(\Google\Cloud\SecurityCenter\V1\SecurityMarks $securityMarks): self - { - return (new self()) - ->setSecurityMarks($securityMarks); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1\SecurityMarks $security_marks - * Required. The security marks resource to update. - * @type \Google\Protobuf\FieldMask $update_mask - * The FieldMask to use when updating the security marks resource. - * The field mask must not contain duplicate fields. - * If empty or set to "marks", all marks will be replaced. Individual - * marks can be updated using "marks.". - * @type \Google\Protobuf\Timestamp $start_time - * The time at which the updated SecurityMarks take effect. - * If not set uses current server time. Updates will be applied to the - * SecurityMarks that are active immediately preceding this time. Must be - * earlier or equal to the server time. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The security marks resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityMarks security_marks = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1\SecurityMarks|null - */ - public function getSecurityMarks() - { - return $this->security_marks; - } - - public function hasSecurityMarks() - { - return isset($this->security_marks); - } - - public function clearSecurityMarks() - { - unset($this->security_marks); - } - - /** - * Required. The security marks resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityMarks security_marks = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1\SecurityMarks $var - * @return $this - */ - public function setSecurityMarks($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SecurityMarks::class); - $this->security_marks = $var; - - return $this; - } - - /** - * The FieldMask to use when updating the security marks resource. - * The field mask must not contain duplicate fields. - * If empty or set to "marks", all marks will be replaced. Individual - * marks can be updated using "marks.". - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The FieldMask to use when updating the security marks resource. - * The field mask must not contain duplicate fields. - * If empty or set to "marks", all marks will be replaced. Individual - * marks can be updated using "marks.". - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - - /** - * The time at which the updated SecurityMarks take effect. - * If not set uses current server time. Updates will be applied to the - * SecurityMarks that are active immediately preceding this time. Must be - * earlier or equal to the server time. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 3; - * @return \Google\Protobuf\Timestamp|null - */ - public function getStartTime() - { - return $this->start_time; - } - - public function hasStartTime() - { - return isset($this->start_time); - } - - public function clearStartTime() - { - unset($this->start_time); - } - - /** - * The time at which the updated SecurityMarks take effect. - * If not set uses current server time. Updates will be applied to the - * SecurityMarks that are active immediately preceding this time. Must be - * earlier or equal to the server time. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 3; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setStartTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->start_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSourceRequest.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSourceRequest.php deleted file mode 100644 index 5556e978062e..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/UpdateSourceRequest.php +++ /dev/null @@ -1,138 +0,0 @@ -google.cloud.securitycenter.v1.UpdateSourceRequest - */ -class UpdateSourceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The source resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Source source = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $source = null; - /** - * The FieldMask to use when updating the source resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\SecurityCenter\V1\Source $source Required. The source resource to update. - * - * @return \Google\Cloud\SecurityCenter\V1\UpdateSourceRequest - * - * @experimental - */ - public static function build(\Google\Cloud\SecurityCenter\V1\Source $source): self - { - return (new self()) - ->setSource($source); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1\Source $source - * Required. The source resource to update. - * @type \Google\Protobuf\FieldMask $update_mask - * The FieldMask to use when updating the source resource. - * If empty all mutable fields will be updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The source resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Source source = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1\Source|null - */ - public function getSource() - { - return $this->source; - } - - public function hasSource() - { - return isset($this->source); - } - - public function clearSource() - { - unset($this->source); - } - - /** - * Required. The source resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Source source = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1\Source $var - * @return $this - */ - public function setSource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Source::class); - $this->source = $var; - - return $this; - } - - /** - * The FieldMask to use when updating the source resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The FieldMask to use when updating the source resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Vulnerability.php b/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Vulnerability.php deleted file mode 100644 index 961cb0210a9e..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/proto/src/Google/Cloud/SecurityCenter/V1/Vulnerability.php +++ /dev/null @@ -1,213 +0,0 @@ -google.cloud.securitycenter.v1.Vulnerability - */ -class Vulnerability extends \Google\Protobuf\Internal\Message -{ - /** - * CVE stands for Common Vulnerabilities and Exposures - * (https://cve.mitre.org/about/) - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cve cve = 1; - */ - protected $cve = null; - /** - * The offending package is relevant to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Package offending_package = 2; - */ - protected $offending_package = null; - /** - * The fixed package is relevant to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Package fixed_package = 3; - */ - protected $fixed_package = null; - /** - * The security bulletin is relevant to this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityBulletin security_bulletin = 4; - */ - protected $security_bulletin = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1\Cve $cve - * CVE stands for Common Vulnerabilities and Exposures - * (https://cve.mitre.org/about/) - * @type \Google\Cloud\SecurityCenter\V1\Package $offending_package - * The offending package is relevant to the finding. - * @type \Google\Cloud\SecurityCenter\V1\Package $fixed_package - * The fixed package is relevant to the finding. - * @type \Google\Cloud\SecurityCenter\V1\SecurityBulletin $security_bulletin - * The security bulletin is relevant to this finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1\Vulnerability::initOnce(); - parent::__construct($data); - } - - /** - * CVE stands for Common Vulnerabilities and Exposures - * (https://cve.mitre.org/about/) - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cve cve = 1; - * @return \Google\Cloud\SecurityCenter\V1\Cve|null - */ - public function getCve() - { - return $this->cve; - } - - public function hasCve() - { - return isset($this->cve); - } - - public function clearCve() - { - unset($this->cve); - } - - /** - * CVE stands for Common Vulnerabilities and Exposures - * (https://cve.mitre.org/about/) - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Cve cve = 1; - * @param \Google\Cloud\SecurityCenter\V1\Cve $var - * @return $this - */ - public function setCve($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Cve::class); - $this->cve = $var; - - return $this; - } - - /** - * The offending package is relevant to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Package offending_package = 2; - * @return \Google\Cloud\SecurityCenter\V1\Package|null - */ - public function getOffendingPackage() - { - return $this->offending_package; - } - - public function hasOffendingPackage() - { - return isset($this->offending_package); - } - - public function clearOffendingPackage() - { - unset($this->offending_package); - } - - /** - * The offending package is relevant to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Package offending_package = 2; - * @param \Google\Cloud\SecurityCenter\V1\Package $var - * @return $this - */ - public function setOffendingPackage($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Package::class); - $this->offending_package = $var; - - return $this; - } - - /** - * The fixed package is relevant to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Package fixed_package = 3; - * @return \Google\Cloud\SecurityCenter\V1\Package|null - */ - public function getFixedPackage() - { - return $this->fixed_package; - } - - public function hasFixedPackage() - { - return isset($this->fixed_package); - } - - public function clearFixedPackage() - { - unset($this->fixed_package); - } - - /** - * The fixed package is relevant to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.Package fixed_package = 3; - * @param \Google\Cloud\SecurityCenter\V1\Package $var - * @return $this - */ - public function setFixedPackage($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\Package::class); - $this->fixed_package = $var; - - return $this; - } - - /** - * The security bulletin is relevant to this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityBulletin security_bulletin = 4; - * @return \Google\Cloud\SecurityCenter\V1\SecurityBulletin|null - */ - public function getSecurityBulletin() - { - return $this->security_bulletin; - } - - public function hasSecurityBulletin() - { - return isset($this->security_bulletin); - } - - public function clearSecurityBulletin() - { - unset($this->security_bulletin); - } - - /** - * The security bulletin is relevant to this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1.SecurityBulletin security_bulletin = 4; - * @param \Google\Cloud\SecurityCenter\V1\SecurityBulletin $var - * @return $this - */ - public function setSecurityBulletin($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1\SecurityBulletin::class); - $this->security_bulletin = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/bulk_mute_findings.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/bulk_mute_findings.php deleted file mode 100644 index 80feebddbebc..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/bulk_mute_findings.php +++ /dev/null @@ -1,86 +0,0 @@ -setParent($parent); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $securityCenterClient->bulkMuteFindings($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var BulkMuteFindingsResponse $result */ - $result = $response->getResult(); - printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString()); - } else { - /** @var Status $error */ - $error = $response->getError(); - printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $parent = '[PARENT]'; - - bulk_mute_findings_sample($parent); -} -// [END securitycenter_v1_generated_SecurityCenter_BulkMuteFindings_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_big_query_export.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_big_query_export.php deleted file mode 100644 index fdd1f5ab23eb..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_big_query_export.php +++ /dev/null @@ -1,81 +0,0 @@ -setParent($formattedParent) - ->setBigQueryExport($bigQueryExport) - ->setBigQueryExportId($bigQueryExportId); - - // Call the API and handle any network failures. - try { - /** @var BigQueryExport $response */ - $response = $securityCenterClient->createBigQueryExport($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); - $bigQueryExportId = '[BIG_QUERY_EXPORT_ID]'; - - create_big_query_export_sample($formattedParent, $bigQueryExportId); -} -// [END securitycenter_v1_generated_SecurityCenter_CreateBigQueryExport_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_finding.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_finding.php deleted file mode 100644 index dc2277172523..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_finding.php +++ /dev/null @@ -1,80 +0,0 @@ -setParent($formattedParent) - ->setFindingId($findingId) - ->setFinding($finding); - - // Call the API and handle any network failures. - try { - /** @var Finding $response */ - $response = $securityCenterClient->createFinding($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); - $findingId = '[FINDING_ID]'; - - create_finding_sample($formattedParent, $findingId); -} -// [END securitycenter_v1_generated_SecurityCenter_CreateFinding_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_mute_config.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_mute_config.php deleted file mode 100644 index 70bd67210518..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_mute_config.php +++ /dev/null @@ -1,106 +0,0 @@ -setFilter($muteConfigFilter); - $request = (new CreateMuteConfigRequest()) - ->setParent($formattedParent) - ->setMuteConfig($muteConfig) - ->setMuteConfigId($muteConfigId); - - // Call the API and handle any network failures. - try { - /** @var MuteConfig $response */ - $response = $securityCenterClient->createMuteConfig($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); - $muteConfigFilter = '[FILTER]'; - $muteConfigId = '[MUTE_CONFIG_ID]'; - - create_mute_config_sample($formattedParent, $muteConfigFilter, $muteConfigId); -} -// [END securitycenter_v1_generated_SecurityCenter_CreateMuteConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_notification_config.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_notification_config.php deleted file mode 100644 index aa00064b0625..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_notification_config.php +++ /dev/null @@ -1,81 +0,0 @@ -setParent($formattedParent) - ->setConfigId($configId) - ->setNotificationConfig($notificationConfig); - - // Call the API and handle any network failures. - try { - /** @var NotificationConfig $response */ - $response = $securityCenterClient->createNotificationConfig($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); - $configId = '[CONFIG_ID]'; - - create_notification_config_sample($formattedParent, $configId); -} -// [END securitycenter_v1_generated_SecurityCenter_CreateNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_security_health_analytics_custom_module.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_security_health_analytics_custom_module.php deleted file mode 100644 index 442f66ce7363..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_security_health_analytics_custom_module.php +++ /dev/null @@ -1,79 +0,0 @@ -setParent($formattedParent) - ->setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); - - // Call the API and handle any network failures. - try { - /** @var SecurityHealthAnalyticsCustomModule $response */ - $response = $securityCenterClient->createSecurityHealthAnalyticsCustomModule($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - - create_security_health_analytics_custom_module_sample($formattedParent); -} -// [END securitycenter_v1_generated_SecurityCenter_CreateSecurityHealthAnalyticsCustomModule_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_source.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_source.php deleted file mode 100644 index bddbfa2e99bc..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/create_source.php +++ /dev/null @@ -1,74 +0,0 @@ -setParent($formattedParent) - ->setSource($source); - - // Call the API and handle any network failures. - try { - /** @var Source $response */ - $response = $securityCenterClient->createSource($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::organizationName('[ORGANIZATION]'); - - create_source_sample($formattedParent); -} -// [END securitycenter_v1_generated_SecurityCenter_CreateSource_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_big_query_export.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_big_query_export.php deleted file mode 100644 index 1930b7c0678c..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_big_query_export.php +++ /dev/null @@ -1,72 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $securityCenterClient->deleteBigQueryExport($request); - printf('Call completed successfully.' . PHP_EOL); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); - - delete_big_query_export_sample($formattedName); -} -// [END securitycenter_v1_generated_SecurityCenter_DeleteBigQueryExport_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_mute_config.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_mute_config.php deleted file mode 100644 index 375bafb853e6..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_mute_config.php +++ /dev/null @@ -1,72 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $securityCenterClient->deleteMuteConfig($request); - printf('Call completed successfully.' . PHP_EOL); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); - - delete_mute_config_sample($formattedName); -} -// [END securitycenter_v1_generated_SecurityCenter_DeleteMuteConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_notification_config.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_notification_config.php deleted file mode 100644 index a4532eb5eb2c..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_notification_config.php +++ /dev/null @@ -1,75 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $securityCenterClient->deleteNotificationConfig($request); - printf('Call completed successfully.' . PHP_EOL); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::notificationConfigName( - '[ORGANIZATION]', - '[NOTIFICATION_CONFIG]' - ); - - delete_notification_config_sample($formattedName); -} -// [END securitycenter_v1_generated_SecurityCenter_DeleteNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_security_health_analytics_custom_module.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_security_health_analytics_custom_module.php deleted file mode 100644 index 0285b1386476..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/delete_security_health_analytics_custom_module.php +++ /dev/null @@ -1,78 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $securityCenterClient->deleteSecurityHealthAnalyticsCustomModule($request); - printf('Call completed successfully.' . PHP_EOL); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::securityHealthAnalyticsCustomModuleName( - '[ORGANIZATION]', - '[CUSTOM_MODULE]' - ); - - delete_security_health_analytics_custom_module_sample($formattedName); -} -// [END securitycenter_v1_generated_SecurityCenter_DeleteSecurityHealthAnalyticsCustomModule_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_big_query_export.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_big_query_export.php deleted file mode 100644 index 955db018e902..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_big_query_export.php +++ /dev/null @@ -1,74 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var BigQueryExport $response */ - $response = $securityCenterClient->getBigQueryExport($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); - - get_big_query_export_sample($formattedName); -} -// [END securitycenter_v1_generated_SecurityCenter_GetBigQueryExport_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_effective_security_health_analytics_custom_module.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_effective_security_health_analytics_custom_module.php deleted file mode 100644 index c6ba7eb70944..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_effective_security_health_analytics_custom_module.php +++ /dev/null @@ -1,78 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var EffectiveSecurityHealthAnalyticsCustomModule $response */ - $response = $securityCenterClient->getEffectiveSecurityHealthAnalyticsCustomModule($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::effectiveSecurityHealthAnalyticsCustomModuleName( - '[ORGANIZATION]', - '[EFFECTIVE_CUSTOM_MODULE]' - ); - - get_effective_security_health_analytics_custom_module_sample($formattedName); -} -// [END securitycenter_v1_generated_SecurityCenter_GetEffectiveSecurityHealthAnalyticsCustomModule_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_iam_policy.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_iam_policy.php deleted file mode 100644 index 3ffb39b0d6d6..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_iam_policy.php +++ /dev/null @@ -1,71 +0,0 @@ -setResource($resource); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $securityCenterClient->getIamPolicy($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $resource = '[RESOURCE]'; - - get_iam_policy_sample($resource); -} -// [END securitycenter_v1_generated_SecurityCenter_GetIamPolicy_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_mute_config.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_mute_config.php deleted file mode 100644 index 99477532741d..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_mute_config.php +++ /dev/null @@ -1,74 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var MuteConfig $response */ - $response = $securityCenterClient->getMuteConfig($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); - - get_mute_config_sample($formattedName); -} -// [END securitycenter_v1_generated_SecurityCenter_GetMuteConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_notification_config.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_notification_config.php deleted file mode 100644 index 564c7cf8540b..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_notification_config.php +++ /dev/null @@ -1,77 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var NotificationConfig $response */ - $response = $securityCenterClient->getNotificationConfig($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::notificationConfigName( - '[ORGANIZATION]', - '[NOTIFICATION_CONFIG]' - ); - - get_notification_config_sample($formattedName); -} -// [END securitycenter_v1_generated_SecurityCenter_GetNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_organization_settings.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_organization_settings.php deleted file mode 100644 index dfc3175045d1..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_organization_settings.php +++ /dev/null @@ -1,72 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OrganizationSettings $response */ - $response = $securityCenterClient->getOrganizationSettings($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::organizationSettingsName('[ORGANIZATION]'); - - get_organization_settings_sample($formattedName); -} -// [END securitycenter_v1_generated_SecurityCenter_GetOrganizationSettings_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_security_health_analytics_custom_module.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_security_health_analytics_custom_module.php deleted file mode 100644 index 9c9bea04f859..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_security_health_analytics_custom_module.php +++ /dev/null @@ -1,78 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var SecurityHealthAnalyticsCustomModule $response */ - $response = $securityCenterClient->getSecurityHealthAnalyticsCustomModule($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::securityHealthAnalyticsCustomModuleName( - '[ORGANIZATION]', - '[CUSTOM_MODULE]' - ); - - get_security_health_analytics_custom_module_sample($formattedName); -} -// [END securitycenter_v1_generated_SecurityCenter_GetSecurityHealthAnalyticsCustomModule_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_source.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_source.php deleted file mode 100644 index b94b2259d9d9..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/get_source.php +++ /dev/null @@ -1,72 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Source $response */ - $response = $securityCenterClient->getSource($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); - - get_source_sample($formattedName); -} -// [END securitycenter_v1_generated_SecurityCenter_GetSource_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/group_assets.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/group_assets.php deleted file mode 100644 index 43591738c3cf..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/group_assets.php +++ /dev/null @@ -1,99 +0,0 @@ -setParent($formattedParent) - ->setGroupBy($groupBy); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->groupAssets($request); - - /** @var GroupResult $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); - $groupBy = '[GROUP_BY]'; - - group_assets_sample($formattedParent, $groupBy); -} -// [END securitycenter_v1_generated_SecurityCenter_GroupAssets_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/group_findings.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/group_findings.php deleted file mode 100644 index 5476ffe0cdcf..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/group_findings.php +++ /dev/null @@ -1,105 +0,0 @@ -setParent($formattedParent) - ->setGroupBy($groupBy); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->groupFindings($request); - - /** @var GroupResult $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); - $groupBy = '[GROUP_BY]'; - - group_findings_sample($formattedParent, $groupBy); -} -// [END securitycenter_v1_generated_SecurityCenter_GroupFindings_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_assets.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_assets.php deleted file mode 100644 index e7560d13a4f3..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_assets.php +++ /dev/null @@ -1,80 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->listAssets($request); - - /** @var ListAssetsResult $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); - - list_assets_sample($formattedParent); -} -// [END securitycenter_v1_generated_SecurityCenter_ListAssets_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_big_query_exports.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_big_query_exports.php deleted file mode 100644 index b54603a1d336..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_big_query_exports.php +++ /dev/null @@ -1,82 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->listBigQueryExports($request); - - /** @var BigQueryExport $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); - - list_big_query_exports_sample($formattedParent); -} -// [END securitycenter_v1_generated_SecurityCenter_ListBigQueryExports_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_descendant_security_health_analytics_custom_modules.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_descendant_security_health_analytics_custom_modules.php deleted file mode 100644 index d0257ba9ff25..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_descendant_security_health_analytics_custom_modules.php +++ /dev/null @@ -1,81 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->listDescendantSecurityHealthAnalyticsCustomModules($request); - - /** @var SecurityHealthAnalyticsCustomModule $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - - list_descendant_security_health_analytics_custom_modules_sample($formattedParent); -} -// [END securitycenter_v1_generated_SecurityCenter_ListDescendantSecurityHealthAnalyticsCustomModules_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_effective_security_health_analytics_custom_modules.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_effective_security_health_analytics_custom_modules.php deleted file mode 100644 index 2c6fcbbaeff1..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_effective_security_health_analytics_custom_modules.php +++ /dev/null @@ -1,82 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->listEffectiveSecurityHealthAnalyticsCustomModules($request); - - /** @var EffectiveSecurityHealthAnalyticsCustomModule $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - - list_effective_security_health_analytics_custom_modules_sample($formattedParent); -} -// [END securitycenter_v1_generated_SecurityCenter_ListEffectiveSecurityHealthAnalyticsCustomModules_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_findings.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_findings.php deleted file mode 100644 index c786a7416e57..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_findings.php +++ /dev/null @@ -1,85 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->listFindings($request); - - /** @var ListFindingsResult $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); - - list_findings_sample($formattedParent); -} -// [END securitycenter_v1_generated_SecurityCenter_ListFindings_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_mute_configs.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_mute_configs.php deleted file mode 100644 index 65bc0f73a734..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_mute_configs.php +++ /dev/null @@ -1,78 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->listMuteConfigs($request); - - /** @var MuteConfig $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); - - list_mute_configs_sample($formattedParent); -} -// [END securitycenter_v1_generated_SecurityCenter_ListMuteConfigs_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_notification_configs.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_notification_configs.php deleted file mode 100644 index be548b5de10f..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_notification_configs.php +++ /dev/null @@ -1,78 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->listNotificationConfigs($request); - - /** @var NotificationConfig $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); - - list_notification_configs_sample($formattedParent); -} -// [END securitycenter_v1_generated_SecurityCenter_ListNotificationConfigs_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_security_health_analytics_custom_modules.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_security_health_analytics_custom_modules.php deleted file mode 100644 index 2f7e96bb712d..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_security_health_analytics_custom_modules.php +++ /dev/null @@ -1,81 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->listSecurityHealthAnalyticsCustomModules($request); - - /** @var SecurityHealthAnalyticsCustomModule $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - - list_security_health_analytics_custom_modules_sample($formattedParent); -} -// [END securitycenter_v1_generated_SecurityCenter_ListSecurityHealthAnalyticsCustomModules_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_sources.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_sources.php deleted file mode 100644 index 95ec1a19185a..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/list_sources.php +++ /dev/null @@ -1,78 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->listSources($request); - - /** @var Source $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); - - list_sources_sample($formattedParent); -} -// [END securitycenter_v1_generated_SecurityCenter_ListSources_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/run_asset_discovery.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/run_asset_discovery.php deleted file mode 100644 index af586cf40157..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/run_asset_discovery.php +++ /dev/null @@ -1,89 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $securityCenterClient->runAssetDiscovery($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var RunAssetDiscoveryResponse $result */ - $result = $response->getResult(); - printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString()); - } else { - /** @var Status $error */ - $error = $response->getError(); - printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::organizationName('[ORGANIZATION]'); - - run_asset_discovery_sample($formattedParent); -} -// [END securitycenter_v1_generated_SecurityCenter_RunAssetDiscovery_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_finding_state.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_finding_state.php deleted file mode 100644 index e9b370ef7502..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_finding_state.php +++ /dev/null @@ -1,83 +0,0 @@ -setName($formattedName) - ->setState($state) - ->setStartTime($startTime); - - // Call the API and handle any network failures. - try { - /** @var Finding $response */ - $response = $securityCenterClient->setFindingState($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - $state = State::STATE_UNSPECIFIED; - - set_finding_state_sample($formattedName, $state); -} -// [END securitycenter_v1_generated_SecurityCenter_SetFindingState_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_iam_policy.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_iam_policy.php deleted file mode 100644 index 4ab864d1b55a..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_iam_policy.php +++ /dev/null @@ -1,73 +0,0 @@ -setResource($resource) - ->setPolicy($policy); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $securityCenterClient->setIamPolicy($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $resource = '[RESOURCE]'; - - set_iam_policy_sample($resource); -} -// [END securitycenter_v1_generated_SecurityCenter_SetIamPolicy_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_mute.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_mute.php deleted file mode 100644 index 03a4c9a86b54..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/set_mute.php +++ /dev/null @@ -1,80 +0,0 @@ -setName($formattedName) - ->setMute($mute); - - // Call the API and handle any network failures. - try { - /** @var Finding $response */ - $response = $securityCenterClient->setMute($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - $mute = Mute::MUTE_UNSPECIFIED; - - set_mute_sample($formattedName, $mute); -} -// [END securitycenter_v1_generated_SecurityCenter_SetMute_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/simulate_security_health_analytics_custom_module.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/simulate_security_health_analytics_custom_module.php deleted file mode 100644 index 1ba3284c5d28..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/simulate_security_health_analytics_custom_module.php +++ /dev/null @@ -1,86 +0,0 @@ -setResourceType($resourceResourceType); - $request = (new SimulateSecurityHealthAnalyticsCustomModuleRequest()) - ->setParent($parent) - ->setCustomConfig($customConfig) - ->setResource($resource); - - // Call the API and handle any network failures. - try { - /** @var SimulateSecurityHealthAnalyticsCustomModuleResponse $response */ - $response = $securityCenterClient->simulateSecurityHealthAnalyticsCustomModule($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $parent = '[PARENT]'; - $resourceResourceType = '[RESOURCE_TYPE]'; - - simulate_security_health_analytics_custom_module_sample($parent, $resourceResourceType); -} -// [END securitycenter_v1_generated_SecurityCenter_SimulateSecurityHealthAnalyticsCustomModule_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/test_iam_permissions.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/test_iam_permissions.php deleted file mode 100644 index 307d0e363f5b..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/test_iam_permissions.php +++ /dev/null @@ -1,78 +0,0 @@ -setResource($resource) - ->setPermissions($permissions); - - // Call the API and handle any network failures. - try { - /** @var TestIamPermissionsResponse $response */ - $response = $securityCenterClient->testIamPermissions($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $resource = '[RESOURCE]'; - $permissionsElement = '[PERMISSIONS]'; - - test_iam_permissions_sample($resource, $permissionsElement); -} -// [END securitycenter_v1_generated_SecurityCenter_TestIamPermissions_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_big_query_export.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_big_query_export.php deleted file mode 100644 index 48f972ee0ae6..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_big_query_export.php +++ /dev/null @@ -1,59 +0,0 @@ -setBigQueryExport($bigQueryExport); - - // Call the API and handle any network failures. - try { - /** @var BigQueryExport $response */ - $response = $securityCenterClient->updateBigQueryExport($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END securitycenter_v1_generated_SecurityCenter_UpdateBigQueryExport_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_external_system.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_external_system.php deleted file mode 100644 index 682b53415973..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_external_system.php +++ /dev/null @@ -1,59 +0,0 @@ -setExternalSystem($externalSystem); - - // Call the API and handle any network failures. - try { - /** @var ExternalSystem $response */ - $response = $securityCenterClient->updateExternalSystem($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END securitycenter_v1_generated_SecurityCenter_UpdateExternalSystem_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_finding.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_finding.php deleted file mode 100644 index c6f695d3246c..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_finding.php +++ /dev/null @@ -1,60 +0,0 @@ -setFinding($finding); - - // Call the API and handle any network failures. - try { - /** @var Finding $response */ - $response = $securityCenterClient->updateFinding($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END securitycenter_v1_generated_SecurityCenter_UpdateFinding_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_mute_config.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_mute_config.php deleted file mode 100644 index ae056f031403..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_mute_config.php +++ /dev/null @@ -1,91 +0,0 @@ -setFilter($muteConfigFilter); - $request = (new UpdateMuteConfigRequest()) - ->setMuteConfig($muteConfig); - - // Call the API and handle any network failures. - try { - /** @var MuteConfig $response */ - $response = $securityCenterClient->updateMuteConfig($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $muteConfigFilter = '[FILTER]'; - - update_mute_config_sample($muteConfigFilter); -} -// [END securitycenter_v1_generated_SecurityCenter_UpdateMuteConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_notification_config.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_notification_config.php deleted file mode 100644 index ec39139cb19e..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_notification_config.php +++ /dev/null @@ -1,61 +0,0 @@ -setNotificationConfig($notificationConfig); - - // Call the API and handle any network failures. - try { - /** @var NotificationConfig $response */ - $response = $securityCenterClient->updateNotificationConfig($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END securitycenter_v1_generated_SecurityCenter_UpdateNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_organization_settings.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_organization_settings.php deleted file mode 100644 index 4443cc5ed796..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_organization_settings.php +++ /dev/null @@ -1,59 +0,0 @@ -setOrganizationSettings($organizationSettings); - - // Call the API and handle any network failures. - try { - /** @var OrganizationSettings $response */ - $response = $securityCenterClient->updateOrganizationSettings($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END securitycenter_v1_generated_SecurityCenter_UpdateOrganizationSettings_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_security_health_analytics_custom_module.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_security_health_analytics_custom_module.php deleted file mode 100644 index 24c2c65791fc..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_security_health_analytics_custom_module.php +++ /dev/null @@ -1,63 +0,0 @@ -setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); - - // Call the API and handle any network failures. - try { - /** @var SecurityHealthAnalyticsCustomModule $response */ - $response = $securityCenterClient->updateSecurityHealthAnalyticsCustomModule($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END securitycenter_v1_generated_SecurityCenter_UpdateSecurityHealthAnalyticsCustomModule_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_security_marks.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_security_marks.php deleted file mode 100644 index b6621f3eaea4..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_security_marks.php +++ /dev/null @@ -1,59 +0,0 @@ -setSecurityMarks($securityMarks); - - // Call the API and handle any network failures. - try { - /** @var SecurityMarks $response */ - $response = $securityCenterClient->updateSecurityMarks($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END securitycenter_v1_generated_SecurityCenter_UpdateSecurityMarks_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_source.php b/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_source.php deleted file mode 100644 index 61688c301805..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/samples/V1/SecurityCenterClient/update_source.php +++ /dev/null @@ -1,59 +0,0 @@ -setSource($source); - - // Call the API and handle any network failures. - try { - /** @var Source $response */ - $response = $securityCenterClient->updateSource($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END securitycenter_v1_generated_SecurityCenter_UpdateSource_sync] diff --git a/owl-bot-staging/SecurityCenter/v1/src/V1/Client/SecurityCenterClient.php b/owl-bot-staging/SecurityCenter/v1/src/V1/Client/SecurityCenterClient.php deleted file mode 100644 index 53ad9049aa0a..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/src/V1/Client/SecurityCenterClient.php +++ /dev/null @@ -1,2617 +0,0 @@ - self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/security_center_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/security_center_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/security_center_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/security_center_rest_client_config.php', - ], - ], - ]; - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * Resume an existing long running operation that was previously started by a long - * running API method. If $methodName is not provided, or does not match a long - * running API method, then the operation can still be resumed, but the - * OperationResponse object will not deserialize the final response. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Formats a string containing the fully-qualified path to represent a - * big_query_export resource. - * - * @param string $organization - * @param string $export - * - * @return string The formatted big_query_export resource. - */ - public static function bigQueryExportName(string $organization, string $export): string - { - return self::getPathTemplate('bigQueryExport')->render([ - 'organization' => $organization, - 'export' => $export, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a dlp_job - * resource. - * - * @param string $project - * @param string $dlpJob - * - * @return string The formatted dlp_job resource. - */ - public static function dlpJobName(string $project, string $dlpJob): string - { - return self::getPathTemplate('dlpJob')->render([ - 'project' => $project, - 'dlp_job' => $dlpJob, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * effective_security_health_analytics_custom_module resource. - * - * @param string $organization - * @param string $effectiveCustomModule - * - * @return string The formatted effective_security_health_analytics_custom_module resource. - */ - public static function effectiveSecurityHealthAnalyticsCustomModuleName(string $organization, string $effectiveCustomModule): string - { - return self::getPathTemplate('effectiveSecurityHealthAnalyticsCustomModule')->render([ - 'organization' => $organization, - 'effective_custom_module' => $effectiveCustomModule, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * external_system resource. - * - * @param string $organization - * @param string $source - * @param string $finding - * @param string $externalsystem - * - * @return string The formatted external_system resource. - */ - public static function externalSystemName(string $organization, string $source, string $finding, string $externalsystem): string - { - return self::getPathTemplate('externalSystem')->render([ - 'organization' => $organization, - 'source' => $source, - 'finding' => $finding, - 'externalsystem' => $externalsystem, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a finding - * resource. - * - * @param string $organization - * @param string $source - * @param string $finding - * - * @return string The formatted finding resource. - */ - public static function findingName(string $organization, string $source, string $finding): string - { - return self::getPathTemplate('finding')->render([ - 'organization' => $organization, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a folder - * resource. - * - * @param string $folder - * - * @return string The formatted folder resource. - */ - public static function folderName(string $folder): string - { - return self::getPathTemplate('folder')->render([ - 'folder' => $folder, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_asset_securityMarks resource. - * - * @param string $folder - * @param string $asset - * - * @return string The formatted folder_asset_securityMarks resource. - */ - public static function folderAssetSecurityMarksName(string $folder, string $asset): string - { - return self::getPathTemplate('folderAssetSecurityMarks')->render([ - 'folder' => $folder, - 'asset' => $asset, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_constraint_name resource. - * - * @param string $folder - * @param string $constraintName - * - * @return string The formatted folder_constraint_name resource. - */ - public static function folderConstraintNameName(string $folder, string $constraintName): string - { - return self::getPathTemplate('folderConstraintName')->render([ - 'folder' => $folder, - 'constraint_name' => $constraintName, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_custom_module resource. - * - * @param string $folder - * @param string $customModule - * - * @return string The formatted folder_custom_module resource. - */ - public static function folderCustomModuleName(string $folder, string $customModule): string - { - return self::getPathTemplate('folderCustomModule')->render([ - 'folder' => $folder, - 'custom_module' => $customModule, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_effective_custom_module resource. - * - * @param string $folder - * @param string $effectiveCustomModule - * - * @return string The formatted folder_effective_custom_module resource. - */ - public static function folderEffectiveCustomModuleName(string $folder, string $effectiveCustomModule): string - { - return self::getPathTemplate('folderEffectiveCustomModule')->render([ - 'folder' => $folder, - 'effective_custom_module' => $effectiveCustomModule, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_export resource. - * - * @param string $folder - * @param string $export - * - * @return string The formatted folder_export resource. - */ - public static function folderExportName(string $folder, string $export): string - { - return self::getPathTemplate('folderExport')->render([ - 'folder' => $folder, - 'export' => $export, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_mute_config resource. - * - * @param string $folder - * @param string $muteConfig - * - * @return string The formatted folder_mute_config resource. - */ - public static function folderMuteConfigName(string $folder, string $muteConfig): string - { - return self::getPathTemplate('folderMuteConfig')->render([ - 'folder' => $folder, - 'mute_config' => $muteConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_notification_config resource. - * - * @param string $folder - * @param string $notificationConfig - * - * @return string The formatted folder_notification_config resource. - */ - public static function folderNotificationConfigName(string $folder, string $notificationConfig): string - { - return self::getPathTemplate('folderNotificationConfig')->render([ - 'folder' => $folder, - 'notification_config' => $notificationConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_securityHealthAnalyticsSettings resource. - * - * @param string $folder - * - * @return string The formatted folder_securityHealthAnalyticsSettings resource. - */ - public static function folderSecurityHealthAnalyticsSettingsName(string $folder): string - { - return self::getPathTemplate('folderSecurityHealthAnalyticsSettings')->render([ - 'folder' => $folder, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_source resource. - * - * @param string $folder - * @param string $source - * - * @return string The formatted folder_source resource. - */ - public static function folderSourceName(string $folder, string $source): string - { - return self::getPathTemplate('folderSource')->render([ - 'folder' => $folder, - 'source' => $source, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_source_finding resource. - * - * @param string $folder - * @param string $source - * @param string $finding - * - * @return string The formatted folder_source_finding resource. - */ - public static function folderSourceFindingName(string $folder, string $source, string $finding): string - { - return self::getPathTemplate('folderSourceFinding')->render([ - 'folder' => $folder, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_source_finding_externalsystem resource. - * - * @param string $folder - * @param string $source - * @param string $finding - * @param string $externalsystem - * - * @return string The formatted folder_source_finding_externalsystem resource. - */ - public static function folderSourceFindingExternalsystemName(string $folder, string $source, string $finding, string $externalsystem): string - { - return self::getPathTemplate('folderSourceFindingExternalsystem')->render([ - 'folder' => $folder, - 'source' => $source, - 'finding' => $finding, - 'externalsystem' => $externalsystem, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_source_finding_securityMarks resource. - * - * @param string $folder - * @param string $source - * @param string $finding - * - * @return string The formatted folder_source_finding_securityMarks resource. - */ - public static function folderSourceFindingSecurityMarksName(string $folder, string $source, string $finding): string - { - return self::getPathTemplate('folderSourceFindingSecurityMarks')->render([ - 'folder' => $folder, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a mute_config - * resource. - * - * @param string $organization - * @param string $muteConfig - * - * @return string The formatted mute_config resource. - */ - public static function muteConfigName(string $organization, string $muteConfig): string - { - return self::getPathTemplate('muteConfig')->render([ - 'organization' => $organization, - 'mute_config' => $muteConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * notification_config resource. - * - * @param string $organization - * @param string $notificationConfig - * - * @return string The formatted notification_config resource. - */ - public static function notificationConfigName(string $organization, string $notificationConfig): string - { - return self::getPathTemplate('notificationConfig')->render([ - 'organization' => $organization, - 'notification_config' => $notificationConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a organization - * resource. - * - * @param string $organization - * - * @return string The formatted organization resource. - */ - public static function organizationName(string $organization): string - { - return self::getPathTemplate('organization')->render([ - 'organization' => $organization, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_asset_securityMarks resource. - * - * @param string $organization - * @param string $asset - * - * @return string The formatted organization_asset_securityMarks resource. - */ - public static function organizationAssetSecurityMarksName(string $organization, string $asset): string - { - return self::getPathTemplate('organizationAssetSecurityMarks')->render([ - 'organization' => $organization, - 'asset' => $asset, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_constraint_name resource. - * - * @param string $organization - * @param string $constraintName - * - * @return string The formatted organization_constraint_name resource. - */ - public static function organizationConstraintNameName(string $organization, string $constraintName): string - { - return self::getPathTemplate('organizationConstraintName')->render([ - 'organization' => $organization, - 'constraint_name' => $constraintName, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_custom_module resource. - * - * @param string $organization - * @param string $customModule - * - * @return string The formatted organization_custom_module resource. - */ - public static function organizationCustomModuleName(string $organization, string $customModule): string - { - return self::getPathTemplate('organizationCustomModule')->render([ - 'organization' => $organization, - 'custom_module' => $customModule, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_effective_custom_module resource. - * - * @param string $organization - * @param string $effectiveCustomModule - * - * @return string The formatted organization_effective_custom_module resource. - */ - public static function organizationEffectiveCustomModuleName(string $organization, string $effectiveCustomModule): string - { - return self::getPathTemplate('organizationEffectiveCustomModule')->render([ - 'organization' => $organization, - 'effective_custom_module' => $effectiveCustomModule, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_export resource. - * - * @param string $organization - * @param string $export - * - * @return string The formatted organization_export resource. - */ - public static function organizationExportName(string $organization, string $export): string - { - return self::getPathTemplate('organizationExport')->render([ - 'organization' => $organization, - 'export' => $export, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_mute_config resource. - * - * @param string $organization - * @param string $muteConfig - * - * @return string The formatted organization_mute_config resource. - */ - public static function organizationMuteConfigName(string $organization, string $muteConfig): string - { - return self::getPathTemplate('organizationMuteConfig')->render([ - 'organization' => $organization, - 'mute_config' => $muteConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_notification_config resource. - * - * @param string $organization - * @param string $notificationConfig - * - * @return string The formatted organization_notification_config resource. - */ - public static function organizationNotificationConfigName(string $organization, string $notificationConfig): string - { - return self::getPathTemplate('organizationNotificationConfig')->render([ - 'organization' => $organization, - 'notification_config' => $notificationConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_securityHealthAnalyticsSettings resource. - * - * @param string $organization - * - * @return string The formatted organization_securityHealthAnalyticsSettings resource. - */ - public static function organizationSecurityHealthAnalyticsSettingsName(string $organization): string - { - return self::getPathTemplate('organizationSecurityHealthAnalyticsSettings')->render([ - 'organization' => $organization, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_settings resource. - * - * @param string $organization - * - * @return string The formatted organization_settings resource. - */ - public static function organizationSettingsName(string $organization): string - { - return self::getPathTemplate('organizationSettings')->render([ - 'organization' => $organization, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_source resource. - * - * @param string $organization - * @param string $source - * - * @return string The formatted organization_source resource. - */ - public static function organizationSourceName(string $organization, string $source): string - { - return self::getPathTemplate('organizationSource')->render([ - 'organization' => $organization, - 'source' => $source, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_source_finding resource. - * - * @param string $organization - * @param string $source - * @param string $finding - * - * @return string The formatted organization_source_finding resource. - */ - public static function organizationSourceFindingName(string $organization, string $source, string $finding): string - { - return self::getPathTemplate('organizationSourceFinding')->render([ - 'organization' => $organization, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_source_finding_externalsystem resource. - * - * @param string $organization - * @param string $source - * @param string $finding - * @param string $externalsystem - * - * @return string The formatted organization_source_finding_externalsystem resource. - */ - public static function organizationSourceFindingExternalsystemName(string $organization, string $source, string $finding, string $externalsystem): string - { - return self::getPathTemplate('organizationSourceFindingExternalsystem')->render([ - 'organization' => $organization, - 'source' => $source, - 'finding' => $finding, - 'externalsystem' => $externalsystem, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_source_finding_securityMarks resource. - * - * @param string $organization - * @param string $source - * @param string $finding - * - * @return string The formatted organization_source_finding_securityMarks resource. - */ - public static function organizationSourceFindingSecurityMarksName(string $organization, string $source, string $finding): string - { - return self::getPathTemplate('organizationSourceFindingSecurityMarks')->render([ - 'organization' => $organization, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a policy - * resource. - * - * @param string $organization - * @param string $constraintName - * - * @return string The formatted policy resource. - */ - public static function policyName(string $organization, string $constraintName): string - { - return self::getPathTemplate('policy')->render([ - 'organization' => $organization, - 'constraint_name' => $constraintName, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a project - * resource. - * - * @param string $project - * - * @return string The formatted project resource. - */ - public static function projectName(string $project): string - { - return self::getPathTemplate('project')->render([ - 'project' => $project, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_asset_securityMarks resource. - * - * @param string $project - * @param string $asset - * - * @return string The formatted project_asset_securityMarks resource. - */ - public static function projectAssetSecurityMarksName(string $project, string $asset): string - { - return self::getPathTemplate('projectAssetSecurityMarks')->render([ - 'project' => $project, - 'asset' => $asset, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_constraint_name resource. - * - * @param string $project - * @param string $constraintName - * - * @return string The formatted project_constraint_name resource. - */ - public static function projectConstraintNameName(string $project, string $constraintName): string - { - return self::getPathTemplate('projectConstraintName')->render([ - 'project' => $project, - 'constraint_name' => $constraintName, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_custom_module resource. - * - * @param string $project - * @param string $customModule - * - * @return string The formatted project_custom_module resource. - */ - public static function projectCustomModuleName(string $project, string $customModule): string - { - return self::getPathTemplate('projectCustomModule')->render([ - 'project' => $project, - 'custom_module' => $customModule, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_dlp_job resource. - * - * @param string $project - * @param string $dlpJob - * - * @return string The formatted project_dlp_job resource. - */ - public static function projectDlpJobName(string $project, string $dlpJob): string - { - return self::getPathTemplate('projectDlpJob')->render([ - 'project' => $project, - 'dlp_job' => $dlpJob, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_effective_custom_module resource. - * - * @param string $project - * @param string $effectiveCustomModule - * - * @return string The formatted project_effective_custom_module resource. - */ - public static function projectEffectiveCustomModuleName(string $project, string $effectiveCustomModule): string - { - return self::getPathTemplate('projectEffectiveCustomModule')->render([ - 'project' => $project, - 'effective_custom_module' => $effectiveCustomModule, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_export resource. - * - * @param string $project - * @param string $export - * - * @return string The formatted project_export resource. - */ - public static function projectExportName(string $project, string $export): string - { - return self::getPathTemplate('projectExport')->render([ - 'project' => $project, - 'export' => $export, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_dlp_job resource. - * - * @param string $project - * @param string $location - * @param string $dlpJob - * - * @return string The formatted project_location_dlp_job resource. - */ - public static function projectLocationDlpJobName(string $project, string $location, string $dlpJob): string - { - return self::getPathTemplate('projectLocationDlpJob')->render([ - 'project' => $project, - 'location' => $location, - 'dlp_job' => $dlpJob, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_table_profile resource. - * - * @param string $project - * @param string $location - * @param string $tableProfile - * - * @return string The formatted project_location_table_profile resource. - */ - public static function projectLocationTableProfileName(string $project, string $location, string $tableProfile): string - { - return self::getPathTemplate('projectLocationTableProfile')->render([ - 'project' => $project, - 'location' => $location, - 'table_profile' => $tableProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_mute_config resource. - * - * @param string $project - * @param string $muteConfig - * - * @return string The formatted project_mute_config resource. - */ - public static function projectMuteConfigName(string $project, string $muteConfig): string - { - return self::getPathTemplate('projectMuteConfig')->render([ - 'project' => $project, - 'mute_config' => $muteConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_notification_config resource. - * - * @param string $project - * @param string $notificationConfig - * - * @return string The formatted project_notification_config resource. - */ - public static function projectNotificationConfigName(string $project, string $notificationConfig): string - { - return self::getPathTemplate('projectNotificationConfig')->render([ - 'project' => $project, - 'notification_config' => $notificationConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_securityHealthAnalyticsSettings resource. - * - * @param string $project - * - * @return string The formatted project_securityHealthAnalyticsSettings resource. - */ - public static function projectSecurityHealthAnalyticsSettingsName(string $project): string - { - return self::getPathTemplate('projectSecurityHealthAnalyticsSettings')->render([ - 'project' => $project, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_source resource. - * - * @param string $project - * @param string $source - * - * @return string The formatted project_source resource. - */ - public static function projectSourceName(string $project, string $source): string - { - return self::getPathTemplate('projectSource')->render([ - 'project' => $project, - 'source' => $source, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_source_finding resource. - * - * @param string $project - * @param string $source - * @param string $finding - * - * @return string The formatted project_source_finding resource. - */ - public static function projectSourceFindingName(string $project, string $source, string $finding): string - { - return self::getPathTemplate('projectSourceFinding')->render([ - 'project' => $project, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_source_finding_externalsystem resource. - * - * @param string $project - * @param string $source - * @param string $finding - * @param string $externalsystem - * - * @return string The formatted project_source_finding_externalsystem resource. - */ - public static function projectSourceFindingExternalsystemName(string $project, string $source, string $finding, string $externalsystem): string - { - return self::getPathTemplate('projectSourceFindingExternalsystem')->render([ - 'project' => $project, - 'source' => $source, - 'finding' => $finding, - 'externalsystem' => $externalsystem, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_source_finding_securityMarks resource. - * - * @param string $project - * @param string $source - * @param string $finding - * - * @return string The formatted project_source_finding_securityMarks resource. - */ - public static function projectSourceFindingSecurityMarksName(string $project, string $source, string $finding): string - { - return self::getPathTemplate('projectSourceFindingSecurityMarks')->render([ - 'project' => $project, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_table_profile resource. - * - * @param string $project - * @param string $tableProfile - * - * @return string The formatted project_table_profile resource. - */ - public static function projectTableProfileName(string $project, string $tableProfile): string - { - return self::getPathTemplate('projectTableProfile')->render([ - 'project' => $project, - 'table_profile' => $tableProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * security_health_analytics_custom_module resource. - * - * @param string $organization - * @param string $customModule - * - * @return string The formatted security_health_analytics_custom_module resource. - */ - public static function securityHealthAnalyticsCustomModuleName(string $organization, string $customModule): string - { - return self::getPathTemplate('securityHealthAnalyticsCustomModule')->render([ - 'organization' => $organization, - 'custom_module' => $customModule, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * security_health_analytics_settings resource. - * - * @param string $organization - * - * @return string The formatted security_health_analytics_settings resource. - */ - public static function securityHealthAnalyticsSettingsName(string $organization): string - { - return self::getPathTemplate('securityHealthAnalyticsSettings')->render([ - 'organization' => $organization, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * security_marks resource. - * - * @param string $organization - * @param string $asset - * - * @return string The formatted security_marks resource. - */ - public static function securityMarksName(string $organization, string $asset): string - { - return self::getPathTemplate('securityMarks')->render([ - 'organization' => $organization, - 'asset' => $asset, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a source - * resource. - * - * @param string $organization - * @param string $source - * - * @return string The formatted source resource. - */ - public static function sourceName(string $organization, string $source): string - { - return self::getPathTemplate('source')->render([ - 'organization' => $organization, - 'source' => $source, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * table_data_profile resource. - * - * @param string $project - * @param string $tableProfile - * - * @return string The formatted table_data_profile resource. - */ - public static function tableDataProfileName(string $project, string $tableProfile): string - { - return self::getPathTemplate('tableDataProfile')->render([ - 'project' => $project, - 'table_profile' => $tableProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a topic - * resource. - * - * @param string $project - * @param string $topic - * - * @return string The formatted topic resource. - */ - public static function topicName(string $project, string $topic): string - { - return self::getPathTemplate('topic')->render([ - 'project' => $project, - 'topic' => $topic, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - bigQueryExport: organizations/{organization}/bigQueryExports/{export} - * - dlpJob: projects/{project}/dlpJobs/{dlp_job} - * - effectiveSecurityHealthAnalyticsCustomModule: organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module} - * - externalSystem: organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} - * - finding: organizations/{organization}/sources/{source}/findings/{finding} - * - folder: folders/{folder} - * - folderAssetSecurityMarks: folders/{folder}/assets/{asset}/securityMarks - * - folderConstraintName: folders/{folder}/policies/{constraint_name} - * - folderCustomModule: folders/{folder}/securityHealthAnalyticsSettings/customModules/{custom_module} - * - folderEffectiveCustomModule: folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module} - * - folderExport: folders/{folder}/bigQueryExports/{export} - * - folderMuteConfig: folders/{folder}/muteConfigs/{mute_config} - * - folderNotificationConfig: folders/{folder}/notificationConfigs/{notification_config} - * - folderSecurityHealthAnalyticsSettings: folders/{folder}/securityHealthAnalyticsSettings - * - folderSource: folders/{folder}/sources/{source} - * - folderSourceFinding: folders/{folder}/sources/{source}/findings/{finding} - * - folderSourceFindingExternalsystem: folders/{folder}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} - * - folderSourceFindingSecurityMarks: folders/{folder}/sources/{source}/findings/{finding}/securityMarks - * - muteConfig: organizations/{organization}/muteConfigs/{mute_config} - * - notificationConfig: organizations/{organization}/notificationConfigs/{notification_config} - * - organization: organizations/{organization} - * - organizationAssetSecurityMarks: organizations/{organization}/assets/{asset}/securityMarks - * - organizationConstraintName: organizations/{organization}/policies/{constraint_name} - * - organizationCustomModule: organizations/{organization}/securityHealthAnalyticsSettings/customModules/{custom_module} - * - organizationEffectiveCustomModule: organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module} - * - organizationExport: organizations/{organization}/bigQueryExports/{export} - * - organizationMuteConfig: organizations/{organization}/muteConfigs/{mute_config} - * - organizationNotificationConfig: organizations/{organization}/notificationConfigs/{notification_config} - * - organizationSecurityHealthAnalyticsSettings: organizations/{organization}/securityHealthAnalyticsSettings - * - organizationSettings: organizations/{organization}/organizationSettings - * - organizationSource: organizations/{organization}/sources/{source} - * - organizationSourceFinding: organizations/{organization}/sources/{source}/findings/{finding} - * - organizationSourceFindingExternalsystem: organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} - * - organizationSourceFindingSecurityMarks: organizations/{organization}/sources/{source}/findings/{finding}/securityMarks - * - policy: organizations/{organization}/policies/{constraint_name} - * - project: projects/{project} - * - projectAssetSecurityMarks: projects/{project}/assets/{asset}/securityMarks - * - projectConstraintName: projects/{project}/policies/{constraint_name} - * - projectCustomModule: projects/{project}/securityHealthAnalyticsSettings/customModules/{custom_module} - * - projectDlpJob: projects/{project}/dlpJobs/{dlp_job} - * - projectEffectiveCustomModule: projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module} - * - projectExport: projects/{project}/bigQueryExports/{export} - * - projectLocationDlpJob: projects/{project}/locations/{location}/dlpJobs/{dlp_job} - * - projectLocationTableProfile: projects/{project}/locations/{location}/tableProfiles/{table_profile} - * - projectMuteConfig: projects/{project}/muteConfigs/{mute_config} - * - projectNotificationConfig: projects/{project}/notificationConfigs/{notification_config} - * - projectSecurityHealthAnalyticsSettings: projects/{project}/securityHealthAnalyticsSettings - * - projectSource: projects/{project}/sources/{source} - * - projectSourceFinding: projects/{project}/sources/{source}/findings/{finding} - * - projectSourceFindingExternalsystem: projects/{project}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} - * - projectSourceFindingSecurityMarks: projects/{project}/sources/{source}/findings/{finding}/securityMarks - * - projectTableProfile: projects/{project}/tableProfiles/{table_profile} - * - securityHealthAnalyticsCustomModule: organizations/{organization}/securityHealthAnalyticsSettings/customModules/{custom_module} - * - securityHealthAnalyticsSettings: organizations/{organization}/securityHealthAnalyticsSettings - * - securityMarks: organizations/{organization}/assets/{asset}/securityMarks - * - source: organizations/{organization}/sources/{source} - * - tableDataProfile: projects/{project}/tableProfiles/{table_profile} - * - topic: projects/{project}/topics/{topic} - * - * The optional $template argument can be supplied to specify a particular pattern, - * and must match one of the templates listed above. If no $template argument is - * provided, or if the $template argument does not match one of the templates - * listed, then parseName will check each of the supported templates, and return - * the first match. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName(string $formattedName, string $template = null): array - { - return self::parseFormattedName($formattedName, $template); - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'securitycenter.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * Client method configuration, including retry settings. This option can be either - * a path to a JSON file, or a PHP array containing the decoded JSON data. By - * default this settings points to the default client config file, which is - * provided in the resources folder. - * @type string|TransportInterface $transport - * The transport used for executing network requests. May be either the string - * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. - * *Advanced usage*: Additionally, it is possible to pass in an already - * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * Configuration options that will be used to construct the transport. Options for - * each supported transport type should be passed in a key for that transport. For - * example: - * $transportConfig = [ - * 'grpc' => [...], - * 'rest' => [...], - * ]; - * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * A callable which returns the client cert as a string. This can be used to - * provide a certificate and private key to the transport layer for mTLS. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** Handles execution of the async variants for each documented method. */ - public function __call($method, $args) - { - if (substr($method, -5) !== 'Async') { - trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); - } - - array_unshift($args, substr($method, 0, -5)); - return call_user_func_array([$this, 'startAsyncCall'], $args); - } - - /** - * Kicks off an LRO to bulk mute findings for a parent based on a filter. The - * parent can be either an organization, folder or project. The findings - * matched by the filter will be muted after the LRO is done. - * - * The async variant is {@see SecurityCenterClient::bulkMuteFindingsAsync()} . - * - * @example samples/V1/SecurityCenterClient/bulk_mute_findings.php - * - * @param BulkMuteFindingsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function bulkMuteFindings(BulkMuteFindingsRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('BulkMuteFindings', $request, $callOptions)->wait(); - } - - /** - * Creates a BigQuery export. - * - * The async variant is {@see SecurityCenterClient::createBigQueryExportAsync()} . - * - * @example samples/V1/SecurityCenterClient/create_big_query_export.php - * - * @param CreateBigQueryExportRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return BigQueryExport - * - * @throws ApiException Thrown if the API call fails. - */ - public function createBigQueryExport(CreateBigQueryExportRequest $request, array $callOptions = []): BigQueryExport - { - return $this->startApiCall('CreateBigQueryExport', $request, $callOptions)->wait(); - } - - /** - * Creates a finding. The corresponding source must exist for finding creation - * to succeed. - * - * The async variant is {@see SecurityCenterClient::createFindingAsync()} . - * - * @example samples/V1/SecurityCenterClient/create_finding.php - * - * @param CreateFindingRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Finding - * - * @throws ApiException Thrown if the API call fails. - */ - public function createFinding(CreateFindingRequest $request, array $callOptions = []): Finding - { - return $this->startApiCall('CreateFinding', $request, $callOptions)->wait(); - } - - /** - * Creates a mute config. - * - * The async variant is {@see SecurityCenterClient::createMuteConfigAsync()} . - * - * @example samples/V1/SecurityCenterClient/create_mute_config.php - * - * @param CreateMuteConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return MuteConfig - * - * @throws ApiException Thrown if the API call fails. - */ - public function createMuteConfig(CreateMuteConfigRequest $request, array $callOptions = []): MuteConfig - { - return $this->startApiCall('CreateMuteConfig', $request, $callOptions)->wait(); - } - - /** - * Creates a notification config. - * - * The async variant is - * {@see SecurityCenterClient::createNotificationConfigAsync()} . - * - * @example samples/V1/SecurityCenterClient/create_notification_config.php - * - * @param CreateNotificationConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return NotificationConfig - * - * @throws ApiException Thrown if the API call fails. - */ - public function createNotificationConfig(CreateNotificationConfigRequest $request, array $callOptions = []): NotificationConfig - { - return $this->startApiCall('CreateNotificationConfig', $request, $callOptions)->wait(); - } - - /** - * Creates a resident SecurityHealthAnalyticsCustomModule at the scope of the - * given CRM parent, and also creates inherited - * SecurityHealthAnalyticsCustomModules for all CRM descendants of the given - * parent. These modules are enabled by default. - * - * The async variant is - * {@see SecurityCenterClient::createSecurityHealthAnalyticsCustomModuleAsync()} . - * - * @example samples/V1/SecurityCenterClient/create_security_health_analytics_custom_module.php - * - * @param CreateSecurityHealthAnalyticsCustomModuleRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return SecurityHealthAnalyticsCustomModule - * - * @throws ApiException Thrown if the API call fails. - */ - public function createSecurityHealthAnalyticsCustomModule(CreateSecurityHealthAnalyticsCustomModuleRequest $request, array $callOptions = []): SecurityHealthAnalyticsCustomModule - { - return $this->startApiCall('CreateSecurityHealthAnalyticsCustomModule', $request, $callOptions)->wait(); - } - - /** - * Creates a source. - * - * The async variant is {@see SecurityCenterClient::createSourceAsync()} . - * - * @example samples/V1/SecurityCenterClient/create_source.php - * - * @param CreateSourceRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Source - * - * @throws ApiException Thrown if the API call fails. - */ - public function createSource(CreateSourceRequest $request, array $callOptions = []): Source - { - return $this->startApiCall('CreateSource', $request, $callOptions)->wait(); - } - - /** - * Deletes an existing BigQuery export. - * - * The async variant is {@see SecurityCenterClient::deleteBigQueryExportAsync()} . - * - * @example samples/V1/SecurityCenterClient/delete_big_query_export.php - * - * @param DeleteBigQueryExportRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteBigQueryExport(DeleteBigQueryExportRequest $request, array $callOptions = []): void - { - $this->startApiCall('DeleteBigQueryExport', $request, $callOptions)->wait(); - } - - /** - * Deletes an existing mute config. - * - * The async variant is {@see SecurityCenterClient::deleteMuteConfigAsync()} . - * - * @example samples/V1/SecurityCenterClient/delete_mute_config.php - * - * @param DeleteMuteConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteMuteConfig(DeleteMuteConfigRequest $request, array $callOptions = []): void - { - $this->startApiCall('DeleteMuteConfig', $request, $callOptions)->wait(); - } - - /** - * Deletes a notification config. - * - * The async variant is - * {@see SecurityCenterClient::deleteNotificationConfigAsync()} . - * - * @example samples/V1/SecurityCenterClient/delete_notification_config.php - * - * @param DeleteNotificationConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteNotificationConfig(DeleteNotificationConfigRequest $request, array $callOptions = []): void - { - $this->startApiCall('DeleteNotificationConfig', $request, $callOptions)->wait(); - } - - /** - * Deletes the specified SecurityHealthAnalyticsCustomModule and all of its - * descendants in the CRM hierarchy. This method is only supported for - * resident custom modules. - * - * The async variant is - * {@see SecurityCenterClient::deleteSecurityHealthAnalyticsCustomModuleAsync()} . - * - * @example samples/V1/SecurityCenterClient/delete_security_health_analytics_custom_module.php - * - * @param DeleteSecurityHealthAnalyticsCustomModuleRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteSecurityHealthAnalyticsCustomModule(DeleteSecurityHealthAnalyticsCustomModuleRequest $request, array $callOptions = []): void - { - $this->startApiCall('DeleteSecurityHealthAnalyticsCustomModule', $request, $callOptions)->wait(); - } - - /** - * Gets a BigQuery export. - * - * The async variant is {@see SecurityCenterClient::getBigQueryExportAsync()} . - * - * @example samples/V1/SecurityCenterClient/get_big_query_export.php - * - * @param GetBigQueryExportRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return BigQueryExport - * - * @throws ApiException Thrown if the API call fails. - */ - public function getBigQueryExport(GetBigQueryExportRequest $request, array $callOptions = []): BigQueryExport - { - return $this->startApiCall('GetBigQueryExport', $request, $callOptions)->wait(); - } - - /** - * Retrieves an EffectiveSecurityHealthAnalyticsCustomModule. - * - * The async variant is - * {@see SecurityCenterClient::getEffectiveSecurityHealthAnalyticsCustomModuleAsync()} - * . - * - * @example samples/V1/SecurityCenterClient/get_effective_security_health_analytics_custom_module.php - * - * @param GetEffectiveSecurityHealthAnalyticsCustomModuleRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return EffectiveSecurityHealthAnalyticsCustomModule - * - * @throws ApiException Thrown if the API call fails. - */ - public function getEffectiveSecurityHealthAnalyticsCustomModule(GetEffectiveSecurityHealthAnalyticsCustomModuleRequest $request, array $callOptions = []): EffectiveSecurityHealthAnalyticsCustomModule - { - return $this->startApiCall('GetEffectiveSecurityHealthAnalyticsCustomModule', $request, $callOptions)->wait(); - } - - /** - * Gets the access control policy on the specified Source. - * - * The async variant is {@see SecurityCenterClient::getIamPolicyAsync()} . - * - * @example samples/V1/SecurityCenterClient/get_iam_policy.php - * - * @param GetIamPolicyRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Policy - * - * @throws ApiException Thrown if the API call fails. - */ - public function getIamPolicy(GetIamPolicyRequest $request, array $callOptions = []): Policy - { - return $this->startApiCall('GetIamPolicy', $request, $callOptions)->wait(); - } - - /** - * Gets a mute config. - * - * The async variant is {@see SecurityCenterClient::getMuteConfigAsync()} . - * - * @example samples/V1/SecurityCenterClient/get_mute_config.php - * - * @param GetMuteConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return MuteConfig - * - * @throws ApiException Thrown if the API call fails. - */ - public function getMuteConfig(GetMuteConfigRequest $request, array $callOptions = []): MuteConfig - { - return $this->startApiCall('GetMuteConfig', $request, $callOptions)->wait(); - } - - /** - * Gets a notification config. - * - * The async variant is {@see SecurityCenterClient::getNotificationConfigAsync()} . - * - * @example samples/V1/SecurityCenterClient/get_notification_config.php - * - * @param GetNotificationConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return NotificationConfig - * - * @throws ApiException Thrown if the API call fails. - */ - public function getNotificationConfig(GetNotificationConfigRequest $request, array $callOptions = []): NotificationConfig - { - return $this->startApiCall('GetNotificationConfig', $request, $callOptions)->wait(); - } - - /** - * Gets the settings for an organization. - * - * The async variant is {@see SecurityCenterClient::getOrganizationSettingsAsync()} - * . - * - * @example samples/V1/SecurityCenterClient/get_organization_settings.php - * - * @param GetOrganizationSettingsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return OrganizationSettings - * - * @throws ApiException Thrown if the API call fails. - */ - public function getOrganizationSettings(GetOrganizationSettingsRequest $request, array $callOptions = []): OrganizationSettings - { - return $this->startApiCall('GetOrganizationSettings', $request, $callOptions)->wait(); - } - - /** - * Retrieves a SecurityHealthAnalyticsCustomModule. - * - * The async variant is - * {@see SecurityCenterClient::getSecurityHealthAnalyticsCustomModuleAsync()} . - * - * @example samples/V1/SecurityCenterClient/get_security_health_analytics_custom_module.php - * - * @param GetSecurityHealthAnalyticsCustomModuleRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return SecurityHealthAnalyticsCustomModule - * - * @throws ApiException Thrown if the API call fails. - */ - public function getSecurityHealthAnalyticsCustomModule(GetSecurityHealthAnalyticsCustomModuleRequest $request, array $callOptions = []): SecurityHealthAnalyticsCustomModule - { - return $this->startApiCall('GetSecurityHealthAnalyticsCustomModule', $request, $callOptions)->wait(); - } - - /** - * Gets a source. - * - * The async variant is {@see SecurityCenterClient::getSourceAsync()} . - * - * @example samples/V1/SecurityCenterClient/get_source.php - * - * @param GetSourceRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Source - * - * @throws ApiException Thrown if the API call fails. - */ - public function getSource(GetSourceRequest $request, array $callOptions = []): Source - { - return $this->startApiCall('GetSource', $request, $callOptions)->wait(); - } - - /** - * Filters an organization's assets and groups them by their specified - * properties. - * - * The async variant is {@see SecurityCenterClient::groupAssetsAsync()} . - * - * @example samples/V1/SecurityCenterClient/group_assets.php - * - * @param GroupAssetsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @deprecated This method will be removed in the next major version update. - */ - public function groupAssets(GroupAssetsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('GroupAssets', $request, $callOptions); - } - - /** - * Filters an organization or source's findings and groups them by their - * specified properties. - * - * To group across all sources provide a `-` as the source id. - * Example: /v1/organizations/{organization_id}/sources/-/findings, - * /v1/folders/{folder_id}/sources/-/findings, - * /v1/projects/{project_id}/sources/-/findings - * - * The async variant is {@see SecurityCenterClient::groupFindingsAsync()} . - * - * @example samples/V1/SecurityCenterClient/group_findings.php - * - * @param GroupFindingsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function groupFindings(GroupFindingsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('GroupFindings', $request, $callOptions); - } - - /** - * Lists an organization's assets. - * - * The async variant is {@see SecurityCenterClient::listAssetsAsync()} . - * - * @example samples/V1/SecurityCenterClient/list_assets.php - * - * @param ListAssetsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @deprecated This method will be removed in the next major version update. - */ - public function listAssets(ListAssetsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListAssets', $request, $callOptions); - } - - /** - * Lists BigQuery exports. Note that when requesting BigQuery exports at a - * given level all exports under that level are also returned e.g. if - * requesting BigQuery exports under a folder, then all BigQuery exports - * immediately under the folder plus the ones created under the projects - * within the folder are returned. - * - * The async variant is {@see SecurityCenterClient::listBigQueryExportsAsync()} . - * - * @example samples/V1/SecurityCenterClient/list_big_query_exports.php - * - * @param ListBigQueryExportsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listBigQueryExports(ListBigQueryExportsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListBigQueryExports', $request, $callOptions); - } - - /** - * Returns a list of all resident SecurityHealthAnalyticsCustomModules under - * the given CRM parent and all of the parent’s CRM descendants. - * - * The async variant is - * {@see SecurityCenterClient::listDescendantSecurityHealthAnalyticsCustomModulesAsync()} - * . - * - * @example samples/V1/SecurityCenterClient/list_descendant_security_health_analytics_custom_modules.php - * - * @param ListDescendantSecurityHealthAnalyticsCustomModulesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listDescendantSecurityHealthAnalyticsCustomModules(ListDescendantSecurityHealthAnalyticsCustomModulesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListDescendantSecurityHealthAnalyticsCustomModules', $request, $callOptions); - } - - /** - * Returns a list of all EffectiveSecurityHealthAnalyticsCustomModules for the - * given parent. This includes resident modules defined at the scope of the - * parent, and inherited modules, inherited from CRM ancestors. - * - * The async variant is - * {@see SecurityCenterClient::listEffectiveSecurityHealthAnalyticsCustomModulesAsync()} - * . - * - * @example samples/V1/SecurityCenterClient/list_effective_security_health_analytics_custom_modules.php - * - * @param ListEffectiveSecurityHealthAnalyticsCustomModulesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listEffectiveSecurityHealthAnalyticsCustomModules(ListEffectiveSecurityHealthAnalyticsCustomModulesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListEffectiveSecurityHealthAnalyticsCustomModules', $request, $callOptions); - } - - /** - * Lists an organization or source's findings. - * - * To list across all sources provide a `-` as the source id. - * Example: /v1/organizations/{organization_id}/sources/-/findings - * - * The async variant is {@see SecurityCenterClient::listFindingsAsync()} . - * - * @example samples/V1/SecurityCenterClient/list_findings.php - * - * @param ListFindingsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listFindings(ListFindingsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListFindings', $request, $callOptions); - } - - /** - * Lists mute configs. - * - * The async variant is {@see SecurityCenterClient::listMuteConfigsAsync()} . - * - * @example samples/V1/SecurityCenterClient/list_mute_configs.php - * - * @param ListMuteConfigsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listMuteConfigs(ListMuteConfigsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListMuteConfigs', $request, $callOptions); - } - - /** - * Lists notification configs. - * - * The async variant is {@see SecurityCenterClient::listNotificationConfigsAsync()} - * . - * - * @example samples/V1/SecurityCenterClient/list_notification_configs.php - * - * @param ListNotificationConfigsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listNotificationConfigs(ListNotificationConfigsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListNotificationConfigs', $request, $callOptions); - } - - /** - * Returns a list of all SecurityHealthAnalyticsCustomModules for the given - * parent. This includes resident modules defined at the scope of the parent, - * and inherited modules, inherited from CRM ancestors. - * - * The async variant is - * {@see SecurityCenterClient::listSecurityHealthAnalyticsCustomModulesAsync()} . - * - * @example samples/V1/SecurityCenterClient/list_security_health_analytics_custom_modules.php - * - * @param ListSecurityHealthAnalyticsCustomModulesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listSecurityHealthAnalyticsCustomModules(ListSecurityHealthAnalyticsCustomModulesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListSecurityHealthAnalyticsCustomModules', $request, $callOptions); - } - - /** - * Lists all sources belonging to an organization. - * - * The async variant is {@see SecurityCenterClient::listSourcesAsync()} . - * - * @example samples/V1/SecurityCenterClient/list_sources.php - * - * @param ListSourcesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listSources(ListSourcesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListSources', $request, $callOptions); - } - - /** - * Runs asset discovery. The discovery is tracked with a long-running - * operation. - * - * This API can only be called with limited frequency for an organization. If - * it is called too frequently the caller will receive a TOO_MANY_REQUESTS - * error. - * - * The async variant is {@see SecurityCenterClient::runAssetDiscoveryAsync()} . - * - * @example samples/V1/SecurityCenterClient/run_asset_discovery.php - * - * @param RunAssetDiscoveryRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return OperationResponse - * - * @throws ApiException Thrown if the API call fails. - * - * @deprecated This method will be removed in the next major version update. - */ - public function runAssetDiscovery(RunAssetDiscoveryRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('RunAssetDiscovery', $request, $callOptions)->wait(); - } - - /** - * Updates the state of a finding. - * - * The async variant is {@see SecurityCenterClient::setFindingStateAsync()} . - * - * @example samples/V1/SecurityCenterClient/set_finding_state.php - * - * @param SetFindingStateRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Finding - * - * @throws ApiException Thrown if the API call fails. - */ - public function setFindingState(SetFindingStateRequest $request, array $callOptions = []): Finding - { - return $this->startApiCall('SetFindingState', $request, $callOptions)->wait(); - } - - /** - * Sets the access control policy on the specified Source. - * - * The async variant is {@see SecurityCenterClient::setIamPolicyAsync()} . - * - * @example samples/V1/SecurityCenterClient/set_iam_policy.php - * - * @param SetIamPolicyRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Policy - * - * @throws ApiException Thrown if the API call fails. - */ - public function setIamPolicy(SetIamPolicyRequest $request, array $callOptions = []): Policy - { - return $this->startApiCall('SetIamPolicy', $request, $callOptions)->wait(); - } - - /** - * Updates the mute state of a finding. - * - * The async variant is {@see SecurityCenterClient::setMuteAsync()} . - * - * @example samples/V1/SecurityCenterClient/set_mute.php - * - * @param SetMuteRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Finding - * - * @throws ApiException Thrown if the API call fails. - */ - public function setMute(SetMuteRequest $request, array $callOptions = []): Finding - { - return $this->startApiCall('SetMute', $request, $callOptions)->wait(); - } - - /** - * Simulates a given SecurityHealthAnalyticsCustomModule and Resource. - * - * The async variant is - * {@see SecurityCenterClient::simulateSecurityHealthAnalyticsCustomModuleAsync()} - * . - * - * @example samples/V1/SecurityCenterClient/simulate_security_health_analytics_custom_module.php - * - * @param SimulateSecurityHealthAnalyticsCustomModuleRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return SimulateSecurityHealthAnalyticsCustomModuleResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function simulateSecurityHealthAnalyticsCustomModule(SimulateSecurityHealthAnalyticsCustomModuleRequest $request, array $callOptions = []): SimulateSecurityHealthAnalyticsCustomModuleResponse - { - return $this->startApiCall('SimulateSecurityHealthAnalyticsCustomModule', $request, $callOptions)->wait(); - } - - /** - * Returns the permissions that a caller has on the specified source. - * - * The async variant is {@see SecurityCenterClient::testIamPermissionsAsync()} . - * - * @example samples/V1/SecurityCenterClient/test_iam_permissions.php - * - * @param TestIamPermissionsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return TestIamPermissionsResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function testIamPermissions(TestIamPermissionsRequest $request, array $callOptions = []): TestIamPermissionsResponse - { - return $this->startApiCall('TestIamPermissions', $request, $callOptions)->wait(); - } - - /** - * Updates a BigQuery export. - * - * The async variant is {@see SecurityCenterClient::updateBigQueryExportAsync()} . - * - * @example samples/V1/SecurityCenterClient/update_big_query_export.php - * - * @param UpdateBigQueryExportRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return BigQueryExport - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateBigQueryExport(UpdateBigQueryExportRequest $request, array $callOptions = []): BigQueryExport - { - return $this->startApiCall('UpdateBigQueryExport', $request, $callOptions)->wait(); - } - - /** - * Updates external system. This is for a given finding. - * - * The async variant is {@see SecurityCenterClient::updateExternalSystemAsync()} . - * - * @example samples/V1/SecurityCenterClient/update_external_system.php - * - * @param UpdateExternalSystemRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return ExternalSystem - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateExternalSystem(UpdateExternalSystemRequest $request, array $callOptions = []): ExternalSystem - { - return $this->startApiCall('UpdateExternalSystem', $request, $callOptions)->wait(); - } - - /** - * Creates or updates a finding. The corresponding source must exist for a - * finding creation to succeed. - * - * The async variant is {@see SecurityCenterClient::updateFindingAsync()} . - * - * @example samples/V1/SecurityCenterClient/update_finding.php - * - * @param UpdateFindingRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Finding - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateFinding(UpdateFindingRequest $request, array $callOptions = []): Finding - { - return $this->startApiCall('UpdateFinding', $request, $callOptions)->wait(); - } - - /** - * Updates a mute config. - * - * The async variant is {@see SecurityCenterClient::updateMuteConfigAsync()} . - * - * @example samples/V1/SecurityCenterClient/update_mute_config.php - * - * @param UpdateMuteConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return MuteConfig - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateMuteConfig(UpdateMuteConfigRequest $request, array $callOptions = []): MuteConfig - { - return $this->startApiCall('UpdateMuteConfig', $request, $callOptions)->wait(); - } - - /** - * - * Updates a notification config. The following update - * fields are allowed: description, pubsub_topic, streaming_config.filter - * - * The async variant is - * {@see SecurityCenterClient::updateNotificationConfigAsync()} . - * - * @example samples/V1/SecurityCenterClient/update_notification_config.php - * - * @param UpdateNotificationConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return NotificationConfig - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateNotificationConfig(UpdateNotificationConfigRequest $request, array $callOptions = []): NotificationConfig - { - return $this->startApiCall('UpdateNotificationConfig', $request, $callOptions)->wait(); - } - - /** - * Updates an organization's settings. - * - * The async variant is - * {@see SecurityCenterClient::updateOrganizationSettingsAsync()} . - * - * @example samples/V1/SecurityCenterClient/update_organization_settings.php - * - * @param UpdateOrganizationSettingsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return OrganizationSettings - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateOrganizationSettings(UpdateOrganizationSettingsRequest $request, array $callOptions = []): OrganizationSettings - { - return $this->startApiCall('UpdateOrganizationSettings', $request, $callOptions)->wait(); - } - - /** - * Updates the SecurityHealthAnalyticsCustomModule under the given name based - * on the given update mask. Updating the enablement state is supported on - * both resident and inherited modules (though resident modules cannot have an - * enablement state of "inherited"). Updating the display name and custom - * config of a module is supported on resident modules only. - * - * The async variant is - * {@see SecurityCenterClient::updateSecurityHealthAnalyticsCustomModuleAsync()} . - * - * @example samples/V1/SecurityCenterClient/update_security_health_analytics_custom_module.php - * - * @param UpdateSecurityHealthAnalyticsCustomModuleRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return SecurityHealthAnalyticsCustomModule - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateSecurityHealthAnalyticsCustomModule(UpdateSecurityHealthAnalyticsCustomModuleRequest $request, array $callOptions = []): SecurityHealthAnalyticsCustomModule - { - return $this->startApiCall('UpdateSecurityHealthAnalyticsCustomModule', $request, $callOptions)->wait(); - } - - /** - * Updates security marks. - * - * The async variant is {@see SecurityCenterClient::updateSecurityMarksAsync()} . - * - * @example samples/V1/SecurityCenterClient/update_security_marks.php - * - * @param UpdateSecurityMarksRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return SecurityMarks - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateSecurityMarks(UpdateSecurityMarksRequest $request, array $callOptions = []): SecurityMarks - { - return $this->startApiCall('UpdateSecurityMarks', $request, $callOptions)->wait(); - } - - /** - * Updates a source. - * - * The async variant is {@see SecurityCenterClient::updateSourceAsync()} . - * - * @example samples/V1/SecurityCenterClient/update_source.php - * - * @param UpdateSourceRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Source - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateSource(UpdateSourceRequest $request, array $callOptions = []): Source - { - return $this->startApiCall('UpdateSource', $request, $callOptions)->wait(); - } -} diff --git a/owl-bot-staging/SecurityCenter/v1/src/V1/Gapic/SecurityCenterGapicClient.php b/owl-bot-staging/SecurityCenter/v1/src/V1/Gapic/SecurityCenterGapicClient.php deleted file mode 100644 index 01a38f3241d4..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/src/V1/Gapic/SecurityCenterGapicClient.php +++ /dev/null @@ -1,5120 +0,0 @@ -bulkMuteFindings($parent); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $securityCenterClient->bulkMuteFindings($parent); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $securityCenterClient->resumeOperation($operationName, 'bulkMuteFindings'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * Many parameters require resource names to be formatted in a particular way. To - * assist with these names, this class includes a format method for each type of - * name, and additionally a parseName method to extract the individual identifiers - * contained within formatted names that are returned by the API. - * - * @deprecated Please use the new service client {@see \Google\Cloud\SecurityCenter\V1\Client\SecurityCenterClient}. - */ -class SecurityCenterGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.securitycenter.v1.SecurityCenter'; - - /** - * The default address of the service. - * - * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. - */ - const SERVICE_ADDRESS = 'securitycenter.googleapis.com'; - - /** The address template of the service. */ - private const SERVICE_ADDRESS_TEMPLATE = 'securitycenter.UNIVERSE_DOMAIN'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $bigQueryExportNameTemplate; - - private static $dlpJobNameTemplate; - - private static $effectiveSecurityHealthAnalyticsCustomModuleNameTemplate; - - private static $externalSystemNameTemplate; - - private static $findingNameTemplate; - - private static $folderNameTemplate; - - private static $folderAssetSecurityMarksNameTemplate; - - private static $folderConstraintNameNameTemplate; - - private static $folderCustomModuleNameTemplate; - - private static $folderEffectiveCustomModuleNameTemplate; - - private static $folderExportNameTemplate; - - private static $folderMuteConfigNameTemplate; - - private static $folderNotificationConfigNameTemplate; - - private static $folderSecurityHealthAnalyticsSettingsNameTemplate; - - private static $folderSourceNameTemplate; - - private static $folderSourceFindingNameTemplate; - - private static $folderSourceFindingExternalsystemNameTemplate; - - private static $folderSourceFindingSecurityMarksNameTemplate; - - private static $muteConfigNameTemplate; - - private static $notificationConfigNameTemplate; - - private static $organizationNameTemplate; - - private static $organizationAssetSecurityMarksNameTemplate; - - private static $organizationConstraintNameNameTemplate; - - private static $organizationCustomModuleNameTemplate; - - private static $organizationEffectiveCustomModuleNameTemplate; - - private static $organizationExportNameTemplate; - - private static $organizationMuteConfigNameTemplate; - - private static $organizationNotificationConfigNameTemplate; - - private static $organizationSecurityHealthAnalyticsSettingsNameTemplate; - - private static $organizationSettingsNameTemplate; - - private static $organizationSourceNameTemplate; - - private static $organizationSourceFindingNameTemplate; - - private static $organizationSourceFindingExternalsystemNameTemplate; - - private static $organizationSourceFindingSecurityMarksNameTemplate; - - private static $policyNameTemplate; - - private static $projectNameTemplate; - - private static $projectAssetSecurityMarksNameTemplate; - - private static $projectConstraintNameNameTemplate; - - private static $projectCustomModuleNameTemplate; - - private static $projectDlpJobNameTemplate; - - private static $projectEffectiveCustomModuleNameTemplate; - - private static $projectExportNameTemplate; - - private static $projectLocationDlpJobNameTemplate; - - private static $projectLocationTableProfileNameTemplate; - - private static $projectMuteConfigNameTemplate; - - private static $projectNotificationConfigNameTemplate; - - private static $projectSecurityHealthAnalyticsSettingsNameTemplate; - - private static $projectSourceNameTemplate; - - private static $projectSourceFindingNameTemplate; - - private static $projectSourceFindingExternalsystemNameTemplate; - - private static $projectSourceFindingSecurityMarksNameTemplate; - - private static $projectTableProfileNameTemplate; - - private static $securityHealthAnalyticsCustomModuleNameTemplate; - - private static $securityHealthAnalyticsSettingsNameTemplate; - - private static $securityMarksNameTemplate; - - private static $sourceNameTemplate; - - private static $tableDataProfileNameTemplate; - - private static $topicNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/security_center_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/security_center_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/security_center_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/security_center_rest_client_config.php', - ], - ], - ]; - } - - private static function getBigQueryExportNameTemplate() - { - if (self::$bigQueryExportNameTemplate == null) { - self::$bigQueryExportNameTemplate = new PathTemplate('organizations/{organization}/bigQueryExports/{export}'); - } - - return self::$bigQueryExportNameTemplate; - } - - private static function getDlpJobNameTemplate() - { - if (self::$dlpJobNameTemplate == null) { - self::$dlpJobNameTemplate = new PathTemplate('projects/{project}/dlpJobs/{dlp_job}'); - } - - return self::$dlpJobNameTemplate; - } - - private static function getEffectiveSecurityHealthAnalyticsCustomModuleNameTemplate() - { - if (self::$effectiveSecurityHealthAnalyticsCustomModuleNameTemplate == null) { - self::$effectiveSecurityHealthAnalyticsCustomModuleNameTemplate = new PathTemplate('organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module}'); - } - - return self::$effectiveSecurityHealthAnalyticsCustomModuleNameTemplate; - } - - private static function getExternalSystemNameTemplate() - { - if (self::$externalSystemNameTemplate == null) { - self::$externalSystemNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}'); - } - - return self::$externalSystemNameTemplate; - } - - private static function getFindingNameTemplate() - { - if (self::$findingNameTemplate == null) { - self::$findingNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}/findings/{finding}'); - } - - return self::$findingNameTemplate; - } - - private static function getFolderNameTemplate() - { - if (self::$folderNameTemplate == null) { - self::$folderNameTemplate = new PathTemplate('folders/{folder}'); - } - - return self::$folderNameTemplate; - } - - private static function getFolderAssetSecurityMarksNameTemplate() - { - if (self::$folderAssetSecurityMarksNameTemplate == null) { - self::$folderAssetSecurityMarksNameTemplate = new PathTemplate('folders/{folder}/assets/{asset}/securityMarks'); - } - - return self::$folderAssetSecurityMarksNameTemplate; - } - - private static function getFolderConstraintNameNameTemplate() - { - if (self::$folderConstraintNameNameTemplate == null) { - self::$folderConstraintNameNameTemplate = new PathTemplate('folders/{folder}/policies/{constraint_name}'); - } - - return self::$folderConstraintNameNameTemplate; - } - - private static function getFolderCustomModuleNameTemplate() - { - if (self::$folderCustomModuleNameTemplate == null) { - self::$folderCustomModuleNameTemplate = new PathTemplate('folders/{folder}/securityHealthAnalyticsSettings/customModules/{custom_module}'); - } - - return self::$folderCustomModuleNameTemplate; - } - - private static function getFolderEffectiveCustomModuleNameTemplate() - { - if (self::$folderEffectiveCustomModuleNameTemplate == null) { - self::$folderEffectiveCustomModuleNameTemplate = new PathTemplate('folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module}'); - } - - return self::$folderEffectiveCustomModuleNameTemplate; - } - - private static function getFolderExportNameTemplate() - { - if (self::$folderExportNameTemplate == null) { - self::$folderExportNameTemplate = new PathTemplate('folders/{folder}/bigQueryExports/{export}'); - } - - return self::$folderExportNameTemplate; - } - - private static function getFolderMuteConfigNameTemplate() - { - if (self::$folderMuteConfigNameTemplate == null) { - self::$folderMuteConfigNameTemplate = new PathTemplate('folders/{folder}/muteConfigs/{mute_config}'); - } - - return self::$folderMuteConfigNameTemplate; - } - - private static function getFolderNotificationConfigNameTemplate() - { - if (self::$folderNotificationConfigNameTemplate == null) { - self::$folderNotificationConfigNameTemplate = new PathTemplate('folders/{folder}/notificationConfigs/{notification_config}'); - } - - return self::$folderNotificationConfigNameTemplate; - } - - private static function getFolderSecurityHealthAnalyticsSettingsNameTemplate() - { - if (self::$folderSecurityHealthAnalyticsSettingsNameTemplate == null) { - self::$folderSecurityHealthAnalyticsSettingsNameTemplate = new PathTemplate('folders/{folder}/securityHealthAnalyticsSettings'); - } - - return self::$folderSecurityHealthAnalyticsSettingsNameTemplate; - } - - private static function getFolderSourceNameTemplate() - { - if (self::$folderSourceNameTemplate == null) { - self::$folderSourceNameTemplate = new PathTemplate('folders/{folder}/sources/{source}'); - } - - return self::$folderSourceNameTemplate; - } - - private static function getFolderSourceFindingNameTemplate() - { - if (self::$folderSourceFindingNameTemplate == null) { - self::$folderSourceFindingNameTemplate = new PathTemplate('folders/{folder}/sources/{source}/findings/{finding}'); - } - - return self::$folderSourceFindingNameTemplate; - } - - private static function getFolderSourceFindingExternalsystemNameTemplate() - { - if (self::$folderSourceFindingExternalsystemNameTemplate == null) { - self::$folderSourceFindingExternalsystemNameTemplate = new PathTemplate('folders/{folder}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}'); - } - - return self::$folderSourceFindingExternalsystemNameTemplate; - } - - private static function getFolderSourceFindingSecurityMarksNameTemplate() - { - if (self::$folderSourceFindingSecurityMarksNameTemplate == null) { - self::$folderSourceFindingSecurityMarksNameTemplate = new PathTemplate('folders/{folder}/sources/{source}/findings/{finding}/securityMarks'); - } - - return self::$folderSourceFindingSecurityMarksNameTemplate; - } - - private static function getMuteConfigNameTemplate() - { - if (self::$muteConfigNameTemplate == null) { - self::$muteConfigNameTemplate = new PathTemplate('organizations/{organization}/muteConfigs/{mute_config}'); - } - - return self::$muteConfigNameTemplate; - } - - private static function getNotificationConfigNameTemplate() - { - if (self::$notificationConfigNameTemplate == null) { - self::$notificationConfigNameTemplate = new PathTemplate('organizations/{organization}/notificationConfigs/{notification_config}'); - } - - return self::$notificationConfigNameTemplate; - } - - private static function getOrganizationNameTemplate() - { - if (self::$organizationNameTemplate == null) { - self::$organizationNameTemplate = new PathTemplate('organizations/{organization}'); - } - - return self::$organizationNameTemplate; - } - - private static function getOrganizationAssetSecurityMarksNameTemplate() - { - if (self::$organizationAssetSecurityMarksNameTemplate == null) { - self::$organizationAssetSecurityMarksNameTemplate = new PathTemplate('organizations/{organization}/assets/{asset}/securityMarks'); - } - - return self::$organizationAssetSecurityMarksNameTemplate; - } - - private static function getOrganizationConstraintNameNameTemplate() - { - if (self::$organizationConstraintNameNameTemplate == null) { - self::$organizationConstraintNameNameTemplate = new PathTemplate('organizations/{organization}/policies/{constraint_name}'); - } - - return self::$organizationConstraintNameNameTemplate; - } - - private static function getOrganizationCustomModuleNameTemplate() - { - if (self::$organizationCustomModuleNameTemplate == null) { - self::$organizationCustomModuleNameTemplate = new PathTemplate('organizations/{organization}/securityHealthAnalyticsSettings/customModules/{custom_module}'); - } - - return self::$organizationCustomModuleNameTemplate; - } - - private static function getOrganizationEffectiveCustomModuleNameTemplate() - { - if (self::$organizationEffectiveCustomModuleNameTemplate == null) { - self::$organizationEffectiveCustomModuleNameTemplate = new PathTemplate('organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module}'); - } - - return self::$organizationEffectiveCustomModuleNameTemplate; - } - - private static function getOrganizationExportNameTemplate() - { - if (self::$organizationExportNameTemplate == null) { - self::$organizationExportNameTemplate = new PathTemplate('organizations/{organization}/bigQueryExports/{export}'); - } - - return self::$organizationExportNameTemplate; - } - - private static function getOrganizationMuteConfigNameTemplate() - { - if (self::$organizationMuteConfigNameTemplate == null) { - self::$organizationMuteConfigNameTemplate = new PathTemplate('organizations/{organization}/muteConfigs/{mute_config}'); - } - - return self::$organizationMuteConfigNameTemplate; - } - - private static function getOrganizationNotificationConfigNameTemplate() - { - if (self::$organizationNotificationConfigNameTemplate == null) { - self::$organizationNotificationConfigNameTemplate = new PathTemplate('organizations/{organization}/notificationConfigs/{notification_config}'); - } - - return self::$organizationNotificationConfigNameTemplate; - } - - private static function getOrganizationSecurityHealthAnalyticsSettingsNameTemplate() - { - if (self::$organizationSecurityHealthAnalyticsSettingsNameTemplate == null) { - self::$organizationSecurityHealthAnalyticsSettingsNameTemplate = new PathTemplate('organizations/{organization}/securityHealthAnalyticsSettings'); - } - - return self::$organizationSecurityHealthAnalyticsSettingsNameTemplate; - } - - private static function getOrganizationSettingsNameTemplate() - { - if (self::$organizationSettingsNameTemplate == null) { - self::$organizationSettingsNameTemplate = new PathTemplate('organizations/{organization}/organizationSettings'); - } - - return self::$organizationSettingsNameTemplate; - } - - private static function getOrganizationSourceNameTemplate() - { - if (self::$organizationSourceNameTemplate == null) { - self::$organizationSourceNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}'); - } - - return self::$organizationSourceNameTemplate; - } - - private static function getOrganizationSourceFindingNameTemplate() - { - if (self::$organizationSourceFindingNameTemplate == null) { - self::$organizationSourceFindingNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}/findings/{finding}'); - } - - return self::$organizationSourceFindingNameTemplate; - } - - private static function getOrganizationSourceFindingExternalsystemNameTemplate() - { - if (self::$organizationSourceFindingExternalsystemNameTemplate == null) { - self::$organizationSourceFindingExternalsystemNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}'); - } - - return self::$organizationSourceFindingExternalsystemNameTemplate; - } - - private static function getOrganizationSourceFindingSecurityMarksNameTemplate() - { - if (self::$organizationSourceFindingSecurityMarksNameTemplate == null) { - self::$organizationSourceFindingSecurityMarksNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}/findings/{finding}/securityMarks'); - } - - return self::$organizationSourceFindingSecurityMarksNameTemplate; - } - - private static function getPolicyNameTemplate() - { - if (self::$policyNameTemplate == null) { - self::$policyNameTemplate = new PathTemplate('organizations/{organization}/policies/{constraint_name}'); - } - - return self::$policyNameTemplate; - } - - private static function getProjectNameTemplate() - { - if (self::$projectNameTemplate == null) { - self::$projectNameTemplate = new PathTemplate('projects/{project}'); - } - - return self::$projectNameTemplate; - } - - private static function getProjectAssetSecurityMarksNameTemplate() - { - if (self::$projectAssetSecurityMarksNameTemplate == null) { - self::$projectAssetSecurityMarksNameTemplate = new PathTemplate('projects/{project}/assets/{asset}/securityMarks'); - } - - return self::$projectAssetSecurityMarksNameTemplate; - } - - private static function getProjectConstraintNameNameTemplate() - { - if (self::$projectConstraintNameNameTemplate == null) { - self::$projectConstraintNameNameTemplate = new PathTemplate('projects/{project}/policies/{constraint_name}'); - } - - return self::$projectConstraintNameNameTemplate; - } - - private static function getProjectCustomModuleNameTemplate() - { - if (self::$projectCustomModuleNameTemplate == null) { - self::$projectCustomModuleNameTemplate = new PathTemplate('projects/{project}/securityHealthAnalyticsSettings/customModules/{custom_module}'); - } - - return self::$projectCustomModuleNameTemplate; - } - - private static function getProjectDlpJobNameTemplate() - { - if (self::$projectDlpJobNameTemplate == null) { - self::$projectDlpJobNameTemplate = new PathTemplate('projects/{project}/dlpJobs/{dlp_job}'); - } - - return self::$projectDlpJobNameTemplate; - } - - private static function getProjectEffectiveCustomModuleNameTemplate() - { - if (self::$projectEffectiveCustomModuleNameTemplate == null) { - self::$projectEffectiveCustomModuleNameTemplate = new PathTemplate('projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module}'); - } - - return self::$projectEffectiveCustomModuleNameTemplate; - } - - private static function getProjectExportNameTemplate() - { - if (self::$projectExportNameTemplate == null) { - self::$projectExportNameTemplate = new PathTemplate('projects/{project}/bigQueryExports/{export}'); - } - - return self::$projectExportNameTemplate; - } - - private static function getProjectLocationDlpJobNameTemplate() - { - if (self::$projectLocationDlpJobNameTemplate == null) { - self::$projectLocationDlpJobNameTemplate = new PathTemplate('projects/{project}/locations/{location}/dlpJobs/{dlp_job}'); - } - - return self::$projectLocationDlpJobNameTemplate; - } - - private static function getProjectLocationTableProfileNameTemplate() - { - if (self::$projectLocationTableProfileNameTemplate == null) { - self::$projectLocationTableProfileNameTemplate = new PathTemplate('projects/{project}/locations/{location}/tableProfiles/{table_profile}'); - } - - return self::$projectLocationTableProfileNameTemplate; - } - - private static function getProjectMuteConfigNameTemplate() - { - if (self::$projectMuteConfigNameTemplate == null) { - self::$projectMuteConfigNameTemplate = new PathTemplate('projects/{project}/muteConfigs/{mute_config}'); - } - - return self::$projectMuteConfigNameTemplate; - } - - private static function getProjectNotificationConfigNameTemplate() - { - if (self::$projectNotificationConfigNameTemplate == null) { - self::$projectNotificationConfigNameTemplate = new PathTemplate('projects/{project}/notificationConfigs/{notification_config}'); - } - - return self::$projectNotificationConfigNameTemplate; - } - - private static function getProjectSecurityHealthAnalyticsSettingsNameTemplate() - { - if (self::$projectSecurityHealthAnalyticsSettingsNameTemplate == null) { - self::$projectSecurityHealthAnalyticsSettingsNameTemplate = new PathTemplate('projects/{project}/securityHealthAnalyticsSettings'); - } - - return self::$projectSecurityHealthAnalyticsSettingsNameTemplate; - } - - private static function getProjectSourceNameTemplate() - { - if (self::$projectSourceNameTemplate == null) { - self::$projectSourceNameTemplate = new PathTemplate('projects/{project}/sources/{source}'); - } - - return self::$projectSourceNameTemplate; - } - - private static function getProjectSourceFindingNameTemplate() - { - if (self::$projectSourceFindingNameTemplate == null) { - self::$projectSourceFindingNameTemplate = new PathTemplate('projects/{project}/sources/{source}/findings/{finding}'); - } - - return self::$projectSourceFindingNameTemplate; - } - - private static function getProjectSourceFindingExternalsystemNameTemplate() - { - if (self::$projectSourceFindingExternalsystemNameTemplate == null) { - self::$projectSourceFindingExternalsystemNameTemplate = new PathTemplate('projects/{project}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}'); - } - - return self::$projectSourceFindingExternalsystemNameTemplate; - } - - private static function getProjectSourceFindingSecurityMarksNameTemplate() - { - if (self::$projectSourceFindingSecurityMarksNameTemplate == null) { - self::$projectSourceFindingSecurityMarksNameTemplate = new PathTemplate('projects/{project}/sources/{source}/findings/{finding}/securityMarks'); - } - - return self::$projectSourceFindingSecurityMarksNameTemplate; - } - - private static function getProjectTableProfileNameTemplate() - { - if (self::$projectTableProfileNameTemplate == null) { - self::$projectTableProfileNameTemplate = new PathTemplate('projects/{project}/tableProfiles/{table_profile}'); - } - - return self::$projectTableProfileNameTemplate; - } - - private static function getSecurityHealthAnalyticsCustomModuleNameTemplate() - { - if (self::$securityHealthAnalyticsCustomModuleNameTemplate == null) { - self::$securityHealthAnalyticsCustomModuleNameTemplate = new PathTemplate('organizations/{organization}/securityHealthAnalyticsSettings/customModules/{custom_module}'); - } - - return self::$securityHealthAnalyticsCustomModuleNameTemplate; - } - - private static function getSecurityHealthAnalyticsSettingsNameTemplate() - { - if (self::$securityHealthAnalyticsSettingsNameTemplate == null) { - self::$securityHealthAnalyticsSettingsNameTemplate = new PathTemplate('organizations/{organization}/securityHealthAnalyticsSettings'); - } - - return self::$securityHealthAnalyticsSettingsNameTemplate; - } - - private static function getSecurityMarksNameTemplate() - { - if (self::$securityMarksNameTemplate == null) { - self::$securityMarksNameTemplate = new PathTemplate('organizations/{organization}/assets/{asset}/securityMarks'); - } - - return self::$securityMarksNameTemplate; - } - - private static function getSourceNameTemplate() - { - if (self::$sourceNameTemplate == null) { - self::$sourceNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}'); - } - - return self::$sourceNameTemplate; - } - - private static function getTableDataProfileNameTemplate() - { - if (self::$tableDataProfileNameTemplate == null) { - self::$tableDataProfileNameTemplate = new PathTemplate('projects/{project}/tableProfiles/{table_profile}'); - } - - return self::$tableDataProfileNameTemplate; - } - - private static function getTopicNameTemplate() - { - if (self::$topicNameTemplate == null) { - self::$topicNameTemplate = new PathTemplate('projects/{project}/topics/{topic}'); - } - - return self::$topicNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'bigQueryExport' => self::getBigQueryExportNameTemplate(), - 'dlpJob' => self::getDlpJobNameTemplate(), - 'effectiveSecurityHealthAnalyticsCustomModule' => self::getEffectiveSecurityHealthAnalyticsCustomModuleNameTemplate(), - 'externalSystem' => self::getExternalSystemNameTemplate(), - 'finding' => self::getFindingNameTemplate(), - 'folder' => self::getFolderNameTemplate(), - 'folderAssetSecurityMarks' => self::getFolderAssetSecurityMarksNameTemplate(), - 'folderConstraintName' => self::getFolderConstraintNameNameTemplate(), - 'folderCustomModule' => self::getFolderCustomModuleNameTemplate(), - 'folderEffectiveCustomModule' => self::getFolderEffectiveCustomModuleNameTemplate(), - 'folderExport' => self::getFolderExportNameTemplate(), - 'folderMuteConfig' => self::getFolderMuteConfigNameTemplate(), - 'folderNotificationConfig' => self::getFolderNotificationConfigNameTemplate(), - 'folderSecurityHealthAnalyticsSettings' => self::getFolderSecurityHealthAnalyticsSettingsNameTemplate(), - 'folderSource' => self::getFolderSourceNameTemplate(), - 'folderSourceFinding' => self::getFolderSourceFindingNameTemplate(), - 'folderSourceFindingExternalsystem' => self::getFolderSourceFindingExternalsystemNameTemplate(), - 'folderSourceFindingSecurityMarks' => self::getFolderSourceFindingSecurityMarksNameTemplate(), - 'muteConfig' => self::getMuteConfigNameTemplate(), - 'notificationConfig' => self::getNotificationConfigNameTemplate(), - 'organization' => self::getOrganizationNameTemplate(), - 'organizationAssetSecurityMarks' => self::getOrganizationAssetSecurityMarksNameTemplate(), - 'organizationConstraintName' => self::getOrganizationConstraintNameNameTemplate(), - 'organizationCustomModule' => self::getOrganizationCustomModuleNameTemplate(), - 'organizationEffectiveCustomModule' => self::getOrganizationEffectiveCustomModuleNameTemplate(), - 'organizationExport' => self::getOrganizationExportNameTemplate(), - 'organizationMuteConfig' => self::getOrganizationMuteConfigNameTemplate(), - 'organizationNotificationConfig' => self::getOrganizationNotificationConfigNameTemplate(), - 'organizationSecurityHealthAnalyticsSettings' => self::getOrganizationSecurityHealthAnalyticsSettingsNameTemplate(), - 'organizationSettings' => self::getOrganizationSettingsNameTemplate(), - 'organizationSource' => self::getOrganizationSourceNameTemplate(), - 'organizationSourceFinding' => self::getOrganizationSourceFindingNameTemplate(), - 'organizationSourceFindingExternalsystem' => self::getOrganizationSourceFindingExternalsystemNameTemplate(), - 'organizationSourceFindingSecurityMarks' => self::getOrganizationSourceFindingSecurityMarksNameTemplate(), - 'policy' => self::getPolicyNameTemplate(), - 'project' => self::getProjectNameTemplate(), - 'projectAssetSecurityMarks' => self::getProjectAssetSecurityMarksNameTemplate(), - 'projectConstraintName' => self::getProjectConstraintNameNameTemplate(), - 'projectCustomModule' => self::getProjectCustomModuleNameTemplate(), - 'projectDlpJob' => self::getProjectDlpJobNameTemplate(), - 'projectEffectiveCustomModule' => self::getProjectEffectiveCustomModuleNameTemplate(), - 'projectExport' => self::getProjectExportNameTemplate(), - 'projectLocationDlpJob' => self::getProjectLocationDlpJobNameTemplate(), - 'projectLocationTableProfile' => self::getProjectLocationTableProfileNameTemplate(), - 'projectMuteConfig' => self::getProjectMuteConfigNameTemplate(), - 'projectNotificationConfig' => self::getProjectNotificationConfigNameTemplate(), - 'projectSecurityHealthAnalyticsSettings' => self::getProjectSecurityHealthAnalyticsSettingsNameTemplate(), - 'projectSource' => self::getProjectSourceNameTemplate(), - 'projectSourceFinding' => self::getProjectSourceFindingNameTemplate(), - 'projectSourceFindingExternalsystem' => self::getProjectSourceFindingExternalsystemNameTemplate(), - 'projectSourceFindingSecurityMarks' => self::getProjectSourceFindingSecurityMarksNameTemplate(), - 'projectTableProfile' => self::getProjectTableProfileNameTemplate(), - 'securityHealthAnalyticsCustomModule' => self::getSecurityHealthAnalyticsCustomModuleNameTemplate(), - 'securityHealthAnalyticsSettings' => self::getSecurityHealthAnalyticsSettingsNameTemplate(), - 'securityMarks' => self::getSecurityMarksNameTemplate(), - 'source' => self::getSourceNameTemplate(), - 'tableDataProfile' => self::getTableDataProfileNameTemplate(), - 'topic' => self::getTopicNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a - * big_query_export resource. - * - * @param string $organization - * @param string $export - * - * @return string The formatted big_query_export resource. - */ - public static function bigQueryExportName($organization, $export) - { - return self::getBigQueryExportNameTemplate()->render([ - 'organization' => $organization, - 'export' => $export, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a dlp_job - * resource. - * - * @param string $project - * @param string $dlpJob - * - * @return string The formatted dlp_job resource. - */ - public static function dlpJobName($project, $dlpJob) - { - return self::getDlpJobNameTemplate()->render([ - 'project' => $project, - 'dlp_job' => $dlpJob, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * effective_security_health_analytics_custom_module resource. - * - * @param string $organization - * @param string $effectiveCustomModule - * - * @return string The formatted effective_security_health_analytics_custom_module resource. - */ - public static function effectiveSecurityHealthAnalyticsCustomModuleName($organization, $effectiveCustomModule) - { - return self::getEffectiveSecurityHealthAnalyticsCustomModuleNameTemplate()->render([ - 'organization' => $organization, - 'effective_custom_module' => $effectiveCustomModule, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * external_system resource. - * - * @param string $organization - * @param string $source - * @param string $finding - * @param string $externalsystem - * - * @return string The formatted external_system resource. - */ - public static function externalSystemName($organization, $source, $finding, $externalsystem) - { - return self::getExternalSystemNameTemplate()->render([ - 'organization' => $organization, - 'source' => $source, - 'finding' => $finding, - 'externalsystem' => $externalsystem, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a finding - * resource. - * - * @param string $organization - * @param string $source - * @param string $finding - * - * @return string The formatted finding resource. - */ - public static function findingName($organization, $source, $finding) - { - return self::getFindingNameTemplate()->render([ - 'organization' => $organization, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a folder - * resource. - * - * @param string $folder - * - * @return string The formatted folder resource. - */ - public static function folderName($folder) - { - return self::getFolderNameTemplate()->render([ - 'folder' => $folder, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_asset_securityMarks resource. - * - * @param string $folder - * @param string $asset - * - * @return string The formatted folder_asset_securityMarks resource. - */ - public static function folderAssetSecurityMarksName($folder, $asset) - { - return self::getFolderAssetSecurityMarksNameTemplate()->render([ - 'folder' => $folder, - 'asset' => $asset, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_constraint_name resource. - * - * @param string $folder - * @param string $constraintName - * - * @return string The formatted folder_constraint_name resource. - */ - public static function folderConstraintNameName($folder, $constraintName) - { - return self::getFolderConstraintNameNameTemplate()->render([ - 'folder' => $folder, - 'constraint_name' => $constraintName, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_custom_module resource. - * - * @param string $folder - * @param string $customModule - * - * @return string The formatted folder_custom_module resource. - */ - public static function folderCustomModuleName($folder, $customModule) - { - return self::getFolderCustomModuleNameTemplate()->render([ - 'folder' => $folder, - 'custom_module' => $customModule, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_effective_custom_module resource. - * - * @param string $folder - * @param string $effectiveCustomModule - * - * @return string The formatted folder_effective_custom_module resource. - */ - public static function folderEffectiveCustomModuleName($folder, $effectiveCustomModule) - { - return self::getFolderEffectiveCustomModuleNameTemplate()->render([ - 'folder' => $folder, - 'effective_custom_module' => $effectiveCustomModule, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_export resource. - * - * @param string $folder - * @param string $export - * - * @return string The formatted folder_export resource. - */ - public static function folderExportName($folder, $export) - { - return self::getFolderExportNameTemplate()->render([ - 'folder' => $folder, - 'export' => $export, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_mute_config resource. - * - * @param string $folder - * @param string $muteConfig - * - * @return string The formatted folder_mute_config resource. - */ - public static function folderMuteConfigName($folder, $muteConfig) - { - return self::getFolderMuteConfigNameTemplate()->render([ - 'folder' => $folder, - 'mute_config' => $muteConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_notification_config resource. - * - * @param string $folder - * @param string $notificationConfig - * - * @return string The formatted folder_notification_config resource. - */ - public static function folderNotificationConfigName($folder, $notificationConfig) - { - return self::getFolderNotificationConfigNameTemplate()->render([ - 'folder' => $folder, - 'notification_config' => $notificationConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_securityHealthAnalyticsSettings resource. - * - * @param string $folder - * - * @return string The formatted folder_securityHealthAnalyticsSettings resource. - */ - public static function folderSecurityHealthAnalyticsSettingsName($folder) - { - return self::getFolderSecurityHealthAnalyticsSettingsNameTemplate()->render([ - 'folder' => $folder, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_source resource. - * - * @param string $folder - * @param string $source - * - * @return string The formatted folder_source resource. - */ - public static function folderSourceName($folder, $source) - { - return self::getFolderSourceNameTemplate()->render([ - 'folder' => $folder, - 'source' => $source, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_source_finding resource. - * - * @param string $folder - * @param string $source - * @param string $finding - * - * @return string The formatted folder_source_finding resource. - */ - public static function folderSourceFindingName($folder, $source, $finding) - { - return self::getFolderSourceFindingNameTemplate()->render([ - 'folder' => $folder, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_source_finding_externalsystem resource. - * - * @param string $folder - * @param string $source - * @param string $finding - * @param string $externalsystem - * - * @return string The formatted folder_source_finding_externalsystem resource. - */ - public static function folderSourceFindingExternalsystemName($folder, $source, $finding, $externalsystem) - { - return self::getFolderSourceFindingExternalsystemNameTemplate()->render([ - 'folder' => $folder, - 'source' => $source, - 'finding' => $finding, - 'externalsystem' => $externalsystem, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_source_finding_securityMarks resource. - * - * @param string $folder - * @param string $source - * @param string $finding - * - * @return string The formatted folder_source_finding_securityMarks resource. - */ - public static function folderSourceFindingSecurityMarksName($folder, $source, $finding) - { - return self::getFolderSourceFindingSecurityMarksNameTemplate()->render([ - 'folder' => $folder, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a mute_config - * resource. - * - * @param string $organization - * @param string $muteConfig - * - * @return string The formatted mute_config resource. - */ - public static function muteConfigName($organization, $muteConfig) - { - return self::getMuteConfigNameTemplate()->render([ - 'organization' => $organization, - 'mute_config' => $muteConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * notification_config resource. - * - * @param string $organization - * @param string $notificationConfig - * - * @return string The formatted notification_config resource. - */ - public static function notificationConfigName($organization, $notificationConfig) - { - return self::getNotificationConfigNameTemplate()->render([ - 'organization' => $organization, - 'notification_config' => $notificationConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a organization - * resource. - * - * @param string $organization - * - * @return string The formatted organization resource. - */ - public static function organizationName($organization) - { - return self::getOrganizationNameTemplate()->render([ - 'organization' => $organization, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_asset_securityMarks resource. - * - * @param string $organization - * @param string $asset - * - * @return string The formatted organization_asset_securityMarks resource. - */ - public static function organizationAssetSecurityMarksName($organization, $asset) - { - return self::getOrganizationAssetSecurityMarksNameTemplate()->render([ - 'organization' => $organization, - 'asset' => $asset, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_constraint_name resource. - * - * @param string $organization - * @param string $constraintName - * - * @return string The formatted organization_constraint_name resource. - */ - public static function organizationConstraintNameName($organization, $constraintName) - { - return self::getOrganizationConstraintNameNameTemplate()->render([ - 'organization' => $organization, - 'constraint_name' => $constraintName, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_custom_module resource. - * - * @param string $organization - * @param string $customModule - * - * @return string The formatted organization_custom_module resource. - */ - public static function organizationCustomModuleName($organization, $customModule) - { - return self::getOrganizationCustomModuleNameTemplate()->render([ - 'organization' => $organization, - 'custom_module' => $customModule, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_effective_custom_module resource. - * - * @param string $organization - * @param string $effectiveCustomModule - * - * @return string The formatted organization_effective_custom_module resource. - */ - public static function organizationEffectiveCustomModuleName($organization, $effectiveCustomModule) - { - return self::getOrganizationEffectiveCustomModuleNameTemplate()->render([ - 'organization' => $organization, - 'effective_custom_module' => $effectiveCustomModule, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_export resource. - * - * @param string $organization - * @param string $export - * - * @return string The formatted organization_export resource. - */ - public static function organizationExportName($organization, $export) - { - return self::getOrganizationExportNameTemplate()->render([ - 'organization' => $organization, - 'export' => $export, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_mute_config resource. - * - * @param string $organization - * @param string $muteConfig - * - * @return string The formatted organization_mute_config resource. - */ - public static function organizationMuteConfigName($organization, $muteConfig) - { - return self::getOrganizationMuteConfigNameTemplate()->render([ - 'organization' => $organization, - 'mute_config' => $muteConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_notification_config resource. - * - * @param string $organization - * @param string $notificationConfig - * - * @return string The formatted organization_notification_config resource. - */ - public static function organizationNotificationConfigName($organization, $notificationConfig) - { - return self::getOrganizationNotificationConfigNameTemplate()->render([ - 'organization' => $organization, - 'notification_config' => $notificationConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_securityHealthAnalyticsSettings resource. - * - * @param string $organization - * - * @return string The formatted organization_securityHealthAnalyticsSettings resource. - */ - public static function organizationSecurityHealthAnalyticsSettingsName($organization) - { - return self::getOrganizationSecurityHealthAnalyticsSettingsNameTemplate()->render([ - 'organization' => $organization, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_settings resource. - * - * @param string $organization - * - * @return string The formatted organization_settings resource. - */ - public static function organizationSettingsName($organization) - { - return self::getOrganizationSettingsNameTemplate()->render([ - 'organization' => $organization, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_source resource. - * - * @param string $organization - * @param string $source - * - * @return string The formatted organization_source resource. - */ - public static function organizationSourceName($organization, $source) - { - return self::getOrganizationSourceNameTemplate()->render([ - 'organization' => $organization, - 'source' => $source, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_source_finding resource. - * - * @param string $organization - * @param string $source - * @param string $finding - * - * @return string The formatted organization_source_finding resource. - */ - public static function organizationSourceFindingName($organization, $source, $finding) - { - return self::getOrganizationSourceFindingNameTemplate()->render([ - 'organization' => $organization, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_source_finding_externalsystem resource. - * - * @param string $organization - * @param string $source - * @param string $finding - * @param string $externalsystem - * - * @return string The formatted organization_source_finding_externalsystem resource. - */ - public static function organizationSourceFindingExternalsystemName($organization, $source, $finding, $externalsystem) - { - return self::getOrganizationSourceFindingExternalsystemNameTemplate()->render([ - 'organization' => $organization, - 'source' => $source, - 'finding' => $finding, - 'externalsystem' => $externalsystem, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_source_finding_securityMarks resource. - * - * @param string $organization - * @param string $source - * @param string $finding - * - * @return string The formatted organization_source_finding_securityMarks resource. - */ - public static function organizationSourceFindingSecurityMarksName($organization, $source, $finding) - { - return self::getOrganizationSourceFindingSecurityMarksNameTemplate()->render([ - 'organization' => $organization, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a policy - * resource. - * - * @param string $organization - * @param string $constraintName - * - * @return string The formatted policy resource. - */ - public static function policyName($organization, $constraintName) - { - return self::getPolicyNameTemplate()->render([ - 'organization' => $organization, - 'constraint_name' => $constraintName, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a project - * resource. - * - * @param string $project - * - * @return string The formatted project resource. - */ - public static function projectName($project) - { - return self::getProjectNameTemplate()->render([ - 'project' => $project, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_asset_securityMarks resource. - * - * @param string $project - * @param string $asset - * - * @return string The formatted project_asset_securityMarks resource. - */ - public static function projectAssetSecurityMarksName($project, $asset) - { - return self::getProjectAssetSecurityMarksNameTemplate()->render([ - 'project' => $project, - 'asset' => $asset, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_constraint_name resource. - * - * @param string $project - * @param string $constraintName - * - * @return string The formatted project_constraint_name resource. - */ - public static function projectConstraintNameName($project, $constraintName) - { - return self::getProjectConstraintNameNameTemplate()->render([ - 'project' => $project, - 'constraint_name' => $constraintName, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_custom_module resource. - * - * @param string $project - * @param string $customModule - * - * @return string The formatted project_custom_module resource. - */ - public static function projectCustomModuleName($project, $customModule) - { - return self::getProjectCustomModuleNameTemplate()->render([ - 'project' => $project, - 'custom_module' => $customModule, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_dlp_job resource. - * - * @param string $project - * @param string $dlpJob - * - * @return string The formatted project_dlp_job resource. - */ - public static function projectDlpJobName($project, $dlpJob) - { - return self::getProjectDlpJobNameTemplate()->render([ - 'project' => $project, - 'dlp_job' => $dlpJob, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_effective_custom_module resource. - * - * @param string $project - * @param string $effectiveCustomModule - * - * @return string The formatted project_effective_custom_module resource. - */ - public static function projectEffectiveCustomModuleName($project, $effectiveCustomModule) - { - return self::getProjectEffectiveCustomModuleNameTemplate()->render([ - 'project' => $project, - 'effective_custom_module' => $effectiveCustomModule, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_export resource. - * - * @param string $project - * @param string $export - * - * @return string The formatted project_export resource. - */ - public static function projectExportName($project, $export) - { - return self::getProjectExportNameTemplate()->render([ - 'project' => $project, - 'export' => $export, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_dlp_job resource. - * - * @param string $project - * @param string $location - * @param string $dlpJob - * - * @return string The formatted project_location_dlp_job resource. - */ - public static function projectLocationDlpJobName($project, $location, $dlpJob) - { - return self::getProjectLocationDlpJobNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'dlp_job' => $dlpJob, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_table_profile resource. - * - * @param string $project - * @param string $location - * @param string $tableProfile - * - * @return string The formatted project_location_table_profile resource. - */ - public static function projectLocationTableProfileName($project, $location, $tableProfile) - { - return self::getProjectLocationTableProfileNameTemplate()->render([ - 'project' => $project, - 'location' => $location, - 'table_profile' => $tableProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_mute_config resource. - * - * @param string $project - * @param string $muteConfig - * - * @return string The formatted project_mute_config resource. - */ - public static function projectMuteConfigName($project, $muteConfig) - { - return self::getProjectMuteConfigNameTemplate()->render([ - 'project' => $project, - 'mute_config' => $muteConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_notification_config resource. - * - * @param string $project - * @param string $notificationConfig - * - * @return string The formatted project_notification_config resource. - */ - public static function projectNotificationConfigName($project, $notificationConfig) - { - return self::getProjectNotificationConfigNameTemplate()->render([ - 'project' => $project, - 'notification_config' => $notificationConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_securityHealthAnalyticsSettings resource. - * - * @param string $project - * - * @return string The formatted project_securityHealthAnalyticsSettings resource. - */ - public static function projectSecurityHealthAnalyticsSettingsName($project) - { - return self::getProjectSecurityHealthAnalyticsSettingsNameTemplate()->render([ - 'project' => $project, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_source resource. - * - * @param string $project - * @param string $source - * - * @return string The formatted project_source resource. - */ - public static function projectSourceName($project, $source) - { - return self::getProjectSourceNameTemplate()->render([ - 'project' => $project, - 'source' => $source, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_source_finding resource. - * - * @param string $project - * @param string $source - * @param string $finding - * - * @return string The formatted project_source_finding resource. - */ - public static function projectSourceFindingName($project, $source, $finding) - { - return self::getProjectSourceFindingNameTemplate()->render([ - 'project' => $project, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_source_finding_externalsystem resource. - * - * @param string $project - * @param string $source - * @param string $finding - * @param string $externalsystem - * - * @return string The formatted project_source_finding_externalsystem resource. - */ - public static function projectSourceFindingExternalsystemName($project, $source, $finding, $externalsystem) - { - return self::getProjectSourceFindingExternalsystemNameTemplate()->render([ - 'project' => $project, - 'source' => $source, - 'finding' => $finding, - 'externalsystem' => $externalsystem, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_source_finding_securityMarks resource. - * - * @param string $project - * @param string $source - * @param string $finding - * - * @return string The formatted project_source_finding_securityMarks resource. - */ - public static function projectSourceFindingSecurityMarksName($project, $source, $finding) - { - return self::getProjectSourceFindingSecurityMarksNameTemplate()->render([ - 'project' => $project, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_table_profile resource. - * - * @param string $project - * @param string $tableProfile - * - * @return string The formatted project_table_profile resource. - */ - public static function projectTableProfileName($project, $tableProfile) - { - return self::getProjectTableProfileNameTemplate()->render([ - 'project' => $project, - 'table_profile' => $tableProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * security_health_analytics_custom_module resource. - * - * @param string $organization - * @param string $customModule - * - * @return string The formatted security_health_analytics_custom_module resource. - */ - public static function securityHealthAnalyticsCustomModuleName($organization, $customModule) - { - return self::getSecurityHealthAnalyticsCustomModuleNameTemplate()->render([ - 'organization' => $organization, - 'custom_module' => $customModule, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * security_health_analytics_settings resource. - * - * @param string $organization - * - * @return string The formatted security_health_analytics_settings resource. - */ - public static function securityHealthAnalyticsSettingsName($organization) - { - return self::getSecurityHealthAnalyticsSettingsNameTemplate()->render([ - 'organization' => $organization, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * security_marks resource. - * - * @param string $organization - * @param string $asset - * - * @return string The formatted security_marks resource. - */ - public static function securityMarksName($organization, $asset) - { - return self::getSecurityMarksNameTemplate()->render([ - 'organization' => $organization, - 'asset' => $asset, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a source - * resource. - * - * @param string $organization - * @param string $source - * - * @return string The formatted source resource. - */ - public static function sourceName($organization, $source) - { - return self::getSourceNameTemplate()->render([ - 'organization' => $organization, - 'source' => $source, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * table_data_profile resource. - * - * @param string $project - * @param string $tableProfile - * - * @return string The formatted table_data_profile resource. - */ - public static function tableDataProfileName($project, $tableProfile) - { - return self::getTableDataProfileNameTemplate()->render([ - 'project' => $project, - 'table_profile' => $tableProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a topic - * resource. - * - * @param string $project - * @param string $topic - * - * @return string The formatted topic resource. - */ - public static function topicName($project, $topic) - { - return self::getTopicNameTemplate()->render([ - 'project' => $project, - 'topic' => $topic, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - bigQueryExport: organizations/{organization}/bigQueryExports/{export} - * - dlpJob: projects/{project}/dlpJobs/{dlp_job} - * - effectiveSecurityHealthAnalyticsCustomModule: organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module} - * - externalSystem: organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} - * - finding: organizations/{organization}/sources/{source}/findings/{finding} - * - folder: folders/{folder} - * - folderAssetSecurityMarks: folders/{folder}/assets/{asset}/securityMarks - * - folderConstraintName: folders/{folder}/policies/{constraint_name} - * - folderCustomModule: folders/{folder}/securityHealthAnalyticsSettings/customModules/{custom_module} - * - folderEffectiveCustomModule: folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module} - * - folderExport: folders/{folder}/bigQueryExports/{export} - * - folderMuteConfig: folders/{folder}/muteConfigs/{mute_config} - * - folderNotificationConfig: folders/{folder}/notificationConfigs/{notification_config} - * - folderSecurityHealthAnalyticsSettings: folders/{folder}/securityHealthAnalyticsSettings - * - folderSource: folders/{folder}/sources/{source} - * - folderSourceFinding: folders/{folder}/sources/{source}/findings/{finding} - * - folderSourceFindingExternalsystem: folders/{folder}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} - * - folderSourceFindingSecurityMarks: folders/{folder}/sources/{source}/findings/{finding}/securityMarks - * - muteConfig: organizations/{organization}/muteConfigs/{mute_config} - * - notificationConfig: organizations/{organization}/notificationConfigs/{notification_config} - * - organization: organizations/{organization} - * - organizationAssetSecurityMarks: organizations/{organization}/assets/{asset}/securityMarks - * - organizationConstraintName: organizations/{organization}/policies/{constraint_name} - * - organizationCustomModule: organizations/{organization}/securityHealthAnalyticsSettings/customModules/{custom_module} - * - organizationEffectiveCustomModule: organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module} - * - organizationExport: organizations/{organization}/bigQueryExports/{export} - * - organizationMuteConfig: organizations/{organization}/muteConfigs/{mute_config} - * - organizationNotificationConfig: organizations/{organization}/notificationConfigs/{notification_config} - * - organizationSecurityHealthAnalyticsSettings: organizations/{organization}/securityHealthAnalyticsSettings - * - organizationSettings: organizations/{organization}/organizationSettings - * - organizationSource: organizations/{organization}/sources/{source} - * - organizationSourceFinding: organizations/{organization}/sources/{source}/findings/{finding} - * - organizationSourceFindingExternalsystem: organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} - * - organizationSourceFindingSecurityMarks: organizations/{organization}/sources/{source}/findings/{finding}/securityMarks - * - policy: organizations/{organization}/policies/{constraint_name} - * - project: projects/{project} - * - projectAssetSecurityMarks: projects/{project}/assets/{asset}/securityMarks - * - projectConstraintName: projects/{project}/policies/{constraint_name} - * - projectCustomModule: projects/{project}/securityHealthAnalyticsSettings/customModules/{custom_module} - * - projectDlpJob: projects/{project}/dlpJobs/{dlp_job} - * - projectEffectiveCustomModule: projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module} - * - projectExport: projects/{project}/bigQueryExports/{export} - * - projectLocationDlpJob: projects/{project}/locations/{location}/dlpJobs/{dlp_job} - * - projectLocationTableProfile: projects/{project}/locations/{location}/tableProfiles/{table_profile} - * - projectMuteConfig: projects/{project}/muteConfigs/{mute_config} - * - projectNotificationConfig: projects/{project}/notificationConfigs/{notification_config} - * - projectSecurityHealthAnalyticsSettings: projects/{project}/securityHealthAnalyticsSettings - * - projectSource: projects/{project}/sources/{source} - * - projectSourceFinding: projects/{project}/sources/{source}/findings/{finding} - * - projectSourceFindingExternalsystem: projects/{project}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} - * - projectSourceFindingSecurityMarks: projects/{project}/sources/{source}/findings/{finding}/securityMarks - * - projectTableProfile: projects/{project}/tableProfiles/{table_profile} - * - securityHealthAnalyticsCustomModule: organizations/{organization}/securityHealthAnalyticsSettings/customModules/{custom_module} - * - securityHealthAnalyticsSettings: organizations/{organization}/securityHealthAnalyticsSettings - * - securityMarks: organizations/{organization}/assets/{asset}/securityMarks - * - source: organizations/{organization}/sources/{source} - * - tableDataProfile: projects/{project}/tableProfiles/{table_profile} - * - topic: projects/{project}/topics/{topic} - * - * The optional $template argument can be supplied to specify a particular pattern, - * and must match one of the templates listed above. If no $template argument is - * provided, or if the $template argument does not match one of the templates - * listed, then parseName will check each of the supported templates, and return - * the first match. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * Resume an existing long running operation that was previously started by a long - * running API method. If $methodName is not provided, or does not match a long - * running API method, then the operation can still be resumed, but the - * OperationResponse object will not deserialize the final response. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'securitycenter.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * Client method configuration, including retry settings. This option can be either - * a path to a JSON file, or a PHP array containing the decoded JSON data. By - * default this settings points to the default client config file, which is - * provided in the resources folder. - * @type string|TransportInterface $transport - * The transport used for executing network requests. May be either the string - * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. - * *Advanced usage*: Additionally, it is possible to pass in an already - * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * Configuration options that will be used to construct the transport. Options for - * each supported transport type should be passed in a key for that transport. For - * example: - * $transportConfig = [ - * 'grpc' => [...], - * 'rest' => [...], - * ]; - * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * A callable which returns the client cert as a string. This can be used to - * provide a certificate and private key to the transport layer for mTLS. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Kicks off an LRO to bulk mute findings for a parent based on a filter. The - * parent can be either an organization, folder or project. The findings - * matched by the filter will be muted after the LRO is done. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $parent = 'parent'; - * $operationResponse = $securityCenterClient->bulkMuteFindings($parent); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $securityCenterClient->bulkMuteFindings($parent); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $securityCenterClient->resumeOperation($operationName, 'bulkMuteFindings'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent, at which bulk action needs to be applied. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]". - * @param array $optionalArgs { - * Optional. - * - * @type string $filter - * Expression that identifies findings that should be updated. - * The expression is a list of zero or more restrictions combined - * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` - * has higher precedence than `AND`. - * - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * - * The supported operators are: - * - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * - * The supported value types are: - * - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * @type string $muteAnnotation - * This can be a mute configuration name or any identifier for mute/unmute - * of findings based on the filter. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - */ - public function bulkMuteFindings($parent, array $optionalArgs = []) - { - $request = new BulkMuteFindingsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['muteAnnotation'])) { - $request->setMuteAnnotation($optionalArgs['muteAnnotation']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('BulkMuteFindings', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Creates a BigQuery export. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); - * $bigQueryExport = new BigQueryExport(); - * $bigQueryExportId = 'big_query_export_id'; - * $response = $securityCenterClient->createBigQueryExport($formattedParent, $bigQueryExport, $bigQueryExportId); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. The name of the parent resource of the new BigQuery export. Its - * format is "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * @param BigQueryExport $bigQueryExport Required. The BigQuery export being created. - * @param string $bigQueryExportId Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\BigQueryExport - * - * @throws ApiException if the remote call fails - */ - public function createBigQueryExport($parent, $bigQueryExport, $bigQueryExportId, array $optionalArgs = []) - { - $request = new CreateBigQueryExportRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setBigQueryExport($bigQueryExport); - $request->setBigQueryExportId($bigQueryExportId); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateBigQueryExport', BigQueryExport::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a finding. The corresponding source must exist for finding creation - * to succeed. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - * $findingId = 'finding_id'; - * $finding = new Finding(); - * $response = $securityCenterClient->createFinding($formattedParent, $findingId, $finding); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Resource name of the new finding's parent. Its format should be - * "organizations/[organization_id]/sources/[source_id]". - * @param string $findingId Required. Unique identifier provided by the client within the parent scope. - * It must be alphanumeric and less than or equal to 32 characters and - * greater than 0 characters in length. - * @param Finding $finding Required. The Finding being created. The name and security_marks will be - * ignored as they are both output only fields on this resource. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\Finding - * - * @throws ApiException if the remote call fails - */ - public function createFinding($parent, $findingId, $finding, array $optionalArgs = []) - { - $request = new CreateFindingRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setFindingId($findingId); - $request->setFinding($finding); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateFinding', Finding::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a mute config. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); - * $muteConfig = new MuteConfig(); - * $muteConfigId = 'mute_config_id'; - * $response = $securityCenterClient->createMuteConfig($formattedParent, $muteConfig, $muteConfigId); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Resource name of the new mute configs's parent. Its format is - * "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * @param MuteConfig $muteConfig Required. The mute config being created. - * @param string $muteConfigId Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\MuteConfig - * - * @throws ApiException if the remote call fails - */ - public function createMuteConfig($parent, $muteConfig, $muteConfigId, array $optionalArgs = []) - { - $request = new CreateMuteConfigRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setMuteConfig($muteConfig); - $request->setMuteConfigId($muteConfigId); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateMuteConfig', MuteConfig::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a notification config. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); - * $configId = 'config_id'; - * $notificationConfig = new NotificationConfig(); - * $response = $securityCenterClient->createNotificationConfig($formattedParent, $configId, $notificationConfig); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Resource name of the new notification config's parent. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * @param string $configId Required. - * Unique identifier provided by the client within the parent scope. - * It must be between 1 and 128 characters and contain alphanumeric - * characters, underscores, or hyphens only. - * @param NotificationConfig $notificationConfig Required. The notification config being created. The name and the service - * account will be ignored as they are both output only fields on this - * resource. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\NotificationConfig - * - * @throws ApiException if the remote call fails - */ - public function createNotificationConfig($parent, $configId, $notificationConfig, array $optionalArgs = []) - { - $request = new CreateNotificationConfigRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setConfigId($configId); - $request->setNotificationConfig($notificationConfig); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateNotificationConfig', NotificationConfig::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a resident SecurityHealthAnalyticsCustomModule at the scope of the - * given CRM parent, and also creates inherited - * SecurityHealthAnalyticsCustomModules for all CRM descendants of the given - * parent. These modules are enabled by default. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - * $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); - * $response = $securityCenterClient->createSecurityHealthAnalyticsCustomModule($formattedParent, $securityHealthAnalyticsCustomModule); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Resource name of the new custom module's parent. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * @param SecurityHealthAnalyticsCustomModule $securityHealthAnalyticsCustomModule Required. SecurityHealthAnalytics custom module to create. The provided - * name is ignored and reset with provided parent information and - * server-generated ID. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule - * - * @throws ApiException if the remote call fails - */ - public function createSecurityHealthAnalyticsCustomModule($parent, $securityHealthAnalyticsCustomModule, array $optionalArgs = []) - { - $request = new CreateSecurityHealthAnalyticsCustomModuleRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateSecurityHealthAnalyticsCustomModule', SecurityHealthAnalyticsCustomModule::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a source. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->organizationName('[ORGANIZATION]'); - * $source = new Source(); - * $response = $securityCenterClient->createSource($formattedParent, $source); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Resource name of the new source's parent. Its format should be - * "organizations/[organization_id]". - * @param Source $source Required. The Source being created, only the display_name and description - * will be used. All other fields will be ignored. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\Source - * - * @throws ApiException if the remote call fails - */ - public function createSource($parent, $source, array $optionalArgs = []) - { - $request = new CreateSourceRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setSource($source); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateSource', Source::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes an existing BigQuery export. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedName = $securityCenterClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); - * $securityCenterClient->deleteBigQueryExport($formattedName); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $name Required. The name of the BigQuery export to delete. Its format is - * organizations/{organization}/bigQueryExports/{export_id}, - * folders/{folder}/bigQueryExports/{export_id}, or - * projects/{project}/bigQueryExports/{export_id} - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - */ - public function deleteBigQueryExport($name, array $optionalArgs = []) - { - $request = new DeleteBigQueryExportRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteBigQueryExport', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes an existing mute config. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedName = $securityCenterClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); - * $securityCenterClient->deleteMuteConfig($formattedName); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the mute config to delete. Its format is - * organizations/{organization}/muteConfigs/{config_id}, - * folders/{folder}/muteConfigs/{config_id}, or - * projects/{project}/muteConfigs/{config_id} - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - */ - public function deleteMuteConfig($name, array $optionalArgs = []) - { - $request = new DeleteMuteConfigRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteMuteConfig', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes a notification config. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedName = $securityCenterClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); - * $securityCenterClient->deleteNotificationConfig($formattedName); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the notification config to delete. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]", - * "folders/[folder_id]/notificationConfigs/[config_id]", - * or "projects/[project_id]/notificationConfigs/[config_id]". - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - */ - public function deleteNotificationConfig($name, array $optionalArgs = []) - { - $request = new DeleteNotificationConfigRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteNotificationConfig', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes the specified SecurityHealthAnalyticsCustomModule and all of its - * descendants in the CRM hierarchy. This method is only supported for - * resident custom modules. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedName = $securityCenterClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); - * $securityCenterClient->deleteSecurityHealthAnalyticsCustomModule($formattedName); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the custom module to delete. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", - * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - */ - public function deleteSecurityHealthAnalyticsCustomModule($name, array $optionalArgs = []) - { - $request = new DeleteSecurityHealthAnalyticsCustomModuleRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteSecurityHealthAnalyticsCustomModule', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets a BigQuery export. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedName = $securityCenterClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); - * $response = $securityCenterClient->getBigQueryExport($formattedName); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the BigQuery export to retrieve. Its format is - * organizations/{organization}/bigQueryExports/{export_id}, - * folders/{folder}/bigQueryExports/{export_id}, or - * projects/{project}/bigQueryExports/{export_id} - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\BigQueryExport - * - * @throws ApiException if the remote call fails - */ - public function getBigQueryExport($name, array $optionalArgs = []) - { - $request = new GetBigQueryExportRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetBigQueryExport', BigQueryExport::class, $optionalArgs, $request)->wait(); - } - - /** - * Retrieves an EffectiveSecurityHealthAnalyticsCustomModule. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedName = $securityCenterClient->effectiveSecurityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[EFFECTIVE_CUSTOM_MODULE]'); - * $response = $securityCenterClient->getEffectiveSecurityHealthAnalyticsCustomModule($formattedName); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the effective custom module to get. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * "folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{customModule}" - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\EffectiveSecurityHealthAnalyticsCustomModule - * - * @throws ApiException if the remote call fails - */ - public function getEffectiveSecurityHealthAnalyticsCustomModule($name, array $optionalArgs = []) - { - $request = new GetEffectiveSecurityHealthAnalyticsCustomModuleRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetEffectiveSecurityHealthAnalyticsCustomModule', EffectiveSecurityHealthAnalyticsCustomModule::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets the access control policy on the specified Source. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $resource = 'resource'; - * $response = $securityCenterClient->getIamPolicy($resource); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - * @param array $optionalArgs { - * Optional. - * - * @type GetPolicyOptions $options - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function getIamPolicy($resource, array $optionalArgs = []) - { - $request = new GetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['options'])) { - $request->setOptions($optionalArgs['options']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetIamPolicy', Policy::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets a mute config. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedName = $securityCenterClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); - * $response = $securityCenterClient->getMuteConfig($formattedName); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the mute config to retrieve. Its format is - * organizations/{organization}/muteConfigs/{config_id}, - * folders/{folder}/muteConfigs/{config_id}, or - * projects/{project}/muteConfigs/{config_id} - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\MuteConfig - * - * @throws ApiException if the remote call fails - */ - public function getMuteConfig($name, array $optionalArgs = []) - { - $request = new GetMuteConfigRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetMuteConfig', MuteConfig::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets a notification config. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedName = $securityCenterClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); - * $response = $securityCenterClient->getNotificationConfig($formattedName); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the notification config to get. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]", - * "folders/[folder_id]/notificationConfigs/[config_id]", - * or "projects/[project_id]/notificationConfigs/[config_id]". - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\NotificationConfig - * - * @throws ApiException if the remote call fails - */ - public function getNotificationConfig($name, array $optionalArgs = []) - { - $request = new GetNotificationConfigRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetNotificationConfig', NotificationConfig::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets the settings for an organization. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedName = $securityCenterClient->organizationSettingsName('[ORGANIZATION]'); - * $response = $securityCenterClient->getOrganizationSettings($formattedName); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the organization to get organization settings for. Its - * format is "organizations/[organization_id]/organizationSettings". - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\OrganizationSettings - * - * @throws ApiException if the remote call fails - */ - public function getOrganizationSettings($name, array $optionalArgs = []) - { - $request = new GetOrganizationSettingsRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetOrganizationSettings', OrganizationSettings::class, $optionalArgs, $request)->wait(); - } - - /** - * Retrieves a SecurityHealthAnalyticsCustomModule. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedName = $securityCenterClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); - * $response = $securityCenterClient->getSecurityHealthAnalyticsCustomModule($formattedName); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the custom module to get. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings/customModules/{customModule}", - * "folders/{folder}/securityHealthAnalyticsSettings/customModules/{customModule}", - * or - * "projects/{project}/securityHealthAnalyticsSettings/customModules/{customModule}" - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule - * - * @throws ApiException if the remote call fails - */ - public function getSecurityHealthAnalyticsCustomModule($name, array $optionalArgs = []) - { - $request = new GetSecurityHealthAnalyticsCustomModuleRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetSecurityHealthAnalyticsCustomModule', SecurityHealthAnalyticsCustomModule::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets a source. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedName = $securityCenterClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - * $response = $securityCenterClient->getSource($formattedName); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $name Required. Relative resource name of the source. Its format is - * "organizations/[organization_id]/source/[source_id]". - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\Source - * - * @throws ApiException if the remote call fails - */ - public function getSource($name, array $optionalArgs = []) - { - $request = new GetSourceRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetSource', Source::class, $optionalArgs, $request)->wait(); - } - - /** - * Filters an organization's assets and groups them by their specified - * properties. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); - * $groupBy = 'group_by'; - * // Iterate over pages of elements - * $pagedResponse = $securityCenterClient->groupAssets($formattedParent, $groupBy); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $securityCenterClient->groupAssets($formattedParent, $groupBy); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. The name of the parent to group the assets by. Its format is - * "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * @param string $groupBy Required. Expression that defines what assets fields to use for grouping. - * The string value should follow SQL syntax: comma separated list of fields. - * For example: - * "security_center_properties.resource_project,security_center_properties.project". - * - * The following fields are supported when compare_duration is not set: - * - * * security_center_properties.resource_project - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_type - * * security_center_properties.resource_parent - * * security_center_properties.resource_parent_display_name - * - * The following fields are supported when compare_duration is set: - * - * * security_center_properties.resource_type - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_parent_display_name - * @param array $optionalArgs { - * Optional. - * - * @type string $filter - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * - * The supported operators are: - * - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * - * The supported value types are: - * - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * The following field and operator combinations are supported: - * - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * - * For example, `resource_properties.size = 100` is a valid filter string. - * - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * @type Duration $compareDuration - * When compare_duration is set, the GroupResult's "state_change" property is - * updated to indicate whether the asset was added, removed, or remained - * present during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * - * The state change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * - * Possible "state_change" values when compare_duration is specified: - * - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at reference_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at reference_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and reference_time. - * - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * @type Timestamp $readTime - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - * - * @deprecated This method will be removed in the next major version update. - */ - public function groupAssets($parent, $groupBy, array $optionalArgs = []) - { - $request = new GroupAssetsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setGroupBy($groupBy); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['compareDuration'])) { - $request->setCompareDuration($optionalArgs['compareDuration']); - } - - if (isset($optionalArgs['readTime'])) { - $request->setReadTime($optionalArgs['readTime']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('GroupAssets', $optionalArgs, GroupAssetsResponse::class, $request); - } - - /** - * Filters an organization or source's findings and groups them by their - * specified properties. - * - * To group across all sources provide a `-` as the source id. - * Example: /v1/organizations/{organization_id}/sources/-/findings, - * /v1/folders/{folder_id}/sources/-/findings, - * /v1/projects/{project_id}/sources/-/findings - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - * $groupBy = 'group_by'; - * // Iterate over pages of elements - * $pagedResponse = $securityCenterClient->groupFindings($formattedParent, $groupBy); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $securityCenterClient->groupFindings($formattedParent, $groupBy); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Name of the source to groupBy. Its format is - * "organizations/[organization_id]/sources/[source_id]", - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]. To groupBy across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, - * or projects/{project_id}/sources/- - * @param string $groupBy Required. Expression that defines what assets fields to use for grouping - * (including `state_change`). The string value should follow SQL syntax: - * comma separated list of fields. For example: "parent,resource_name". - * - * The following fields are supported: - * - * * resource_name - * * category - * * state - * * parent - * * severity - * - * The following fields are supported when compare_duration is set: - * - * * state_change - * @param array $optionalArgs { - * Optional. - * - * @type string $filter - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * - * The supported operators are: - * - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * - * The supported value types are: - * - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * The following field and operator combinations are supported: - * - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * - * * severity: `=`, `:` - * * workflow_state: `=`, `:` - * * security_marks.marks: `=`, `:` - * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * - * For example, `source_properties.size = 100` is a valid filter string. - * - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * - * * resource: - * * resource.name: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.type: `=`, `:` - * @type Timestamp $readTime - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * @type Duration $compareDuration - * When compare_duration is set, the GroupResult's "state_change" attribute is - * updated to indicate whether the finding had its state changed, the - * finding's state remained unchanged, or if the finding was added during the - * compare_duration period of time that precedes the read_time. This is the - * time between (read_time - compare_duration) and read_time. - * - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * - * Possible "state_change" values when compare_duration is specified: - * - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present - * at read_time. - * - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function groupFindings($parent, $groupBy, array $optionalArgs = []) - { - $request = new GroupFindingsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setGroupBy($groupBy); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['readTime'])) { - $request->setReadTime($optionalArgs['readTime']); - } - - if (isset($optionalArgs['compareDuration'])) { - $request->setCompareDuration($optionalArgs['compareDuration']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('GroupFindings', $optionalArgs, GroupFindingsResponse::class, $request); - } - - /** - * Lists an organization's assets. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); - * // Iterate over pages of elements - * $pagedResponse = $securityCenterClient->listAssets($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $securityCenterClient->listAssets($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. The name of the parent resource that contains the assets. The - * value that you can specify on parent depends on the method in which you - * specify parent. You can specify one of the following values: - * "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * @param array $optionalArgs { - * Optional. - * - * @type string $filter - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * - * The supported operators are: - * - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * - * The supported value types are: - * - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * The following are the allowed field and operator combinations: - * - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * - * For example, `resource_properties.size = 100` is a valid filter string. - * - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * @type string $orderBy - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,resource_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,resource_properties.a_property" and " - * name desc , resource_properties.a_property " are equivalent. - * - * The following fields are supported: - * name - * update_time - * resource_properties - * security_marks.marks - * security_center_properties.resource_name - * security_center_properties.resource_display_name - * security_center_properties.resource_parent - * security_center_properties.resource_parent_display_name - * security_center_properties.resource_project - * security_center_properties.resource_project_display_name - * security_center_properties.resource_type - * @type Timestamp $readTime - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * @type Duration $compareDuration - * When compare_duration is set, the ListAssetsResult's "state_change" - * attribute is updated to indicate whether the asset was added, removed, or - * remained present during the compare_duration period of time that precedes - * the read_time. This is the time between (read_time - compare_duration) and - * read_time. - * - * The state_change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * - * Possible "state_change" values when compare_duration is specified: - * - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at read_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at read_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and read_time. - * - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * @type FieldMask $fieldMask - * A field mask to specify the ListAssetsResult fields to be listed in the - * response. - * An empty field mask will list all fields. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - * - * @deprecated This method will be removed in the next major version update. - */ - public function listAssets($parent, array $optionalArgs = []) - { - $request = new ListAssetsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - if (isset($optionalArgs['readTime'])) { - $request->setReadTime($optionalArgs['readTime']); - } - - if (isset($optionalArgs['compareDuration'])) { - $request->setCompareDuration($optionalArgs['compareDuration']); - } - - if (isset($optionalArgs['fieldMask'])) { - $request->setFieldMask($optionalArgs['fieldMask']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListAssets', $optionalArgs, ListAssetsResponse::class, $request); - } - - /** - * Lists BigQuery exports. Note that when requesting BigQuery exports at a - * given level all exports under that level are also returned e.g. if - * requesting BigQuery exports under a folder, then all BigQuery exports - * immediately under the folder plus the ones created under the projects - * within the folder are returned. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); - * // Iterate over pages of elements - * $pagedResponse = $securityCenterClient->listBigQueryExports($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $securityCenterClient->listBigQueryExports($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent, which owns the collection of BigQuery exports. Its - * format is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]". - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listBigQueryExports($parent, array $optionalArgs = []) - { - $request = new ListBigQueryExportsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListBigQueryExports', $optionalArgs, ListBigQueryExportsResponse::class, $request); - } - - /** - * Returns a list of all resident SecurityHealthAnalyticsCustomModules under - * the given CRM parent and all of the parent’s CRM descendants. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - * // Iterate over pages of elements - * $pagedResponse = $securityCenterClient->listDescendantSecurityHealthAnalyticsCustomModules($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $securityCenterClient->listDescendantSecurityHealthAnalyticsCustomModules($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Name of parent to list descendant custom modules. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listDescendantSecurityHealthAnalyticsCustomModules($parent, array $optionalArgs = []) - { - $request = new ListDescendantSecurityHealthAnalyticsCustomModulesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListDescendantSecurityHealthAnalyticsCustomModules', $optionalArgs, ListDescendantSecurityHealthAnalyticsCustomModulesResponse::class, $request); - } - - /** - * Returns a list of all EffectiveSecurityHealthAnalyticsCustomModules for the - * given parent. This includes resident modules defined at the scope of the - * parent, and inherited modules, inherited from CRM ancestors. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - * // Iterate over pages of elements - * $pagedResponse = $securityCenterClient->listEffectiveSecurityHealthAnalyticsCustomModules($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $securityCenterClient->listEffectiveSecurityHealthAnalyticsCustomModules($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Name of parent to list effective custom modules. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listEffectiveSecurityHealthAnalyticsCustomModules($parent, array $optionalArgs = []) - { - $request = new ListEffectiveSecurityHealthAnalyticsCustomModulesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListEffectiveSecurityHealthAnalyticsCustomModules', $optionalArgs, ListEffectiveSecurityHealthAnalyticsCustomModulesResponse::class, $request); - } - - /** - * Lists an organization or source's findings. - * - * To list across all sources provide a `-` as the source id. - * Example: /v1/organizations/{organization_id}/sources/-/findings - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - * // Iterate over pages of elements - * $pagedResponse = $securityCenterClient->listFindings($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $securityCenterClient->listFindings($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Name of the source the findings belong to. Its format is - * "organizations/[organization_id]/sources/[source_id], - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]". To list across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or - * projects/{projects_id}/sources/- - * @param array $optionalArgs { - * Optional. - * - * @type string $filter - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * - * The supported operators are: - * - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * - * The supported value types are: - * - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * The following field and operator combinations are supported: - * - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * - * * severity: `=`, `:` - * * workflow_state: `=`, `:` - * * security_marks.marks: `=`, `:` - * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * - * For example, `source_properties.size = 100` is a valid filter string. - * - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * - * * resource: - * * resource.name: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.type: `=`, `:` - * * resource.folders.resource_folder: `=`, `:` - * * resource.display_name: `=`, `:` - * @type string $orderBy - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,source_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,source_properties.a_property" and " - * name desc , source_properties.a_property " are equivalent. - * - * The following fields are supported: - * name - * parent - * state - * category - * resource_name - * event_time - * source_properties - * security_marks.marks - * @type Timestamp $readTime - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * @type Duration $compareDuration - * When compare_duration is set, the ListFindingsResult's "state_change" - * attribute is updated to indicate whether the finding had its state changed, - * the finding's state remained unchanged, or if the finding was added in any - * state during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * - * Possible "state_change" values when compare_duration is specified: - * - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present at - * read_time. - * @type FieldMask $fieldMask - * A field mask to specify the Finding fields to be listed in the response. - * An empty field mask will list all fields. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listFindings($parent, array $optionalArgs = []) - { - $request = new ListFindingsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - if (isset($optionalArgs['readTime'])) { - $request->setReadTime($optionalArgs['readTime']); - } - - if (isset($optionalArgs['compareDuration'])) { - $request->setCompareDuration($optionalArgs['compareDuration']); - } - - if (isset($optionalArgs['fieldMask'])) { - $request->setFieldMask($optionalArgs['fieldMask']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListFindings', $optionalArgs, ListFindingsResponse::class, $request); - } - - /** - * Lists mute configs. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); - * // Iterate over pages of elements - * $pagedResponse = $securityCenterClient->listMuteConfigs($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $securityCenterClient->listMuteConfigs($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. The parent, which owns the collection of mute configs. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]". - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listMuteConfigs($parent, array $optionalArgs = []) - { - $request = new ListMuteConfigsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListMuteConfigs', $optionalArgs, ListMuteConfigsResponse::class, $request); - } - - /** - * Lists notification configs. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); - * // Iterate over pages of elements - * $pagedResponse = $securityCenterClient->listNotificationConfigs($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $securityCenterClient->listNotificationConfigs($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. The name of the parent in which to list the notification - * configurations. Its format is "organizations/[organization_id]", - * "folders/[folder_id]", or "projects/[project_id]". - * @param array $optionalArgs { - * Optional. - * - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listNotificationConfigs($parent, array $optionalArgs = []) - { - $request = new ListNotificationConfigsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListNotificationConfigs', $optionalArgs, ListNotificationConfigsResponse::class, $request); - } - - /** - * Returns a list of all SecurityHealthAnalyticsCustomModules for the given - * parent. This includes resident modules defined at the scope of the parent, - * and inherited modules, inherited from CRM ancestors. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - * // Iterate over pages of elements - * $pagedResponse = $securityCenterClient->listSecurityHealthAnalyticsCustomModules($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $securityCenterClient->listSecurityHealthAnalyticsCustomModules($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Name of parent to list custom modules. Its format is - * "organizations/{organization}/securityHealthAnalyticsSettings", - * "folders/{folder}/securityHealthAnalyticsSettings", or - * "projects/{project}/securityHealthAnalyticsSettings" - * @param array $optionalArgs { - * Optional. - * - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listSecurityHealthAnalyticsCustomModules($parent, array $optionalArgs = []) - { - $request = new ListSecurityHealthAnalyticsCustomModulesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListSecurityHealthAnalyticsCustomModules', $optionalArgs, ListSecurityHealthAnalyticsCustomModulesResponse::class, $request); - } - - /** - * Lists all sources belonging to an organization. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); - * // Iterate over pages of elements - * $pagedResponse = $securityCenterClient->listSources($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $securityCenterClient->listSources($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Resource name of the parent of sources to list. Its format should - * be "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * @param array $optionalArgs { - * Optional. - * - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - */ - public function listSources($parent, array $optionalArgs = []) - { - $request = new ListSourcesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListSources', $optionalArgs, ListSourcesResponse::class, $request); - } - - /** - * Runs asset discovery. The discovery is tracked with a long-running - * operation. - * - * This API can only be called with limited frequency for an organization. If - * it is called too frequently the caller will receive a TOO_MANY_REQUESTS - * error. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->organizationName('[ORGANIZATION]'); - * $operationResponse = $securityCenterClient->runAssetDiscovery($formattedParent); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $securityCenterClient->runAssetDiscovery($formattedParent); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $securityCenterClient->resumeOperation($operationName, 'runAssetDiscovery'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Name of the organization to run asset discovery for. Its format - * is "organizations/[organization_id]". - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - * - * @deprecated This method will be removed in the next major version update. - */ - public function runAssetDiscovery($parent, array $optionalArgs = []) - { - $request = new RunAssetDiscoveryRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('RunAssetDiscovery', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Updates the state of a finding. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedName = $securityCenterClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - * $state = State::STATE_UNSPECIFIED; - * $startTime = new Timestamp(); - * $response = $securityCenterClient->setFindingState($formattedName, $state, $startTime); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $name Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", - * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". - * @param int $state Required. The desired State of the finding. - * For allowed values, use constants defined on {@see \Google\Cloud\SecurityCenter\V1\Finding\State} - * @param Timestamp $startTime Required. The time at which the updated state takes effect. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\Finding - * - * @throws ApiException if the remote call fails - */ - public function setFindingState($name, $state, $startTime, array $optionalArgs = []) - { - $request = new SetFindingStateRequest(); - $requestParamHeaders = []; - $request->setName($name); - $request->setState($state); - $request->setStartTime($startTime); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SetFindingState', Finding::class, $optionalArgs, $request)->wait(); - } - - /** - * Sets the access control policy on the specified Source. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $resource = 'resource'; - * $policy = new Policy(); - * $response = $securityCenterClient->setIamPolicy($resource, $policy); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - * @param Policy $policy REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * - * `paths: "bindings, etag"` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - */ - public function setIamPolicy($resource, $policy, array $optionalArgs = []) - { - $request = new SetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPolicy($policy); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SetIamPolicy', Policy::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates the mute state of a finding. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedName = $securityCenterClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - * $mute = Mute::MUTE_UNSPECIFIED; - * $response = $securityCenterClient->setMute($formattedName, $mute); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $name Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}", - * "projects/{project_id}/sources/{source_id}/findings/{finding_id}". - * @param int $mute Required. The desired state of the Mute. - * For allowed values, use constants defined on {@see \Google\Cloud\SecurityCenter\V1\Finding\Mute} - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\Finding - * - * @throws ApiException if the remote call fails - */ - public function setMute($name, $mute, array $optionalArgs = []) - { - $request = new SetMuteRequest(); - $requestParamHeaders = []; - $request->setName($name); - $request->setMute($mute); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SetMute', Finding::class, $optionalArgs, $request)->wait(); - } - - /** - * Simulates a given SecurityHealthAnalyticsCustomModule and Resource. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $parent = 'parent'; - * $customConfig = new CustomConfig(); - * $resource = new SimulatedResource(); - * $response = $securityCenterClient->simulateSecurityHealthAnalyticsCustomModule($parent, $customConfig, $resource); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. The relative resource name of the organization, project, or - * folder. For more information about relative resource names, see [Relative - * Resource - * Name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * Example: `organizations/{organization_id}` - * @param CustomConfig $customConfig Required. The custom configuration that you need to test. - * @param SimulatedResource $resource Required. Resource data to simulate custom module against. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleResponse - * - * @throws ApiException if the remote call fails - */ - public function simulateSecurityHealthAnalyticsCustomModule($parent, $customConfig, $resource, array $optionalArgs = []) - { - $request = new SimulateSecurityHealthAnalyticsCustomModuleRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setCustomConfig($customConfig); - $request->setResource($resource); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SimulateSecurityHealthAnalyticsCustomModule', SimulateSecurityHealthAnalyticsCustomModuleResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns the permissions that a caller has on the specified source. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $resource = 'resource'; - * $permissions = []; - * $response = $securityCenterClient->testIamPermissions($resource, $permissions); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy detail is being requested. - * See the operation documentation for the appropriate value for this field. - * @param string[] $permissions The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\TestIamPermissionsResponse - * - * @throws ApiException if the remote call fails - */ - public function testIamPermissions($resource, $permissions, array $optionalArgs = []) - { - $request = new TestIamPermissionsRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPermissions($permissions); - $requestParamHeaders['resource'] = $resource; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('TestIamPermissions', TestIamPermissionsResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates a BigQuery export. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $bigQueryExport = new BigQueryExport(); - * $response = $securityCenterClient->updateBigQueryExport($bigQueryExport); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param BigQueryExport $bigQueryExport Required. The BigQuery export being updated. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\BigQueryExport - * - * @throws ApiException if the remote call fails - */ - public function updateBigQueryExport($bigQueryExport, array $optionalArgs = []) - { - $request = new UpdateBigQueryExportRequest(); - $requestParamHeaders = []; - $request->setBigQueryExport($bigQueryExport); - $requestParamHeaders['big_query_export.name'] = $bigQueryExport->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateBigQueryExport', BigQueryExport::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates external system. This is for a given finding. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $externalSystem = new ExternalSystem(); - * $response = $securityCenterClient->updateExternalSystem($externalSystem); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param ExternalSystem $externalSystem Required. The external system resource to update. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The FieldMask to use when updating the external system resource. - * - * If empty all mutable fields will be updated. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\ExternalSystem - * - * @throws ApiException if the remote call fails - */ - public function updateExternalSystem($externalSystem, array $optionalArgs = []) - { - $request = new UpdateExternalSystemRequest(); - $requestParamHeaders = []; - $request->setExternalSystem($externalSystem); - $requestParamHeaders['external_system.name'] = $externalSystem->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateExternalSystem', ExternalSystem::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates or updates a finding. The corresponding source must exist for a - * finding creation to succeed. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $finding = new Finding(); - * $response = $securityCenterClient->updateFinding($finding); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param Finding $finding Required. The finding resource to update or create if it does not already - * exist. parent, security_marks, and update_time will be ignored. - * - * In the case of creation, the finding id portion of the name must be - * alphanumeric and less than or equal to 32 characters and greater than 0 - * characters in length. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The FieldMask to use when updating the finding resource. This field should - * not be specified when creating a finding. - * - * When updating a finding, an empty mask is treated as updating all mutable - * fields and replacing source_properties. Individual source_properties can - * be added/updated by using "source_properties." in the field - * mask. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\Finding - * - * @throws ApiException if the remote call fails - */ - public function updateFinding($finding, array $optionalArgs = []) - { - $request = new UpdateFindingRequest(); - $requestParamHeaders = []; - $request->setFinding($finding); - $requestParamHeaders['finding.name'] = $finding->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateFinding', Finding::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates a mute config. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $muteConfig = new MuteConfig(); - * $response = $securityCenterClient->updateMuteConfig($muteConfig); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param MuteConfig $muteConfig Required. The mute config being updated. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\MuteConfig - * - * @throws ApiException if the remote call fails - */ - public function updateMuteConfig($muteConfig, array $optionalArgs = []) - { - $request = new UpdateMuteConfigRequest(); - $requestParamHeaders = []; - $request->setMuteConfig($muteConfig); - $requestParamHeaders['mute_config.name'] = $muteConfig->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateMuteConfig', MuteConfig::class, $optionalArgs, $request)->wait(); - } - - /** - * - * Updates a notification config. The following update - * fields are allowed: description, pubsub_topic, streaming_config.filter - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $notificationConfig = new NotificationConfig(); - * $response = $securityCenterClient->updateNotificationConfig($notificationConfig); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param NotificationConfig $notificationConfig Required. The notification config to update. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The FieldMask to use when updating the notification config. - * - * If empty all mutable fields will be updated. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\NotificationConfig - * - * @throws ApiException if the remote call fails - */ - public function updateNotificationConfig($notificationConfig, array $optionalArgs = []) - { - $request = new UpdateNotificationConfigRequest(); - $requestParamHeaders = []; - $request->setNotificationConfig($notificationConfig); - $requestParamHeaders['notification_config.name'] = $notificationConfig->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateNotificationConfig', NotificationConfig::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates an organization's settings. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $organizationSettings = new OrganizationSettings(); - * $response = $securityCenterClient->updateOrganizationSettings($organizationSettings); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param OrganizationSettings $organizationSettings Required. The organization settings resource to update. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The FieldMask to use when updating the settings resource. - * - * If empty all mutable fields will be updated. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\OrganizationSettings - * - * @throws ApiException if the remote call fails - */ - public function updateOrganizationSettings($organizationSettings, array $optionalArgs = []) - { - $request = new UpdateOrganizationSettingsRequest(); - $requestParamHeaders = []; - $request->setOrganizationSettings($organizationSettings); - $requestParamHeaders['organization_settings.name'] = $organizationSettings->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateOrganizationSettings', OrganizationSettings::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates the SecurityHealthAnalyticsCustomModule under the given name based - * on the given update mask. Updating the enablement state is supported on - * both resident and inherited modules (though resident modules cannot have an - * enablement state of "inherited"). Updating the display name and custom - * config of a module is supported on resident modules only. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); - * $response = $securityCenterClient->updateSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param SecurityHealthAnalyticsCustomModule $securityHealthAnalyticsCustomModule Required. The SecurityHealthAnalytics custom module to update. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The list of fields to update. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule - * - * @throws ApiException if the remote call fails - */ - public function updateSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule, array $optionalArgs = []) - { - $request = new UpdateSecurityHealthAnalyticsCustomModuleRequest(); - $requestParamHeaders = []; - $request->setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); - $requestParamHeaders['security_health_analytics_custom_module.name'] = $securityHealthAnalyticsCustomModule->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateSecurityHealthAnalyticsCustomModule', SecurityHealthAnalyticsCustomModule::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates security marks. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $securityMarks = new SecurityMarks(); - * $response = $securityCenterClient->updateSecurityMarks($securityMarks); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param SecurityMarks $securityMarks Required. The security marks resource to update. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The FieldMask to use when updating the security marks resource. - * - * The field mask must not contain duplicate fields. - * If empty or set to "marks", all marks will be replaced. Individual - * marks can be updated using "marks.". - * @type Timestamp $startTime - * The time at which the updated SecurityMarks take effect. - * If not set uses current server time. Updates will be applied to the - * SecurityMarks that are active immediately preceding this time. Must be - * earlier or equal to the server time. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\SecurityMarks - * - * @throws ApiException if the remote call fails - */ - public function updateSecurityMarks($securityMarks, array $optionalArgs = []) - { - $request = new UpdateSecurityMarksRequest(); - $requestParamHeaders = []; - $request->setSecurityMarks($securityMarks); - $requestParamHeaders['security_marks.name'] = $securityMarks->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - if (isset($optionalArgs['startTime'])) { - $request->setStartTime($optionalArgs['startTime']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateSecurityMarks', SecurityMarks::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates a source. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $source = new Source(); - * $response = $securityCenterClient->updateSource($source); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param Source $source Required. The source resource to update. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The FieldMask to use when updating the source resource. - * - * If empty all mutable fields will be updated. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1\Source - * - * @throws ApiException if the remote call fails - */ - public function updateSource($source, array $optionalArgs = []) - { - $request = new UpdateSourceRequest(); - $requestParamHeaders = []; - $request->setSource($source); - $requestParamHeaders['source.name'] = $source->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateSource', Source::class, $optionalArgs, $request)->wait(); - } -} diff --git a/owl-bot-staging/SecurityCenter/v1/src/V1/SecurityCenterClient.php b/owl-bot-staging/SecurityCenter/v1/src/V1/SecurityCenterClient.php deleted file mode 100644 index 983e341e88d3..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/src/V1/SecurityCenterClient.php +++ /dev/null @@ -1,34 +0,0 @@ - [ - 'google.cloud.securitycenter.v1.SecurityCenter' => [ - 'BulkMuteFindings' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\SecurityCenter\V1\BulkMuteFindingsResponse', - 'metadataReturnType' => '\Google\Protobuf\GPBEmpty', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'RunAssetDiscovery' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\SecurityCenter\V1\RunAssetDiscoveryResponse', - 'metadataReturnType' => '\Google\Protobuf\GPBEmpty', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateBigQueryExport' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\BigQueryExport', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateFinding' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\Finding', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateMuteConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\MuteConfig', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateNotificationConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\NotificationConfig', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateSecurityHealthAnalyticsCustomModule' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateSource' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\Source', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteBigQueryExport' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteMuteConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteNotificationConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteSecurityHealthAnalyticsCustomModule' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetBigQueryExport' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\BigQueryExport', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetEffectiveSecurityHealthAnalyticsCustomModule' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\EffectiveSecurityHealthAnalyticsCustomModule', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - ], - 'GetMuteConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\MuteConfig', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetNotificationConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\NotificationConfig', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetOrganizationSettings' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\OrganizationSettings', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetSecurityHealthAnalyticsCustomModule' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetSource' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\Source', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GroupAssets' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getGroupByResults', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\GroupAssetsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'GroupFindings' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getGroupByResults', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\GroupFindingsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListAssets' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getListAssetsResults', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\ListAssetsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListBigQueryExports' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getBigQueryExports', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\ListBigQueryExportsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListDescendantSecurityHealthAnalyticsCustomModules' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getSecurityHealthAnalyticsCustomModules', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\ListDescendantSecurityHealthAnalyticsCustomModulesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListEffectiveSecurityHealthAnalyticsCustomModules' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getEffectiveSecurityHealthAnalyticsCustomModules', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\ListEffectiveSecurityHealthAnalyticsCustomModulesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListFindings' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getListFindingsResults', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\ListFindingsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListMuteConfigs' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getMuteConfigs', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\ListMuteConfigsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListNotificationConfigs' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getNotificationConfigs', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\ListNotificationConfigsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListSecurityHealthAnalyticsCustomModules' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getSecurityHealthAnalyticsCustomModules', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\ListSecurityHealthAnalyticsCustomModulesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListSources' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getSources', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\ListSourcesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'SetFindingState' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\Finding', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - ], - 'SetMute' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\Finding', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'SimulateSecurityHealthAnalyticsCustomModule' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\SimulateSecurityHealthAnalyticsCustomModuleResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - ], - 'UpdateBigQueryExport' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\BigQueryExport', - 'headerParams' => [ - [ - 'keyName' => 'big_query_export.name', - 'fieldAccessors' => [ - 'getBigQueryExport', - 'getName', - ], - ], - ], - ], - 'UpdateExternalSystem' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\ExternalSystem', - 'headerParams' => [ - [ - 'keyName' => 'external_system.name', - 'fieldAccessors' => [ - 'getExternalSystem', - 'getName', - ], - ], - ], - ], - 'UpdateFinding' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\Finding', - 'headerParams' => [ - [ - 'keyName' => 'finding.name', - 'fieldAccessors' => [ - 'getFinding', - 'getName', - ], - ], - ], - ], - 'UpdateMuteConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\MuteConfig', - 'headerParams' => [ - [ - 'keyName' => 'mute_config.name', - 'fieldAccessors' => [ - 'getMuteConfig', - 'getName', - ], - ], - ], - ], - 'UpdateNotificationConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\NotificationConfig', - 'headerParams' => [ - [ - 'keyName' => 'notification_config.name', - 'fieldAccessors' => [ - 'getNotificationConfig', - 'getName', - ], - ], - ], - ], - 'UpdateOrganizationSettings' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\OrganizationSettings', - 'headerParams' => [ - [ - 'keyName' => 'organization_settings.name', - 'fieldAccessors' => [ - 'getOrganizationSettings', - 'getName', - ], - ], - ], - ], - 'UpdateSecurityHealthAnalyticsCustomModule' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\SecurityHealthAnalyticsCustomModule', - 'headerParams' => [ - [ - 'keyName' => 'security_health_analytics_custom_module.name', - 'fieldAccessors' => [ - 'getSecurityHealthAnalyticsCustomModule', - 'getName', - ], - ], - ], - ], - 'UpdateSecurityMarks' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\SecurityMarks', - 'headerParams' => [ - [ - 'keyName' => 'security_marks.name', - 'fieldAccessors' => [ - 'getSecurityMarks', - 'getName', - ], - ], - ], - ], - 'UpdateSource' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V1\Source', - 'headerParams' => [ - [ - 'keyName' => 'source.name', - 'fieldAccessors' => [ - 'getSource', - 'getName', - ], - ], - ], - ], - 'templateMap' => [ - 'bigQueryExport' => 'organizations/{organization}/bigQueryExports/{export}', - 'dlpJob' => 'projects/{project}/dlpJobs/{dlp_job}', - 'effectiveSecurityHealthAnalyticsCustomModule' => 'organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module}', - 'externalSystem' => 'organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}', - 'finding' => 'organizations/{organization}/sources/{source}/findings/{finding}', - 'folder' => 'folders/{folder}', - 'folderAssetSecurityMarks' => 'folders/{folder}/assets/{asset}/securityMarks', - 'folderConstraintName' => 'folders/{folder}/policies/{constraint_name}', - 'folderCustomModule' => 'folders/{folder}/securityHealthAnalyticsSettings/customModules/{custom_module}', - 'folderEffectiveCustomModule' => 'folders/{folder}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module}', - 'folderExport' => 'folders/{folder}/bigQueryExports/{export}', - 'folderMuteConfig' => 'folders/{folder}/muteConfigs/{mute_config}', - 'folderNotificationConfig' => 'folders/{folder}/notificationConfigs/{notification_config}', - 'folderSecurityHealthAnalyticsSettings' => 'folders/{folder}/securityHealthAnalyticsSettings', - 'folderSource' => 'folders/{folder}/sources/{source}', - 'folderSourceFinding' => 'folders/{folder}/sources/{source}/findings/{finding}', - 'folderSourceFindingExternalsystem' => 'folders/{folder}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}', - 'folderSourceFindingSecurityMarks' => 'folders/{folder}/sources/{source}/findings/{finding}/securityMarks', - 'muteConfig' => 'organizations/{organization}/muteConfigs/{mute_config}', - 'notificationConfig' => 'organizations/{organization}/notificationConfigs/{notification_config}', - 'organization' => 'organizations/{organization}', - 'organizationAssetSecurityMarks' => 'organizations/{organization}/assets/{asset}/securityMarks', - 'organizationConstraintName' => 'organizations/{organization}/policies/{constraint_name}', - 'organizationCustomModule' => 'organizations/{organization}/securityHealthAnalyticsSettings/customModules/{custom_module}', - 'organizationEffectiveCustomModule' => 'organizations/{organization}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module}', - 'organizationExport' => 'organizations/{organization}/bigQueryExports/{export}', - 'organizationMuteConfig' => 'organizations/{organization}/muteConfigs/{mute_config}', - 'organizationNotificationConfig' => 'organizations/{organization}/notificationConfigs/{notification_config}', - 'organizationSecurityHealthAnalyticsSettings' => 'organizations/{organization}/securityHealthAnalyticsSettings', - 'organizationSettings' => 'organizations/{organization}/organizationSettings', - 'organizationSource' => 'organizations/{organization}/sources/{source}', - 'organizationSourceFinding' => 'organizations/{organization}/sources/{source}/findings/{finding}', - 'organizationSourceFindingExternalsystem' => 'organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}', - 'organizationSourceFindingSecurityMarks' => 'organizations/{organization}/sources/{source}/findings/{finding}/securityMarks', - 'policy' => 'organizations/{organization}/policies/{constraint_name}', - 'project' => 'projects/{project}', - 'projectAssetSecurityMarks' => 'projects/{project}/assets/{asset}/securityMarks', - 'projectConstraintName' => 'projects/{project}/policies/{constraint_name}', - 'projectCustomModule' => 'projects/{project}/securityHealthAnalyticsSettings/customModules/{custom_module}', - 'projectDlpJob' => 'projects/{project}/dlpJobs/{dlp_job}', - 'projectEffectiveCustomModule' => 'projects/{project}/securityHealthAnalyticsSettings/effectiveCustomModules/{effective_custom_module}', - 'projectExport' => 'projects/{project}/bigQueryExports/{export}', - 'projectLocationDlpJob' => 'projects/{project}/locations/{location}/dlpJobs/{dlp_job}', - 'projectLocationTableProfile' => 'projects/{project}/locations/{location}/tableProfiles/{table_profile}', - 'projectMuteConfig' => 'projects/{project}/muteConfigs/{mute_config}', - 'projectNotificationConfig' => 'projects/{project}/notificationConfigs/{notification_config}', - 'projectSecurityHealthAnalyticsSettings' => 'projects/{project}/securityHealthAnalyticsSettings', - 'projectSource' => 'projects/{project}/sources/{source}', - 'projectSourceFinding' => 'projects/{project}/sources/{source}/findings/{finding}', - 'projectSourceFindingExternalsystem' => 'projects/{project}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}', - 'projectSourceFindingSecurityMarks' => 'projects/{project}/sources/{source}/findings/{finding}/securityMarks', - 'projectTableProfile' => 'projects/{project}/tableProfiles/{table_profile}', - 'securityHealthAnalyticsCustomModule' => 'organizations/{organization}/securityHealthAnalyticsSettings/customModules/{custom_module}', - 'securityHealthAnalyticsSettings' => 'organizations/{organization}/securityHealthAnalyticsSettings', - 'securityMarks' => 'organizations/{organization}/assets/{asset}/securityMarks', - 'source' => 'organizations/{organization}/sources/{source}', - 'tableDataProfile' => 'projects/{project}/tableProfiles/{table_profile}', - 'topic' => 'projects/{project}/topics/{topic}', - ], - ], - ], -]; diff --git a/owl-bot-staging/SecurityCenter/v1/src/V1/resources/security_center_rest_client_config.php b/owl-bot-staging/SecurityCenter/v1/src/V1/resources/security_center_rest_client_config.php deleted file mode 100644 index 4968eb9f6970..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/src/V1/resources/security_center_rest_client_config.php +++ /dev/null @@ -1,1033 +0,0 @@ - [ - 'google.cloud.securitycenter.v1.SecurityCenter' => [ - 'BulkMuteFindings' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=organizations/*}/findings:bulkMute', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=folders/*}/findings:bulkMute', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*}/findings:bulkMute', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreateBigQueryExport' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=organizations/*}/bigQueryExports', - 'body' => 'big_query_export', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=folders/*}/bigQueryExports', - 'body' => 'big_query_export', - 'queryParams' => [ - 'big_query_export_id', - ], - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*}/bigQueryExports', - 'body' => 'big_query_export', - 'queryParams' => [ - 'big_query_export_id', - ], - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'big_query_export_id', - ], - ], - 'CreateFinding' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=organizations/*/sources/*}/findings', - 'body' => 'finding', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'finding_id', - ], - ], - 'CreateMuteConfig' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=organizations/*}/muteConfigs', - 'body' => 'mute_config', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=folders/*}/muteConfigs', - 'body' => 'mute_config', - 'queryParams' => [ - 'mute_config_id', - ], - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*}/muteConfigs', - 'body' => 'mute_config', - 'queryParams' => [ - 'mute_config_id', - ], - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'mute_config_id', - ], - ], - 'CreateNotificationConfig' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=organizations/*}/notificationConfigs', - 'body' => 'notification_config', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=folders/*}/notificationConfigs', - 'body' => 'notification_config', - 'queryParams' => [ - 'config_id', - ], - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*}/notificationConfigs', - 'body' => 'notification_config', - 'queryParams' => [ - 'config_id', - ], - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'config_id', - ], - ], - 'CreateSecurityHealthAnalyticsCustomModule' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/customModules', - 'body' => 'security_health_analytics_custom_module', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=folders/*/securityHealthAnalyticsSettings}/customModules', - 'body' => 'security_health_analytics_custom_module', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/securityHealthAnalyticsSettings}/customModules', - 'body' => 'security_health_analytics_custom_module', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreateSource' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=organizations/*}/sources', - 'body' => 'source', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteBigQueryExport' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=organizations/*/bigQueryExports/*}', - 'additionalBindings' => [ - [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=folders/*/bigQueryExports/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/bigQueryExports/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteMuteConfig' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=organizations/*/muteConfigs/*}', - 'additionalBindings' => [ - [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=folders/*/muteConfigs/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/muteConfigs/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteNotificationConfig' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=organizations/*/notificationConfigs/*}', - 'additionalBindings' => [ - [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=folders/*/notificationConfigs/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/notificationConfigs/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteSecurityHealthAnalyticsCustomModule' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=organizations/*/securityHealthAnalyticsSettings/customModules/*}', - 'additionalBindings' => [ - [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=folders/*/securityHealthAnalyticsSettings/customModules/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/securityHealthAnalyticsSettings/customModules/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetBigQueryExport' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=organizations/*/bigQueryExports/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=folders/*/bigQueryExports/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/bigQueryExports/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetEffectiveSecurityHealthAnalyticsCustomModule' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=organizations/*/securityHealthAnalyticsSettings/effectiveCustomModules/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=folders/*/securityHealthAnalyticsSettings/effectiveCustomModules/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/securityHealthAnalyticsSettings/effectiveCustomModules/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=organizations/*/sources/*}:getIamPolicy', - 'body' => '*', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'GetMuteConfig' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=organizations/*/muteConfigs/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=folders/*/muteConfigs/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/muteConfigs/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetNotificationConfig' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=organizations/*/notificationConfigs/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=folders/*/notificationConfigs/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/notificationConfigs/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOrganizationSettings' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=organizations/*/organizationSettings}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetSecurityHealthAnalyticsCustomModule' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=organizations/*/securityHealthAnalyticsSettings/customModules/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=folders/*/securityHealthAnalyticsSettings/customModules/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/securityHealthAnalyticsSettings/customModules/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetSource' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=organizations/*/sources/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GroupAssets' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=organizations/*}/assets:group', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=folders/*}/assets:group', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*}/assets:group', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'GroupFindings' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=organizations/*/sources/*}/findings:group', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=folders/*/sources/*}/findings:group', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/sources/*}/findings:group', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListAssets' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=organizations/*}/assets', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=folders/*}/assets', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*}/assets', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListBigQueryExports' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=organizations/*}/bigQueryExports', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=folders/*}/bigQueryExports', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*}/bigQueryExports', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListDescendantSecurityHealthAnalyticsCustomModules' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/customModules:listDescendant', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=folders/*/securityHealthAnalyticsSettings}/customModules:listDescendant', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/securityHealthAnalyticsSettings}/customModules:listDescendant', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListEffectiveSecurityHealthAnalyticsCustomModules' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/effectiveCustomModules', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=folders/*/securityHealthAnalyticsSettings}/effectiveCustomModules', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/securityHealthAnalyticsSettings}/effectiveCustomModules', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListFindings' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=organizations/*/sources/*}/findings', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=folders/*/sources/*}/findings', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/sources/*}/findings', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListMuteConfigs' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=organizations/*}/muteConfigs', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=folders/*}/muteConfigs', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*}/muteConfigs', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListNotificationConfigs' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=organizations/*}/notificationConfigs', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=folders/*}/notificationConfigs', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*}/notificationConfigs', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListSecurityHealthAnalyticsCustomModules' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/customModules', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=folders/*/securityHealthAnalyticsSettings}/customModules', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/securityHealthAnalyticsSettings}/customModules', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListSources' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=organizations/*}/sources', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=folders/*}/sources', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*}/sources', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'RunAssetDiscovery' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=organizations/*}/assets:runDiscovery', - 'body' => '*', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'SetFindingState' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=organizations/*/sources/*/findings/*}:setState', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=folders/*/sources/*/findings/*}:setState', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/sources/*/findings/*}:setState', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=organizations/*/sources/*}:setIamPolicy', - 'body' => '*', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'SetMute' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=organizations/*/sources/*/findings/*}:setMute', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=folders/*/sources/*/findings/*}:setMute', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/sources/*/findings/*}:setMute', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'SimulateSecurityHealthAnalyticsCustomModule' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=organizations/*/securityHealthAnalyticsSettings}/customModules:simulate', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=folders/*/securityHealthAnalyticsSettings}/customModules:simulate', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/securityHealthAnalyticsSettings}/customModules:simulate', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=organizations/*/sources/*}:testIamPermissions', - 'body' => '*', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'UpdateBigQueryExport' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{big_query_export.name=organizations/*/bigQueryExports/*}', - 'body' => 'big_query_export', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{big_query_export.name=folders/*/bigQueryExports/*}', - 'body' => 'big_query_export', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{big_query_export.name=projects/*/bigQueryExports/*}', - 'body' => 'big_query_export', - ], - ], - 'placeholders' => [ - 'big_query_export.name' => [ - 'getters' => [ - 'getBigQueryExport', - 'getName', - ], - ], - ], - ], - 'UpdateExternalSystem' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{external_system.name=organizations/*/sources/*/findings/*/externalSystems/*}', - 'body' => 'external_system', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{external_system.name=folders/*/sources/*/findings/*/externalSystems/*}', - 'body' => 'external_system', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{external_system.name=projects/*/sources/*/findings/*/externalSystems/*}', - 'body' => 'external_system', - ], - ], - 'placeholders' => [ - 'external_system.name' => [ - 'getters' => [ - 'getExternalSystem', - 'getName', - ], - ], - ], - ], - 'UpdateFinding' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{finding.name=organizations/*/sources/*/findings/*}', - 'body' => 'finding', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{finding.name=folders/*/sources/*/findings/*}', - 'body' => 'finding', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{finding.name=projects/*/sources/*/findings/*}', - 'body' => 'finding', - ], - ], - 'placeholders' => [ - 'finding.name' => [ - 'getters' => [ - 'getFinding', - 'getName', - ], - ], - ], - ], - 'UpdateMuteConfig' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{mute_config.name=organizations/*/muteConfigs/*}', - 'body' => 'mute_config', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{mute_config.name=folders/*/muteConfigs/*}', - 'body' => 'mute_config', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{mute_config.name=projects/*/muteConfigs/*}', - 'body' => 'mute_config', - ], - ], - 'placeholders' => [ - 'mute_config.name' => [ - 'getters' => [ - 'getMuteConfig', - 'getName', - ], - ], - ], - ], - 'UpdateNotificationConfig' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{notification_config.name=organizations/*/notificationConfigs/*}', - 'body' => 'notification_config', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{notification_config.name=folders/*/notificationConfigs/*}', - 'body' => 'notification_config', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{notification_config.name=projects/*/notificationConfigs/*}', - 'body' => 'notification_config', - ], - ], - 'placeholders' => [ - 'notification_config.name' => [ - 'getters' => [ - 'getNotificationConfig', - 'getName', - ], - ], - ], - ], - 'UpdateOrganizationSettings' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{organization_settings.name=organizations/*/organizationSettings}', - 'body' => 'organization_settings', - 'placeholders' => [ - 'organization_settings.name' => [ - 'getters' => [ - 'getOrganizationSettings', - 'getName', - ], - ], - ], - ], - 'UpdateSecurityHealthAnalyticsCustomModule' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{security_health_analytics_custom_module.name=organizations/*/securityHealthAnalyticsSettings/customModules/*}', - 'body' => 'security_health_analytics_custom_module', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{security_health_analytics_custom_module.name=folders/*/securityHealthAnalyticsSettings/customModules/*}', - 'body' => 'security_health_analytics_custom_module', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{security_health_analytics_custom_module.name=projects/*/securityHealthAnalyticsSettings/customModules/*}', - 'body' => 'security_health_analytics_custom_module', - ], - ], - 'placeholders' => [ - 'security_health_analytics_custom_module.name' => [ - 'getters' => [ - 'getSecurityHealthAnalyticsCustomModule', - 'getName', - ], - ], - ], - ], - 'UpdateSecurityMarks' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{security_marks.name=organizations/*/assets/*/securityMarks}', - 'body' => 'security_marks', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{security_marks.name=folders/*/assets/*/securityMarks}', - 'body' => 'security_marks', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{security_marks.name=projects/*/assets/*/securityMarks}', - 'body' => 'security_marks', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{security_marks.name=organizations/*/sources/*/findings/*/securityMarks}', - 'body' => 'security_marks', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{security_marks.name=folders/*/sources/*/findings/*/securityMarks}', - 'body' => 'security_marks', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{security_marks.name=projects/*/sources/*/findings/*/securityMarks}', - 'body' => 'security_marks', - ], - ], - 'placeholders' => [ - 'security_marks.name' => [ - 'getters' => [ - 'getSecurityMarks', - 'getName', - ], - ], - ], - ], - 'UpdateSource' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{source.name=organizations/*/sources/*}', - 'body' => 'source', - 'placeholders' => [ - 'source.name' => [ - 'getters' => [ - 'getSource', - 'getName', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - 'CancelOperation' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=organizations/*/operations/*}:cancel', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteOperation' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=organizations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOperation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=organizations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListOperations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=organizations/*/operations}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/SecurityCenter/v1/tests/Unit/V1/Client/SecurityCenterClientTest.php b/owl-bot-staging/SecurityCenter/v1/tests/Unit/V1/Client/SecurityCenterClientTest.php deleted file mode 100644 index c64e942c99f8..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/tests/Unit/V1/Client/SecurityCenterClientTest.php +++ /dev/null @@ -1,3616 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return SecurityCenterClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new SecurityCenterClient($options); - } - - /** @test */ - public function bulkMuteFindingsTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/bulkMuteFindingsTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new BulkMuteFindingsResponse(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/bulkMuteFindingsTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $parent = 'parent-995424086'; - $request = (new BulkMuteFindingsRequest()) - ->setParent($parent); - $response = $gapicClient->bulkMuteFindings($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/BulkMuteFindings', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($parent, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/bulkMuteFindingsTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function bulkMuteFindingsExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/bulkMuteFindingsTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $parent = 'parent-995424086'; - $request = (new BulkMuteFindingsRequest()) - ->setParent($parent); - $response = $gapicClient->bulkMuteFindings($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/bulkMuteFindingsTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createBigQueryExportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $description = 'description-1724546052'; - $filter = 'filter-1274492040'; - $dataset = 'dataset1443214456'; - $mostRecentEditor = 'mostRecentEditor-657770475'; - $principal = 'principal-1812041682'; - $expectedResponse = new BigQueryExport(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setFilter($filter); - $expectedResponse->setDataset($dataset); - $expectedResponse->setMostRecentEditor($mostRecentEditor); - $expectedResponse->setPrincipal($principal); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $bigQueryExport = new BigQueryExport(); - $bigQueryExportId = 'bigQueryExportId269737360'; - $request = (new CreateBigQueryExportRequest()) - ->setParent($formattedParent) - ->setBigQueryExport($bigQueryExport) - ->setBigQueryExportId($bigQueryExportId); - $response = $gapicClient->createBigQueryExport($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateBigQueryExport', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getBigQueryExport(); - $this->assertProtobufEquals($bigQueryExport, $actualValue); - $actualValue = $actualRequestObject->getBigQueryExportId(); - $this->assertProtobufEquals($bigQueryExportId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createBigQueryExportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $bigQueryExport = new BigQueryExport(); - $bigQueryExportId = 'bigQueryExportId269737360'; - $request = (new CreateBigQueryExportRequest()) - ->setParent($formattedParent) - ->setBigQueryExport($bigQueryExport) - ->setBigQueryExportId($bigQueryExportId); - try { - $gapicClient->createBigQueryExport($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createFindingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $parent2 = 'parent21175163357'; - $resourceName = 'resourceName979421212'; - $category = 'category50511102'; - $externalUri = 'externalUri-1385596168'; - $canonicalName = 'canonicalName1385400054'; - $muteInitiator = 'muteInitiator7603081'; - $parentDisplayName = 'parentDisplayName934119773'; - $description = 'description-1724546052'; - $nextSteps = 'nextSteps-921338149'; - $moduleName = 'moduleName-1195003778'; - $expectedResponse = new Finding(); - $expectedResponse->setName($name); - $expectedResponse->setParent($parent2); - $expectedResponse->setResourceName($resourceName); - $expectedResponse->setCategory($category); - $expectedResponse->setExternalUri($externalUri); - $expectedResponse->setCanonicalName($canonicalName); - $expectedResponse->setMuteInitiator($muteInitiator); - $expectedResponse->setParentDisplayName($parentDisplayName); - $expectedResponse->setDescription($description); - $expectedResponse->setNextSteps($nextSteps); - $expectedResponse->setModuleName($moduleName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $findingId = 'findingId728776081'; - $finding = new Finding(); - $request = (new CreateFindingRequest()) - ->setParent($formattedParent) - ->setFindingId($findingId) - ->setFinding($finding); - $response = $gapicClient->createFinding($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateFinding', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getFindingId(); - $this->assertProtobufEquals($findingId, $actualValue); - $actualValue = $actualRequestObject->getFinding(); - $this->assertProtobufEquals($finding, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createFindingExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $findingId = 'findingId728776081'; - $finding = new Finding(); - $request = (new CreateFindingRequest()) - ->setParent($formattedParent) - ->setFindingId($findingId) - ->setFinding($finding); - try { - $gapicClient->createFinding($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createMuteConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $filter = 'filter-1274492040'; - $mostRecentEditor = 'mostRecentEditor-657770475'; - $expectedResponse = new MuteConfig(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setFilter($filter); - $expectedResponse->setMostRecentEditor($mostRecentEditor); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $muteConfig = new MuteConfig(); - $muteConfigFilter = 'muteConfigFilter-1921414637'; - $muteConfig->setFilter($muteConfigFilter); - $muteConfigId = 'muteConfigId-547860334'; - $request = (new CreateMuteConfigRequest()) - ->setParent($formattedParent) - ->setMuteConfig($muteConfig) - ->setMuteConfigId($muteConfigId); - $response = $gapicClient->createMuteConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateMuteConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getMuteConfig(); - $this->assertProtobufEquals($muteConfig, $actualValue); - $actualValue = $actualRequestObject->getMuteConfigId(); - $this->assertProtobufEquals($muteConfigId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createMuteConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $muteConfig = new MuteConfig(); - $muteConfigFilter = 'muteConfigFilter-1921414637'; - $muteConfig->setFilter($muteConfigFilter); - $muteConfigId = 'muteConfigId-547860334'; - $request = (new CreateMuteConfigRequest()) - ->setParent($formattedParent) - ->setMuteConfig($muteConfig) - ->setMuteConfigId($muteConfigId); - try { - $gapicClient->createMuteConfig($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createNotificationConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $description = 'description-1724546052'; - $pubsubTopic = 'pubsubTopic-338126829'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new NotificationConfig(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setPubsubTopic($pubsubTopic); - $expectedResponse->setServiceAccount($serviceAccount); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $configId = 'configId-804450504'; - $notificationConfig = new NotificationConfig(); - $request = (new CreateNotificationConfigRequest()) - ->setParent($formattedParent) - ->setConfigId($configId) - ->setNotificationConfig($notificationConfig); - $response = $gapicClient->createNotificationConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateNotificationConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getConfigId(); - $this->assertProtobufEquals($configId, $actualValue); - $actualValue = $actualRequestObject->getNotificationConfig(); - $this->assertProtobufEquals($notificationConfig, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createNotificationConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $configId = 'configId-804450504'; - $notificationConfig = new NotificationConfig(); - $request = (new CreateNotificationConfigRequest()) - ->setParent($formattedParent) - ->setConfigId($configId) - ->setNotificationConfig($notificationConfig); - try { - $gapicClient->createNotificationConfig($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createSecurityHealthAnalyticsCustomModuleTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $lastEditor = 'lastEditor1620154166'; - $ancestorModule = 'ancestorModule-521996712'; - $expectedResponse = new SecurityHealthAnalyticsCustomModule(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setLastEditor($lastEditor); - $expectedResponse->setAncestorModule($ancestorModule); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); - $request = (new CreateSecurityHealthAnalyticsCustomModuleRequest()) - ->setParent($formattedParent) - ->setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); - $response = $gapicClient->createSecurityHealthAnalyticsCustomModule($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateSecurityHealthAnalyticsCustomModule', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getSecurityHealthAnalyticsCustomModule(); - $this->assertProtobufEquals($securityHealthAnalyticsCustomModule, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createSecurityHealthAnalyticsCustomModuleExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); - $request = (new CreateSecurityHealthAnalyticsCustomModuleRequest()) - ->setParent($formattedParent) - ->setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); - try { - $gapicClient->createSecurityHealthAnalyticsCustomModule($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createSourceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $canonicalName = 'canonicalName1385400054'; - $expectedResponse = new Source(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setCanonicalName($canonicalName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); - $source = new Source(); - $request = (new CreateSourceRequest()) - ->setParent($formattedParent) - ->setSource($source); - $response = $gapicClient->createSource($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateSource', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getSource(); - $this->assertProtobufEquals($source, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createSourceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); - $source = new Source(); - $request = (new CreateSourceRequest()) - ->setParent($formattedParent) - ->setSource($source); - try { - $gapicClient->createSource($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteBigQueryExportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); - $request = (new DeleteBigQueryExportRequest()) - ->setName($formattedName); - $gapicClient->deleteBigQueryExport($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/DeleteBigQueryExport', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteBigQueryExportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); - $request = (new DeleteBigQueryExportRequest()) - ->setName($formattedName); - try { - $gapicClient->deleteBigQueryExport($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteMuteConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); - $request = (new DeleteMuteConfigRequest()) - ->setName($formattedName); - $gapicClient->deleteMuteConfig($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/DeleteMuteConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteMuteConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); - $request = (new DeleteMuteConfigRequest()) - ->setName($formattedName); - try { - $gapicClient->deleteMuteConfig($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteNotificationConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); - $request = (new DeleteNotificationConfigRequest()) - ->setName($formattedName); - $gapicClient->deleteNotificationConfig($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/DeleteNotificationConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteNotificationConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); - $request = (new DeleteNotificationConfigRequest()) - ->setName($formattedName); - try { - $gapicClient->deleteNotificationConfig($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteSecurityHealthAnalyticsCustomModuleTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); - $request = (new DeleteSecurityHealthAnalyticsCustomModuleRequest()) - ->setName($formattedName); - $gapicClient->deleteSecurityHealthAnalyticsCustomModule($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/DeleteSecurityHealthAnalyticsCustomModule', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteSecurityHealthAnalyticsCustomModuleExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); - $request = (new DeleteSecurityHealthAnalyticsCustomModuleRequest()) - ->setName($formattedName); - try { - $gapicClient->deleteSecurityHealthAnalyticsCustomModule($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getBigQueryExportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $filter = 'filter-1274492040'; - $dataset = 'dataset1443214456'; - $mostRecentEditor = 'mostRecentEditor-657770475'; - $principal = 'principal-1812041682'; - $expectedResponse = new BigQueryExport(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setFilter($filter); - $expectedResponse->setDataset($dataset); - $expectedResponse->setMostRecentEditor($mostRecentEditor); - $expectedResponse->setPrincipal($principal); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); - $request = (new GetBigQueryExportRequest()) - ->setName($formattedName); - $response = $gapicClient->getBigQueryExport($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetBigQueryExport', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getBigQueryExportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); - $request = (new GetBigQueryExportRequest()) - ->setName($formattedName); - try { - $gapicClient->getBigQueryExport($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getEffectiveSecurityHealthAnalyticsCustomModuleTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $expectedResponse = new EffectiveSecurityHealthAnalyticsCustomModule(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->effectiveSecurityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[EFFECTIVE_CUSTOM_MODULE]'); - $request = (new GetEffectiveSecurityHealthAnalyticsCustomModuleRequest()) - ->setName($formattedName); - $response = $gapicClient->getEffectiveSecurityHealthAnalyticsCustomModule($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetEffectiveSecurityHealthAnalyticsCustomModule', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getEffectiveSecurityHealthAnalyticsCustomModuleExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->effectiveSecurityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[EFFECTIVE_CUSTOM_MODULE]'); - $request = (new GetEffectiveSecurityHealthAnalyticsCustomModuleRequest()) - ->setName($formattedName); - try { - $gapicClient->getEffectiveSecurityHealthAnalyticsCustomModule($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $request = (new GetIamPolicyRequest()) - ->setResource($resource); - $response = $gapicClient->getIamPolicy($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $request = (new GetIamPolicyRequest()) - ->setResource($resource); - try { - $gapicClient->getIamPolicy($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getMuteConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $filter = 'filter-1274492040'; - $mostRecentEditor = 'mostRecentEditor-657770475'; - $expectedResponse = new MuteConfig(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setFilter($filter); - $expectedResponse->setMostRecentEditor($mostRecentEditor); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); - $request = (new GetMuteConfigRequest()) - ->setName($formattedName); - $response = $gapicClient->getMuteConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetMuteConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getMuteConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); - $request = (new GetMuteConfigRequest()) - ->setName($formattedName); - try { - $gapicClient->getMuteConfig($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getNotificationConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $pubsubTopic = 'pubsubTopic-338126829'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new NotificationConfig(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setPubsubTopic($pubsubTopic); - $expectedResponse->setServiceAccount($serviceAccount); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); - $request = (new GetNotificationConfigRequest()) - ->setName($formattedName); - $response = $gapicClient->getNotificationConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetNotificationConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getNotificationConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); - $request = (new GetNotificationConfigRequest()) - ->setName($formattedName); - try { - $gapicClient->getNotificationConfig($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getOrganizationSettingsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $enableAssetDiscovery = false; - $expectedResponse = new OrganizationSettings(); - $expectedResponse->setName($name2); - $expectedResponse->setEnableAssetDiscovery($enableAssetDiscovery); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->organizationSettingsName('[ORGANIZATION]'); - $request = (new GetOrganizationSettingsRequest()) - ->setName($formattedName); - $response = $gapicClient->getOrganizationSettings($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetOrganizationSettings', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getOrganizationSettingsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->organizationSettingsName('[ORGANIZATION]'); - $request = (new GetOrganizationSettingsRequest()) - ->setName($formattedName); - try { - $gapicClient->getOrganizationSettings($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getSecurityHealthAnalyticsCustomModuleTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $lastEditor = 'lastEditor1620154166'; - $ancestorModule = 'ancestorModule-521996712'; - $expectedResponse = new SecurityHealthAnalyticsCustomModule(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setLastEditor($lastEditor); - $expectedResponse->setAncestorModule($ancestorModule); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); - $request = (new GetSecurityHealthAnalyticsCustomModuleRequest()) - ->setName($formattedName); - $response = $gapicClient->getSecurityHealthAnalyticsCustomModule($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetSecurityHealthAnalyticsCustomModule', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getSecurityHealthAnalyticsCustomModuleExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); - $request = (new GetSecurityHealthAnalyticsCustomModuleRequest()) - ->setName($formattedName); - try { - $gapicClient->getSecurityHealthAnalyticsCustomModule($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getSourceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $canonicalName = 'canonicalName1385400054'; - $expectedResponse = new Source(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setCanonicalName($canonicalName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $request = (new GetSourceRequest()) - ->setName($formattedName); - $response = $gapicClient->getSource($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetSource', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getSourceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $request = (new GetSourceRequest()) - ->setName($formattedName); - try { - $gapicClient->getSource($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function groupAssetsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $totalSize = 705419236; - $groupByResultsElement = new GroupResult(); - $groupByResults = [ - $groupByResultsElement, - ]; - $expectedResponse = new GroupAssetsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTotalSize($totalSize); - $expectedResponse->setGroupByResults($groupByResults); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $groupBy = 'groupBy506361367'; - $request = (new GroupAssetsRequest()) - ->setParent($formattedParent) - ->setGroupBy($groupBy); - $response = $gapicClient->groupAssets($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getGroupByResults()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GroupAssets', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getGroupBy(); - $this->assertProtobufEquals($groupBy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function groupAssetsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $groupBy = 'groupBy506361367'; - $request = (new GroupAssetsRequest()) - ->setParent($formattedParent) - ->setGroupBy($groupBy); - try { - $gapicClient->groupAssets($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function groupFindingsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $totalSize = 705419236; - $groupByResultsElement = new GroupResult(); - $groupByResults = [ - $groupByResultsElement, - ]; - $expectedResponse = new GroupFindingsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTotalSize($totalSize); - $expectedResponse->setGroupByResults($groupByResults); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $groupBy = 'groupBy506361367'; - $request = (new GroupFindingsRequest()) - ->setParent($formattedParent) - ->setGroupBy($groupBy); - $response = $gapicClient->groupFindings($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getGroupByResults()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GroupFindings', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getGroupBy(); - $this->assertProtobufEquals($groupBy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function groupFindingsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $groupBy = 'groupBy506361367'; - $request = (new GroupFindingsRequest()) - ->setParent($formattedParent) - ->setGroupBy($groupBy); - try { - $gapicClient->groupFindings($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAssetsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $totalSize = 705419236; - $listAssetsResultsElement = new ListAssetsResult(); - $listAssetsResults = [ - $listAssetsResultsElement, - ]; - $expectedResponse = new ListAssetsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTotalSize($totalSize); - $expectedResponse->setListAssetsResults($listAssetsResults); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $request = (new ListAssetsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listAssets($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getListAssetsResults()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListAssets', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAssetsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $request = (new ListAssetsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listAssets($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listBigQueryExportsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $bigQueryExportsElement = new BigQueryExport(); - $bigQueryExports = [ - $bigQueryExportsElement, - ]; - $expectedResponse = new ListBigQueryExportsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setBigQueryExports($bigQueryExports); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $request = (new ListBigQueryExportsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listBigQueryExports($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getBigQueryExports()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListBigQueryExports', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listBigQueryExportsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $request = (new ListBigQueryExportsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listBigQueryExports($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDescendantSecurityHealthAnalyticsCustomModulesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $securityHealthAnalyticsCustomModulesElement = new SecurityHealthAnalyticsCustomModule(); - $securityHealthAnalyticsCustomModules = [ - $securityHealthAnalyticsCustomModulesElement, - ]; - $expectedResponse = new ListDescendantSecurityHealthAnalyticsCustomModulesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setSecurityHealthAnalyticsCustomModules($securityHealthAnalyticsCustomModules); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - $request = (new ListDescendantSecurityHealthAnalyticsCustomModulesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listDescendantSecurityHealthAnalyticsCustomModules($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getSecurityHealthAnalyticsCustomModules()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListDescendantSecurityHealthAnalyticsCustomModules', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDescendantSecurityHealthAnalyticsCustomModulesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - $request = (new ListDescendantSecurityHealthAnalyticsCustomModulesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listDescendantSecurityHealthAnalyticsCustomModules($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listEffectiveSecurityHealthAnalyticsCustomModulesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $effectiveSecurityHealthAnalyticsCustomModulesElement = new EffectiveSecurityHealthAnalyticsCustomModule(); - $effectiveSecurityHealthAnalyticsCustomModules = [ - $effectiveSecurityHealthAnalyticsCustomModulesElement, - ]; - $expectedResponse = new ListEffectiveSecurityHealthAnalyticsCustomModulesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setEffectiveSecurityHealthAnalyticsCustomModules($effectiveSecurityHealthAnalyticsCustomModules); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - $request = (new ListEffectiveSecurityHealthAnalyticsCustomModulesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listEffectiveSecurityHealthAnalyticsCustomModules($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getEffectiveSecurityHealthAnalyticsCustomModules()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListEffectiveSecurityHealthAnalyticsCustomModules', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listEffectiveSecurityHealthAnalyticsCustomModulesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - $request = (new ListEffectiveSecurityHealthAnalyticsCustomModulesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listEffectiveSecurityHealthAnalyticsCustomModules($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listFindingsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $totalSize = 705419236; - $listFindingsResultsElement = new ListFindingsResult(); - $listFindingsResults = [ - $listFindingsResultsElement, - ]; - $expectedResponse = new ListFindingsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTotalSize($totalSize); - $expectedResponse->setListFindingsResults($listFindingsResults); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $request = (new ListFindingsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listFindings($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getListFindingsResults()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListFindings', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listFindingsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $request = (new ListFindingsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listFindings($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listMuteConfigsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $muteConfigsElement = new MuteConfig(); - $muteConfigs = [ - $muteConfigsElement, - ]; - $expectedResponse = new ListMuteConfigsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setMuteConfigs($muteConfigs); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $request = (new ListMuteConfigsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listMuteConfigs($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getMuteConfigs()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListMuteConfigs', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listMuteConfigsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $request = (new ListMuteConfigsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listMuteConfigs($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNotificationConfigsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $notificationConfigsElement = new NotificationConfig(); - $notificationConfigs = [ - $notificationConfigsElement, - ]; - $expectedResponse = new ListNotificationConfigsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setNotificationConfigs($notificationConfigs); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $request = (new ListNotificationConfigsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listNotificationConfigs($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getNotificationConfigs()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListNotificationConfigs', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNotificationConfigsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $request = (new ListNotificationConfigsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listNotificationConfigs($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listSecurityHealthAnalyticsCustomModulesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $securityHealthAnalyticsCustomModulesElement = new SecurityHealthAnalyticsCustomModule(); - $securityHealthAnalyticsCustomModules = [ - $securityHealthAnalyticsCustomModulesElement, - ]; - $expectedResponse = new ListSecurityHealthAnalyticsCustomModulesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setSecurityHealthAnalyticsCustomModules($securityHealthAnalyticsCustomModules); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - $request = (new ListSecurityHealthAnalyticsCustomModulesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listSecurityHealthAnalyticsCustomModules($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getSecurityHealthAnalyticsCustomModules()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListSecurityHealthAnalyticsCustomModules', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listSecurityHealthAnalyticsCustomModulesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - $request = (new ListSecurityHealthAnalyticsCustomModulesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listSecurityHealthAnalyticsCustomModules($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listSourcesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $sourcesElement = new Source(); - $sources = [ - $sourcesElement, - ]; - $expectedResponse = new ListSourcesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setSources($sources); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $request = (new ListSourcesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listSources($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getSources()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListSources', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listSourcesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $request = (new ListSourcesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listSources($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function runAssetDiscoveryTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/runAssetDiscoveryTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new RunAssetDiscoveryResponse(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/runAssetDiscoveryTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); - $request = (new RunAssetDiscoveryRequest()) - ->setParent($formattedParent); - $response = $gapicClient->runAssetDiscovery($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/RunAssetDiscovery', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/runAssetDiscoveryTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function runAssetDiscoveryExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/runAssetDiscoveryTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); - $request = (new RunAssetDiscoveryRequest()) - ->setParent($formattedParent); - $response = $gapicClient->runAssetDiscovery($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/runAssetDiscoveryTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function setFindingStateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $parent = 'parent-995424086'; - $resourceName = 'resourceName979421212'; - $category = 'category50511102'; - $externalUri = 'externalUri-1385596168'; - $canonicalName = 'canonicalName1385400054'; - $muteInitiator = 'muteInitiator7603081'; - $parentDisplayName = 'parentDisplayName934119773'; - $description = 'description-1724546052'; - $nextSteps = 'nextSteps-921338149'; - $moduleName = 'moduleName-1195003778'; - $expectedResponse = new Finding(); - $expectedResponse->setName($name2); - $expectedResponse->setParent($parent); - $expectedResponse->setResourceName($resourceName); - $expectedResponse->setCategory($category); - $expectedResponse->setExternalUri($externalUri); - $expectedResponse->setCanonicalName($canonicalName); - $expectedResponse->setMuteInitiator($muteInitiator); - $expectedResponse->setParentDisplayName($parentDisplayName); - $expectedResponse->setDescription($description); - $expectedResponse->setNextSteps($nextSteps); - $expectedResponse->setModuleName($moduleName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - $state = State::STATE_UNSPECIFIED; - $startTime = new Timestamp(); - $request = (new SetFindingStateRequest()) - ->setName($formattedName) - ->setState($state) - ->setStartTime($startTime); - $response = $gapicClient->setFindingState($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/SetFindingState', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualRequestObject->getState(); - $this->assertProtobufEquals($state, $actualValue); - $actualValue = $actualRequestObject->getStartTime(); - $this->assertProtobufEquals($startTime, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setFindingStateExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - $state = State::STATE_UNSPECIFIED; - $startTime = new Timestamp(); - $request = (new SetFindingStateRequest()) - ->setName($formattedName) - ->setState($state) - ->setStartTime($startTime); - try { - $gapicClient->setFindingState($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $request = (new SetIamPolicyRequest()) - ->setResource($resource) - ->setPolicy($policy); - $response = $gapicClient->setIamPolicy($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/SetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPolicy(); - $this->assertProtobufEquals($policy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $request = (new SetIamPolicyRequest()) - ->setResource($resource) - ->setPolicy($policy); - try { - $gapicClient->setIamPolicy($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setMuteTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $parent = 'parent-995424086'; - $resourceName = 'resourceName979421212'; - $category = 'category50511102'; - $externalUri = 'externalUri-1385596168'; - $canonicalName = 'canonicalName1385400054'; - $muteInitiator = 'muteInitiator7603081'; - $parentDisplayName = 'parentDisplayName934119773'; - $description = 'description-1724546052'; - $nextSteps = 'nextSteps-921338149'; - $moduleName = 'moduleName-1195003778'; - $expectedResponse = new Finding(); - $expectedResponse->setName($name2); - $expectedResponse->setParent($parent); - $expectedResponse->setResourceName($resourceName); - $expectedResponse->setCategory($category); - $expectedResponse->setExternalUri($externalUri); - $expectedResponse->setCanonicalName($canonicalName); - $expectedResponse->setMuteInitiator($muteInitiator); - $expectedResponse->setParentDisplayName($parentDisplayName); - $expectedResponse->setDescription($description); - $expectedResponse->setNextSteps($nextSteps); - $expectedResponse->setModuleName($moduleName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - $mute = Mute::MUTE_UNSPECIFIED; - $request = (new SetMuteRequest()) - ->setName($formattedName) - ->setMute($mute); - $response = $gapicClient->setMute($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/SetMute', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualRequestObject->getMute(); - $this->assertProtobufEquals($mute, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setMuteExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - $mute = Mute::MUTE_UNSPECIFIED; - $request = (new SetMuteRequest()) - ->setName($formattedName) - ->setMute($mute); - try { - $gapicClient->setMute($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function simulateSecurityHealthAnalyticsCustomModuleTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new SimulateSecurityHealthAnalyticsCustomModuleResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $parent = 'parent-995424086'; - $customConfig = new CustomConfig(); - $resource = new SimulatedResource(); - $resourceResourceType = 'resourceResourceType305300374'; - $resource->setResourceType($resourceResourceType); - $request = (new SimulateSecurityHealthAnalyticsCustomModuleRequest()) - ->setParent($parent) - ->setCustomConfig($customConfig) - ->setResource($resource); - $response = $gapicClient->simulateSecurityHealthAnalyticsCustomModule($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/SimulateSecurityHealthAnalyticsCustomModule', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($parent, $actualValue); - $actualValue = $actualRequestObject->getCustomConfig(); - $this->assertProtobufEquals($customConfig, $actualValue); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function simulateSecurityHealthAnalyticsCustomModuleExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $parent = 'parent-995424086'; - $customConfig = new CustomConfig(); - $resource = new SimulatedResource(); - $resourceResourceType = 'resourceResourceType305300374'; - $resource->setResourceType($resourceResourceType); - $request = (new SimulateSecurityHealthAnalyticsCustomModuleRequest()) - ->setParent($parent) - ->setCustomConfig($customConfig) - ->setResource($resource); - try { - $gapicClient->simulateSecurityHealthAnalyticsCustomModule($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new TestIamPermissionsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $request = (new TestIamPermissionsRequest()) - ->setResource($resource) - ->setPermissions($permissions); - $response = $gapicClient->testIamPermissions($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/TestIamPermissions', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPermissions(); - $this->assertProtobufEquals($permissions, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $request = (new TestIamPermissionsRequest()) - ->setResource($resource) - ->setPermissions($permissions); - try { - $gapicClient->testIamPermissions($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateBigQueryExportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $description = 'description-1724546052'; - $filter = 'filter-1274492040'; - $dataset = 'dataset1443214456'; - $mostRecentEditor = 'mostRecentEditor-657770475'; - $principal = 'principal-1812041682'; - $expectedResponse = new BigQueryExport(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setFilter($filter); - $expectedResponse->setDataset($dataset); - $expectedResponse->setMostRecentEditor($mostRecentEditor); - $expectedResponse->setPrincipal($principal); - $transport->addResponse($expectedResponse); - // Mock request - $bigQueryExport = new BigQueryExport(); - $request = (new UpdateBigQueryExportRequest()) - ->setBigQueryExport($bigQueryExport); - $response = $gapicClient->updateBigQueryExport($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateBigQueryExport', $actualFuncCall); - $actualValue = $actualRequestObject->getBigQueryExport(); - $this->assertProtobufEquals($bigQueryExport, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateBigQueryExportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $bigQueryExport = new BigQueryExport(); - $request = (new UpdateBigQueryExportRequest()) - ->setBigQueryExport($bigQueryExport); - try { - $gapicClient->updateBigQueryExport($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateExternalSystemTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $externalUid = 'externalUid-1385596452'; - $status = 'status-892481550'; - $caseUri = 'caseUri21649373'; - $casePriority = 'casePriority715048403'; - $expectedResponse = new ExternalSystem(); - $expectedResponse->setName($name); - $expectedResponse->setExternalUid($externalUid); - $expectedResponse->setStatus($status); - $expectedResponse->setCaseUri($caseUri); - $expectedResponse->setCasePriority($casePriority); - $transport->addResponse($expectedResponse); - // Mock request - $externalSystem = new ExternalSystem(); - $request = (new UpdateExternalSystemRequest()) - ->setExternalSystem($externalSystem); - $response = $gapicClient->updateExternalSystem($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateExternalSystem', $actualFuncCall); - $actualValue = $actualRequestObject->getExternalSystem(); - $this->assertProtobufEquals($externalSystem, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateExternalSystemExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $externalSystem = new ExternalSystem(); - $request = (new UpdateExternalSystemRequest()) - ->setExternalSystem($externalSystem); - try { - $gapicClient->updateExternalSystem($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateFindingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $parent = 'parent-995424086'; - $resourceName = 'resourceName979421212'; - $category = 'category50511102'; - $externalUri = 'externalUri-1385596168'; - $canonicalName = 'canonicalName1385400054'; - $muteInitiator = 'muteInitiator7603081'; - $parentDisplayName = 'parentDisplayName934119773'; - $description = 'description-1724546052'; - $nextSteps = 'nextSteps-921338149'; - $moduleName = 'moduleName-1195003778'; - $expectedResponse = new Finding(); - $expectedResponse->setName($name); - $expectedResponse->setParent($parent); - $expectedResponse->setResourceName($resourceName); - $expectedResponse->setCategory($category); - $expectedResponse->setExternalUri($externalUri); - $expectedResponse->setCanonicalName($canonicalName); - $expectedResponse->setMuteInitiator($muteInitiator); - $expectedResponse->setParentDisplayName($parentDisplayName); - $expectedResponse->setDescription($description); - $expectedResponse->setNextSteps($nextSteps); - $expectedResponse->setModuleName($moduleName); - $transport->addResponse($expectedResponse); - // Mock request - $finding = new Finding(); - $request = (new UpdateFindingRequest()) - ->setFinding($finding); - $response = $gapicClient->updateFinding($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateFinding', $actualFuncCall); - $actualValue = $actualRequestObject->getFinding(); - $this->assertProtobufEquals($finding, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateFindingExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $finding = new Finding(); - $request = (new UpdateFindingRequest()) - ->setFinding($finding); - try { - $gapicClient->updateFinding($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateMuteConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $filter = 'filter-1274492040'; - $mostRecentEditor = 'mostRecentEditor-657770475'; - $expectedResponse = new MuteConfig(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setFilter($filter); - $expectedResponse->setMostRecentEditor($mostRecentEditor); - $transport->addResponse($expectedResponse); - // Mock request - $muteConfig = new MuteConfig(); - $muteConfigFilter = 'muteConfigFilter-1921414637'; - $muteConfig->setFilter($muteConfigFilter); - $request = (new UpdateMuteConfigRequest()) - ->setMuteConfig($muteConfig); - $response = $gapicClient->updateMuteConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateMuteConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getMuteConfig(); - $this->assertProtobufEquals($muteConfig, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateMuteConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $muteConfig = new MuteConfig(); - $muteConfigFilter = 'muteConfigFilter-1921414637'; - $muteConfig->setFilter($muteConfigFilter); - $request = (new UpdateMuteConfigRequest()) - ->setMuteConfig($muteConfig); - try { - $gapicClient->updateMuteConfig($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateNotificationConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $description = 'description-1724546052'; - $pubsubTopic = 'pubsubTopic-338126829'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new NotificationConfig(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setPubsubTopic($pubsubTopic); - $expectedResponse->setServiceAccount($serviceAccount); - $transport->addResponse($expectedResponse); - // Mock request - $notificationConfig = new NotificationConfig(); - $request = (new UpdateNotificationConfigRequest()) - ->setNotificationConfig($notificationConfig); - $response = $gapicClient->updateNotificationConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateNotificationConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getNotificationConfig(); - $this->assertProtobufEquals($notificationConfig, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateNotificationConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $notificationConfig = new NotificationConfig(); - $request = (new UpdateNotificationConfigRequest()) - ->setNotificationConfig($notificationConfig); - try { - $gapicClient->updateNotificationConfig($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateOrganizationSettingsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $enableAssetDiscovery = false; - $expectedResponse = new OrganizationSettings(); - $expectedResponse->setName($name); - $expectedResponse->setEnableAssetDiscovery($enableAssetDiscovery); - $transport->addResponse($expectedResponse); - // Mock request - $organizationSettings = new OrganizationSettings(); - $request = (new UpdateOrganizationSettingsRequest()) - ->setOrganizationSettings($organizationSettings); - $response = $gapicClient->updateOrganizationSettings($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateOrganizationSettings', $actualFuncCall); - $actualValue = $actualRequestObject->getOrganizationSettings(); - $this->assertProtobufEquals($organizationSettings, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateOrganizationSettingsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $organizationSettings = new OrganizationSettings(); - $request = (new UpdateOrganizationSettingsRequest()) - ->setOrganizationSettings($organizationSettings); - try { - $gapicClient->updateOrganizationSettings($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSecurityHealthAnalyticsCustomModuleTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $lastEditor = 'lastEditor1620154166'; - $ancestorModule = 'ancestorModule-521996712'; - $expectedResponse = new SecurityHealthAnalyticsCustomModule(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setLastEditor($lastEditor); - $expectedResponse->setAncestorModule($ancestorModule); - $transport->addResponse($expectedResponse); - // Mock request - $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); - $request = (new UpdateSecurityHealthAnalyticsCustomModuleRequest()) - ->setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); - $response = $gapicClient->updateSecurityHealthAnalyticsCustomModule($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateSecurityHealthAnalyticsCustomModule', $actualFuncCall); - $actualValue = $actualRequestObject->getSecurityHealthAnalyticsCustomModule(); - $this->assertProtobufEquals($securityHealthAnalyticsCustomModule, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSecurityHealthAnalyticsCustomModuleExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); - $request = (new UpdateSecurityHealthAnalyticsCustomModuleRequest()) - ->setSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); - try { - $gapicClient->updateSecurityHealthAnalyticsCustomModule($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSecurityMarksTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $canonicalName = 'canonicalName1385400054'; - $expectedResponse = new SecurityMarks(); - $expectedResponse->setName($name); - $expectedResponse->setCanonicalName($canonicalName); - $transport->addResponse($expectedResponse); - // Mock request - $securityMarks = new SecurityMarks(); - $request = (new UpdateSecurityMarksRequest()) - ->setSecurityMarks($securityMarks); - $response = $gapicClient->updateSecurityMarks($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateSecurityMarks', $actualFuncCall); - $actualValue = $actualRequestObject->getSecurityMarks(); - $this->assertProtobufEquals($securityMarks, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSecurityMarksExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $securityMarks = new SecurityMarks(); - $request = (new UpdateSecurityMarksRequest()) - ->setSecurityMarks($securityMarks); - try { - $gapicClient->updateSecurityMarks($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSourceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $canonicalName = 'canonicalName1385400054'; - $expectedResponse = new Source(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setCanonicalName($canonicalName); - $transport->addResponse($expectedResponse); - // Mock request - $source = new Source(); - $request = (new UpdateSourceRequest()) - ->setSource($source); - $response = $gapicClient->updateSource($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateSource', $actualFuncCall); - $actualValue = $actualRequestObject->getSource(); - $this->assertProtobufEquals($source, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSourceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $source = new Source(); - $request = (new UpdateSourceRequest()) - ->setSource($source); - try { - $gapicClient->updateSource($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function bulkMuteFindingsAsyncTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/bulkMuteFindingsTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new BulkMuteFindingsResponse(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/bulkMuteFindingsTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $parent = 'parent-995424086'; - $request = (new BulkMuteFindingsRequest()) - ->setParent($parent); - $response = $gapicClient->bulkMuteFindingsAsync($request)->wait(); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/BulkMuteFindings', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($parent, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/bulkMuteFindingsTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } -} diff --git a/owl-bot-staging/SecurityCenter/v1/tests/Unit/V1/SecurityCenterClientTest.php b/owl-bot-staging/SecurityCenter/v1/tests/Unit/V1/SecurityCenterClientTest.php deleted file mode 100644 index 638d1b3fb681..000000000000 --- a/owl-bot-staging/SecurityCenter/v1/tests/Unit/V1/SecurityCenterClientTest.php +++ /dev/null @@ -1,3289 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return SecurityCenterClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new SecurityCenterClient($options); - } - - /** @test */ - public function bulkMuteFindingsTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/bulkMuteFindingsTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new BulkMuteFindingsResponse(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/bulkMuteFindingsTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $parent = 'parent-995424086'; - $response = $gapicClient->bulkMuteFindings($parent); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/BulkMuteFindings', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($parent, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/bulkMuteFindingsTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function bulkMuteFindingsExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/bulkMuteFindingsTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $parent = 'parent-995424086'; - $response = $gapicClient->bulkMuteFindings($parent); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/bulkMuteFindingsTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createBigQueryExportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $description = 'description-1724546052'; - $filter = 'filter-1274492040'; - $dataset = 'dataset1443214456'; - $mostRecentEditor = 'mostRecentEditor-657770475'; - $principal = 'principal-1812041682'; - $expectedResponse = new BigQueryExport(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setFilter($filter); - $expectedResponse->setDataset($dataset); - $expectedResponse->setMostRecentEditor($mostRecentEditor); - $expectedResponse->setPrincipal($principal); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $bigQueryExport = new BigQueryExport(); - $bigQueryExportId = 'bigQueryExportId269737360'; - $response = $gapicClient->createBigQueryExport($formattedParent, $bigQueryExport, $bigQueryExportId); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateBigQueryExport', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getBigQueryExport(); - $this->assertProtobufEquals($bigQueryExport, $actualValue); - $actualValue = $actualRequestObject->getBigQueryExportId(); - $this->assertProtobufEquals($bigQueryExportId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createBigQueryExportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $bigQueryExport = new BigQueryExport(); - $bigQueryExportId = 'bigQueryExportId269737360'; - try { - $gapicClient->createBigQueryExport($formattedParent, $bigQueryExport, $bigQueryExportId); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createFindingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $parent2 = 'parent21175163357'; - $resourceName = 'resourceName979421212'; - $category = 'category50511102'; - $externalUri = 'externalUri-1385596168'; - $canonicalName = 'canonicalName1385400054'; - $muteInitiator = 'muteInitiator7603081'; - $parentDisplayName = 'parentDisplayName934119773'; - $description = 'description-1724546052'; - $nextSteps = 'nextSteps-921338149'; - $moduleName = 'moduleName-1195003778'; - $expectedResponse = new Finding(); - $expectedResponse->setName($name); - $expectedResponse->setParent($parent2); - $expectedResponse->setResourceName($resourceName); - $expectedResponse->setCategory($category); - $expectedResponse->setExternalUri($externalUri); - $expectedResponse->setCanonicalName($canonicalName); - $expectedResponse->setMuteInitiator($muteInitiator); - $expectedResponse->setParentDisplayName($parentDisplayName); - $expectedResponse->setDescription($description); - $expectedResponse->setNextSteps($nextSteps); - $expectedResponse->setModuleName($moduleName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $findingId = 'findingId728776081'; - $finding = new Finding(); - $response = $gapicClient->createFinding($formattedParent, $findingId, $finding); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateFinding', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getFindingId(); - $this->assertProtobufEquals($findingId, $actualValue); - $actualValue = $actualRequestObject->getFinding(); - $this->assertProtobufEquals($finding, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createFindingExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $findingId = 'findingId728776081'; - $finding = new Finding(); - try { - $gapicClient->createFinding($formattedParent, $findingId, $finding); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createMuteConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $filter = 'filter-1274492040'; - $mostRecentEditor = 'mostRecentEditor-657770475'; - $expectedResponse = new MuteConfig(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setFilter($filter); - $expectedResponse->setMostRecentEditor($mostRecentEditor); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $muteConfig = new MuteConfig(); - $muteConfigFilter = 'muteConfigFilter-1921414637'; - $muteConfig->setFilter($muteConfigFilter); - $muteConfigId = 'muteConfigId-547860334'; - $response = $gapicClient->createMuteConfig($formattedParent, $muteConfig, $muteConfigId); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateMuteConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getMuteConfig(); - $this->assertProtobufEquals($muteConfig, $actualValue); - $actualValue = $actualRequestObject->getMuteConfigId(); - $this->assertProtobufEquals($muteConfigId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createMuteConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $muteConfig = new MuteConfig(); - $muteConfigFilter = 'muteConfigFilter-1921414637'; - $muteConfig->setFilter($muteConfigFilter); - $muteConfigId = 'muteConfigId-547860334'; - try { - $gapicClient->createMuteConfig($formattedParent, $muteConfig, $muteConfigId); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createNotificationConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $description = 'description-1724546052'; - $pubsubTopic = 'pubsubTopic-338126829'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new NotificationConfig(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setPubsubTopic($pubsubTopic); - $expectedResponse->setServiceAccount($serviceAccount); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $configId = 'configId-804450504'; - $notificationConfig = new NotificationConfig(); - $response = $gapicClient->createNotificationConfig($formattedParent, $configId, $notificationConfig); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateNotificationConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getConfigId(); - $this->assertProtobufEquals($configId, $actualValue); - $actualValue = $actualRequestObject->getNotificationConfig(); - $this->assertProtobufEquals($notificationConfig, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createNotificationConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $configId = 'configId-804450504'; - $notificationConfig = new NotificationConfig(); - try { - $gapicClient->createNotificationConfig($formattedParent, $configId, $notificationConfig); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createSecurityHealthAnalyticsCustomModuleTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $lastEditor = 'lastEditor1620154166'; - $ancestorModule = 'ancestorModule-521996712'; - $expectedResponse = new SecurityHealthAnalyticsCustomModule(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setLastEditor($lastEditor); - $expectedResponse->setAncestorModule($ancestorModule); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); - $response = $gapicClient->createSecurityHealthAnalyticsCustomModule($formattedParent, $securityHealthAnalyticsCustomModule); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateSecurityHealthAnalyticsCustomModule', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getSecurityHealthAnalyticsCustomModule(); - $this->assertProtobufEquals($securityHealthAnalyticsCustomModule, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createSecurityHealthAnalyticsCustomModuleExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); - try { - $gapicClient->createSecurityHealthAnalyticsCustomModule($formattedParent, $securityHealthAnalyticsCustomModule); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createSourceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $canonicalName = 'canonicalName1385400054'; - $expectedResponse = new Source(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setCanonicalName($canonicalName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); - $source = new Source(); - $response = $gapicClient->createSource($formattedParent, $source); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/CreateSource', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getSource(); - $this->assertProtobufEquals($source, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createSourceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); - $source = new Source(); - try { - $gapicClient->createSource($formattedParent, $source); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteBigQueryExportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); - $gapicClient->deleteBigQueryExport($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/DeleteBigQueryExport', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteBigQueryExportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); - try { - $gapicClient->deleteBigQueryExport($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteMuteConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); - $gapicClient->deleteMuteConfig($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/DeleteMuteConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteMuteConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); - try { - $gapicClient->deleteMuteConfig($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteNotificationConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); - $gapicClient->deleteNotificationConfig($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/DeleteNotificationConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteNotificationConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); - try { - $gapicClient->deleteNotificationConfig($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteSecurityHealthAnalyticsCustomModuleTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); - $gapicClient->deleteSecurityHealthAnalyticsCustomModule($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/DeleteSecurityHealthAnalyticsCustomModule', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteSecurityHealthAnalyticsCustomModuleExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); - try { - $gapicClient->deleteSecurityHealthAnalyticsCustomModule($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getBigQueryExportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $filter = 'filter-1274492040'; - $dataset = 'dataset1443214456'; - $mostRecentEditor = 'mostRecentEditor-657770475'; - $principal = 'principal-1812041682'; - $expectedResponse = new BigQueryExport(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setFilter($filter); - $expectedResponse->setDataset($dataset); - $expectedResponse->setMostRecentEditor($mostRecentEditor); - $expectedResponse->setPrincipal($principal); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); - $response = $gapicClient->getBigQueryExport($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetBigQueryExport', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getBigQueryExportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[EXPORT]'); - try { - $gapicClient->getBigQueryExport($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getEffectiveSecurityHealthAnalyticsCustomModuleTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $expectedResponse = new EffectiveSecurityHealthAnalyticsCustomModule(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->effectiveSecurityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[EFFECTIVE_CUSTOM_MODULE]'); - $response = $gapicClient->getEffectiveSecurityHealthAnalyticsCustomModule($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetEffectiveSecurityHealthAnalyticsCustomModule', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getEffectiveSecurityHealthAnalyticsCustomModuleExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->effectiveSecurityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[EFFECTIVE_CUSTOM_MODULE]'); - try { - $gapicClient->getEffectiveSecurityHealthAnalyticsCustomModule($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $response = $gapicClient->getIamPolicy($resource); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - try { - $gapicClient->getIamPolicy($resource); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getMuteConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $filter = 'filter-1274492040'; - $mostRecentEditor = 'mostRecentEditor-657770475'; - $expectedResponse = new MuteConfig(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setFilter($filter); - $expectedResponse->setMostRecentEditor($mostRecentEditor); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); - $response = $gapicClient->getMuteConfig($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetMuteConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getMuteConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); - try { - $gapicClient->getMuteConfig($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getNotificationConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $pubsubTopic = 'pubsubTopic-338126829'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new NotificationConfig(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setPubsubTopic($pubsubTopic); - $expectedResponse->setServiceAccount($serviceAccount); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); - $response = $gapicClient->getNotificationConfig($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetNotificationConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getNotificationConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); - try { - $gapicClient->getNotificationConfig($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getOrganizationSettingsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $enableAssetDiscovery = false; - $expectedResponse = new OrganizationSettings(); - $expectedResponse->setName($name2); - $expectedResponse->setEnableAssetDiscovery($enableAssetDiscovery); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->organizationSettingsName('[ORGANIZATION]'); - $response = $gapicClient->getOrganizationSettings($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetOrganizationSettings', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getOrganizationSettingsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->organizationSettingsName('[ORGANIZATION]'); - try { - $gapicClient->getOrganizationSettings($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getSecurityHealthAnalyticsCustomModuleTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $lastEditor = 'lastEditor1620154166'; - $ancestorModule = 'ancestorModule-521996712'; - $expectedResponse = new SecurityHealthAnalyticsCustomModule(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setLastEditor($lastEditor); - $expectedResponse->setAncestorModule($ancestorModule); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); - $response = $gapicClient->getSecurityHealthAnalyticsCustomModule($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetSecurityHealthAnalyticsCustomModule', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getSecurityHealthAnalyticsCustomModuleExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->securityHealthAnalyticsCustomModuleName('[ORGANIZATION]', '[CUSTOM_MODULE]'); - try { - $gapicClient->getSecurityHealthAnalyticsCustomModule($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getSourceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $canonicalName = 'canonicalName1385400054'; - $expectedResponse = new Source(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setCanonicalName($canonicalName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $response = $gapicClient->getSource($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GetSource', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getSourceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - try { - $gapicClient->getSource($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function groupAssetsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $totalSize = 705419236; - $groupByResultsElement = new GroupResult(); - $groupByResults = [ - $groupByResultsElement, - ]; - $expectedResponse = new GroupAssetsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTotalSize($totalSize); - $expectedResponse->setGroupByResults($groupByResults); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $groupBy = 'groupBy506361367'; - $response = $gapicClient->groupAssets($formattedParent, $groupBy); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getGroupByResults()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GroupAssets', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getGroupBy(); - $this->assertProtobufEquals($groupBy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function groupAssetsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $groupBy = 'groupBy506361367'; - try { - $gapicClient->groupAssets($formattedParent, $groupBy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function groupFindingsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $totalSize = 705419236; - $groupByResultsElement = new GroupResult(); - $groupByResults = [ - $groupByResultsElement, - ]; - $expectedResponse = new GroupFindingsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTotalSize($totalSize); - $expectedResponse->setGroupByResults($groupByResults); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $groupBy = 'groupBy506361367'; - $response = $gapicClient->groupFindings($formattedParent, $groupBy); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getGroupByResults()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/GroupFindings', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getGroupBy(); - $this->assertProtobufEquals($groupBy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function groupFindingsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $groupBy = 'groupBy506361367'; - try { - $gapicClient->groupFindings($formattedParent, $groupBy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAssetsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $totalSize = 705419236; - $listAssetsResultsElement = new ListAssetsResult(); - $listAssetsResults = [ - $listAssetsResultsElement, - ]; - $expectedResponse = new ListAssetsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTotalSize($totalSize); - $expectedResponse->setListAssetsResults($listAssetsResults); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $response = $gapicClient->listAssets($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getListAssetsResults()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListAssets', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAssetsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - try { - $gapicClient->listAssets($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listBigQueryExportsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $bigQueryExportsElement = new BigQueryExport(); - $bigQueryExports = [ - $bigQueryExportsElement, - ]; - $expectedResponse = new ListBigQueryExportsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setBigQueryExports($bigQueryExports); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $response = $gapicClient->listBigQueryExports($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getBigQueryExports()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListBigQueryExports', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listBigQueryExportsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - try { - $gapicClient->listBigQueryExports($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDescendantSecurityHealthAnalyticsCustomModulesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $securityHealthAnalyticsCustomModulesElement = new SecurityHealthAnalyticsCustomModule(); - $securityHealthAnalyticsCustomModules = [ - $securityHealthAnalyticsCustomModulesElement, - ]; - $expectedResponse = new ListDescendantSecurityHealthAnalyticsCustomModulesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setSecurityHealthAnalyticsCustomModules($securityHealthAnalyticsCustomModules); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - $response = $gapicClient->listDescendantSecurityHealthAnalyticsCustomModules($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getSecurityHealthAnalyticsCustomModules()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListDescendantSecurityHealthAnalyticsCustomModules', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listDescendantSecurityHealthAnalyticsCustomModulesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - try { - $gapicClient->listDescendantSecurityHealthAnalyticsCustomModules($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listEffectiveSecurityHealthAnalyticsCustomModulesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $effectiveSecurityHealthAnalyticsCustomModulesElement = new EffectiveSecurityHealthAnalyticsCustomModule(); - $effectiveSecurityHealthAnalyticsCustomModules = [ - $effectiveSecurityHealthAnalyticsCustomModulesElement, - ]; - $expectedResponse = new ListEffectiveSecurityHealthAnalyticsCustomModulesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setEffectiveSecurityHealthAnalyticsCustomModules($effectiveSecurityHealthAnalyticsCustomModules); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - $response = $gapicClient->listEffectiveSecurityHealthAnalyticsCustomModules($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getEffectiveSecurityHealthAnalyticsCustomModules()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListEffectiveSecurityHealthAnalyticsCustomModules', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listEffectiveSecurityHealthAnalyticsCustomModulesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - try { - $gapicClient->listEffectiveSecurityHealthAnalyticsCustomModules($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listFindingsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $totalSize = 705419236; - $listFindingsResultsElement = new ListFindingsResult(); - $listFindingsResults = [ - $listFindingsResultsElement, - ]; - $expectedResponse = new ListFindingsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTotalSize($totalSize); - $expectedResponse->setListFindingsResults($listFindingsResults); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $response = $gapicClient->listFindings($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getListFindingsResults()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListFindings', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listFindingsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - try { - $gapicClient->listFindings($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listMuteConfigsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $muteConfigsElement = new MuteConfig(); - $muteConfigs = [ - $muteConfigsElement, - ]; - $expectedResponse = new ListMuteConfigsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setMuteConfigs($muteConfigs); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $response = $gapicClient->listMuteConfigs($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getMuteConfigs()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListMuteConfigs', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listMuteConfigsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - try { - $gapicClient->listMuteConfigs($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNotificationConfigsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $notificationConfigsElement = new NotificationConfig(); - $notificationConfigs = [ - $notificationConfigsElement, - ]; - $expectedResponse = new ListNotificationConfigsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setNotificationConfigs($notificationConfigs); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $response = $gapicClient->listNotificationConfigs($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getNotificationConfigs()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListNotificationConfigs', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNotificationConfigsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - try { - $gapicClient->listNotificationConfigs($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listSecurityHealthAnalyticsCustomModulesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $securityHealthAnalyticsCustomModulesElement = new SecurityHealthAnalyticsCustomModule(); - $securityHealthAnalyticsCustomModules = [ - $securityHealthAnalyticsCustomModulesElement, - ]; - $expectedResponse = new ListSecurityHealthAnalyticsCustomModulesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setSecurityHealthAnalyticsCustomModules($securityHealthAnalyticsCustomModules); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - $response = $gapicClient->listSecurityHealthAnalyticsCustomModules($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getSecurityHealthAnalyticsCustomModules()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListSecurityHealthAnalyticsCustomModules', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listSecurityHealthAnalyticsCustomModulesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->securityHealthAnalyticsSettingsName('[ORGANIZATION]'); - try { - $gapicClient->listSecurityHealthAnalyticsCustomModules($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listSourcesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $sourcesElement = new Source(); - $sources = [ - $sourcesElement, - ]; - $expectedResponse = new ListSourcesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setSources($sources); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $response = $gapicClient->listSources($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getSources()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/ListSources', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listSourcesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - try { - $gapicClient->listSources($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function runAssetDiscoveryTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/runAssetDiscoveryTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new RunAssetDiscoveryResponse(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/runAssetDiscoveryTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); - $response = $gapicClient->runAssetDiscovery($formattedParent); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/RunAssetDiscovery', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/runAssetDiscoveryTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function runAssetDiscoveryExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/runAssetDiscoveryTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); - $response = $gapicClient->runAssetDiscovery($formattedParent); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/runAssetDiscoveryTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function setFindingStateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $parent = 'parent-995424086'; - $resourceName = 'resourceName979421212'; - $category = 'category50511102'; - $externalUri = 'externalUri-1385596168'; - $canonicalName = 'canonicalName1385400054'; - $muteInitiator = 'muteInitiator7603081'; - $parentDisplayName = 'parentDisplayName934119773'; - $description = 'description-1724546052'; - $nextSteps = 'nextSteps-921338149'; - $moduleName = 'moduleName-1195003778'; - $expectedResponse = new Finding(); - $expectedResponse->setName($name2); - $expectedResponse->setParent($parent); - $expectedResponse->setResourceName($resourceName); - $expectedResponse->setCategory($category); - $expectedResponse->setExternalUri($externalUri); - $expectedResponse->setCanonicalName($canonicalName); - $expectedResponse->setMuteInitiator($muteInitiator); - $expectedResponse->setParentDisplayName($parentDisplayName); - $expectedResponse->setDescription($description); - $expectedResponse->setNextSteps($nextSteps); - $expectedResponse->setModuleName($moduleName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - $state = State::STATE_UNSPECIFIED; - $startTime = new Timestamp(); - $response = $gapicClient->setFindingState($formattedName, $state, $startTime); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/SetFindingState', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualRequestObject->getState(); - $this->assertProtobufEquals($state, $actualValue); - $actualValue = $actualRequestObject->getStartTime(); - $this->assertProtobufEquals($startTime, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setFindingStateExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - $state = State::STATE_UNSPECIFIED; - $startTime = new Timestamp(); - try { - $gapicClient->setFindingState($formattedName, $state, $startTime); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $response = $gapicClient->setIamPolicy($resource, $policy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/SetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPolicy(); - $this->assertProtobufEquals($policy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - try { - $gapicClient->setIamPolicy($resource, $policy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setMuteTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $parent = 'parent-995424086'; - $resourceName = 'resourceName979421212'; - $category = 'category50511102'; - $externalUri = 'externalUri-1385596168'; - $canonicalName = 'canonicalName1385400054'; - $muteInitiator = 'muteInitiator7603081'; - $parentDisplayName = 'parentDisplayName934119773'; - $description = 'description-1724546052'; - $nextSteps = 'nextSteps-921338149'; - $moduleName = 'moduleName-1195003778'; - $expectedResponse = new Finding(); - $expectedResponse->setName($name2); - $expectedResponse->setParent($parent); - $expectedResponse->setResourceName($resourceName); - $expectedResponse->setCategory($category); - $expectedResponse->setExternalUri($externalUri); - $expectedResponse->setCanonicalName($canonicalName); - $expectedResponse->setMuteInitiator($muteInitiator); - $expectedResponse->setParentDisplayName($parentDisplayName); - $expectedResponse->setDescription($description); - $expectedResponse->setNextSteps($nextSteps); - $expectedResponse->setModuleName($moduleName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - $mute = Mute::MUTE_UNSPECIFIED; - $response = $gapicClient->setMute($formattedName, $mute); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/SetMute', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualRequestObject->getMute(); - $this->assertProtobufEquals($mute, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setMuteExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - $mute = Mute::MUTE_UNSPECIFIED; - try { - $gapicClient->setMute($formattedName, $mute); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function simulateSecurityHealthAnalyticsCustomModuleTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new SimulateSecurityHealthAnalyticsCustomModuleResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $parent = 'parent-995424086'; - $customConfig = new CustomConfig(); - $resource = new SimulatedResource(); - $resourceResourceType = 'resourceResourceType305300374'; - $resource->setResourceType($resourceResourceType); - $response = $gapicClient->simulateSecurityHealthAnalyticsCustomModule($parent, $customConfig, $resource); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/SimulateSecurityHealthAnalyticsCustomModule', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($parent, $actualValue); - $actualValue = $actualRequestObject->getCustomConfig(); - $this->assertProtobufEquals($customConfig, $actualValue); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function simulateSecurityHealthAnalyticsCustomModuleExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $parent = 'parent-995424086'; - $customConfig = new CustomConfig(); - $resource = new SimulatedResource(); - $resourceResourceType = 'resourceResourceType305300374'; - $resource->setResourceType($resourceResourceType); - try { - $gapicClient->simulateSecurityHealthAnalyticsCustomModule($parent, $customConfig, $resource); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new TestIamPermissionsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $response = $gapicClient->testIamPermissions($resource, $permissions); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/TestIamPermissions', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPermissions(); - $this->assertProtobufEquals($permissions, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - try { - $gapicClient->testIamPermissions($resource, $permissions); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateBigQueryExportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $description = 'description-1724546052'; - $filter = 'filter-1274492040'; - $dataset = 'dataset1443214456'; - $mostRecentEditor = 'mostRecentEditor-657770475'; - $principal = 'principal-1812041682'; - $expectedResponse = new BigQueryExport(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setFilter($filter); - $expectedResponse->setDataset($dataset); - $expectedResponse->setMostRecentEditor($mostRecentEditor); - $expectedResponse->setPrincipal($principal); - $transport->addResponse($expectedResponse); - // Mock request - $bigQueryExport = new BigQueryExport(); - $response = $gapicClient->updateBigQueryExport($bigQueryExport); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateBigQueryExport', $actualFuncCall); - $actualValue = $actualRequestObject->getBigQueryExport(); - $this->assertProtobufEquals($bigQueryExport, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateBigQueryExportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $bigQueryExport = new BigQueryExport(); - try { - $gapicClient->updateBigQueryExport($bigQueryExport); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateExternalSystemTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $externalUid = 'externalUid-1385596452'; - $status = 'status-892481550'; - $caseUri = 'caseUri21649373'; - $casePriority = 'casePriority715048403'; - $expectedResponse = new ExternalSystem(); - $expectedResponse->setName($name); - $expectedResponse->setExternalUid($externalUid); - $expectedResponse->setStatus($status); - $expectedResponse->setCaseUri($caseUri); - $expectedResponse->setCasePriority($casePriority); - $transport->addResponse($expectedResponse); - // Mock request - $externalSystem = new ExternalSystem(); - $response = $gapicClient->updateExternalSystem($externalSystem); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateExternalSystem', $actualFuncCall); - $actualValue = $actualRequestObject->getExternalSystem(); - $this->assertProtobufEquals($externalSystem, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateExternalSystemExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $externalSystem = new ExternalSystem(); - try { - $gapicClient->updateExternalSystem($externalSystem); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateFindingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $parent = 'parent-995424086'; - $resourceName = 'resourceName979421212'; - $category = 'category50511102'; - $externalUri = 'externalUri-1385596168'; - $canonicalName = 'canonicalName1385400054'; - $muteInitiator = 'muteInitiator7603081'; - $parentDisplayName = 'parentDisplayName934119773'; - $description = 'description-1724546052'; - $nextSteps = 'nextSteps-921338149'; - $moduleName = 'moduleName-1195003778'; - $expectedResponse = new Finding(); - $expectedResponse->setName($name); - $expectedResponse->setParent($parent); - $expectedResponse->setResourceName($resourceName); - $expectedResponse->setCategory($category); - $expectedResponse->setExternalUri($externalUri); - $expectedResponse->setCanonicalName($canonicalName); - $expectedResponse->setMuteInitiator($muteInitiator); - $expectedResponse->setParentDisplayName($parentDisplayName); - $expectedResponse->setDescription($description); - $expectedResponse->setNextSteps($nextSteps); - $expectedResponse->setModuleName($moduleName); - $transport->addResponse($expectedResponse); - // Mock request - $finding = new Finding(); - $response = $gapicClient->updateFinding($finding); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateFinding', $actualFuncCall); - $actualValue = $actualRequestObject->getFinding(); - $this->assertProtobufEquals($finding, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateFindingExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $finding = new Finding(); - try { - $gapicClient->updateFinding($finding); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateMuteConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $filter = 'filter-1274492040'; - $mostRecentEditor = 'mostRecentEditor-657770475'; - $expectedResponse = new MuteConfig(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setFilter($filter); - $expectedResponse->setMostRecentEditor($mostRecentEditor); - $transport->addResponse($expectedResponse); - // Mock request - $muteConfig = new MuteConfig(); - $muteConfigFilter = 'muteConfigFilter-1921414637'; - $muteConfig->setFilter($muteConfigFilter); - $response = $gapicClient->updateMuteConfig($muteConfig); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateMuteConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getMuteConfig(); - $this->assertProtobufEquals($muteConfig, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateMuteConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $muteConfig = new MuteConfig(); - $muteConfigFilter = 'muteConfigFilter-1921414637'; - $muteConfig->setFilter($muteConfigFilter); - try { - $gapicClient->updateMuteConfig($muteConfig); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateNotificationConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $description = 'description-1724546052'; - $pubsubTopic = 'pubsubTopic-338126829'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new NotificationConfig(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setPubsubTopic($pubsubTopic); - $expectedResponse->setServiceAccount($serviceAccount); - $transport->addResponse($expectedResponse); - // Mock request - $notificationConfig = new NotificationConfig(); - $response = $gapicClient->updateNotificationConfig($notificationConfig); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateNotificationConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getNotificationConfig(); - $this->assertProtobufEquals($notificationConfig, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateNotificationConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $notificationConfig = new NotificationConfig(); - try { - $gapicClient->updateNotificationConfig($notificationConfig); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateOrganizationSettingsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $enableAssetDiscovery = false; - $expectedResponse = new OrganizationSettings(); - $expectedResponse->setName($name); - $expectedResponse->setEnableAssetDiscovery($enableAssetDiscovery); - $transport->addResponse($expectedResponse); - // Mock request - $organizationSettings = new OrganizationSettings(); - $response = $gapicClient->updateOrganizationSettings($organizationSettings); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateOrganizationSettings', $actualFuncCall); - $actualValue = $actualRequestObject->getOrganizationSettings(); - $this->assertProtobufEquals($organizationSettings, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateOrganizationSettingsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $organizationSettings = new OrganizationSettings(); - try { - $gapicClient->updateOrganizationSettings($organizationSettings); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSecurityHealthAnalyticsCustomModuleTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $lastEditor = 'lastEditor1620154166'; - $ancestorModule = 'ancestorModule-521996712'; - $expectedResponse = new SecurityHealthAnalyticsCustomModule(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setLastEditor($lastEditor); - $expectedResponse->setAncestorModule($ancestorModule); - $transport->addResponse($expectedResponse); - // Mock request - $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); - $response = $gapicClient->updateSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateSecurityHealthAnalyticsCustomModule', $actualFuncCall); - $actualValue = $actualRequestObject->getSecurityHealthAnalyticsCustomModule(); - $this->assertProtobufEquals($securityHealthAnalyticsCustomModule, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSecurityHealthAnalyticsCustomModuleExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $securityHealthAnalyticsCustomModule = new SecurityHealthAnalyticsCustomModule(); - try { - $gapicClient->updateSecurityHealthAnalyticsCustomModule($securityHealthAnalyticsCustomModule); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSecurityMarksTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $canonicalName = 'canonicalName1385400054'; - $expectedResponse = new SecurityMarks(); - $expectedResponse->setName($name); - $expectedResponse->setCanonicalName($canonicalName); - $transport->addResponse($expectedResponse); - // Mock request - $securityMarks = new SecurityMarks(); - $response = $gapicClient->updateSecurityMarks($securityMarks); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateSecurityMarks', $actualFuncCall); - $actualValue = $actualRequestObject->getSecurityMarks(); - $this->assertProtobufEquals($securityMarks, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSecurityMarksExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $securityMarks = new SecurityMarks(); - try { - $gapicClient->updateSecurityMarks($securityMarks); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSourceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $canonicalName = 'canonicalName1385400054'; - $expectedResponse = new Source(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setCanonicalName($canonicalName); - $transport->addResponse($expectedResponse); - // Mock request - $source = new Source(); - $response = $gapicClient->updateSource($source); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1.SecurityCenter/UpdateSource', $actualFuncCall); - $actualValue = $actualRequestObject->getSource(); - $this->assertProtobufEquals($source, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSourceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $source = new Source(); - try { - $gapicClient->updateSource($source); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Asset.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Asset.php deleted file mode 100644 index 35ef1334b2d1..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Asset.php +++ /dev/null @@ -1,60 +0,0 @@ -internalAddGeneratedFile( - ' -Þ -1google/cloud/securitycenter/v1p1beta1/asset.proto%google.cloud.securitycenter.v1p1beta12google/cloud/securitycenter/v1p1beta1/folder.proto:google/cloud/securitycenter/v1p1beta1/security_marks.protogoogle/protobuf/struct.protogoogle/protobuf/timestamp.proto"Ì -Asset -name ( i -security_center_properties ( 2E.google.cloud.securitycenter.v1p1beta1.Asset.SecurityCenterPropertiesa -resource_properties ( 2D.google.cloud.securitycenter.v1p1beta1.Asset.ResourcePropertiesEntryL -security_marks ( 24.google.cloud.securitycenter.v1p1beta1.SecurityMarks/ - create_time ( 2.google.protobuf.Timestamp/ - update_time - ( 2.google.protobuf.TimestampJ - -iam_policy ( 26.google.cloud.securitycenter.v1p1beta1.Asset.IamPolicy -canonical_name ( À -SecurityCenterProperties - resource_name (  - resource_type (  -resource_parent (  -resource_project (  -resource_owners (  -resource_display_name ( $ -resource_parent_display_name ( % -resource_project_display_name ( > -folders - ( 2-.google.cloud.securitycenter.v1p1beta1.Folder - IamPolicy - policy_blob ( Q -ResourcePropertiesEntry -key ( % -value ( 2.google.protobuf.Value:8:šêA– -#securitycenter.googleapis.com/Asset+organizations/{organization}/assets/{asset}folders/{folder}/assets/{asset}!projects/{project}/assets/{asset}Bû -)com.google.cloud.securitycenter.v1p1beta1PZQcloud.google.com/go/securitycenter/apiv1p1beta1/securitycenterpb;securitycenterpbª%Google.Cloud.SecurityCenter.V1P1Beta1Ê%Google\\Cloud\\SecurityCenter\\V1p1beta1ê(Google::Cloud::SecurityCenter::V1p1beta1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Finding.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Finding.php deleted file mode 100644 index 9aaff640672f2da297801204a73510a198a84f79..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2387 zcmbVO-EP}96rSz;ICN{cLQ`nLfN@!aI>08uX|WZ`vdw>S4K%S+yBRhJFl3o_xGIuB z(ZSrpFSJM53k=vUw(GvaZgxmYN}Oh?SKnA9&-d~0JLmB5oA1K25PgnY#3#(*WQ2z^ z%+Cl8S-=A~@bGXt9utP$;5?)rVFt#H4nFSmakJ6xe+JMfm@=1GcoGB?kC?6(Oh;x! z+$p1c<`SP1W?odn%8+oUVvealqW;8?{0RBZIf+8YCAihC9f8Hj;f~#sRCZlZ*}VlS z`?S)n)CAQ&LaygT5k6Fu=ncZ~3#UVmx;Wwvhrfq38c?5d>Ui`uobCXR9WNq)eb;t8 z^<7Q_9}7UocS(5{D^6kiFbqJA1DrV56#{`cc3Yg#cRag6BA3yS2doRGmNg+fl~v4? zcjIjZ9UbGc^3k&1aq<9jHYHbg$Cwd5W&XbOTM*3CFZ%}Rsv)%xDe*=%a^_snfLYe% zsV+(W3;Ke@QC%8!d#utR9y#n)w7f5=$UP9m>E`*M; zpTt;MbC9xTB-M;pKfS)n6Umgp_FwC0J+3kB4q6c83#goeM8c1CC(;MGtyMnOjK|g0W}l=y%*3%`3QCpH?n>gtc!bJC-k?c zN=hZauEnOwmN9DccWeflzT;HamMVR)eFa)5}7cCy$6XG=^;@??ls?iBTC3Lk?bBu{18JFWAIGEY_6f@O z5_ffUzt=o%zG(MT_Voqm^gv*0WMp@E$>LdwEpKY3nHWyz@h8#riYz zw)%Sp?Ie*`eJ%DL$~7{eL7GXGd>^oh-&`HeO_iQ7tv=>SPlTDVYGrfn z$vE&vgo!Enu^j3vknv~Ya)8BOOW|t&WY8}7p9JIfl;~!DI#Cu$8N7ZRMN*gV2P19zza@5d{5nWGi?X!geGor2-e${+(y}C{ oWi66gR%$w2llk}fQF`5fp*rxDhAnO|>fX?-rKM`Ab2LZjU*9$s%K!iX diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Folder.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Folder.php deleted file mode 100644 index 2bb7fd7317b4..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Folder.php +++ /dev/null @@ -1,30 +0,0 @@ -internalAddGeneratedFile( - ' -· -2google/cloud/securitycenter/v1p1beta1/folder.proto%google.cloud.securitycenter.v1p1beta1"G -Folder -resource_folder ( $ -resource_folder_display_name ( Bˆ -)com.google.cloud.securitycenter.v1p1beta1B FolderProtoPZQcloud.google.com/go/securitycenter/apiv1p1beta1/securitycenterpb;securitycenterpbª%Google.Cloud.SecurityCenter.V1P1Beta1Ê%Google\\Cloud\\SecurityCenter\\V1p1beta1ê(Google::Cloud::SecurityCenter::V1p1Beta1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/NotificationConfig.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/NotificationConfig.php deleted file mode 100644 index 2807cc138addda2f984d3ab834e2d3279eb040a7..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1738 zcmbtU-EPw`6kfYAm^Zd5NT>{uys>GW1PL98i;OY)PcP^SD?^}2Rq8sOQ5HvzQ>mMB z$;UT5`BcBo8N7&(* zX}z4AYh!NaG>39x5oB^gofe{wMY^i21%P9oV$U@ZhSf<p_}+%&2Z)+mOs#?ct8 zahz-93L)$s0LV5y57tNEixM5211KKXZ`%YxkBiC(ZW6CW9KwldlQS{&KD12R!vbbH z*YX_{b_>G|hYrHo9T;JTxtlH(B<;gNpN)_=!I@DD2X{={C}9sV;&RFwB30MBm?vz9 zk?c-fHiRP<%tk%x`c#wqkTV~TR)>&b?lWgk_8kHQ$(L~ni+PtA6@u+f0iT#XLYb}) zry7D>we>xY5Bt(xl8Ps#&cZ&o!Pi^h;6F8^Y()U76rDOQIyDj9 z+P%1r=@N~_GeoM}_&x`eY0)T4U@nwnCIwU31?3J{?8K)igpf(g;70&(PsqE)`!3GR zirDgQQN30}>U2f59AY&El=1>B3AK8DyTz$XP-ZSHSAf6s55fItA+93E@lmW<7#%%S4F!4$s_>TW5deXB7-qJK5Tm>HW@c?2 ztV{%zWiW3MTik|-&5h?^VL0p>xLZCh*PE^8r$)K;p?=gT7i*PTxwJZ?EP|VrTD?@O zS65SdaFIU)PbZEzVmsksnpUMkS=V&PnKT?vJ0JZG#@r|xL8Le%9uhMZ6js1(8SlrD z!jClA5!_#oyGH8syGWx0eTY-*(n*^XgCwGzSaaKZ*jcs|ol?uuW z@gN*{6b`%q7rdWM+9CzWDe{hgGxPU<=EW;@qR=B4Gr=@5EQH_;%n1XfrIA!75M)ur zG*CHLJYm`e7){`4atv=q2geWW)l_DhG7Pblal$;B$Sm|yMl;RL8D+vS?Va{iFJOlB zJRuE_I3L_Nm6Dxmt&($(7ayAFH8hw zP8UjM9=oNam1zKVq0?MBtD1k1w=PKHk621IS4Qfo4aGQSrqMe;ak^F79LFPY${I1g zROA4R&e(Ex0L@IMMZc&!2P~R@{$I=J?{g7y5o3Jb>N)uzc<)(dk1K(NbWdLLN~qm1 zY;@VTW^jlGGlTp9Ya1-5R zr*>qAzgnnkM}EEg)7GbVrJQxia_+_Q;u0W=H~L=qrh@+JOQ_)M#`d_Fe7Bfh($ diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/OrganizationSettings.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/OrganizationSettings.php deleted file mode 100644 index 4eba6944f9471ad3f772bc5b91757c87b25bb60a..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1581 zcmb_c-A>yu7+nh*n_;NR5JFrakAW!Cma6P7j7_C2RV8S<6(%-CixS5TMj?)D2MJKG z_ZYjM_9S~0UST)0oi?_hJgiZcvjMg>JQ zgkI9?VFnSsh)IZ<31O`bTkT_5uQiWf$fKMl3}Fiflm;O#p^zqiiDQ&7BCZgQ1ZJhn za$NSXaLXmi0yiSpt{^mWI2M9L0XH=p0FirvdF&z#8=d_lneV&8wHq4Pt}0-=I|gij zDtF5J3V0U)6uO+l_6R|DfDdi}luw*^AwiG}$&TO#;SPz2AZ|#mW#N0U=Y||hp!>PK zBtl9tR0rA-!o_WvVyfJYn94@&!J*QQ>YePH-BiU#ZfMsqM~uXRvW`r(tN@FwfX=D}S3RGz5S3wi7Owi1Ayi3z9ec4NX#X*H#3eKpE-8@*!Qn;qaxBfKHm36q)VgL@f4p$Lor{ANkFOHZW5gm^n1Cs&+;*Gq7L7 zJbU1DnboD4w)DDziQeXmDWqj-Ov@SvwX7`Fd#tVX%~p12U!?{z;x~Ww8l9QiLLc-2 F_yd*r7~TK? diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Resource.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Resource.php deleted file mode 100644 index ff0c76c38b4c..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Resource.php +++ /dev/null @@ -1,36 +0,0 @@ -internalAddGeneratedFile( - ' -â -4google/cloud/securitycenter/v1p1beta1/resource.proto%google.cloud.securitycenter.v1p1beta12google/cloud/securitycenter/v1p1beta1/folder.proto"¹ -Resource -name (  -project (  -project_display_name (  -parent (  -parent_display_name ( C -folders ( 2-.google.cloud.securitycenter.v1p1beta1.FolderBàABŠ -)com.google.cloud.securitycenter.v1p1beta1B ResourceProtoPZQcloud.google.com/go/securitycenter/apiv1p1beta1/securitycenterpb;securitycenterpbª%Google.Cloud.SecurityCenter.V1P1Beta1Ê%Google\\Cloud\\SecurityCenter\\V1p1beta1ê(Google::Cloud::SecurityCenter::V1p1beta1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/RunAssetDiscoveryResponse.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/RunAssetDiscoveryResponse.php deleted file mode 100644 index 25ba78f13571ae848ed9c5e3b62900f9d25b06aa..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1287 zcmb`H(T>tU6ov&|qhs8xB%AEsjq7fI+UdYfQaa6ay2)yI zAs@vjF<$rr-Z<0J?y@V!3%P+Q=X~d!f6m|6Z=>@FJcB(F67CA(L+=uba{?pI1j8(V zUNWB(4l!FsG$34u&=|qtXaY^6KY1!sW0r7C5L_^}2uKYFEb(hG!3n405|dC6Uc0DA zb&m+QUgJqPbK{tZnNMTPE(pJzaS}%?jESBW1t4^n@`;NH>{;!BO!HmgI=z(dbQIsQ zH~7xSx>av0eggm;NIo1VVM~=U@+#wX5%2{-`H2!Qpcux&74qwt#xojHLEV6UmLfFa z+znzPX}4qNNr(kyAyf&Y5EHEmGp33?j+hj!3G;R>rK8l)=_?^ZH*gFRV@@N%xFtgo zS`bmFubybtby*{{+>y0(D!_D$l_Ke=XcWS&|=}9p>b8mF2zbxw1zCu#;u&gD3W+ zH8E$?p>3I+ez$KLdv_|2!NbmIV7)gd@>r_u0$@)qb8MT2JeSpZVvYy>q0BV)?zVrG zKvkMDulIL(tkS0sSwucKThinternalAddGeneratedFile( - ' -È -:google/cloud/securitycenter/v1p1beta1/security_marks.proto%google.cloud.securitycenter.v1p1beta1"Ü - SecurityMarks -name ( N -marks ( 2?.google.cloud.securitycenter.v1p1beta1.SecurityMarks.MarksEntry -canonical_name ( , - -MarksEntry -key (  -value ( :8:¦êA¢ -+securitycenter.googleapis.com/SecurityMarks9organizations/{organization}/assets/{asset}/securityMarksNorganizations/{organization}/sources/{source}/findings/{finding}/securityMarks-folders/{folder}/assets/{asset}/securityMarks/projects/{project}/assets/{asset}/securityMarksBfolders/{folder}/sources/{source}/findings/{finding}/securityMarksDprojects/{project}/sources/{source}/findings/{finding}/securityMarksBû -)com.google.cloud.securitycenter.v1p1beta1PZQcloud.google.com/go/securitycenter/apiv1p1beta1/securitycenterpb;securitycenterpbª%Google.Cloud.SecurityCenter.V1P1Beta1Ê%Google\\Cloud\\SecurityCenter\\V1p1beta1ê(Google::Cloud::SecurityCenter::V1p1beta1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/SecuritycenterService.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/SecuritycenterService.php deleted file mode 100644 index a32e77ed09b41f6d57ec66f5badec3bf9d3aa8da..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 15636 zcmdrTTWlOxwX=?s_&N{w+HPF;k?k~ToYdK^H-#qSJT!iX#*P~&DVUYEw zGn?X87KloGAdrgsK|er%K$QUT5<)@(@sa?kKOiU)G9Oe>35id{2ecq@?rZkW&g|}t z>wG{yVtejA&wJi;=lrGmtvY%%J8#;iYxrg*ySAD2Z<*P;>-bLDsb$w1)vD=c%g#pK zs+n#so1M9uUAlTbJ3Djv`Xd19ISsdLYT0$iS+AM-a?NQ}@}604xR$?JHf`T@^LHld z6Kke#OtdVNJkz~nmCYO_hmdV-m|oo|o7ws0sYL*&7`{=QrTgVtHbU zV4g&%Tr)f`8{V+O2%wix7XH;6Yc;E!^?bvJAIB`OWZ9N)88z!g5dA{7YScUvFh%!P z8+O^Z96L(@uG(dD>|~bVBzuq59Z=PUtYCGSXb&`3yiCNmjaqTW^vbSP_Z@c`wrbkC z=?6L|PsUDivILz~&5ki1H7&yAg{<#3OqqH%>zaPUwI?ax1i@DDTQRjFi%X7gRjo3p z$gvkq&okCdO>2tXq_P9t*BZ9&d8R*Od1dF0>26+w^LA`61qHos6?NNo$Qc4;a@Gjo zbj<>bOb0V(nYGH4dCRzCIc_>okdArBZt0IIFF6mLU8Xo^*%ixP-#vUztzxE7Q5W`P zL!5T(sLR0TO4ddesN3Ki~ zZZ4e4b3rN}T}Va>OrivN+4M^l5%fzgkNPa{k3PsT8FedfG($UIJtD1^Y5e93N2P@- z3DTuC9;Nw)`=t#)k~$Dyn&3-R#+Ir?Dpx4u9OO(gkSYtR9H@{Gh(=Bhb14}Nq`)9g zm&!Cgas+xZ1dbF0p%PX zS%sZr+=ByoIVjchE7aEU5rnuomaNK1hGOUe40s0Z;|n7_@U*{>;~2U)eU7s?MX;!E zDd;HUI-07501GVwoTUO3&=b`2gja4DHk6res~B>c#`mE9SJxB{2!Ttc~` z0x%K3qM$)0B2($^i#3JzGEboA(_c89kYmOV8`jL1*g#2 zjH2k&Dtd6<^rH*AP3L*^Fwl_=K-6i1(n3fgjoQ_dsL)xWIE3mF8UR}11J**=Q@Ne` zat7gf*J;#gx$X&uCtF{Ag#EDH41L?X6lh=q8yP<6*RaoscN4ZBkS3qn3cr zpaIgVL&zwJ05`ISdiedqu0#;Zi8>3PMtu-_DkTz?MtbS)(a7$gRKXabI(TczcW#^Z z$UYKP@V%&yKJ%cH9@!6%dextR>x8txIz4;^4G7LjA<(G#9#~}$1fhZ;+PU(`QLNV} zXqa~r;ra`mct3&;+vZ38k|Y2LfPF+LA9~7KiAq3J)~kLpgN7(A9`%Bgd~Z=X;ZcT8 zg`Ht1$>L6)on?oUPk59+Q_ygWBL3$N6U?z+Hk_Ma#V#ome9IIDIF;T2bISpeS=)Cv z@j=vEb{dedi81z!UPgyocl4v4+vX;V#P~Ssy<^lGCXfF22@V1;y-8NJ%vnYKtb!iC zVtFyaH!#fI%eG<5pru3D$%)(as;@!`(3U4|BhR8CJ6fv>o$owDLwOT%X3D6#i7;V` zMf5;9ZM+sItEIXsgapD~)kcFM(p(1@(LR>th1luRe0x#9nL+mwf_E|1450mv3xk~? z)r5oYT?$P(QoE9-j#Sw+%fvNQCFP2){}VLYKMtm>$t17r|w zmddvbdz}TTLxr0OafEoGW8R29aw`P=G{vr7K>gC6;Bb3yEZta{of)_X_n}^WW(Iy$ za6j62ZFceMP52{2_UO~sFW;OU=uy9uVZL{Fv-SU#H+*9+8X~9ER2lb&4K!RM{!nGp zj8>0WN?`%5xTy_D5AU{D{Av&L_!g3vnk_JCty8zaxE|{ptGlZi**~z2_KSv@x3|yk zGBqfw>EwVk6Fs9pR?vR&1RszaB0Pi+K!x(WS@uh`tz-qlgJ?)Rg<)U4W^A%mR$>pL zem2Ws4@utW!w;ZA{xAeVD%U;?S+hzfW8Mg&9YWHqIY*(?#r6ROqR8}uzBErm%0bk3 zV@dp(X$G4fIoRw`-&D|j(1mhCqM@qU+sWFGBTr|K}%x@Gl%9-I;3Fvz|p}l9&A>p%ZsLj=u z)F)SDq&s5~L+P8wi3|TcgANJ0)AYs#{-uHr$a71qB|LT+i0foD-MOewZ|etHOdn_2 zf0{oQ32A`|I3Vowv}dHjP68ex(|qZFP?b*NDULMuCu zWa?|mwtkFjC>YO=$MpN#`Y7KPvq-hIq(0SMTU&Vw753__~!~5X*U*6th#mx zgzBOL8~OrTo!i!FML;DxcPbbd8q(r$sI#)AoyDPu6KiR5%oQ(HwlI`KeIO>w zt@x?rf-wjoO3GZJ$;_X|p%f9zeA5*1>lr@LWwRWd)K=&eSj>NDl{=a=JBC16tE_%e zp}zE*qCO!zQ@aF5hcTYEPF~)C1Fh!OQ!!w??IAg#72t{3M9TXvnnPP4@Sij2AmyB= zP!A_HxDb>$;`2#ugNP_dLLW&dKKU(*|DXG-(0Z77bVLLfG!kg|ltEa$_qw{5c5f zgc{2#UgDrG!3g1!2K5jq7wDB1d-=E$&Q0w^;_0cKj|5f{G&-we__2Rp?1TV?iGf z=}F{8q02Ts$%mjC5PiouyVgf_rH6|Fv87XM0y+vx&(iH?`tbd4rF6+0G(- zug1R<{##~@q0}^rQ`5poH7(e>e9yA7winLDcg~y$K8PA;U&%@z)sl+bD#v_KOLwxb KTDQ;^LjMIoMP`ox diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Source.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Source.php deleted file mode 100644 index 0132c372a211..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V1P1Beta1/Source.php +++ /dev/null @@ -1,34 +0,0 @@ -internalAddGeneratedFile( - ' -á -2google/cloud/securitycenter/v1p1beta1/source.proto%google.cloud.securitycenter.v1p1beta1"ý -Source -name (  - display_name (  - description (  -canonical_name ( :¡êA -$securitycenter.googleapis.com/Source-organizations/{organization}/sources/{source}!folders/{folder}/sources/{source}#projects/{project}/sources/{source}Bû -)com.google.cloud.securitycenter.v1p1beta1PZQcloud.google.com/go/securitycenter/apiv1p1beta1/securitycenterpb;securitycenterpbª%Google.Cloud.SecurityCenter.V1P1Beta1Ê%Google\\Cloud\\SecurityCenter\\V1p1beta1ê(Google::Cloud::SecurityCenter::V1p1beta1bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset.php deleted file mode 100644 index 0f552c3e99a7..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset.php +++ /dev/null @@ -1,412 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.Asset - */ -class Asset extends \Google\Protobuf\Internal\Message -{ - /** - * The relative resource name of this asset. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/assets/{asset_id}". - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Security Command Center managed properties. These properties are managed by - * Security Command Center and cannot be modified by the user. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Asset.SecurityCenterProperties security_center_properties = 2; - */ - protected $security_center_properties = null; - /** - * Resource managed properties. These properties are managed and defined by - * the Google Cloud resource and cannot be modified by the user. - * - * Generated from protobuf field map resource_properties = 7; - */ - private $resource_properties; - /** - * User specified security marks. These marks are entirely managed by the user - * and come from the SecurityMarks resource that belongs to the asset. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.SecurityMarks security_marks = 8; - */ - protected $security_marks = null; - /** - * The time at which the asset was created in Security Command Center. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 9; - */ - protected $create_time = null; - /** - * The time at which the asset was last updated or added in Cloud SCC. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 10; - */ - protected $update_time = null; - /** - * Cloud IAM Policy information associated with the Google Cloud resource - * described by the Security Command Center asset. This information is managed - * and defined by the Google Cloud resource and cannot be modified by the - * user. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Asset.IamPolicy iam_policy = 11; - */ - protected $iam_policy = null; - /** - * The canonical name of the resource. It's either - * "organizations/{organization_id}/assets/{asset_id}", - * "folders/{folder_id}/assets/{asset_id}" or - * "projects/{project_number}/assets/{asset_id}", depending on the closest CRM - * ancestor of the resource. - * - * Generated from protobuf field string canonical_name = 13; - */ - protected $canonical_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The relative resource name of this asset. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/assets/{asset_id}". - * @type \Google\Cloud\SecurityCenter\V1p1beta1\Asset\SecurityCenterProperties $security_center_properties - * Security Command Center managed properties. These properties are managed by - * Security Command Center and cannot be modified by the user. - * @type array|\Google\Protobuf\Internal\MapField $resource_properties - * Resource managed properties. These properties are managed and defined by - * the Google Cloud resource and cannot be modified by the user. - * @type \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks $security_marks - * User specified security marks. These marks are entirely managed by the user - * and come from the SecurityMarks resource that belongs to the asset. - * @type \Google\Protobuf\Timestamp $create_time - * The time at which the asset was created in Security Command Center. - * @type \Google\Protobuf\Timestamp $update_time - * The time at which the asset was last updated or added in Cloud SCC. - * @type \Google\Cloud\SecurityCenter\V1p1beta1\Asset\IamPolicy $iam_policy - * Cloud IAM Policy information associated with the Google Cloud resource - * described by the Security Command Center asset. This information is managed - * and defined by the Google Cloud resource and cannot be modified by the - * user. - * @type string $canonical_name - * The canonical name of the resource. It's either - * "organizations/{organization_id}/assets/{asset_id}", - * "folders/{folder_id}/assets/{asset_id}" or - * "projects/{project_number}/assets/{asset_id}", depending on the closest CRM - * ancestor of the resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\Asset::initOnce(); - parent::__construct($data); - } - - /** - * The relative resource name of this asset. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/assets/{asset_id}". - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The relative resource name of this asset. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/assets/{asset_id}". - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Security Command Center managed properties. These properties are managed by - * Security Command Center and cannot be modified by the user. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Asset.SecurityCenterProperties security_center_properties = 2; - * @return \Google\Cloud\SecurityCenter\V1p1beta1\Asset\SecurityCenterProperties|null - */ - public function getSecurityCenterProperties() - { - return $this->security_center_properties; - } - - public function hasSecurityCenterProperties() - { - return isset($this->security_center_properties); - } - - public function clearSecurityCenterProperties() - { - unset($this->security_center_properties); - } - - /** - * Security Command Center managed properties. These properties are managed by - * Security Command Center and cannot be modified by the user. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Asset.SecurityCenterProperties security_center_properties = 2; - * @param \Google\Cloud\SecurityCenter\V1p1beta1\Asset\SecurityCenterProperties $var - * @return $this - */ - public function setSecurityCenterProperties($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Asset\SecurityCenterProperties::class); - $this->security_center_properties = $var; - - return $this; - } - - /** - * Resource managed properties. These properties are managed and defined by - * the Google Cloud resource and cannot be modified by the user. - * - * Generated from protobuf field map resource_properties = 7; - * @return \Google\Protobuf\Internal\MapField - */ - public function getResourceProperties() - { - return $this->resource_properties; - } - - /** - * Resource managed properties. These properties are managed and defined by - * the Google Cloud resource and cannot be modified by the user. - * - * Generated from protobuf field map resource_properties = 7; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setResourceProperties($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Value::class); - $this->resource_properties = $arr; - - return $this; - } - - /** - * User specified security marks. These marks are entirely managed by the user - * and come from the SecurityMarks resource that belongs to the asset. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.SecurityMarks security_marks = 8; - * @return \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks|null - */ - public function getSecurityMarks() - { - return $this->security_marks; - } - - public function hasSecurityMarks() - { - return isset($this->security_marks); - } - - public function clearSecurityMarks() - { - unset($this->security_marks); - } - - /** - * User specified security marks. These marks are entirely managed by the user - * and come from the SecurityMarks resource that belongs to the asset. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.SecurityMarks security_marks = 8; - * @param \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks $var - * @return $this - */ - public function setSecurityMarks($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks::class); - $this->security_marks = $var; - - return $this; - } - - /** - * The time at which the asset was created in Security Command Center. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 9; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * The time at which the asset was created in Security Command Center. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 9; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * The time at which the asset was last updated or added in Cloud SCC. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 10; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * The time at which the asset was last updated or added in Cloud SCC. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 10; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Cloud IAM Policy information associated with the Google Cloud resource - * described by the Security Command Center asset. This information is managed - * and defined by the Google Cloud resource and cannot be modified by the - * user. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Asset.IamPolicy iam_policy = 11; - * @return \Google\Cloud\SecurityCenter\V1p1beta1\Asset\IamPolicy|null - */ - public function getIamPolicy() - { - return $this->iam_policy; - } - - public function hasIamPolicy() - { - return isset($this->iam_policy); - } - - public function clearIamPolicy() - { - unset($this->iam_policy); - } - - /** - * Cloud IAM Policy information associated with the Google Cloud resource - * described by the Security Command Center asset. This information is managed - * and defined by the Google Cloud resource and cannot be modified by the - * user. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Asset.IamPolicy iam_policy = 11; - * @param \Google\Cloud\SecurityCenter\V1p1beta1\Asset\IamPolicy $var - * @return $this - */ - public function setIamPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Asset\IamPolicy::class); - $this->iam_policy = $var; - - return $this; - } - - /** - * The canonical name of the resource. It's either - * "organizations/{organization_id}/assets/{asset_id}", - * "folders/{folder_id}/assets/{asset_id}" or - * "projects/{project_number}/assets/{asset_id}", depending on the closest CRM - * ancestor of the resource. - * - * Generated from protobuf field string canonical_name = 13; - * @return string - */ - public function getCanonicalName() - { - return $this->canonical_name; - } - - /** - * The canonical name of the resource. It's either - * "organizations/{organization_id}/assets/{asset_id}", - * "folders/{folder_id}/assets/{asset_id}" or - * "projects/{project_number}/assets/{asset_id}", depending on the closest CRM - * ancestor of the resource. - * - * Generated from protobuf field string canonical_name = 13; - * @param string $var - * @return $this - */ - public function setCanonicalName($var) - { - GPBUtil::checkString($var, True); - $this->canonical_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset/IamPolicy.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset/IamPolicy.php deleted file mode 100644 index c39f062ad72f..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset/IamPolicy.php +++ /dev/null @@ -1,81 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.Asset.IamPolicy - */ -class IamPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * The JSON representation of the Policy associated with the asset. - * See https://cloud.google.com/iam/docs/reference/rest/v1/Policy for - * format details. - * - * Generated from protobuf field string policy_blob = 1; - */ - protected $policy_blob = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $policy_blob - * The JSON representation of the Policy associated with the asset. - * See https://cloud.google.com/iam/docs/reference/rest/v1/Policy for - * format details. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\Asset::initOnce(); - parent::__construct($data); - } - - /** - * The JSON representation of the Policy associated with the asset. - * See https://cloud.google.com/iam/docs/reference/rest/v1/Policy for - * format details. - * - * Generated from protobuf field string policy_blob = 1; - * @return string - */ - public function getPolicyBlob() - { - return $this->policy_blob; - } - - /** - * The JSON representation of the Policy associated with the asset. - * See https://cloud.google.com/iam/docs/reference/rest/v1/Policy for - * format details. - * - * Generated from protobuf field string policy_blob = 1; - * @param string $var - * @return $this - */ - public function setPolicyBlob($var) - { - GPBUtil::checkString($var, True); - $this->policy_blob = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(IamPolicy::class, \Google\Cloud\SecurityCenter\V1p1beta1\Asset_IamPolicy::class); - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset/SecurityCenterProperties.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset/SecurityCenterProperties.php deleted file mode 100644 index 45ece235170d..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Asset/SecurityCenterProperties.php +++ /dev/null @@ -1,379 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.Asset.SecurityCenterProperties - */ -class SecurityCenterProperties extends \Google\Protobuf\Internal\Message -{ - /** - * The full resource name of the Google Cloud resource this asset - * represents. This field is immutable after create time. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_name = 1; - */ - protected $resource_name = ''; - /** - * The type of the Google Cloud resource. Examples include: APPLICATION, - * PROJECT, and ORGANIZATION. This is a case insensitive field defined by - * Security Command Center and/or the producer of the resource and is - * immutable after create time. - * - * Generated from protobuf field string resource_type = 2; - */ - protected $resource_type = ''; - /** - * The full resource name of the immediate parent of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_parent = 3; - */ - protected $resource_parent = ''; - /** - * The full resource name of the project the resource belongs to. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_project = 4; - */ - protected $resource_project = ''; - /** - * Owners of the Google Cloud resource. - * - * Generated from protobuf field repeated string resource_owners = 5; - */ - private $resource_owners; - /** - * The user defined display name for this resource. - * - * Generated from protobuf field string resource_display_name = 6; - */ - protected $resource_display_name = ''; - /** - * The user defined display name for the parent of this resource. - * - * Generated from protobuf field string resource_parent_display_name = 7; - */ - protected $resource_parent_display_name = ''; - /** - * The user defined display name for the project of this resource. - * - * Generated from protobuf field string resource_project_display_name = 8; - */ - protected $resource_project_display_name = ''; - /** - * Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is the - * folder directly under the Organization. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Folder folders = 10; - */ - private $folders; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $resource_name - * The full resource name of the Google Cloud resource this asset - * represents. This field is immutable after create time. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * @type string $resource_type - * The type of the Google Cloud resource. Examples include: APPLICATION, - * PROJECT, and ORGANIZATION. This is a case insensitive field defined by - * Security Command Center and/or the producer of the resource and is - * immutable after create time. - * @type string $resource_parent - * The full resource name of the immediate parent of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * @type string $resource_project - * The full resource name of the project the resource belongs to. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * @type array|\Google\Protobuf\Internal\RepeatedField $resource_owners - * Owners of the Google Cloud resource. - * @type string $resource_display_name - * The user defined display name for this resource. - * @type string $resource_parent_display_name - * The user defined display name for the parent of this resource. - * @type string $resource_project_display_name - * The user defined display name for the project of this resource. - * @type array<\Google\Cloud\SecurityCenter\V1p1beta1\Folder>|\Google\Protobuf\Internal\RepeatedField $folders - * Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is the - * folder directly under the Organization. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\Asset::initOnce(); - parent::__construct($data); - } - - /** - * The full resource name of the Google Cloud resource this asset - * represents. This field is immutable after create time. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_name = 1; - * @return string - */ - public function getResourceName() - { - return $this->resource_name; - } - - /** - * The full resource name of the Google Cloud resource this asset - * represents. This field is immutable after create time. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_name = 1; - * @param string $var - * @return $this - */ - public function setResourceName($var) - { - GPBUtil::checkString($var, True); - $this->resource_name = $var; - - return $this; - } - - /** - * The type of the Google Cloud resource. Examples include: APPLICATION, - * PROJECT, and ORGANIZATION. This is a case insensitive field defined by - * Security Command Center and/or the producer of the resource and is - * immutable after create time. - * - * Generated from protobuf field string resource_type = 2; - * @return string - */ - public function getResourceType() - { - return $this->resource_type; - } - - /** - * The type of the Google Cloud resource. Examples include: APPLICATION, - * PROJECT, and ORGANIZATION. This is a case insensitive field defined by - * Security Command Center and/or the producer of the resource and is - * immutable after create time. - * - * Generated from protobuf field string resource_type = 2; - * @param string $var - * @return $this - */ - public function setResourceType($var) - { - GPBUtil::checkString($var, True); - $this->resource_type = $var; - - return $this; - } - - /** - * The full resource name of the immediate parent of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_parent = 3; - * @return string - */ - public function getResourceParent() - { - return $this->resource_parent; - } - - /** - * The full resource name of the immediate parent of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_parent = 3; - * @param string $var - * @return $this - */ - public function setResourceParent($var) - { - GPBUtil::checkString($var, True); - $this->resource_parent = $var; - - return $this; - } - - /** - * The full resource name of the project the resource belongs to. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_project = 4; - * @return string - */ - public function getResourceProject() - { - return $this->resource_project; - } - - /** - * The full resource name of the project the resource belongs to. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_project = 4; - * @param string $var - * @return $this - */ - public function setResourceProject($var) - { - GPBUtil::checkString($var, True); - $this->resource_project = $var; - - return $this; - } - - /** - * Owners of the Google Cloud resource. - * - * Generated from protobuf field repeated string resource_owners = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getResourceOwners() - { - return $this->resource_owners; - } - - /** - * Owners of the Google Cloud resource. - * - * Generated from protobuf field repeated string resource_owners = 5; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setResourceOwners($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->resource_owners = $arr; - - return $this; - } - - /** - * The user defined display name for this resource. - * - * Generated from protobuf field string resource_display_name = 6; - * @return string - */ - public function getResourceDisplayName() - { - return $this->resource_display_name; - } - - /** - * The user defined display name for this resource. - * - * Generated from protobuf field string resource_display_name = 6; - * @param string $var - * @return $this - */ - public function setResourceDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->resource_display_name = $var; - - return $this; - } - - /** - * The user defined display name for the parent of this resource. - * - * Generated from protobuf field string resource_parent_display_name = 7; - * @return string - */ - public function getResourceParentDisplayName() - { - return $this->resource_parent_display_name; - } - - /** - * The user defined display name for the parent of this resource. - * - * Generated from protobuf field string resource_parent_display_name = 7; - * @param string $var - * @return $this - */ - public function setResourceParentDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->resource_parent_display_name = $var; - - return $this; - } - - /** - * The user defined display name for the project of this resource. - * - * Generated from protobuf field string resource_project_display_name = 8; - * @return string - */ - public function getResourceProjectDisplayName() - { - return $this->resource_project_display_name; - } - - /** - * The user defined display name for the project of this resource. - * - * Generated from protobuf field string resource_project_display_name = 8; - * @param string $var - * @return $this - */ - public function setResourceProjectDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->resource_project_display_name = $var; - - return $this; - } - - /** - * Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is the - * folder directly under the Organization. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Folder folders = 10; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFolders() - { - return $this->folders; - } - - /** - * Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is the - * folder directly under the Organization. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Folder folders = 10; - * @param array<\Google\Cloud\SecurityCenter\V1p1beta1\Folder>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFolders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1p1beta1\Folder::class); - $this->folders = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SecurityCenterProperties::class, \Google\Cloud\SecurityCenter\V1p1beta1\Asset_SecurityCenterProperties::class); - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateFindingRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateFindingRequest.php deleted file mode 100644 index 8e7c48078d6b..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateFindingRequest.php +++ /dev/null @@ -1,153 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.CreateFindingRequest - */ -class CreateFindingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the new finding's parent. Its format should be - * "organizations/[organization_id]/sources/[source_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. Unique identifier provided by the client within the parent scope. - * - * Generated from protobuf field string finding_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $finding_id = ''; - /** - * Required. The Finding being created. The name and security_marks will be ignored as - * they are both output only fields on this resource. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $finding = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the new finding's parent. Its format should be - * "organizations/[organization_id]/sources/[source_id]". - * @type string $finding_id - * Required. Unique identifier provided by the client within the parent scope. - * @type \Google\Cloud\SecurityCenter\V1p1beta1\Finding $finding - * Required. The Finding being created. The name and security_marks will be ignored as - * they are both output only fields on this resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the new finding's parent. Its format should be - * "organizations/[organization_id]/sources/[source_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the new finding's parent. Its format should be - * "organizations/[organization_id]/sources/[source_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. Unique identifier provided by the client within the parent scope. - * - * Generated from protobuf field string finding_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getFindingId() - { - return $this->finding_id; - } - - /** - * Required. Unique identifier provided by the client within the parent scope. - * - * Generated from protobuf field string finding_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setFindingId($var) - { - GPBUtil::checkString($var, True); - $this->finding_id = $var; - - return $this; - } - - /** - * Required. The Finding being created. The name and security_marks will be ignored as - * they are both output only fields on this resource. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1p1beta1\Finding|null - */ - public function getFinding() - { - return $this->finding; - } - - public function hasFinding() - { - return isset($this->finding); - } - - public function clearFinding() - { - unset($this->finding); - } - - /** - * Required. The Finding being created. The name and security_marks will be ignored as - * they are both output only fields on this resource. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1p1beta1\Finding $var - * @return $this - */ - public function setFinding($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Finding::class); - $this->finding = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateNotificationConfigRequest.php deleted file mode 100644 index 350e616be37a..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateNotificationConfigRequest.php +++ /dev/null @@ -1,161 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.CreateNotificationConfigRequest - */ -class CreateNotificationConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the new notification config's parent. Its format is - * "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must be between 1 and 128 characters, and contains alphanumeric - * characters, underscores or hyphens only. - * - * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $config_id = ''; - /** - * Required. The notification config being created. The name and the service account - * will be ignored as they are both output only fields on this resource. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig notification_config = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $notification_config = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the new notification config's parent. Its format is - * "organizations/[organization_id]". - * @type string $config_id - * Required. Unique identifier provided by the client within the parent scope. - * It must be between 1 and 128 characters, and contains alphanumeric - * characters, underscores or hyphens only. - * @type \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig $notification_config - * Required. The notification config being created. The name and the service account - * will be ignored as they are both output only fields on this resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the new notification config's parent. Its format is - * "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the new notification config's parent. Its format is - * "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must be between 1 and 128 characters, and contains alphanumeric - * characters, underscores or hyphens only. - * - * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getConfigId() - { - return $this->config_id; - } - - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must be between 1 and 128 characters, and contains alphanumeric - * characters, underscores or hyphens only. - * - * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setConfigId($var) - { - GPBUtil::checkString($var, True); - $this->config_id = $var; - - return $this; - } - - /** - * Required. The notification config being created. The name and the service account - * will be ignored as they are both output only fields on this resource. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig notification_config = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig|null - */ - public function getNotificationConfig() - { - return $this->notification_config; - } - - public function hasNotificationConfig() - { - return isset($this->notification_config); - } - - public function clearNotificationConfig() - { - unset($this->notification_config); - } - - /** - * Required. The notification config being created. The name and the service account - * will be ignored as they are both output only fields on this resource. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig notification_config = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig $var - * @return $this - */ - public function setNotificationConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig::class); - $this->notification_config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateSourceRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateSourceRequest.php deleted file mode 100644 index b9856ab4564a..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/CreateSourceRequest.php +++ /dev/null @@ -1,119 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.CreateSourceRequest - */ -class CreateSourceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the new source's parent. Its format should be - * "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The Source being created, only the display_name and description will be - * used. All other fields will be ignored. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Source source = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $source = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the new source's parent. Its format should be - * "organizations/[organization_id]". - * @type \Google\Cloud\SecurityCenter\V1p1beta1\Source $source - * Required. The Source being created, only the display_name and description will be - * used. All other fields will be ignored. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the new source's parent. Its format should be - * "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the new source's parent. Its format should be - * "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The Source being created, only the display_name and description will be - * used. All other fields will be ignored. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Source source = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1p1beta1\Source|null - */ - public function getSource() - { - return $this->source; - } - - public function hasSource() - { - return isset($this->source); - } - - public function clearSource() - { - unset($this->source); - } - - /** - * Required. The Source being created, only the display_name and description will be - * used. All other fields will be ignored. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Source source = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1p1beta1\Source $var - * @return $this - */ - public function setSource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Source::class); - $this->source = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/DeleteNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/DeleteNotificationConfigRequest.php deleted file mode 100644 index 677c4d41b9bf..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/DeleteNotificationConfigRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.DeleteNotificationConfigRequest - */ -class DeleteNotificationConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the notification config to delete. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the notification config to delete. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the notification config to delete. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the notification config to delete. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding.php deleted file mode 100644 index 572c4c7113fd..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding.php +++ /dev/null @@ -1,603 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.Finding - */ -class Finding extends \Google\Protobuf\Internal\Message -{ - /** - * The relative resource name of this finding. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}" - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The relative resource name of the source the finding belongs to. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * This field is immutable after creation time. - * For example: - * "organizations/{organization_id}/sources/{source_id}" - * - * Generated from protobuf field string parent = 2; - */ - protected $parent = ''; - /** - * For findings on Google Cloud resources, the full resource - * name of the Google Cloud resource this finding is for. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * When the finding is for a non-Google Cloud resource, the resourceName can - * be a customer or partner defined string. This field is immutable after - * creation time. - * - * Generated from protobuf field string resource_name = 3; - */ - protected $resource_name = ''; - /** - * The state of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding.State state = 4; - */ - protected $state = 0; - /** - * The additional taxonomy group within findings from a given source. - * This field is immutable after creation time. - * Example: "XSS_FLASH_INJECTION" - * - * Generated from protobuf field string category = 5; - */ - protected $category = ''; - /** - * The URI that, if available, points to a web page outside of Security - * Command Center where additional information about the finding can be found. - * This field is guaranteed to be either empty or a well formed URL. - * - * Generated from protobuf field string external_uri = 6; - */ - protected $external_uri = ''; - /** - * Source specific properties. These properties are managed by the source - * that writes the finding. The key names in the source_properties map must be - * between 1 and 255 characters, and must start with a letter and contain - * alphanumeric characters or underscores only. - * - * Generated from protobuf field map source_properties = 7; - */ - private $source_properties; - /** - * Output only. User specified security marks. These marks are entirely - * managed by the user and come from the SecurityMarks resource that belongs - * to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.SecurityMarks security_marks = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $security_marks = null; - /** - * The time at which the event took place, or when an update to the finding - * occurred. For example, if the finding represents an open firewall it would - * capture the time the detector believes the firewall became open. The - * accuracy is determined by the detector. If the finding were to be resolved - * afterward, this time would reflect when the finding was resolved. Must not - * be set to a value greater than the current timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp event_time = 9; - */ - protected $event_time = null; - /** - * The time at which the finding was created in Security Command Center. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 10; - */ - protected $create_time = null; - /** - * The severity of the finding. This field is managed by the source that - * writes the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding.Severity severity = 13; - */ - protected $severity = 0; - /** - * The canonical name of the finding. It's either - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}" or - * "projects/{project_number}/sources/{source_id}/findings/{finding_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * - * Generated from protobuf field string canonical_name = 14; - */ - protected $canonical_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The relative resource name of this finding. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}" - * @type string $parent - * The relative resource name of the source the finding belongs to. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * This field is immutable after creation time. - * For example: - * "organizations/{organization_id}/sources/{source_id}" - * @type string $resource_name - * For findings on Google Cloud resources, the full resource - * name of the Google Cloud resource this finding is for. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * When the finding is for a non-Google Cloud resource, the resourceName can - * be a customer or partner defined string. This field is immutable after - * creation time. - * @type int $state - * The state of the finding. - * @type string $category - * The additional taxonomy group within findings from a given source. - * This field is immutable after creation time. - * Example: "XSS_FLASH_INJECTION" - * @type string $external_uri - * The URI that, if available, points to a web page outside of Security - * Command Center where additional information about the finding can be found. - * This field is guaranteed to be either empty or a well formed URL. - * @type array|\Google\Protobuf\Internal\MapField $source_properties - * Source specific properties. These properties are managed by the source - * that writes the finding. The key names in the source_properties map must be - * between 1 and 255 characters, and must start with a letter and contain - * alphanumeric characters or underscores only. - * @type \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks $security_marks - * Output only. User specified security marks. These marks are entirely - * managed by the user and come from the SecurityMarks resource that belongs - * to the finding. - * @type \Google\Protobuf\Timestamp $event_time - * The time at which the event took place, or when an update to the finding - * occurred. For example, if the finding represents an open firewall it would - * capture the time the detector believes the firewall became open. The - * accuracy is determined by the detector. If the finding were to be resolved - * afterward, this time would reflect when the finding was resolved. Must not - * be set to a value greater than the current timestamp. - * @type \Google\Protobuf\Timestamp $create_time - * The time at which the finding was created in Security Command Center. - * @type int $severity - * The severity of the finding. This field is managed by the source that - * writes the finding. - * @type string $canonical_name - * The canonical name of the finding. It's either - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}" or - * "projects/{project_number}/sources/{source_id}/findings/{finding_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\Finding::initOnce(); - parent::__construct($data); - } - - /** - * The relative resource name of this finding. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}" - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The relative resource name of this finding. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}" - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The relative resource name of the source the finding belongs to. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * This field is immutable after creation time. - * For example: - * "organizations/{organization_id}/sources/{source_id}" - * - * Generated from protobuf field string parent = 2; - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * The relative resource name of the source the finding belongs to. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * This field is immutable after creation time. - * For example: - * "organizations/{organization_id}/sources/{source_id}" - * - * Generated from protobuf field string parent = 2; - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * For findings on Google Cloud resources, the full resource - * name of the Google Cloud resource this finding is for. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * When the finding is for a non-Google Cloud resource, the resourceName can - * be a customer or partner defined string. This field is immutable after - * creation time. - * - * Generated from protobuf field string resource_name = 3; - * @return string - */ - public function getResourceName() - { - return $this->resource_name; - } - - /** - * For findings on Google Cloud resources, the full resource - * name of the Google Cloud resource this finding is for. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * When the finding is for a non-Google Cloud resource, the resourceName can - * be a customer or partner defined string. This field is immutable after - * creation time. - * - * Generated from protobuf field string resource_name = 3; - * @param string $var - * @return $this - */ - public function setResourceName($var) - { - GPBUtil::checkString($var, True); - $this->resource_name = $var; - - return $this; - } - - /** - * The state of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding.State state = 4; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * The state of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding.State state = 4; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1p1beta1\Finding\State::class); - $this->state = $var; - - return $this; - } - - /** - * The additional taxonomy group within findings from a given source. - * This field is immutable after creation time. - * Example: "XSS_FLASH_INJECTION" - * - * Generated from protobuf field string category = 5; - * @return string - */ - public function getCategory() - { - return $this->category; - } - - /** - * The additional taxonomy group within findings from a given source. - * This field is immutable after creation time. - * Example: "XSS_FLASH_INJECTION" - * - * Generated from protobuf field string category = 5; - * @param string $var - * @return $this - */ - public function setCategory($var) - { - GPBUtil::checkString($var, True); - $this->category = $var; - - return $this; - } - - /** - * The URI that, if available, points to a web page outside of Security - * Command Center where additional information about the finding can be found. - * This field is guaranteed to be either empty or a well formed URL. - * - * Generated from protobuf field string external_uri = 6; - * @return string - */ - public function getExternalUri() - { - return $this->external_uri; - } - - /** - * The URI that, if available, points to a web page outside of Security - * Command Center where additional information about the finding can be found. - * This field is guaranteed to be either empty or a well formed URL. - * - * Generated from protobuf field string external_uri = 6; - * @param string $var - * @return $this - */ - public function setExternalUri($var) - { - GPBUtil::checkString($var, True); - $this->external_uri = $var; - - return $this; - } - - /** - * Source specific properties. These properties are managed by the source - * that writes the finding. The key names in the source_properties map must be - * between 1 and 255 characters, and must start with a letter and contain - * alphanumeric characters or underscores only. - * - * Generated from protobuf field map source_properties = 7; - * @return \Google\Protobuf\Internal\MapField - */ - public function getSourceProperties() - { - return $this->source_properties; - } - - /** - * Source specific properties. These properties are managed by the source - * that writes the finding. The key names in the source_properties map must be - * between 1 and 255 characters, and must start with a letter and contain - * alphanumeric characters or underscores only. - * - * Generated from protobuf field map source_properties = 7; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setSourceProperties($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Value::class); - $this->source_properties = $arr; - - return $this; - } - - /** - * Output only. User specified security marks. These marks are entirely - * managed by the user and come from the SecurityMarks resource that belongs - * to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.SecurityMarks security_marks = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks|null - */ - public function getSecurityMarks() - { - return $this->security_marks; - } - - public function hasSecurityMarks() - { - return isset($this->security_marks); - } - - public function clearSecurityMarks() - { - unset($this->security_marks); - } - - /** - * Output only. User specified security marks. These marks are entirely - * managed by the user and come from the SecurityMarks resource that belongs - * to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.SecurityMarks security_marks = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks $var - * @return $this - */ - public function setSecurityMarks($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks::class); - $this->security_marks = $var; - - return $this; - } - - /** - * The time at which the event took place, or when an update to the finding - * occurred. For example, if the finding represents an open firewall it would - * capture the time the detector believes the firewall became open. The - * accuracy is determined by the detector. If the finding were to be resolved - * afterward, this time would reflect when the finding was resolved. Must not - * be set to a value greater than the current timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp event_time = 9; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEventTime() - { - return $this->event_time; - } - - public function hasEventTime() - { - return isset($this->event_time); - } - - public function clearEventTime() - { - unset($this->event_time); - } - - /** - * The time at which the event took place, or when an update to the finding - * occurred. For example, if the finding represents an open firewall it would - * capture the time the detector believes the firewall became open. The - * accuracy is determined by the detector. If the finding were to be resolved - * afterward, this time would reflect when the finding was resolved. Must not - * be set to a value greater than the current timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp event_time = 9; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEventTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->event_time = $var; - - return $this; - } - - /** - * The time at which the finding was created in Security Command Center. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 10; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * The time at which the finding was created in Security Command Center. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 10; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * The severity of the finding. This field is managed by the source that - * writes the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding.Severity severity = 13; - * @return int - */ - public function getSeverity() - { - return $this->severity; - } - - /** - * The severity of the finding. This field is managed by the source that - * writes the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding.Severity severity = 13; - * @param int $var - * @return $this - */ - public function setSeverity($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1p1beta1\Finding\Severity::class); - $this->severity = $var; - - return $this; - } - - /** - * The canonical name of the finding. It's either - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}" or - * "projects/{project_number}/sources/{source_id}/findings/{finding_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * - * Generated from protobuf field string canonical_name = 14; - * @return string - */ - public function getCanonicalName() - { - return $this->canonical_name; - } - - /** - * The canonical name of the finding. It's either - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}", - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}" or - * "projects/{project_number}/sources/{source_id}/findings/{finding_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * - * Generated from protobuf field string canonical_name = 14; - * @param string $var - * @return $this - */ - public function setCanonicalName($var) - { - GPBUtil::checkString($var, True); - $this->canonical_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding/Severity.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding/Severity.php deleted file mode 100644 index 7b66c33d8bd0..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding/Severity.php +++ /dev/null @@ -1,79 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.Finding.Severity - */ -class Severity -{ - /** - * No severity specified. The default value. - * - * Generated from protobuf enum SEVERITY_UNSPECIFIED = 0; - */ - const SEVERITY_UNSPECIFIED = 0; - /** - * Critical severity. - * - * Generated from protobuf enum CRITICAL = 1; - */ - const CRITICAL = 1; - /** - * High severity. - * - * Generated from protobuf enum HIGH = 2; - */ - const HIGH = 2; - /** - * Medium severity. - * - * Generated from protobuf enum MEDIUM = 3; - */ - const MEDIUM = 3; - /** - * Low severity. - * - * Generated from protobuf enum LOW = 4; - */ - const LOW = 4; - - private static $valueToName = [ - self::SEVERITY_UNSPECIFIED => 'SEVERITY_UNSPECIFIED', - self::CRITICAL => 'CRITICAL', - self::HIGH => 'HIGH', - self::MEDIUM => 'MEDIUM', - self::LOW => 'LOW', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Severity::class, \Google\Cloud\SecurityCenter\V1p1beta1\Finding_Severity::class); - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding/State.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding/State.php deleted file mode 100644 index 188e804f89de..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Finding/State.php +++ /dev/null @@ -1,65 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.Finding.State - */ -class State -{ - /** - * Unspecified state. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The finding requires attention and has not been addressed yet. - * - * Generated from protobuf enum ACTIVE = 1; - */ - const ACTIVE = 1; - /** - * The finding has been fixed, triaged as a non-issue or otherwise addressed - * and is no longer active. - * - * Generated from protobuf enum INACTIVE = 2; - */ - const INACTIVE = 2; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - self::INACTIVE => 'INACTIVE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\SecurityCenter\V1p1beta1\Finding_State::class); - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Folder.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Folder.php deleted file mode 100644 index 1be85831acc6..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Folder.php +++ /dev/null @@ -1,106 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.Folder - */ -class Folder extends \Google\Protobuf\Internal\Message -{ - /** - * Full resource name of this folder. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_folder = 1; - */ - protected $resource_folder = ''; - /** - * The user defined display name for this folder. - * - * Generated from protobuf field string resource_folder_display_name = 2; - */ - protected $resource_folder_display_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $resource_folder - * Full resource name of this folder. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * @type string $resource_folder_display_name - * The user defined display name for this folder. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\Folder::initOnce(); - parent::__construct($data); - } - - /** - * Full resource name of this folder. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_folder = 1; - * @return string - */ - public function getResourceFolder() - { - return $this->resource_folder; - } - - /** - * Full resource name of this folder. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string resource_folder = 1; - * @param string $var - * @return $this - */ - public function setResourceFolder($var) - { - GPBUtil::checkString($var, True); - $this->resource_folder = $var; - - return $this; - } - - /** - * The user defined display name for this folder. - * - * Generated from protobuf field string resource_folder_display_name = 2; - * @return string - */ - public function getResourceFolderDisplayName() - { - return $this->resource_folder_display_name; - } - - /** - * The user defined display name for this folder. - * - * Generated from protobuf field string resource_folder_display_name = 2; - * @param string $var - * @return $this - */ - public function setResourceFolderDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->resource_folder_display_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetNotificationConfigRequest.php deleted file mode 100644 index b612d7b962c2..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetNotificationConfigRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.GetNotificationConfigRequest - */ -class GetNotificationConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the notification config to get. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the notification config to get. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the notification config to get. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the notification config to get. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetOrganizationSettingsRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetOrganizationSettingsRequest.php deleted file mode 100644 index 1f0cdc6d247d..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetOrganizationSettingsRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.GetOrganizationSettingsRequest - */ -class GetOrganizationSettingsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the organization to get organization settings for. Its format is - * "organizations/[organization_id]/organizationSettings". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the organization to get organization settings for. Its format is - * "organizations/[organization_id]/organizationSettings". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the organization to get organization settings for. Its format is - * "organizations/[organization_id]/organizationSettings". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the organization to get organization settings for. Its format is - * "organizations/[organization_id]/organizationSettings". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetSourceRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetSourceRequest.php deleted file mode 100644 index 4372471b4525..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GetSourceRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.GetSourceRequest - */ -class GetSourceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Relative resource name of the source. Its format is - * "organizations/[organization_id]/source/[source_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Relative resource name of the source. Its format is - * "organizations/[organization_id]/source/[source_id]". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Relative resource name of the source. Its format is - * "organizations/[organization_id]/source/[source_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Relative resource name of the source. Its format is - * "organizations/[organization_id]/source/[source_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupAssetsRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupAssetsRequest.php deleted file mode 100644 index 22d91ed7c020..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupAssetsRequest.php +++ /dev/null @@ -1,643 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.GroupAssetsRequest - */ -class GroupAssetsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the organization to groupBy. Its format is - * "organizations/[organization_id], folders/[folder_id], or - * projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_name_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * For example, `resource_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * - * Generated from protobuf field string filter = 2; - */ - protected $filter = ''; - /** - * Required. Expression that defines what assets fields to use for grouping. The string - * value should follow SQL syntax: comma separated list of fields. For - * example: - * "security_center_properties.resource_project,security_center_properties.project". - * The following fields are supported when compare_duration is not set: - * * security_center_properties.resource_project - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_type - * * security_center_properties.resource_parent - * * security_center_properties.resource_parent_display_name - * The following fields are supported when compare_duration is set: - * * security_center_properties.resource_type - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_parent_display_name - * - * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $group_by = ''; - /** - * When compare_duration is set, the GroupResult's "state_change" property is - * updated to indicate whether the asset was added, removed, or remained - * present during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * Possible "state_change" values when compare_duration is specified: - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at reference_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at reference_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and reference_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 4; - */ - protected $compare_duration = null; - /** - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 5; - */ - protected $read_time = null; - /** - * The value returned by the last `GroupAssetsResponse`; indicates - * that this is a continuation of a prior `GroupAssets` call, and that the - * system should return the next page of data. - * - * Generated from protobuf field string page_token = 7; - */ - protected $page_token = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 8; - */ - protected $page_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Name of the organization to groupBy. Its format is - * "organizations/[organization_id], folders/[folder_id], or - * projects/[project_id]". - * @type string $filter - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_name_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * For example, `resource_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * @type string $group_by - * Required. Expression that defines what assets fields to use for grouping. The string - * value should follow SQL syntax: comma separated list of fields. For - * example: - * "security_center_properties.resource_project,security_center_properties.project". - * The following fields are supported when compare_duration is not set: - * * security_center_properties.resource_project - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_type - * * security_center_properties.resource_parent - * * security_center_properties.resource_parent_display_name - * The following fields are supported when compare_duration is set: - * * security_center_properties.resource_type - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_parent_display_name - * @type \Google\Protobuf\Duration $compare_duration - * When compare_duration is set, the GroupResult's "state_change" property is - * updated to indicate whether the asset was added, removed, or remained - * present during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * Possible "state_change" values when compare_duration is specified: - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at reference_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at reference_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and reference_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * @type \Google\Protobuf\Timestamp $read_time - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * @type string $page_token - * The value returned by the last `GroupAssetsResponse`; indicates - * that this is a continuation of a prior `GroupAssets` call, and that the - * system should return the next page of data. - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the organization to groupBy. Its format is - * "organizations/[organization_id], folders/[folder_id], or - * projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Name of the organization to groupBy. Its format is - * "organizations/[organization_id], folders/[folder_id], or - * projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_name_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * For example, `resource_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * - * Generated from protobuf field string filter = 2; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_name_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * For example, `resource_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * - * Generated from protobuf field string filter = 2; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Required. Expression that defines what assets fields to use for grouping. The string - * value should follow SQL syntax: comma separated list of fields. For - * example: - * "security_center_properties.resource_project,security_center_properties.project". - * The following fields are supported when compare_duration is not set: - * * security_center_properties.resource_project - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_type - * * security_center_properties.resource_parent - * * security_center_properties.resource_parent_display_name - * The following fields are supported when compare_duration is set: - * * security_center_properties.resource_type - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_parent_display_name - * - * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getGroupBy() - { - return $this->group_by; - } - - /** - * Required. Expression that defines what assets fields to use for grouping. The string - * value should follow SQL syntax: comma separated list of fields. For - * example: - * "security_center_properties.resource_project,security_center_properties.project". - * The following fields are supported when compare_duration is not set: - * * security_center_properties.resource_project - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_type - * * security_center_properties.resource_parent - * * security_center_properties.resource_parent_display_name - * The following fields are supported when compare_duration is set: - * * security_center_properties.resource_type - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_parent_display_name - * - * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setGroupBy($var) - { - GPBUtil::checkString($var, True); - $this->group_by = $var; - - return $this; - } - - /** - * When compare_duration is set, the GroupResult's "state_change" property is - * updated to indicate whether the asset was added, removed, or remained - * present during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * Possible "state_change" values when compare_duration is specified: - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at reference_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at reference_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and reference_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 4; - * @return \Google\Protobuf\Duration|null - */ - public function getCompareDuration() - { - return $this->compare_duration; - } - - public function hasCompareDuration() - { - return isset($this->compare_duration); - } - - public function clearCompareDuration() - { - unset($this->compare_duration); - } - - /** - * When compare_duration is set, the GroupResult's "state_change" property is - * updated to indicate whether the asset was added, removed, or remained - * present during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * Possible "state_change" values when compare_duration is specified: - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at reference_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at reference_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and reference_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 4; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setCompareDuration($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->compare_duration = $var; - - return $this; - } - - /** - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 5; - * @return \Google\Protobuf\Timestamp|null - */ - public function getReadTime() - { - return $this->read_time; - } - - public function hasReadTime() - { - return isset($this->read_time); - } - - public function clearReadTime() - { - unset($this->read_time); - } - - /** - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 5; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setReadTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->read_time = $var; - - return $this; - } - - /** - * The value returned by the last `GroupAssetsResponse`; indicates - * that this is a continuation of a prior `GroupAssets` call, and that the - * system should return the next page of data. - * - * Generated from protobuf field string page_token = 7; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `GroupAssetsResponse`; indicates - * that this is a continuation of a prior `GroupAssets` call, and that the - * system should return the next page of data. - * - * Generated from protobuf field string page_token = 7; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 8; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 8; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupAssetsResponse.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupAssetsResponse.php deleted file mode 100644 index e617f28d43a0..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupAssetsResponse.php +++ /dev/null @@ -1,191 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.GroupAssetsResponse - */ -class GroupAssetsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.GroupResult group_by_results = 1; - */ - private $group_by_results; - /** - * Time used for executing the groupBy request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - */ - protected $read_time = null; - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - */ - protected $next_page_token = ''; - /** - * The total number of results matching the query. - * - * Generated from protobuf field int32 total_size = 4; - */ - protected $total_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1p1beta1\GroupResult>|\Google\Protobuf\Internal\RepeatedField $group_by_results - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * @type \Google\Protobuf\Timestamp $read_time - * Time used for executing the groupBy request. - * @type string $next_page_token - * Token to retrieve the next page of results, or empty if there are no more - * results. - * @type int $total_size - * The total number of results matching the query. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.GroupResult group_by_results = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getGroupByResults() - { - return $this->group_by_results; - } - - /** - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.GroupResult group_by_results = 1; - * @param array<\Google\Cloud\SecurityCenter\V1p1beta1\GroupResult>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setGroupByResults($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1p1beta1\GroupResult::class); - $this->group_by_results = $arr; - - return $this; - } - - /** - * Time used for executing the groupBy request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getReadTime() - { - return $this->read_time; - } - - public function hasReadTime() - { - return isset($this->read_time); - } - - public function clearReadTime() - { - unset($this->read_time); - } - - /** - * Time used for executing the groupBy request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setReadTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->read_time = $var; - - return $this; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * The total number of results matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @return int - */ - public function getTotalSize() - { - return $this->total_size; - } - - /** - * The total number of results matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @param int $var - * @return $this - */ - public function setTotalSize($var) - { - GPBUtil::checkInt32($var); - $this->total_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupFindingsRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupFindingsRequest.php deleted file mode 100644 index 1d1532312f30..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupFindingsRequest.php +++ /dev/null @@ -1,627 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.GroupFindingsRequest - */ -class GroupFindingsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the source to groupBy. Its format is - * "organizations/[organization_id]/sources/[source_id]", - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]. To groupBy across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, - * or projects/{project_id}/sources/- - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * * severity: `=`, `:` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * security_marks.marks: `=`, `:` - * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * For example, `source_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * - * Generated from protobuf field string filter = 2; - */ - protected $filter = ''; - /** - * Required. Expression that defines what assets fields to use for grouping (including - * `state_change`). The string value should follow SQL syntax: comma separated - * list of fields. For example: "parent,resource_name". - * The following fields are supported: - * * resource_name - * * category - * * state - * * parent - * * severity - * The following fields are supported when compare_duration is set: - * * state_change - * - * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $group_by = ''; - /** - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; - */ - protected $read_time = null; - /** - * When compare_duration is set, the GroupResult's "state_change" attribute is - * updated to indicate whether the finding had its state changed, the - * finding's state remained unchanged, or if the finding was added during the - * compare_duration period of time that precedes the read_time. This is the - * time between (read_time - compare_duration) and read_time. - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * Possible "state_change" values when compare_duration is specified: - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present - * at read_time. - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; - */ - protected $compare_duration = null; - /** - * The value returned by the last `GroupFindingsResponse`; indicates - * that this is a continuation of a prior `GroupFindings` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 7; - */ - protected $page_token = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 8; - */ - protected $page_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Name of the source to groupBy. Its format is - * "organizations/[organization_id]/sources/[source_id]", - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]. To groupBy across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, - * or projects/{project_id}/sources/- - * @type string $filter - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * * severity: `=`, `:` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * security_marks.marks: `=`, `:` - * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * For example, `source_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * @type string $group_by - * Required. Expression that defines what assets fields to use for grouping (including - * `state_change`). The string value should follow SQL syntax: comma separated - * list of fields. For example: "parent,resource_name". - * The following fields are supported: - * * resource_name - * * category - * * state - * * parent - * * severity - * The following fields are supported when compare_duration is set: - * * state_change - * @type \Google\Protobuf\Timestamp $read_time - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * @type \Google\Protobuf\Duration $compare_duration - * When compare_duration is set, the GroupResult's "state_change" attribute is - * updated to indicate whether the finding had its state changed, the - * finding's state remained unchanged, or if the finding was added during the - * compare_duration period of time that precedes the read_time. This is the - * time between (read_time - compare_duration) and read_time. - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * Possible "state_change" values when compare_duration is specified: - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present - * at read_time. - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * @type string $page_token - * The value returned by the last `GroupFindingsResponse`; indicates - * that this is a continuation of a prior `GroupFindings` call, and - * that the system should return the next page of data. - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the source to groupBy. Its format is - * "organizations/[organization_id]/sources/[source_id]", - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]. To groupBy across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, - * or projects/{project_id}/sources/- - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Name of the source to groupBy. Its format is - * "organizations/[organization_id]/sources/[source_id]", - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]. To groupBy across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, - * or projects/{project_id}/sources/- - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * * severity: `=`, `:` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * security_marks.marks: `=`, `:` - * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * For example, `source_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * - * Generated from protobuf field string filter = 2; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * * severity: `=`, `:` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * security_marks.marks: `=`, `:` - * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * For example, `source_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * - * Generated from protobuf field string filter = 2; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Required. Expression that defines what assets fields to use for grouping (including - * `state_change`). The string value should follow SQL syntax: comma separated - * list of fields. For example: "parent,resource_name". - * The following fields are supported: - * * resource_name - * * category - * * state - * * parent - * * severity - * The following fields are supported when compare_duration is set: - * * state_change - * - * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getGroupBy() - { - return $this->group_by; - } - - /** - * Required. Expression that defines what assets fields to use for grouping (including - * `state_change`). The string value should follow SQL syntax: comma separated - * list of fields. For example: "parent,resource_name". - * The following fields are supported: - * * resource_name - * * category - * * state - * * parent - * * severity - * The following fields are supported when compare_duration is set: - * * state_change - * - * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setGroupBy($var) - { - GPBUtil::checkString($var, True); - $this->group_by = $var; - - return $this; - } - - /** - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; - * @return \Google\Protobuf\Timestamp|null - */ - public function getReadTime() - { - return $this->read_time; - } - - public function hasReadTime() - { - return isset($this->read_time); - } - - public function clearReadTime() - { - unset($this->read_time); - } - - /** - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setReadTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->read_time = $var; - - return $this; - } - - /** - * When compare_duration is set, the GroupResult's "state_change" attribute is - * updated to indicate whether the finding had its state changed, the - * finding's state remained unchanged, or if the finding was added during the - * compare_duration period of time that precedes the read_time. This is the - * time between (read_time - compare_duration) and read_time. - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * Possible "state_change" values when compare_duration is specified: - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present - * at read_time. - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; - * @return \Google\Protobuf\Duration|null - */ - public function getCompareDuration() - { - return $this->compare_duration; - } - - public function hasCompareDuration() - { - return isset($this->compare_duration); - } - - public function clearCompareDuration() - { - unset($this->compare_duration); - } - - /** - * When compare_duration is set, the GroupResult's "state_change" attribute is - * updated to indicate whether the finding had its state changed, the - * finding's state remained unchanged, or if the finding was added during the - * compare_duration period of time that precedes the read_time. This is the - * time between (read_time - compare_duration) and read_time. - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * Possible "state_change" values when compare_duration is specified: - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present - * at read_time. - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setCompareDuration($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->compare_duration = $var; - - return $this; - } - - /** - * The value returned by the last `GroupFindingsResponse`; indicates - * that this is a continuation of a prior `GroupFindings` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 7; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `GroupFindingsResponse`; indicates - * that this is a continuation of a prior `GroupFindings` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 7; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 8; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 8; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupFindingsResponse.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupFindingsResponse.php deleted file mode 100644 index 08e112996742..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupFindingsResponse.php +++ /dev/null @@ -1,191 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.GroupFindingsResponse - */ -class GroupFindingsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.GroupResult group_by_results = 1; - */ - private $group_by_results; - /** - * Time used for executing the groupBy request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - */ - protected $read_time = null; - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - */ - protected $next_page_token = ''; - /** - * The total number of results matching the query. - * - * Generated from protobuf field int32 total_size = 4; - */ - protected $total_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1p1beta1\GroupResult>|\Google\Protobuf\Internal\RepeatedField $group_by_results - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * @type \Google\Protobuf\Timestamp $read_time - * Time used for executing the groupBy request. - * @type string $next_page_token - * Token to retrieve the next page of results, or empty if there are no more - * results. - * @type int $total_size - * The total number of results matching the query. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.GroupResult group_by_results = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getGroupByResults() - { - return $this->group_by_results; - } - - /** - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.GroupResult group_by_results = 1; - * @param array<\Google\Cloud\SecurityCenter\V1p1beta1\GroupResult>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setGroupByResults($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1p1beta1\GroupResult::class); - $this->group_by_results = $arr; - - return $this; - } - - /** - * Time used for executing the groupBy request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getReadTime() - { - return $this->read_time; - } - - public function hasReadTime() - { - return isset($this->read_time); - } - - public function clearReadTime() - { - unset($this->read_time); - } - - /** - * Time used for executing the groupBy request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setReadTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->read_time = $var; - - return $this; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * The total number of results matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @return int - */ - public function getTotalSize() - { - return $this->total_size; - } - - /** - * The total number of results matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @param int $var - * @return $this - */ - public function setTotalSize($var) - { - GPBUtil::checkInt32($var); - $this->total_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupResult.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupResult.php deleted file mode 100644 index 5abaf409e1ce..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/GroupResult.php +++ /dev/null @@ -1,101 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.GroupResult - */ -class GroupResult extends \Google\Protobuf\Internal\Message -{ - /** - * Properties matching the groupBy fields in the request. - * - * Generated from protobuf field map properties = 1; - */ - private $properties; - /** - * Total count of resources for the given properties. - * - * Generated from protobuf field int64 count = 2; - */ - protected $count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\MapField $properties - * Properties matching the groupBy fields in the request. - * @type int|string $count - * Total count of resources for the given properties. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Properties matching the groupBy fields in the request. - * - * Generated from protobuf field map properties = 1; - * @return \Google\Protobuf\Internal\MapField - */ - public function getProperties() - { - return $this->properties; - } - - /** - * Properties matching the groupBy fields in the request. - * - * Generated from protobuf field map properties = 1; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setProperties($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Value::class); - $this->properties = $arr; - - return $this; - } - - /** - * Total count of resources for the given properties. - * - * Generated from protobuf field int64 count = 2; - * @return int|string - */ - public function getCount() - { - return $this->count; - } - - /** - * Total count of resources for the given properties. - * - * Generated from protobuf field int64 count = 2; - * @param int|string $var - * @return $this - */ - public function setCount($var) - { - GPBUtil::checkInt64($var); - $this->count = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsRequest.php deleted file mode 100644 index a0a4531e7d95..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsRequest.php +++ /dev/null @@ -1,711 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.ListAssetsRequest - */ -class ListAssetsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the organization assets should belong to. Its format is - * "organizations/[organization_id], folders/[folder_id], or - * projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following are the allowed field and operator combinations: - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * For example, `resource_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * - * Generated from protobuf field string filter = 2; - */ - protected $filter = ''; - /** - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,resource_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,resource_properties.a_property" and " - * name desc , resource_properties.a_property " are equivalent. - * The following fields are supported: - * name - * update_time - * resource_properties - * security_marks.marks - * security_center_properties.resource_name - * security_center_properties.resource_display_name - * security_center_properties.resource_parent - * security_center_properties.resource_parent_display_name - * security_center_properties.resource_project - * security_center_properties.resource_project_display_name - * security_center_properties.resource_type - * - * Generated from protobuf field string order_by = 3; - */ - protected $order_by = ''; - /** - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; - */ - protected $read_time = null; - /** - * When compare_duration is set, the ListAssetsResult's "state_change" - * attribute is updated to indicate whether the asset was added, removed, or - * remained present during the compare_duration period of time that precedes - * the read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state_change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * Possible "state_change" values when compare_duration is specified: - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at read_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at read_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; - */ - protected $compare_duration = null; - /** - * A field mask to specify the ListAssetsResult fields to be listed in the - * response. - * An empty field mask will list all fields. - * - * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; - */ - protected $field_mask = null; - /** - * The value returned by the last `ListAssetsResponse`; indicates - * that this is a continuation of a prior `ListAssets` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 8; - */ - protected $page_token = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 9; - */ - protected $page_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Name of the organization assets should belong to. Its format is - * "organizations/[organization_id], folders/[folder_id], or - * projects/[project_id]". - * @type string $filter - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following are the allowed field and operator combinations: - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * For example, `resource_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * @type string $order_by - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,resource_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,resource_properties.a_property" and " - * name desc , resource_properties.a_property " are equivalent. - * The following fields are supported: - * name - * update_time - * resource_properties - * security_marks.marks - * security_center_properties.resource_name - * security_center_properties.resource_display_name - * security_center_properties.resource_parent - * security_center_properties.resource_parent_display_name - * security_center_properties.resource_project - * security_center_properties.resource_project_display_name - * security_center_properties.resource_type - * @type \Google\Protobuf\Timestamp $read_time - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * @type \Google\Protobuf\Duration $compare_duration - * When compare_duration is set, the ListAssetsResult's "state_change" - * attribute is updated to indicate whether the asset was added, removed, or - * remained present during the compare_duration period of time that precedes - * the read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state_change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * Possible "state_change" values when compare_duration is specified: - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at read_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at read_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * @type \Google\Protobuf\FieldMask $field_mask - * A field mask to specify the ListAssetsResult fields to be listed in the - * response. - * An empty field mask will list all fields. - * @type string $page_token - * The value returned by the last `ListAssetsResponse`; indicates - * that this is a continuation of a prior `ListAssets` call, and - * that the system should return the next page of data. - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the organization assets should belong to. Its format is - * "organizations/[organization_id], folders/[folder_id], or - * projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Name of the organization assets should belong to. Its format is - * "organizations/[organization_id], folders/[folder_id], or - * projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following are the allowed field and operator combinations: - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * For example, `resource_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * - * Generated from protobuf field string filter = 2; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following are the allowed field and operator combinations: - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * For example, `resource_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * - * Generated from protobuf field string filter = 2; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,resource_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,resource_properties.a_property" and " - * name desc , resource_properties.a_property " are equivalent. - * The following fields are supported: - * name - * update_time - * resource_properties - * security_marks.marks - * security_center_properties.resource_name - * security_center_properties.resource_display_name - * security_center_properties.resource_parent - * security_center_properties.resource_parent_display_name - * security_center_properties.resource_project - * security_center_properties.resource_project_display_name - * security_center_properties.resource_type - * - * Generated from protobuf field string order_by = 3; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,resource_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,resource_properties.a_property" and " - * name desc , resource_properties.a_property " are equivalent. - * The following fields are supported: - * name - * update_time - * resource_properties - * security_marks.marks - * security_center_properties.resource_name - * security_center_properties.resource_display_name - * security_center_properties.resource_parent - * security_center_properties.resource_parent_display_name - * security_center_properties.resource_project - * security_center_properties.resource_project_display_name - * security_center_properties.resource_type - * - * Generated from protobuf field string order_by = 3; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - - /** - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; - * @return \Google\Protobuf\Timestamp|null - */ - public function getReadTime() - { - return $this->read_time; - } - - public function hasReadTime() - { - return isset($this->read_time); - } - - public function clearReadTime() - { - unset($this->read_time); - } - - /** - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setReadTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->read_time = $var; - - return $this; - } - - /** - * When compare_duration is set, the ListAssetsResult's "state_change" - * attribute is updated to indicate whether the asset was added, removed, or - * remained present during the compare_duration period of time that precedes - * the read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state_change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * Possible "state_change" values when compare_duration is specified: - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at read_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at read_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; - * @return \Google\Protobuf\Duration|null - */ - public function getCompareDuration() - { - return $this->compare_duration; - } - - public function hasCompareDuration() - { - return isset($this->compare_duration); - } - - public function clearCompareDuration() - { - unset($this->compare_duration); - } - - /** - * When compare_duration is set, the ListAssetsResult's "state_change" - * attribute is updated to indicate whether the asset was added, removed, or - * remained present during the compare_duration period of time that precedes - * the read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state_change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * Possible "state_change" values when compare_duration is specified: - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at read_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at read_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setCompareDuration($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->compare_duration = $var; - - return $this; - } - - /** - * A field mask to specify the ListAssetsResult fields to be listed in the - * response. - * An empty field mask will list all fields. - * - * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; - * @return \Google\Protobuf\FieldMask|null - */ - public function getFieldMask() - { - return $this->field_mask; - } - - public function hasFieldMask() - { - return isset($this->field_mask); - } - - public function clearFieldMask() - { - unset($this->field_mask); - } - - /** - * A field mask to specify the ListAssetsResult fields to be listed in the - * response. - * An empty field mask will list all fields. - * - * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setFieldMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->field_mask = $var; - - return $this; - } - - /** - * The value returned by the last `ListAssetsResponse`; indicates - * that this is a continuation of a prior `ListAssets` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 8; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListAssetsResponse`; indicates - * that this is a continuation of a prior `ListAssets` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 8; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 9; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 9; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse.php deleted file mode 100644 index c1c510821ecf..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse.php +++ /dev/null @@ -1,183 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.ListAssetsResponse - */ -class ListAssetsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Assets matching the list request. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.ListAssetsResponse.ListAssetsResult list_assets_results = 1; - */ - private $list_assets_results; - /** - * Time used for executing the list request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - */ - protected $read_time = null; - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - */ - protected $next_page_token = ''; - /** - * The total number of assets matching the query. - * - * Generated from protobuf field int32 total_size = 4; - */ - protected $total_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1p1beta1\ListAssetsResponse\ListAssetsResult>|\Google\Protobuf\Internal\RepeatedField $list_assets_results - * Assets matching the list request. - * @type \Google\Protobuf\Timestamp $read_time - * Time used for executing the list request. - * @type string $next_page_token - * Token to retrieve the next page of results, or empty if there are no more - * results. - * @type int $total_size - * The total number of assets matching the query. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Assets matching the list request. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.ListAssetsResponse.ListAssetsResult list_assets_results = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getListAssetsResults() - { - return $this->list_assets_results; - } - - /** - * Assets matching the list request. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.ListAssetsResponse.ListAssetsResult list_assets_results = 1; - * @param array<\Google\Cloud\SecurityCenter\V1p1beta1\ListAssetsResponse\ListAssetsResult>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setListAssetsResults($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1p1beta1\ListAssetsResponse\ListAssetsResult::class); - $this->list_assets_results = $arr; - - return $this; - } - - /** - * Time used for executing the list request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getReadTime() - { - return $this->read_time; - } - - public function hasReadTime() - { - return isset($this->read_time); - } - - public function clearReadTime() - { - unset($this->read_time); - } - - /** - * Time used for executing the list request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setReadTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->read_time = $var; - - return $this; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * The total number of assets matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @return int - */ - public function getTotalSize() - { - return $this->total_size; - } - - /** - * The total number of assets matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @param int $var - * @return $this - */ - public function setTotalSize($var) - { - GPBUtil::checkInt32($var); - $this->total_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse/ListAssetsResult.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse/ListAssetsResult.php deleted file mode 100644 index 4e9003862dd2..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse/ListAssetsResult.php +++ /dev/null @@ -1,114 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.ListAssetsResponse.ListAssetsResult - */ -class ListAssetsResult extends \Google\Protobuf\Internal\Message -{ - /** - * Asset matching the search request. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Asset asset = 1; - */ - protected $asset = null; - /** - * State change of the asset between the points in time. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.ListAssetsResponse.ListAssetsResult.StateChange state_change = 2; - */ - protected $state_change = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1p1beta1\Asset $asset - * Asset matching the search request. - * @type int $state_change - * State change of the asset between the points in time. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Asset matching the search request. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Asset asset = 1; - * @return \Google\Cloud\SecurityCenter\V1p1beta1\Asset|null - */ - public function getAsset() - { - return $this->asset; - } - - public function hasAsset() - { - return isset($this->asset); - } - - public function clearAsset() - { - unset($this->asset); - } - - /** - * Asset matching the search request. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Asset asset = 1; - * @param \Google\Cloud\SecurityCenter\V1p1beta1\Asset $var - * @return $this - */ - public function setAsset($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Asset::class); - $this->asset = $var; - - return $this; - } - - /** - * State change of the asset between the points in time. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.ListAssetsResponse.ListAssetsResult.StateChange state_change = 2; - * @return int - */ - public function getStateChange() - { - return $this->state_change; - } - - /** - * State change of the asset between the points in time. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.ListAssetsResponse.ListAssetsResult.StateChange state_change = 2; - * @param int $var - * @return $this - */ - public function setStateChange($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1p1beta1\ListAssetsResponse\ListAssetsResult\StateChange::class); - $this->state_change = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ListAssetsResult::class, \Google\Cloud\SecurityCenter\V1p1beta1\ListAssetsResponse_ListAssetsResult::class); - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse/ListAssetsResult/StateChange.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse/ListAssetsResult/StateChange.php deleted file mode 100644 index 2ef0a7011948..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListAssetsResponse/ListAssetsResult/StateChange.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.ListAssetsResponse.ListAssetsResult.StateChange - */ -class StateChange -{ - /** - * State change is unused, this is the canonical default for this enum. - * - * Generated from protobuf enum UNUSED = 0; - */ - const UNUSED = 0; - /** - * Asset was added between the points in time. - * - * Generated from protobuf enum ADDED = 1; - */ - const ADDED = 1; - /** - * Asset was removed between the points in time. - * - * Generated from protobuf enum REMOVED = 2; - */ - const REMOVED = 2; - /** - * Asset was present at both point(s) in time. - * - * Generated from protobuf enum ACTIVE = 3; - */ - const ACTIVE = 3; - - private static $valueToName = [ - self::UNUSED => 'UNUSED', - self::ADDED => 'ADDED', - self::REMOVED => 'REMOVED', - self::ACTIVE => 'ACTIVE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(StateChange::class, \Google\Cloud\SecurityCenter\V1p1beta1\ListAssetsResponse_ListAssetsResult_StateChange::class); - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsRequest.php deleted file mode 100644 index a16083dde217..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsRequest.php +++ /dev/null @@ -1,695 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.ListFindingsRequest - */ -class ListFindingsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the source the findings belong to. Its format is - * "organizations/[organization_id]/sources/[source_id], - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]". To list across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or - * projects/{projects_id}/sources/- - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * * severity: `=`, `:` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * security_marks.marks: `=`, `:` - * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * For example, `source_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * - * Generated from protobuf field string filter = 2; - */ - protected $filter = ''; - /** - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,source_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,source_properties.a_property" and " - * name desc , source_properties.a_property " are equivalent. - * The following fields are supported: - * name - * parent - * state - * category - * resource_name - * event_time - * source_properties - * security_marks.marks - * - * Generated from protobuf field string order_by = 3; - */ - protected $order_by = ''; - /** - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; - */ - protected $read_time = null; - /** - * When compare_duration is set, the ListFindingsResult's "state_change" - * attribute is updated to indicate whether the finding had its state changed, - * the finding's state remained unchanged, or if the finding was added in any - * state during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * Possible "state_change" values when compare_duration is specified: - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present at - * read_time. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; - */ - protected $compare_duration = null; - /** - * A field mask to specify the Finding fields to be listed in the response. - * An empty field mask will list all fields. - * - * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; - */ - protected $field_mask = null; - /** - * The value returned by the last `ListFindingsResponse`; indicates - * that this is a continuation of a prior `ListFindings` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 8; - */ - protected $page_token = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 9; - */ - protected $page_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Name of the source the findings belong to. Its format is - * "organizations/[organization_id]/sources/[source_id], - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]". To list across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or - * projects/{projects_id}/sources/- - * @type string $filter - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * * severity: `=`, `:` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * security_marks.marks: `=`, `:` - * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * For example, `source_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * @type string $order_by - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,source_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,source_properties.a_property" and " - * name desc , source_properties.a_property " are equivalent. - * The following fields are supported: - * name - * parent - * state - * category - * resource_name - * event_time - * source_properties - * security_marks.marks - * @type \Google\Protobuf\Timestamp $read_time - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * @type \Google\Protobuf\Duration $compare_duration - * When compare_duration is set, the ListFindingsResult's "state_change" - * attribute is updated to indicate whether the finding had its state changed, - * the finding's state remained unchanged, or if the finding was added in any - * state during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * Possible "state_change" values when compare_duration is specified: - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present at - * read_time. - * @type \Google\Protobuf\FieldMask $field_mask - * A field mask to specify the Finding fields to be listed in the response. - * An empty field mask will list all fields. - * @type string $page_token - * The value returned by the last `ListFindingsResponse`; indicates - * that this is a continuation of a prior `ListFindings` call, and - * that the system should return the next page of data. - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the source the findings belong to. Its format is - * "organizations/[organization_id]/sources/[source_id], - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]". To list across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or - * projects/{projects_id}/sources/- - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Name of the source the findings belong to. Its format is - * "organizations/[organization_id]/sources/[source_id], - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]". To list across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or - * projects/{projects_id}/sources/- - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * * severity: `=`, `:` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * security_marks.marks: `=`, `:` - * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * For example, `source_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * - * Generated from protobuf field string filter = 2; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * * severity: `=`, `:` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * security_marks.marks: `=`, `:` - * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * For example, `source_properties.size = 100` is a valid filter string. - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * - * Generated from protobuf field string filter = 2; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,source_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,source_properties.a_property" and " - * name desc , source_properties.a_property " are equivalent. - * The following fields are supported: - * name - * parent - * state - * category - * resource_name - * event_time - * source_properties - * security_marks.marks - * - * Generated from protobuf field string order_by = 3; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,source_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,source_properties.a_property" and " - * name desc , source_properties.a_property " are equivalent. - * The following fields are supported: - * name - * parent - * state - * category - * resource_name - * event_time - * source_properties - * security_marks.marks - * - * Generated from protobuf field string order_by = 3; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - - /** - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; - * @return \Google\Protobuf\Timestamp|null - */ - public function getReadTime() - { - return $this->read_time; - } - - public function hasReadTime() - { - return isset($this->read_time); - } - - public function clearReadTime() - { - unset($this->read_time); - } - - /** - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 4; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setReadTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->read_time = $var; - - return $this; - } - - /** - * When compare_duration is set, the ListFindingsResult's "state_change" - * attribute is updated to indicate whether the finding had its state changed, - * the finding's state remained unchanged, or if the finding was added in any - * state during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * Possible "state_change" values when compare_duration is specified: - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present at - * read_time. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; - * @return \Google\Protobuf\Duration|null - */ - public function getCompareDuration() - { - return $this->compare_duration; - } - - public function hasCompareDuration() - { - return isset($this->compare_duration); - } - - public function clearCompareDuration() - { - unset($this->compare_duration); - } - - /** - * When compare_duration is set, the ListFindingsResult's "state_change" - * attribute is updated to indicate whether the finding had its state changed, - * the finding's state remained unchanged, or if the finding was added in any - * state during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * Possible "state_change" values when compare_duration is specified: - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present at - * read_time. - * - * Generated from protobuf field .google.protobuf.Duration compare_duration = 5; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setCompareDuration($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->compare_duration = $var; - - return $this; - } - - /** - * A field mask to specify the Finding fields to be listed in the response. - * An empty field mask will list all fields. - * - * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; - * @return \Google\Protobuf\FieldMask|null - */ - public function getFieldMask() - { - return $this->field_mask; - } - - public function hasFieldMask() - { - return isset($this->field_mask); - } - - public function clearFieldMask() - { - unset($this->field_mask); - } - - /** - * A field mask to specify the Finding fields to be listed in the response. - * An empty field mask will list all fields. - * - * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setFieldMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->field_mask = $var; - - return $this; - } - - /** - * The value returned by the last `ListFindingsResponse`; indicates - * that this is a continuation of a prior `ListFindings` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 8; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListFindingsResponse`; indicates - * that this is a continuation of a prior `ListFindings` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 8; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 9; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 9; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse.php deleted file mode 100644 index d9166aab0298..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse.php +++ /dev/null @@ -1,183 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.ListFindingsResponse - */ -class ListFindingsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Findings matching the list request. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult list_findings_results = 1; - */ - private $list_findings_results; - /** - * Time used for executing the list request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - */ - protected $read_time = null; - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - */ - protected $next_page_token = ''; - /** - * The total number of findings matching the query. - * - * Generated from protobuf field int32 total_size = 4; - */ - protected $total_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse\ListFindingsResult>|\Google\Protobuf\Internal\RepeatedField $list_findings_results - * Findings matching the list request. - * @type \Google\Protobuf\Timestamp $read_time - * Time used for executing the list request. - * @type string $next_page_token - * Token to retrieve the next page of results, or empty if there are no more - * results. - * @type int $total_size - * The total number of findings matching the query. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Findings matching the list request. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult list_findings_results = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getListFindingsResults() - { - return $this->list_findings_results; - } - - /** - * Findings matching the list request. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult list_findings_results = 1; - * @param array<\Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse\ListFindingsResult>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setListFindingsResults($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse\ListFindingsResult::class); - $this->list_findings_results = $arr; - - return $this; - } - - /** - * Time used for executing the list request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getReadTime() - { - return $this->read_time; - } - - public function hasReadTime() - { - return isset($this->read_time); - } - - public function clearReadTime() - { - unset($this->read_time); - } - - /** - * Time used for executing the list request. - * - * Generated from protobuf field .google.protobuf.Timestamp read_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setReadTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->read_time = $var; - - return $this; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * The total number of findings matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @return int - */ - public function getTotalSize() - { - return $this->total_size; - } - - /** - * The total number of findings matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @param int $var - * @return $this - */ - public function setTotalSize($var) - { - GPBUtil::checkInt32($var); - $this->total_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult.php deleted file mode 100644 index af44be50fcb1..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult.php +++ /dev/null @@ -1,158 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult - */ -class ListFindingsResult extends \Google\Protobuf\Internal\Message -{ - /** - * Finding matching the search request. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 1; - */ - protected $finding = null; - /** - * State change of the finding between the points in time. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult.StateChange state_change = 2; - */ - protected $state_change = 0; - /** - * Output only. Resource that is associated with this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult.Resource resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $resource = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1p1beta1\Finding $finding - * Finding matching the search request. - * @type int $state_change - * State change of the finding between the points in time. - * @type \Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse\ListFindingsResult\Resource $resource - * Output only. Resource that is associated with this finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Finding matching the search request. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 1; - * @return \Google\Cloud\SecurityCenter\V1p1beta1\Finding|null - */ - public function getFinding() - { - return $this->finding; - } - - public function hasFinding() - { - return isset($this->finding); - } - - public function clearFinding() - { - unset($this->finding); - } - - /** - * Finding matching the search request. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 1; - * @param \Google\Cloud\SecurityCenter\V1p1beta1\Finding $var - * @return $this - */ - public function setFinding($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Finding::class); - $this->finding = $var; - - return $this; - } - - /** - * State change of the finding between the points in time. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult.StateChange state_change = 2; - * @return int - */ - public function getStateChange() - { - return $this->state_change; - } - - /** - * State change of the finding between the points in time. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult.StateChange state_change = 2; - * @param int $var - * @return $this - */ - public function setStateChange($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse\ListFindingsResult\StateChange::class); - $this->state_change = $var; - - return $this; - } - - /** - * Output only. Resource that is associated with this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult.Resource resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse\ListFindingsResult\Resource|null - */ - public function getResource() - { - return $this->resource; - } - - public function hasResource() - { - return isset($this->resource); - } - - public function clearResource() - { - unset($this->resource); - } - - /** - * Output only. Resource that is associated with this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult.Resource resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse\ListFindingsResult\Resource $var - * @return $this - */ - public function setResource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse\ListFindingsResult\Resource::class); - $this->resource = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ListFindingsResult::class, \Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse_ListFindingsResult::class); - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult/Resource.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult/Resource.php deleted file mode 100644 index 64280eb4f994..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult/Resource.php +++ /dev/null @@ -1,253 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult.Resource - */ -class Resource extends \Google\Protobuf\Internal\Message -{ - /** - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The full resource name of project that the resource belongs to. - * - * Generated from protobuf field string project_name = 2; - */ - protected $project_name = ''; - /** - * The human readable name of project that the resource belongs to. - * - * Generated from protobuf field string project_display_name = 3; - */ - protected $project_display_name = ''; - /** - * The full resource name of resource's parent. - * - * Generated from protobuf field string parent_name = 4; - */ - protected $parent_name = ''; - /** - * The human readable name of resource's parent. - * - * Generated from protobuf field string parent_display_name = 5; - */ - protected $parent_display_name = ''; - /** - * Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is - * the folder directly under the Organization. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Folder folders = 10; - */ - private $folders; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * @type string $project_name - * The full resource name of project that the resource belongs to. - * @type string $project_display_name - * The human readable name of project that the resource belongs to. - * @type string $parent_name - * The full resource name of resource's parent. - * @type string $parent_display_name - * The human readable name of resource's parent. - * @type array<\Google\Cloud\SecurityCenter\V1p1beta1\Folder>|\Google\Protobuf\Internal\RepeatedField $folders - * Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is - * the folder directly under the Organization. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The full resource name of project that the resource belongs to. - * - * Generated from protobuf field string project_name = 2; - * @return string - */ - public function getProjectName() - { - return $this->project_name; - } - - /** - * The full resource name of project that the resource belongs to. - * - * Generated from protobuf field string project_name = 2; - * @param string $var - * @return $this - */ - public function setProjectName($var) - { - GPBUtil::checkString($var, True); - $this->project_name = $var; - - return $this; - } - - /** - * The human readable name of project that the resource belongs to. - * - * Generated from protobuf field string project_display_name = 3; - * @return string - */ - public function getProjectDisplayName() - { - return $this->project_display_name; - } - - /** - * The human readable name of project that the resource belongs to. - * - * Generated from protobuf field string project_display_name = 3; - * @param string $var - * @return $this - */ - public function setProjectDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->project_display_name = $var; - - return $this; - } - - /** - * The full resource name of resource's parent. - * - * Generated from protobuf field string parent_name = 4; - * @return string - */ - public function getParentName() - { - return $this->parent_name; - } - - /** - * The full resource name of resource's parent. - * - * Generated from protobuf field string parent_name = 4; - * @param string $var - * @return $this - */ - public function setParentName($var) - { - GPBUtil::checkString($var, True); - $this->parent_name = $var; - - return $this; - } - - /** - * The human readable name of resource's parent. - * - * Generated from protobuf field string parent_display_name = 5; - * @return string - */ - public function getParentDisplayName() - { - return $this->parent_display_name; - } - - /** - * The human readable name of resource's parent. - * - * Generated from protobuf field string parent_display_name = 5; - * @param string $var - * @return $this - */ - public function setParentDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->parent_display_name = $var; - - return $this; - } - - /** - * Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is - * the folder directly under the Organization. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Folder folders = 10; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFolders() - { - return $this->folders; - } - - /** - * Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is - * the folder directly under the Organization. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Folder folders = 10; - * @param array<\Google\Cloud\SecurityCenter\V1p1beta1\Folder>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFolders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1p1beta1\Folder::class); - $this->folders = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Resource::class, \Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse_ListFindingsResult_Resource::class); - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult/StateChange.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult/StateChange.php deleted file mode 100644 index 4f8ad2507ab2..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListFindingsResponse/ListFindingsResult/StateChange.php +++ /dev/null @@ -1,87 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.ListFindingsResponse.ListFindingsResult.StateChange - */ -class StateChange -{ - /** - * State change is unused, this is the canonical default for this enum. - * - * Generated from protobuf enum UNUSED = 0; - */ - const UNUSED = 0; - /** - * The finding has changed state in some way between the points in time - * and existed at both points. - * - * Generated from protobuf enum CHANGED = 1; - */ - const CHANGED = 1; - /** - * The finding has not changed state between the points in time and - * existed at both points. - * - * Generated from protobuf enum UNCHANGED = 2; - */ - const UNCHANGED = 2; - /** - * The finding was created between the points in time. - * - * Generated from protobuf enum ADDED = 3; - */ - const ADDED = 3; - /** - * The finding at timestamp does not match the filter specified, but it - * did at timestamp - compare_duration. - * - * Generated from protobuf enum REMOVED = 4; - */ - const REMOVED = 4; - - private static $valueToName = [ - self::UNUSED => 'UNUSED', - self::CHANGED => 'CHANGED', - self::UNCHANGED => 'UNCHANGED', - self::ADDED => 'ADDED', - self::REMOVED => 'REMOVED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(StateChange::class, \Google\Cloud\SecurityCenter\V1p1beta1\ListFindingsResponse_ListFindingsResult_StateChange::class); - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListNotificationConfigsRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListNotificationConfigsRequest.php deleted file mode 100644 index de399ce20dfe..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListNotificationConfigsRequest.php +++ /dev/null @@ -1,151 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.ListNotificationConfigsRequest - */ -class ListNotificationConfigsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the organization to list notification configs. - * Its format is "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The value returned by the last `ListNotificationConfigsResponse`; indicates - * that this is a continuation of a prior `ListNotificationConfigs` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 2; - */ - protected $page_token = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 3; - */ - protected $page_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Name of the organization to list notification configs. - * Its format is "organizations/[organization_id]". - * @type string $page_token - * The value returned by the last `ListNotificationConfigsResponse`; indicates - * that this is a continuation of a prior `ListNotificationConfigs` call, and - * that the system should return the next page of data. - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the organization to list notification configs. - * Its format is "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Name of the organization to list notification configs. - * Its format is "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The value returned by the last `ListNotificationConfigsResponse`; indicates - * that this is a continuation of a prior `ListNotificationConfigs` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 2; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListNotificationConfigsResponse`; indicates - * that this is a continuation of a prior `ListNotificationConfigs` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 2; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 3; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListNotificationConfigsResponse.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListNotificationConfigsResponse.php deleted file mode 100644 index 89c6439423d1..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListNotificationConfigsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.ListNotificationConfigsResponse - */ -class ListNotificationConfigsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Notification configs belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.NotificationConfig notification_configs = 1; - */ - private $notification_configs; - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig>|\Google\Protobuf\Internal\RepeatedField $notification_configs - * Notification configs belonging to the requested parent. - * @type string $next_page_token - * Token to retrieve the next page of results, or empty if there are no more - * results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Notification configs belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.NotificationConfig notification_configs = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNotificationConfigs() - { - return $this->notification_configs; - } - - /** - * Notification configs belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.NotificationConfig notification_configs = 1; - * @param array<\Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNotificationConfigs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig::class); - $this->notification_configs = $arr; - - return $this; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListSourcesRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListSourcesRequest.php deleted file mode 100644 index 9a7274d12191..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListSourcesRequest.php +++ /dev/null @@ -1,155 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.ListSourcesRequest - */ -class ListSourcesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the parent of sources to list. Its format should be - * "organizations/[organization_id], folders/[folder_id], or - * projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The value returned by the last `ListSourcesResponse`; indicates - * that this is a continuation of a prior `ListSources` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 2; - */ - protected $page_token = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 7; - */ - protected $page_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the parent of sources to list. Its format should be - * "organizations/[organization_id], folders/[folder_id], or - * projects/[project_id]". - * @type string $page_token - * The value returned by the last `ListSourcesResponse`; indicates - * that this is a continuation of a prior `ListSources` call, and - * that the system should return the next page of data. - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the parent of sources to list. Its format should be - * "organizations/[organization_id], folders/[folder_id], or - * projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the parent of sources to list. Its format should be - * "organizations/[organization_id], folders/[folder_id], or - * projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The value returned by the last `ListSourcesResponse`; indicates - * that this is a continuation of a prior `ListSources` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 2; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListSourcesResponse`; indicates - * that this is a continuation of a prior `ListSources` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 2; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 7; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 7; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListSourcesResponse.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListSourcesResponse.php deleted file mode 100644 index da561e81ec42..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/ListSourcesResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.ListSourcesResponse - */ -class ListSourcesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Sources belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Source sources = 1; - */ - private $sources; - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V1p1beta1\Source>|\Google\Protobuf\Internal\RepeatedField $sources - * Sources belonging to the requested parent. - * @type string $next_page_token - * Token to retrieve the next page of results, or empty if there are no more - * results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Sources belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Source sources = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSources() - { - return $this->sources; - } - - /** - * Sources belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Source sources = 1; - * @param array<\Google\Cloud\SecurityCenter\V1p1beta1\Source>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSources($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1p1beta1\Source::class); - $this->sources = $arr; - - return $this; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig.php deleted file mode 100644 index 4c365622d5b1..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig.php +++ /dev/null @@ -1,268 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.NotificationConfig - */ -class NotificationConfig extends \Google\Protobuf\Internal\Message -{ - /** - * The relative resource name of this notification config. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/notificationConfigs/notify_public_bucket". - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The description of the notification config (max of 1024 characters). - * - * Generated from protobuf field string description = 2; - */ - protected $description = ''; - /** - * The type of events the config is for, e.g. FINDING. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig.EventType event_type = 3; - */ - protected $event_type = 0; - /** - * The Pub/Sub topic to send notifications to. Its format is - * "projects/[project_id]/topics/[topic]". - * - * Generated from protobuf field string pubsub_topic = 4 [(.google.api.resource_reference) = { - */ - protected $pubsub_topic = ''; - /** - * Output only. The service account that needs "pubsub.topics.publish" - * permission to publish to the Pub/Sub topic. - * - * Generated from protobuf field string service_account = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $service_account = ''; - protected $notify_config; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The relative resource name of this notification config. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/notificationConfigs/notify_public_bucket". - * @type string $description - * The description of the notification config (max of 1024 characters). - * @type int $event_type - * The type of events the config is for, e.g. FINDING. - * @type string $pubsub_topic - * The Pub/Sub topic to send notifications to. Its format is - * "projects/[project_id]/topics/[topic]". - * @type string $service_account - * Output only. The service account that needs "pubsub.topics.publish" - * permission to publish to the Pub/Sub topic. - * @type \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig\StreamingConfig $streaming_config - * The config for triggering streaming-based notifications. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\NotificationConfig::initOnce(); - parent::__construct($data); - } - - /** - * The relative resource name of this notification config. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/notificationConfigs/notify_public_bucket". - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The relative resource name of this notification config. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/notificationConfigs/notify_public_bucket". - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The description of the notification config (max of 1024 characters). - * - * Generated from protobuf field string description = 2; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * The description of the notification config (max of 1024 characters). - * - * Generated from protobuf field string description = 2; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * The type of events the config is for, e.g. FINDING. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig.EventType event_type = 3; - * @return int - */ - public function getEventType() - { - return $this->event_type; - } - - /** - * The type of events the config is for, e.g. FINDING. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig.EventType event_type = 3; - * @param int $var - * @return $this - */ - public function setEventType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig\EventType::class); - $this->event_type = $var; - - return $this; - } - - /** - * The Pub/Sub topic to send notifications to. Its format is - * "projects/[project_id]/topics/[topic]". - * - * Generated from protobuf field string pubsub_topic = 4 [(.google.api.resource_reference) = { - * @return string - */ - public function getPubsubTopic() - { - return $this->pubsub_topic; - } - - /** - * The Pub/Sub topic to send notifications to. Its format is - * "projects/[project_id]/topics/[topic]". - * - * Generated from protobuf field string pubsub_topic = 4 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setPubsubTopic($var) - { - GPBUtil::checkString($var, True); - $this->pubsub_topic = $var; - - return $this; - } - - /** - * Output only. The service account that needs "pubsub.topics.publish" - * permission to publish to the Pub/Sub topic. - * - * Generated from protobuf field string service_account = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getServiceAccount() - { - return $this->service_account; - } - - /** - * Output only. The service account that needs "pubsub.topics.publish" - * permission to publish to the Pub/Sub topic. - * - * Generated from protobuf field string service_account = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setServiceAccount($var) - { - GPBUtil::checkString($var, True); - $this->service_account = $var; - - return $this; - } - - /** - * The config for triggering streaming-based notifications. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig.StreamingConfig streaming_config = 6; - * @return \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig\StreamingConfig|null - */ - public function getStreamingConfig() - { - return $this->readOneof(6); - } - - public function hasStreamingConfig() - { - return $this->hasOneof(6); - } - - /** - * The config for triggering streaming-based notifications. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig.StreamingConfig streaming_config = 6; - * @param \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig\StreamingConfig $var - * @return $this - */ - public function setStreamingConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig\StreamingConfig::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * @return string - */ - public function getNotifyConfig() - { - return $this->whichOneof("notify_config"); - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig/EventType.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig/EventType.php deleted file mode 100644 index 0b27a01f5961..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig/EventType.php +++ /dev/null @@ -1,57 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.NotificationConfig.EventType - */ -class EventType -{ - /** - * Unspecified event type. - * - * Generated from protobuf enum EVENT_TYPE_UNSPECIFIED = 0; - */ - const EVENT_TYPE_UNSPECIFIED = 0; - /** - * Events for findings. - * - * Generated from protobuf enum FINDING = 1; - */ - const FINDING = 1; - - private static $valueToName = [ - self::EVENT_TYPE_UNSPECIFIED => 'EVENT_TYPE_UNSPECIFIED', - self::FINDING => 'FINDING', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(EventType::class, \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig_EventType::class); - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig/StreamingConfig.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig/StreamingConfig.php deleted file mode 100644 index 448267a7d500..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationConfig/StreamingConfig.php +++ /dev/null @@ -1,131 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.NotificationConfig.StreamingConfig - */ -class StreamingConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Expression that defines the filter to apply across create/update events - * of assets or findings as specified by the event type. The expression is a - * list of zero or more restrictions combined via logical operators `AND` - * and `OR`. Parentheses are supported, and `OR` has higher precedence than - * `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 1; - */ - protected $filter = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $filter - * Expression that defines the filter to apply across create/update events - * of assets or findings as specified by the event type. The expression is a - * list of zero or more restrictions combined via logical operators `AND` - * and `OR`. Parentheses are supported, and `OR` has higher precedence than - * `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\NotificationConfig::initOnce(); - parent::__construct($data); - } - - /** - * Expression that defines the filter to apply across create/update events - * of assets or findings as specified by the event type. The expression is a - * list of zero or more restrictions combined via logical operators `AND` - * and `OR`. Parentheses are supported, and `OR` has higher precedence than - * `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 1; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Expression that defines the filter to apply across create/update events - * of assets or findings as specified by the event type. The expression is a - * list of zero or more restrictions combined via logical operators `AND` - * and `OR`. Parentheses are supported, and `OR` has higher precedence than - * `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 1; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(StreamingConfig::class, \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig_StreamingConfig::class); - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationMessage.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationMessage.php deleted file mode 100644 index b5483ae0f269..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/NotificationMessage.php +++ /dev/null @@ -1,156 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.NotificationMessage - */ -class NotificationMessage extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the notification config that generated current notification. - * - * Generated from protobuf field string notification_config_name = 1; - */ - protected $notification_config_name = ''; - /** - * The Cloud resource tied to the notification. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Resource resource = 3; - */ - protected $resource = null; - protected $event; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $notification_config_name - * Name of the notification config that generated current notification. - * @type \Google\Cloud\SecurityCenter\V1p1beta1\Finding $finding - * If it's a Finding based notification config, this field will be - * populated. - * @type \Google\Cloud\SecurityCenter\V1p1beta1\Resource $resource - * The Cloud resource tied to the notification. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\NotificationMessage::initOnce(); - parent::__construct($data); - } - - /** - * Name of the notification config that generated current notification. - * - * Generated from protobuf field string notification_config_name = 1; - * @return string - */ - public function getNotificationConfigName() - { - return $this->notification_config_name; - } - - /** - * Name of the notification config that generated current notification. - * - * Generated from protobuf field string notification_config_name = 1; - * @param string $var - * @return $this - */ - public function setNotificationConfigName($var) - { - GPBUtil::checkString($var, True); - $this->notification_config_name = $var; - - return $this; - } - - /** - * If it's a Finding based notification config, this field will be - * populated. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 2; - * @return \Google\Cloud\SecurityCenter\V1p1beta1\Finding|null - */ - public function getFinding() - { - return $this->readOneof(2); - } - - public function hasFinding() - { - return $this->hasOneof(2); - } - - /** - * If it's a Finding based notification config, this field will be - * populated. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 2; - * @param \Google\Cloud\SecurityCenter\V1p1beta1\Finding $var - * @return $this - */ - public function setFinding($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Finding::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The Cloud resource tied to the notification. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Resource resource = 3; - * @return \Google\Cloud\SecurityCenter\V1p1beta1\Resource|null - */ - public function getResource() - { - return $this->resource; - } - - public function hasResource() - { - return isset($this->resource); - } - - public function clearResource() - { - unset($this->resource); - } - - /** - * The Cloud resource tied to the notification. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Resource resource = 3; - * @param \Google\Cloud\SecurityCenter\V1p1beta1\Resource $var - * @return $this - */ - public function setResource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Resource::class); - $this->resource = $var; - - return $this; - } - - /** - * @return string - */ - public function getEvent() - { - return $this->whichOneof("event"); - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings.php deleted file mode 100644 index ad4b7cd0210c..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings.php +++ /dev/null @@ -1,170 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.OrganizationSettings - */ -class OrganizationSettings extends \Google\Protobuf\Internal\Message -{ - /** - * The relative resource name of the settings. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/organizationSettings". - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * A flag that indicates if Asset Discovery should be enabled. If the flag is - * set to `true`, then discovery of assets will occur. If it is set to `false, - * all historical assets will remain, but discovery of future assets will not - * occur. - * - * Generated from protobuf field bool enable_asset_discovery = 2; - */ - protected $enable_asset_discovery = false; - /** - * The configuration used for Asset Discovery runs. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.OrganizationSettings.AssetDiscoveryConfig asset_discovery_config = 3; - */ - protected $asset_discovery_config = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The relative resource name of the settings. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/organizationSettings". - * @type bool $enable_asset_discovery - * A flag that indicates if Asset Discovery should be enabled. If the flag is - * set to `true`, then discovery of assets will occur. If it is set to `false, - * all historical assets will remain, but discovery of future assets will not - * occur. - * @type \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings\AssetDiscoveryConfig $asset_discovery_config - * The configuration used for Asset Discovery runs. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\OrganizationSettings::initOnce(); - parent::__construct($data); - } - - /** - * The relative resource name of the settings. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/organizationSettings". - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The relative resource name of the settings. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/organizationSettings". - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * A flag that indicates if Asset Discovery should be enabled. If the flag is - * set to `true`, then discovery of assets will occur. If it is set to `false, - * all historical assets will remain, but discovery of future assets will not - * occur. - * - * Generated from protobuf field bool enable_asset_discovery = 2; - * @return bool - */ - public function getEnableAssetDiscovery() - { - return $this->enable_asset_discovery; - } - - /** - * A flag that indicates if Asset Discovery should be enabled. If the flag is - * set to `true`, then discovery of assets will occur. If it is set to `false, - * all historical assets will remain, but discovery of future assets will not - * occur. - * - * Generated from protobuf field bool enable_asset_discovery = 2; - * @param bool $var - * @return $this - */ - public function setEnableAssetDiscovery($var) - { - GPBUtil::checkBool($var); - $this->enable_asset_discovery = $var; - - return $this; - } - - /** - * The configuration used for Asset Discovery runs. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.OrganizationSettings.AssetDiscoveryConfig asset_discovery_config = 3; - * @return \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings\AssetDiscoveryConfig|null - */ - public function getAssetDiscoveryConfig() - { - return $this->asset_discovery_config; - } - - public function hasAssetDiscoveryConfig() - { - return isset($this->asset_discovery_config); - } - - public function clearAssetDiscoveryConfig() - { - unset($this->asset_discovery_config); - } - - /** - * The configuration used for Asset Discovery runs. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.OrganizationSettings.AssetDiscoveryConfig asset_discovery_config = 3; - * @param \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings\AssetDiscoveryConfig $var - * @return $this - */ - public function setAssetDiscoveryConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings\AssetDiscoveryConfig::class); - $this->asset_discovery_config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings/AssetDiscoveryConfig.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings/AssetDiscoveryConfig.php deleted file mode 100644 index c6eb1dfedea0..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings/AssetDiscoveryConfig.php +++ /dev/null @@ -1,142 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.OrganizationSettings.AssetDiscoveryConfig - */ -class AssetDiscoveryConfig extends \Google\Protobuf\Internal\Message -{ - /** - * The project ids to use for filtering asset discovery. - * - * Generated from protobuf field repeated string project_ids = 1; - */ - private $project_ids; - /** - * The mode to use for filtering asset discovery. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.OrganizationSettings.AssetDiscoveryConfig.InclusionMode inclusion_mode = 2; - */ - protected $inclusion_mode = 0; - /** - * The folder ids to use for filtering asset discovery. - * It consists of only digits, e.g., 756619654966. - * - * Generated from protobuf field repeated string folder_ids = 3; - */ - private $folder_ids; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $project_ids - * The project ids to use for filtering asset discovery. - * @type int $inclusion_mode - * The mode to use for filtering asset discovery. - * @type array|\Google\Protobuf\Internal\RepeatedField $folder_ids - * The folder ids to use for filtering asset discovery. - * It consists of only digits, e.g., 756619654966. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\OrganizationSettings::initOnce(); - parent::__construct($data); - } - - /** - * The project ids to use for filtering asset discovery. - * - * Generated from protobuf field repeated string project_ids = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getProjectIds() - { - return $this->project_ids; - } - - /** - * The project ids to use for filtering asset discovery. - * - * Generated from protobuf field repeated string project_ids = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setProjectIds($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->project_ids = $arr; - - return $this; - } - - /** - * The mode to use for filtering asset discovery. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.OrganizationSettings.AssetDiscoveryConfig.InclusionMode inclusion_mode = 2; - * @return int - */ - public function getInclusionMode() - { - return $this->inclusion_mode; - } - - /** - * The mode to use for filtering asset discovery. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.OrganizationSettings.AssetDiscoveryConfig.InclusionMode inclusion_mode = 2; - * @param int $var - * @return $this - */ - public function setInclusionMode($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings\AssetDiscoveryConfig\InclusionMode::class); - $this->inclusion_mode = $var; - - return $this; - } - - /** - * The folder ids to use for filtering asset discovery. - * It consists of only digits, e.g., 756619654966. - * - * Generated from protobuf field repeated string folder_ids = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFolderIds() - { - return $this->folder_ids; - } - - /** - * The folder ids to use for filtering asset discovery. - * It consists of only digits, e.g., 756619654966. - * - * Generated from protobuf field repeated string folder_ids = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFolderIds($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->folder_ids = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AssetDiscoveryConfig::class, \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings_AssetDiscoveryConfig::class); - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings/AssetDiscoveryConfig/InclusionMode.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings/AssetDiscoveryConfig/InclusionMode.php deleted file mode 100644 index 2e218d0692dc..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/OrganizationSettings/AssetDiscoveryConfig/InclusionMode.php +++ /dev/null @@ -1,74 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.OrganizationSettings.AssetDiscoveryConfig.InclusionMode - */ -class InclusionMode -{ - /** - * Unspecified. Setting the mode with this value will disable - * inclusion/exclusion filtering for Asset Discovery. - * - * Generated from protobuf enum INCLUSION_MODE_UNSPECIFIED = 0; - */ - const INCLUSION_MODE_UNSPECIFIED = 0; - /** - * Asset Discovery will capture only the resources within the projects - * specified. All other resources will be ignored. - * - * Generated from protobuf enum INCLUDE_ONLY = 1; - */ - const INCLUDE_ONLY = 1; - /** - * Asset Discovery will ignore all resources under the projects specified. - * All other resources will be retrieved. - * - * Generated from protobuf enum EXCLUDE = 2; - */ - const EXCLUDE = 2; - - private static $valueToName = [ - self::INCLUSION_MODE_UNSPECIFIED => 'INCLUSION_MODE_UNSPECIFIED', - self::INCLUDE_ONLY => 'INCLUDE_ONLY', - self::EXCLUDE => 'EXCLUDE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(InclusionMode::class, \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings_AssetDiscoveryConfig_InclusionMode::class); - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Resource.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Resource.php deleted file mode 100644 index 1ac6538b8c8d..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Resource.php +++ /dev/null @@ -1,249 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.Resource - */ -class Resource extends \Google\Protobuf\Internal\Message -{ - /** - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The full resource name of project that the resource belongs to. - * - * Generated from protobuf field string project = 2; - */ - protected $project = ''; - /** - * The human readable name of project that the resource belongs to. - * - * Generated from protobuf field string project_display_name = 3; - */ - protected $project_display_name = ''; - /** - * The full resource name of resource's parent. - * - * Generated from protobuf field string parent = 4; - */ - protected $parent = ''; - /** - * The human readable name of resource's parent. - * - * Generated from protobuf field string parent_display_name = 5; - */ - protected $parent_display_name = ''; - /** - * Output only. Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is the - * folder directly under the Organization. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Folder folders = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $folders; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * @type string $project - * The full resource name of project that the resource belongs to. - * @type string $project_display_name - * The human readable name of project that the resource belongs to. - * @type string $parent - * The full resource name of resource's parent. - * @type string $parent_display_name - * The human readable name of resource's parent. - * @type array<\Google\Cloud\SecurityCenter\V1p1beta1\Folder>|\Google\Protobuf\Internal\RepeatedField $folders - * Output only. Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is the - * folder directly under the Organization. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\Resource::initOnce(); - parent::__construct($data); - } - - /** - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The full resource name of project that the resource belongs to. - * - * Generated from protobuf field string project = 2; - * @return string - */ - public function getProject() - { - return $this->project; - } - - /** - * The full resource name of project that the resource belongs to. - * - * Generated from protobuf field string project = 2; - * @param string $var - * @return $this - */ - public function setProject($var) - { - GPBUtil::checkString($var, True); - $this->project = $var; - - return $this; - } - - /** - * The human readable name of project that the resource belongs to. - * - * Generated from protobuf field string project_display_name = 3; - * @return string - */ - public function getProjectDisplayName() - { - return $this->project_display_name; - } - - /** - * The human readable name of project that the resource belongs to. - * - * Generated from protobuf field string project_display_name = 3; - * @param string $var - * @return $this - */ - public function setProjectDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->project_display_name = $var; - - return $this; - } - - /** - * The full resource name of resource's parent. - * - * Generated from protobuf field string parent = 4; - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * The full resource name of resource's parent. - * - * Generated from protobuf field string parent = 4; - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The human readable name of resource's parent. - * - * Generated from protobuf field string parent_display_name = 5; - * @return string - */ - public function getParentDisplayName() - { - return $this->parent_display_name; - } - - /** - * The human readable name of resource's parent. - * - * Generated from protobuf field string parent_display_name = 5; - * @param string $var - * @return $this - */ - public function setParentDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->parent_display_name = $var; - - return $this; - } - - /** - * Output only. Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is the - * folder directly under the Organization. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Folder folders = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFolders() - { - return $this->folders; - } - - /** - * Output only. Contains a Folder message for each folder in the assets ancestry. - * The first folder is the deepest nested folder, and the last folder is the - * folder directly under the Organization. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v1p1beta1.Folder folders = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array<\Google\Cloud\SecurityCenter\V1p1beta1\Folder>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFolders($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V1p1beta1\Folder::class); - $this->folders = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryRequest.php deleted file mode 100644 index 7cf38c3e5319..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryRequest.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.RunAssetDiscoveryRequest - */ -class RunAssetDiscoveryRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the organization to run asset discovery for. Its format is - * "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Name of the organization to run asset discovery for. Its format is - * "organizations/[organization_id]". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the organization to run asset discovery for. Its format is - * "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Name of the organization to run asset discovery for. Its format is - * "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryResponse.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryResponse.php deleted file mode 100644 index 3e04eb554e2a..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryResponse.php +++ /dev/null @@ -1,111 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.RunAssetDiscoveryResponse - */ -class RunAssetDiscoveryResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The state of an asset discovery run. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.RunAssetDiscoveryResponse.State state = 1; - */ - protected $state = 0; - /** - * The duration between asset discovery run start and end - * - * Generated from protobuf field .google.protobuf.Duration duration = 2; - */ - protected $duration = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $state - * The state of an asset discovery run. - * @type \Google\Protobuf\Duration $duration - * The duration between asset discovery run start and end - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\RunAssetDiscoveryResponse::initOnce(); - parent::__construct($data); - } - - /** - * The state of an asset discovery run. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.RunAssetDiscoveryResponse.State state = 1; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * The state of an asset discovery run. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.RunAssetDiscoveryResponse.State state = 1; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1p1beta1\RunAssetDiscoveryResponse\State::class); - $this->state = $var; - - return $this; - } - - /** - * The duration between asset discovery run start and end - * - * Generated from protobuf field .google.protobuf.Duration duration = 2; - * @return \Google\Protobuf\Duration|null - */ - public function getDuration() - { - return $this->duration; - } - - public function hasDuration() - { - return isset($this->duration); - } - - public function clearDuration() - { - unset($this->duration); - } - - /** - * The duration between asset discovery run start and end - * - * Generated from protobuf field .google.protobuf.Duration duration = 2; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setDuration($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->duration = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryResponse/State.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryResponse/State.php deleted file mode 100644 index ca26f2bcbecd..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/RunAssetDiscoveryResponse/State.php +++ /dev/null @@ -1,72 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.RunAssetDiscoveryResponse.State - */ -class State -{ - /** - * Asset discovery run state was unspecified. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * Asset discovery run completed successfully. - * - * Generated from protobuf enum COMPLETED = 1; - */ - const COMPLETED = 1; - /** - * Asset discovery run was cancelled with tasks still pending, as another - * run for the same organization was started with a higher priority. - * - * Generated from protobuf enum SUPERSEDED = 2; - */ - const SUPERSEDED = 2; - /** - * Asset discovery run was killed and terminated. - * - * Generated from protobuf enum TERMINATED = 3; - */ - const TERMINATED = 3; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::COMPLETED => 'COMPLETED', - self::SUPERSEDED => 'SUPERSEDED', - self::TERMINATED => 'TERMINATED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\SecurityCenter\V1p1beta1\RunAssetDiscoveryResponse_State::class); - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/SecurityMarks.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/SecurityMarks.php deleted file mode 100644 index 764bcfd68bb2..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/SecurityMarks.php +++ /dev/null @@ -1,206 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.SecurityMarks - */ -class SecurityMarks extends \Google\Protobuf\Internal\Message -{ - /** - * The relative resource name of the SecurityMarks. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Examples: - * "organizations/{organization_id}/assets/{asset_id}/securityMarks" - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks". - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Mutable user specified security marks belonging to the parent resource. - * Constraints are as follows: - * * Keys and values are treated as case insensitive - * * Keys must be between 1 - 256 characters (inclusive) - * * Keys must be letters, numbers, underscores, or dashes - * * Values have leading and trailing whitespace trimmed, remaining - * characters must be between 1 - 4096 characters (inclusive) - * - * Generated from protobuf field map marks = 2; - */ - private $marks; - /** - * The canonical name of the marks. - * Examples: - * "organizations/{organization_id}/assets/{asset_id}/securityMarks" - * "folders/{folder_id}/assets/{asset_id}/securityMarks" - * "projects/{project_number}/assets/{asset_id}/securityMarks" - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks" - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks" - * "projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks" - * - * Generated from protobuf field string canonical_name = 3; - */ - protected $canonical_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The relative resource name of the SecurityMarks. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Examples: - * "organizations/{organization_id}/assets/{asset_id}/securityMarks" - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks". - * @type array|\Google\Protobuf\Internal\MapField $marks - * Mutable user specified security marks belonging to the parent resource. - * Constraints are as follows: - * * Keys and values are treated as case insensitive - * * Keys must be between 1 - 256 characters (inclusive) - * * Keys must be letters, numbers, underscores, or dashes - * * Values have leading and trailing whitespace trimmed, remaining - * characters must be between 1 - 4096 characters (inclusive) - * @type string $canonical_name - * The canonical name of the marks. - * Examples: - * "organizations/{organization_id}/assets/{asset_id}/securityMarks" - * "folders/{folder_id}/assets/{asset_id}/securityMarks" - * "projects/{project_number}/assets/{asset_id}/securityMarks" - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks" - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks" - * "projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks" - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecurityMarks::initOnce(); - parent::__construct($data); - } - - /** - * The relative resource name of the SecurityMarks. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Examples: - * "organizations/{organization_id}/assets/{asset_id}/securityMarks" - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks". - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The relative resource name of the SecurityMarks. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Examples: - * "organizations/{organization_id}/assets/{asset_id}/securityMarks" - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks". - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Mutable user specified security marks belonging to the parent resource. - * Constraints are as follows: - * * Keys and values are treated as case insensitive - * * Keys must be between 1 - 256 characters (inclusive) - * * Keys must be letters, numbers, underscores, or dashes - * * Values have leading and trailing whitespace trimmed, remaining - * characters must be between 1 - 4096 characters (inclusive) - * - * Generated from protobuf field map marks = 2; - * @return \Google\Protobuf\Internal\MapField - */ - public function getMarks() - { - return $this->marks; - } - - /** - * Mutable user specified security marks belonging to the parent resource. - * Constraints are as follows: - * * Keys and values are treated as case insensitive - * * Keys must be between 1 - 256 characters (inclusive) - * * Keys must be letters, numbers, underscores, or dashes - * * Values have leading and trailing whitespace trimmed, remaining - * characters must be between 1 - 4096 characters (inclusive) - * - * Generated from protobuf field map marks = 2; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setMarks($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->marks = $arr; - - return $this; - } - - /** - * The canonical name of the marks. - * Examples: - * "organizations/{organization_id}/assets/{asset_id}/securityMarks" - * "folders/{folder_id}/assets/{asset_id}/securityMarks" - * "projects/{project_number}/assets/{asset_id}/securityMarks" - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks" - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks" - * "projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks" - * - * Generated from protobuf field string canonical_name = 3; - * @return string - */ - public function getCanonicalName() - { - return $this->canonical_name; - } - - /** - * The canonical name of the marks. - * Examples: - * "organizations/{organization_id}/assets/{asset_id}/securityMarks" - * "folders/{folder_id}/assets/{asset_id}/securityMarks" - * "projects/{project_number}/assets/{asset_id}/securityMarks" - * "organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks" - * "folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks" - * "projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks" - * - * Generated from protobuf field string canonical_name = 3; - * @param string $var - * @return $this - */ - public function setCanonicalName($var) - { - GPBUtil::checkString($var, True); - $this->canonical_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/SetFindingStateRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/SetFindingStateRequest.php deleted file mode 100644 index b4da815ef956..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/SetFindingStateRequest.php +++ /dev/null @@ -1,157 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.SetFindingStateRequest - */ -class SetFindingStateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The relative resource name of the finding. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}/finding/{finding_id}". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. The desired State of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding.State state = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $state = 0; - /** - * Required. The time at which the updated state takes effect. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $start_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The relative resource name of the finding. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}/finding/{finding_id}". - * @type int $state - * Required. The desired State of the finding. - * @type \Google\Protobuf\Timestamp $start_time - * Required. The time at which the updated state takes effect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The relative resource name of the finding. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}/finding/{finding_id}". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The relative resource name of the finding. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}/finding/{finding_id}". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. The desired State of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding.State state = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Required. The desired State of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding.State state = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V1p1beta1\Finding\State::class); - $this->state = $var; - - return $this; - } - - /** - * Required. The time at which the updated state takes effect. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getStartTime() - { - return $this->start_time; - } - - public function hasStartTime() - { - return isset($this->start_time); - } - - public function clearStartTime() - { - unset($this->start_time); - } - - /** - * Required. The time at which the updated state takes effect. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setStartTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->start_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Source.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Source.php deleted file mode 100644 index 494d5ccd87d0..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/Source.php +++ /dev/null @@ -1,243 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.Source - */ -class Source extends \Google\Protobuf\Internal\Message -{ - /** - * The relative resource name of this source. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}" - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The source's display name. - * A source's display name must be unique amongst its siblings, for example, - * two sources with the same parent can't share the same display name. - * The display name must have a length between 1 and 64 characters - * (inclusive). - * - * Generated from protobuf field string display_name = 2; - */ - protected $display_name = ''; - /** - * The description of the source (max of 1024 characters). - * Example: - * "Web Security Scanner is a web security scanner for common - * vulnerabilities in App Engine applications. It can automatically - * scan and detect four common vulnerabilities, including cross-site-scripting - * (XSS), Flash injection, mixed content (HTTP in HTTPS), and - * outdated/insecure libraries." - * - * Generated from protobuf field string description = 3; - */ - protected $description = ''; - /** - * The canonical name of the finding. It's either - * "organizations/{organization_id}/sources/{source_id}", - * "folders/{folder_id}/sources/{source_id}" or - * "projects/{project_number}/sources/{source_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * - * Generated from protobuf field string canonical_name = 14; - */ - protected $canonical_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The relative resource name of this source. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}" - * @type string $display_name - * The source's display name. - * A source's display name must be unique amongst its siblings, for example, - * two sources with the same parent can't share the same display name. - * The display name must have a length between 1 and 64 characters - * (inclusive). - * @type string $description - * The description of the source (max of 1024 characters). - * Example: - * "Web Security Scanner is a web security scanner for common - * vulnerabilities in App Engine applications. It can automatically - * scan and detect four common vulnerabilities, including cross-site-scripting - * (XSS), Flash injection, mixed content (HTTP in HTTPS), and - * outdated/insecure libraries." - * @type string $canonical_name - * The canonical name of the finding. It's either - * "organizations/{organization_id}/sources/{source_id}", - * "folders/{folder_id}/sources/{source_id}" or - * "projects/{project_number}/sources/{source_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\Source::initOnce(); - parent::__construct($data); - } - - /** - * The relative resource name of this source. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}" - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The relative resource name of this source. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}" - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The source's display name. - * A source's display name must be unique amongst its siblings, for example, - * two sources with the same parent can't share the same display name. - * The display name must have a length between 1 and 64 characters - * (inclusive). - * - * Generated from protobuf field string display_name = 2; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * The source's display name. - * A source's display name must be unique amongst its siblings, for example, - * two sources with the same parent can't share the same display name. - * The display name must have a length between 1 and 64 characters - * (inclusive). - * - * Generated from protobuf field string display_name = 2; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * The description of the source (max of 1024 characters). - * Example: - * "Web Security Scanner is a web security scanner for common - * vulnerabilities in App Engine applications. It can automatically - * scan and detect four common vulnerabilities, including cross-site-scripting - * (XSS), Flash injection, mixed content (HTTP in HTTPS), and - * outdated/insecure libraries." - * - * Generated from protobuf field string description = 3; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * The description of the source (max of 1024 characters). - * Example: - * "Web Security Scanner is a web security scanner for common - * vulnerabilities in App Engine applications. It can automatically - * scan and detect four common vulnerabilities, including cross-site-scripting - * (XSS), Flash injection, mixed content (HTTP in HTTPS), and - * outdated/insecure libraries." - * - * Generated from protobuf field string description = 3; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * The canonical name of the finding. It's either - * "organizations/{organization_id}/sources/{source_id}", - * "folders/{folder_id}/sources/{source_id}" or - * "projects/{project_number}/sources/{source_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * - * Generated from protobuf field string canonical_name = 14; - * @return string - */ - public function getCanonicalName() - { - return $this->canonical_name; - } - - /** - * The canonical name of the finding. It's either - * "organizations/{organization_id}/sources/{source_id}", - * "folders/{folder_id}/sources/{source_id}" or - * "projects/{project_number}/sources/{source_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * - * Generated from protobuf field string canonical_name = 14; - * @param string $var - * @return $this - */ - public function setCanonicalName($var) - { - GPBUtil::checkString($var, True); - $this->canonical_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateFindingRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateFindingRequest.php deleted file mode 100644 index f56a1a74b304..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateFindingRequest.php +++ /dev/null @@ -1,157 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.UpdateFindingRequest - */ -class UpdateFindingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The finding resource to update or create if it does not already exist. - * parent, security_marks, and update_time will be ignored. - * In the case of creation, the finding id portion of the name must be - * alphanumeric and less than or equal to 32 characters and greater than 0 - * characters in length. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $finding = null; - /** - * The FieldMask to use when updating the finding resource. This field should - * not be specified when creating a finding. - * When updating a finding, an empty mask is treated as updating all mutable - * fields and replacing source_properties. Individual source_properties can - * be added/updated by using "source_properties." in the field - * mask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1p1beta1\Finding $finding - * Required. The finding resource to update or create if it does not already exist. - * parent, security_marks, and update_time will be ignored. - * In the case of creation, the finding id portion of the name must be - * alphanumeric and less than or equal to 32 characters and greater than 0 - * characters in length. - * @type \Google\Protobuf\FieldMask $update_mask - * The FieldMask to use when updating the finding resource. This field should - * not be specified when creating a finding. - * When updating a finding, an empty mask is treated as updating all mutable - * fields and replacing source_properties. Individual source_properties can - * be added/updated by using "source_properties." in the field - * mask. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The finding resource to update or create if it does not already exist. - * parent, security_marks, and update_time will be ignored. - * In the case of creation, the finding id portion of the name must be - * alphanumeric and less than or equal to 32 characters and greater than 0 - * characters in length. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1p1beta1\Finding|null - */ - public function getFinding() - { - return $this->finding; - } - - public function hasFinding() - { - return isset($this->finding); - } - - public function clearFinding() - { - unset($this->finding); - } - - /** - * Required. The finding resource to update or create if it does not already exist. - * parent, security_marks, and update_time will be ignored. - * In the case of creation, the finding id portion of the name must be - * alphanumeric and less than or equal to 32 characters and greater than 0 - * characters in length. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Finding finding = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1p1beta1\Finding $var - * @return $this - */ - public function setFinding($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Finding::class); - $this->finding = $var; - - return $this; - } - - /** - * The FieldMask to use when updating the finding resource. This field should - * not be specified when creating a finding. - * When updating a finding, an empty mask is treated as updating all mutable - * fields and replacing source_properties. Individual source_properties can - * be added/updated by using "source_properties." in the field - * mask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The FieldMask to use when updating the finding resource. This field should - * not be specified when creating a finding. - * When updating a finding, an empty mask is treated as updating all mutable - * fields and replacing source_properties. Individual source_properties can - * be added/updated by using "source_properties." in the field - * mask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateNotificationConfigRequest.php deleted file mode 100644 index bbd8b7c55d97..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateNotificationConfigRequest.php +++ /dev/null @@ -1,125 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.UpdateNotificationConfigRequest - */ -class UpdateNotificationConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The notification config to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig notification_config = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $notification_config = null; - /** - * The FieldMask to use when updating the notification config. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig $notification_config - * Required. The notification config to update. - * @type \Google\Protobuf\FieldMask $update_mask - * The FieldMask to use when updating the notification config. - * If empty all mutable fields will be updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The notification config to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig notification_config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig|null - */ - public function getNotificationConfig() - { - return $this->notification_config; - } - - public function hasNotificationConfig() - { - return isset($this->notification_config); - } - - public function clearNotificationConfig() - { - unset($this->notification_config); - } - - /** - * Required. The notification config to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.NotificationConfig notification_config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig $var - * @return $this - */ - public function setNotificationConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig::class); - $this->notification_config = $var; - - return $this; - } - - /** - * The FieldMask to use when updating the notification config. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The FieldMask to use when updating the notification config. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateOrganizationSettingsRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateOrganizationSettingsRequest.php deleted file mode 100644 index ab2d90e1566d..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateOrganizationSettingsRequest.php +++ /dev/null @@ -1,125 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.UpdateOrganizationSettingsRequest - */ -class UpdateOrganizationSettingsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The organization settings resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.OrganizationSettings organization_settings = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $organization_settings = null; - /** - * The FieldMask to use when updating the settings resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings $organization_settings - * Required. The organization settings resource to update. - * @type \Google\Protobuf\FieldMask $update_mask - * The FieldMask to use when updating the settings resource. - * If empty all mutable fields will be updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The organization settings resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.OrganizationSettings organization_settings = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings|null - */ - public function getOrganizationSettings() - { - return $this->organization_settings; - } - - public function hasOrganizationSettings() - { - return isset($this->organization_settings); - } - - public function clearOrganizationSettings() - { - unset($this->organization_settings); - } - - /** - * Required. The organization settings resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.OrganizationSettings organization_settings = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings $var - * @return $this - */ - public function setOrganizationSettings($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings::class); - $this->organization_settings = $var; - - return $this; - } - - /** - * The FieldMask to use when updating the settings resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The FieldMask to use when updating the settings resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateSecurityMarksRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateSecurityMarksRequest.php deleted file mode 100644 index eb9d37881735..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateSecurityMarksRequest.php +++ /dev/null @@ -1,185 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.UpdateSecurityMarksRequest - */ -class UpdateSecurityMarksRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The security marks resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.SecurityMarks security_marks = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $security_marks = null; - /** - * The FieldMask to use when updating the security marks resource. - * The field mask must not contain duplicate fields. - * If empty or set to "marks", all marks will be replaced. Individual - * marks can be updated using "marks.". - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - /** - * The time at which the updated SecurityMarks take effect. - * If not set uses current server time. Updates will be applied to the - * SecurityMarks that are active immediately preceding this time. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 3; - */ - protected $start_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks $security_marks - * Required. The security marks resource to update. - * @type \Google\Protobuf\FieldMask $update_mask - * The FieldMask to use when updating the security marks resource. - * The field mask must not contain duplicate fields. - * If empty or set to "marks", all marks will be replaced. Individual - * marks can be updated using "marks.". - * @type \Google\Protobuf\Timestamp $start_time - * The time at which the updated SecurityMarks take effect. - * If not set uses current server time. Updates will be applied to the - * SecurityMarks that are active immediately preceding this time. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The security marks resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.SecurityMarks security_marks = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks|null - */ - public function getSecurityMarks() - { - return $this->security_marks; - } - - public function hasSecurityMarks() - { - return isset($this->security_marks); - } - - public function clearSecurityMarks() - { - unset($this->security_marks); - } - - /** - * Required. The security marks resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.SecurityMarks security_marks = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks $var - * @return $this - */ - public function setSecurityMarks($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks::class); - $this->security_marks = $var; - - return $this; - } - - /** - * The FieldMask to use when updating the security marks resource. - * The field mask must not contain duplicate fields. - * If empty or set to "marks", all marks will be replaced. Individual - * marks can be updated using "marks.". - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The FieldMask to use when updating the security marks resource. - * The field mask must not contain duplicate fields. - * If empty or set to "marks", all marks will be replaced. Individual - * marks can be updated using "marks.". - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - - /** - * The time at which the updated SecurityMarks take effect. - * If not set uses current server time. Updates will be applied to the - * SecurityMarks that are active immediately preceding this time. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 3; - * @return \Google\Protobuf\Timestamp|null - */ - public function getStartTime() - { - return $this->start_time; - } - - public function hasStartTime() - { - return isset($this->start_time); - } - - public function clearStartTime() - { - unset($this->start_time); - } - - /** - * The time at which the updated SecurityMarks take effect. - * If not set uses current server time. Updates will be applied to the - * SecurityMarks that are active immediately preceding this time. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 3; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setStartTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->start_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateSourceRequest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateSourceRequest.php deleted file mode 100644 index ba5092d0370b..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/proto/src/Google/Cloud/SecurityCenter/V1p1beta1/UpdateSourceRequest.php +++ /dev/null @@ -1,125 +0,0 @@ -google.cloud.securitycenter.v1p1beta1.UpdateSourceRequest - */ -class UpdateSourceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The source resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Source source = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $source = null; - /** - * The FieldMask to use when updating the source resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V1p1beta1\Source $source - * Required. The source resource to update. - * @type \Google\Protobuf\FieldMask $update_mask - * The FieldMask to use when updating the source resource. - * If empty all mutable fields will be updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V1P1Beta1\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The source resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Source source = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V1p1beta1\Source|null - */ - public function getSource() - { - return $this->source; - } - - public function hasSource() - { - return isset($this->source); - } - - public function clearSource() - { - unset($this->source); - } - - /** - * Required. The source resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v1p1beta1.Source source = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V1p1beta1\Source $var - * @return $this - */ - public function setSource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V1p1beta1\Source::class); - $this->source = $var; - - return $this; - } - - /** - * The FieldMask to use when updating the source resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The FieldMask to use when updating the source resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_finding.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_finding.php deleted file mode 100644 index a630224198be..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_finding.php +++ /dev/null @@ -1,73 +0,0 @@ -createFinding($formattedParent, $findingId, $finding); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); - $findingId = '[FINDING_ID]'; - - create_finding_sample($formattedParent, $findingId); -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_CreateFinding_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_notification_config.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_notification_config.php deleted file mode 100644 index 8cc391c040f6..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_notification_config.php +++ /dev/null @@ -1,78 +0,0 @@ -createNotificationConfig( - $formattedParent, - $configId, - $notificationConfig - ); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::organizationName('[ORGANIZATION]'); - $configId = '[CONFIG_ID]'; - - create_notification_config_sample($formattedParent, $configId); -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_CreateNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_source.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_source.php deleted file mode 100644 index f7961bb5f7ff..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/create_source.php +++ /dev/null @@ -1,70 +0,0 @@ -createSource($formattedParent, $source); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::organizationName('[ORGANIZATION]'); - - create_source_sample($formattedParent); -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_CreateSource_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/delete_notification_config.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/delete_notification_config.php deleted file mode 100644 index 04f15670b27b..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/delete_notification_config.php +++ /dev/null @@ -1,68 +0,0 @@ -deleteNotificationConfig($formattedName); - printf('Call completed successfully.' . PHP_EOL); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::notificationConfigName( - '[ORGANIZATION]', - '[NOTIFICATION_CONFIG]' - ); - - delete_notification_config_sample($formattedName); -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_DeleteNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_iam_policy.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_iam_policy.php deleted file mode 100644 index fd3f11c4c3d7..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_iam_policy.php +++ /dev/null @@ -1,66 +0,0 @@ -getIamPolicy($resource); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $resource = '[RESOURCE]'; - - get_iam_policy_sample($resource); -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_GetIamPolicy_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_notification_config.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_notification_config.php deleted file mode 100644 index 48e88d1dbf90..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_notification_config.php +++ /dev/null @@ -1,70 +0,0 @@ -getNotificationConfig($formattedName); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::notificationConfigName( - '[ORGANIZATION]', - '[NOTIFICATION_CONFIG]' - ); - - get_notification_config_sample($formattedName); -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_GetNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_organization_settings.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_organization_settings.php deleted file mode 100644 index a37f09e90885..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_organization_settings.php +++ /dev/null @@ -1,67 +0,0 @@ -getOrganizationSettings($formattedName); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::organizationSettingsName('[ORGANIZATION]'); - - get_organization_settings_sample($formattedName); -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_GetOrganizationSettings_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_source.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_source.php deleted file mode 100644 index 8e03ab838dc8..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/get_source.php +++ /dev/null @@ -1,67 +0,0 @@ -getSource($formattedName); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); - - get_source_sample($formattedName); -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_GetSource_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/group_assets.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/group_assets.php deleted file mode 100644 index 9f4a21636d33..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/group_assets.php +++ /dev/null @@ -1,93 +0,0 @@ -groupAssets($formattedParent, $groupBy); - - /** @var GroupResult $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); - $groupBy = '[GROUP_BY]'; - - group_assets_sample($formattedParent, $groupBy); -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_GroupAssets_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/group_findings.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/group_findings.php deleted file mode 100644 index 80364d57cfe8..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/group_findings.php +++ /dev/null @@ -1,99 +0,0 @@ -groupFindings($formattedParent, $groupBy); - - /** @var GroupResult $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); - $groupBy = '[GROUP_BY]'; - - group_findings_sample($formattedParent, $groupBy); -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_GroupFindings_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_assets.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_assets.php deleted file mode 100644 index 0d21434ba3f9..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_assets.php +++ /dev/null @@ -1,73 +0,0 @@ -listAssets($formattedParent); - - /** @var ListAssetsResult $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); - - list_assets_sample($formattedParent); -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_ListAssets_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_findings.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_findings.php deleted file mode 100644 index fd5e808557cc..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_findings.php +++ /dev/null @@ -1,80 +0,0 @@ -listFindings($formattedParent); - - /** @var ListFindingsResult $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); - - list_findings_sample($formattedParent); -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_ListFindings_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_notification_configs.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_notification_configs.php deleted file mode 100644 index 5c80f8598b5d..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_notification_configs.php +++ /dev/null @@ -1,72 +0,0 @@ -listNotificationConfigs($formattedParent); - - /** @var NotificationConfig $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::organizationName('[ORGANIZATION]'); - - list_notification_configs_sample($formattedParent); -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_ListNotificationConfigs_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_sources.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_sources.php deleted file mode 100644 index e6becafb315b..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/list_sources.php +++ /dev/null @@ -1,73 +0,0 @@ -listSources($formattedParent); - - /** @var Source $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); - - list_sources_sample($formattedParent); -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_ListSources_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/run_asset_discovery.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/run_asset_discovery.php deleted file mode 100644 index b2f56f56a4cb..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/run_asset_discovery.php +++ /dev/null @@ -1,84 +0,0 @@ -runAssetDiscovery($formattedParent); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var RunAssetDiscoveryResponse $result */ - $result = $response->getResult(); - printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString()); - } else { - /** @var Status $error */ - $error = $response->getError(); - printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::organizationName('[ORGANIZATION]'); - - run_asset_discovery_sample($formattedParent); -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_RunAssetDiscovery_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/set_finding_state.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/set_finding_state.php deleted file mode 100644 index 0da483cc5b5b..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/set_finding_state.php +++ /dev/null @@ -1,76 +0,0 @@ -setFindingState($formattedName, $state, $startTime); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - $state = State::STATE_UNSPECIFIED; - - set_finding_state_sample($formattedName, $state); -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_SetFindingState_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/set_iam_policy.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/set_iam_policy.php deleted file mode 100644 index b43b7e167485..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/set_iam_policy.php +++ /dev/null @@ -1,69 +0,0 @@ -setIamPolicy($resource, $policy); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $resource = '[RESOURCE]'; - - set_iam_policy_sample($resource); -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_SetIamPolicy_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/test_iam_permissions.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/test_iam_permissions.php deleted file mode 100644 index e9fe6046692a..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/test_iam_permissions.php +++ /dev/null @@ -1,74 +0,0 @@ -testIamPermissions($resource, $permissions); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $resource = '[RESOURCE]'; - $permissionsElement = '[PERMISSIONS]'; - - test_iam_permissions_sample($resource, $permissionsElement); -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_TestIamPermissions_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_finding.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_finding.php deleted file mode 100644 index e5b6e36b45e6..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_finding.php +++ /dev/null @@ -1,57 +0,0 @@ -updateFinding($finding); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_UpdateFinding_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_notification_config.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_notification_config.php deleted file mode 100644 index c16382ce5c3c..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_notification_config.php +++ /dev/null @@ -1,57 +0,0 @@ -updateNotificationConfig($notificationConfig); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_UpdateNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_organization_settings.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_organization_settings.php deleted file mode 100644 index 81879ab5ed8a..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_organization_settings.php +++ /dev/null @@ -1,56 +0,0 @@ -updateOrganizationSettings($organizationSettings); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_UpdateOrganizationSettings_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_security_marks.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_security_marks.php deleted file mode 100644 index 2cbacdf6f4f0..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_security_marks.php +++ /dev/null @@ -1,56 +0,0 @@ -updateSecurityMarks($securityMarks); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_UpdateSecurityMarks_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_source.php b/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_source.php deleted file mode 100644 index cb1c762db9e6..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/samples/V1p1beta1/SecurityCenterClient/update_source.php +++ /dev/null @@ -1,56 +0,0 @@ -updateSource($source); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END securitycenter_v1p1beta1_generated_SecurityCenter_UpdateSource_sync] diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/Gapic/SecurityCenterGapicClient.php b/owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/Gapic/SecurityCenterGapicClient.php deleted file mode 100644 index 7e40c1b4f76f..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/Gapic/SecurityCenterGapicClient.php +++ /dev/null @@ -1,2807 +0,0 @@ -sourceName('[ORGANIZATION]', '[SOURCE]'); - * $findingId = 'finding_id'; - * $finding = new Finding(); - * $response = $securityCenterClient->createFinding($formattedParent, $findingId, $finding); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * Many parameters require resource names to be formatted in a particular way. To - * assist with these names, this class includes a format method for each type of - * name, and additionally a parseName method to extract the individual identifiers - * contained within formatted names that are returned by the API. - * - * @experimental - * - * @deprecated This class will be removed in the next major version update. - */ -class SecurityCenterGapicClient -{ - use GapicClientTrait; - - /** The name of the service. */ - const SERVICE_NAME = 'google.cloud.securitycenter.v1p1beta1.SecurityCenter'; - - /** - * The default address of the service. - * - * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. - */ - const SERVICE_ADDRESS = 'securitycenter.googleapis.com'; - - /** The address template of the service. */ - private const SERVICE_ADDRESS_TEMPLATE = 'securitycenter.UNIVERSE_DOMAIN'; - - /** The default port of the service. */ - const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static $findingNameTemplate; - - private static $folderNameTemplate; - - private static $folderAssetSecurityMarksNameTemplate; - - private static $folderSourceNameTemplate; - - private static $folderSourceFindingNameTemplate; - - private static $folderSourceFindingSecurityMarksNameTemplate; - - private static $notificationConfigNameTemplate; - - private static $organizationNameTemplate; - - private static $organizationAssetSecurityMarksNameTemplate; - - private static $organizationSettingsNameTemplate; - - private static $organizationSourceNameTemplate; - - private static $organizationSourceFindingNameTemplate; - - private static $organizationSourceFindingSecurityMarksNameTemplate; - - private static $projectNameTemplate; - - private static $projectAssetSecurityMarksNameTemplate; - - private static $projectSourceNameTemplate; - - private static $projectSourceFindingNameTemplate; - - private static $projectSourceFindingSecurityMarksNameTemplate; - - private static $securityMarksNameTemplate; - - private static $sourceNameTemplate; - - private static $topicNameTemplate; - - private static $pathTemplateMap; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/security_center_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/security_center_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/security_center_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/security_center_rest_client_config.php', - ], - ], - ]; - } - - private static function getFindingNameTemplate() - { - if (self::$findingNameTemplate == null) { - self::$findingNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}/findings/{finding}'); - } - - return self::$findingNameTemplate; - } - - private static function getFolderNameTemplate() - { - if (self::$folderNameTemplate == null) { - self::$folderNameTemplate = new PathTemplate('folders/{folder}'); - } - - return self::$folderNameTemplate; - } - - private static function getFolderAssetSecurityMarksNameTemplate() - { - if (self::$folderAssetSecurityMarksNameTemplate == null) { - self::$folderAssetSecurityMarksNameTemplate = new PathTemplate('folders/{folder}/assets/{asset}/securityMarks'); - } - - return self::$folderAssetSecurityMarksNameTemplate; - } - - private static function getFolderSourceNameTemplate() - { - if (self::$folderSourceNameTemplate == null) { - self::$folderSourceNameTemplate = new PathTemplate('folders/{folder}/sources/{source}'); - } - - return self::$folderSourceNameTemplate; - } - - private static function getFolderSourceFindingNameTemplate() - { - if (self::$folderSourceFindingNameTemplate == null) { - self::$folderSourceFindingNameTemplate = new PathTemplate('folders/{folder}/sources/{source}/findings/{finding}'); - } - - return self::$folderSourceFindingNameTemplate; - } - - private static function getFolderSourceFindingSecurityMarksNameTemplate() - { - if (self::$folderSourceFindingSecurityMarksNameTemplate == null) { - self::$folderSourceFindingSecurityMarksNameTemplate = new PathTemplate('folders/{folder}/sources/{source}/findings/{finding}/securityMarks'); - } - - return self::$folderSourceFindingSecurityMarksNameTemplate; - } - - private static function getNotificationConfigNameTemplate() - { - if (self::$notificationConfigNameTemplate == null) { - self::$notificationConfigNameTemplate = new PathTemplate('organizations/{organization}/notificationConfigs/{notification_config}'); - } - - return self::$notificationConfigNameTemplate; - } - - private static function getOrganizationNameTemplate() - { - if (self::$organizationNameTemplate == null) { - self::$organizationNameTemplate = new PathTemplate('organizations/{organization}'); - } - - return self::$organizationNameTemplate; - } - - private static function getOrganizationAssetSecurityMarksNameTemplate() - { - if (self::$organizationAssetSecurityMarksNameTemplate == null) { - self::$organizationAssetSecurityMarksNameTemplate = new PathTemplate('organizations/{organization}/assets/{asset}/securityMarks'); - } - - return self::$organizationAssetSecurityMarksNameTemplate; - } - - private static function getOrganizationSettingsNameTemplate() - { - if (self::$organizationSettingsNameTemplate == null) { - self::$organizationSettingsNameTemplate = new PathTemplate('organizations/{organization}/organizationSettings'); - } - - return self::$organizationSettingsNameTemplate; - } - - private static function getOrganizationSourceNameTemplate() - { - if (self::$organizationSourceNameTemplate == null) { - self::$organizationSourceNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}'); - } - - return self::$organizationSourceNameTemplate; - } - - private static function getOrganizationSourceFindingNameTemplate() - { - if (self::$organizationSourceFindingNameTemplate == null) { - self::$organizationSourceFindingNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}/findings/{finding}'); - } - - return self::$organizationSourceFindingNameTemplate; - } - - private static function getOrganizationSourceFindingSecurityMarksNameTemplate() - { - if (self::$organizationSourceFindingSecurityMarksNameTemplate == null) { - self::$organizationSourceFindingSecurityMarksNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}/findings/{finding}/securityMarks'); - } - - return self::$organizationSourceFindingSecurityMarksNameTemplate; - } - - private static function getProjectNameTemplate() - { - if (self::$projectNameTemplate == null) { - self::$projectNameTemplate = new PathTemplate('projects/{project}'); - } - - return self::$projectNameTemplate; - } - - private static function getProjectAssetSecurityMarksNameTemplate() - { - if (self::$projectAssetSecurityMarksNameTemplate == null) { - self::$projectAssetSecurityMarksNameTemplate = new PathTemplate('projects/{project}/assets/{asset}/securityMarks'); - } - - return self::$projectAssetSecurityMarksNameTemplate; - } - - private static function getProjectSourceNameTemplate() - { - if (self::$projectSourceNameTemplate == null) { - self::$projectSourceNameTemplate = new PathTemplate('projects/{project}/sources/{source}'); - } - - return self::$projectSourceNameTemplate; - } - - private static function getProjectSourceFindingNameTemplate() - { - if (self::$projectSourceFindingNameTemplate == null) { - self::$projectSourceFindingNameTemplate = new PathTemplate('projects/{project}/sources/{source}/findings/{finding}'); - } - - return self::$projectSourceFindingNameTemplate; - } - - private static function getProjectSourceFindingSecurityMarksNameTemplate() - { - if (self::$projectSourceFindingSecurityMarksNameTemplate == null) { - self::$projectSourceFindingSecurityMarksNameTemplate = new PathTemplate('projects/{project}/sources/{source}/findings/{finding}/securityMarks'); - } - - return self::$projectSourceFindingSecurityMarksNameTemplate; - } - - private static function getSecurityMarksNameTemplate() - { - if (self::$securityMarksNameTemplate == null) { - self::$securityMarksNameTemplate = new PathTemplate('organizations/{organization}/assets/{asset}/securityMarks'); - } - - return self::$securityMarksNameTemplate; - } - - private static function getSourceNameTemplate() - { - if (self::$sourceNameTemplate == null) { - self::$sourceNameTemplate = new PathTemplate('organizations/{organization}/sources/{source}'); - } - - return self::$sourceNameTemplate; - } - - private static function getTopicNameTemplate() - { - if (self::$topicNameTemplate == null) { - self::$topicNameTemplate = new PathTemplate('projects/{project}/topics/{topic}'); - } - - return self::$topicNameTemplate; - } - - private static function getPathTemplateMap() - { - if (self::$pathTemplateMap == null) { - self::$pathTemplateMap = [ - 'finding' => self::getFindingNameTemplate(), - 'folder' => self::getFolderNameTemplate(), - 'folderAssetSecurityMarks' => self::getFolderAssetSecurityMarksNameTemplate(), - 'folderSource' => self::getFolderSourceNameTemplate(), - 'folderSourceFinding' => self::getFolderSourceFindingNameTemplate(), - 'folderSourceFindingSecurityMarks' => self::getFolderSourceFindingSecurityMarksNameTemplate(), - 'notificationConfig' => self::getNotificationConfigNameTemplate(), - 'organization' => self::getOrganizationNameTemplate(), - 'organizationAssetSecurityMarks' => self::getOrganizationAssetSecurityMarksNameTemplate(), - 'organizationSettings' => self::getOrganizationSettingsNameTemplate(), - 'organizationSource' => self::getOrganizationSourceNameTemplate(), - 'organizationSourceFinding' => self::getOrganizationSourceFindingNameTemplate(), - 'organizationSourceFindingSecurityMarks' => self::getOrganizationSourceFindingSecurityMarksNameTemplate(), - 'project' => self::getProjectNameTemplate(), - 'projectAssetSecurityMarks' => self::getProjectAssetSecurityMarksNameTemplate(), - 'projectSource' => self::getProjectSourceNameTemplate(), - 'projectSourceFinding' => self::getProjectSourceFindingNameTemplate(), - 'projectSourceFindingSecurityMarks' => self::getProjectSourceFindingSecurityMarksNameTemplate(), - 'securityMarks' => self::getSecurityMarksNameTemplate(), - 'source' => self::getSourceNameTemplate(), - 'topic' => self::getTopicNameTemplate(), - ]; - } - - return self::$pathTemplateMap; - } - - /** - * Formats a string containing the fully-qualified path to represent a finding - * resource. - * - * @param string $organization - * @param string $source - * @param string $finding - * - * @return string The formatted finding resource. - * - * @experimental - */ - public static function findingName($organization, $source, $finding) - { - return self::getFindingNameTemplate()->render([ - 'organization' => $organization, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a folder - * resource. - * - * @param string $folder - * - * @return string The formatted folder resource. - * - * @experimental - */ - public static function folderName($folder) - { - return self::getFolderNameTemplate()->render([ - 'folder' => $folder, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_asset_securityMarks resource. - * - * @param string $folder - * @param string $asset - * - * @return string The formatted folder_asset_securityMarks resource. - * - * @experimental - */ - public static function folderAssetSecurityMarksName($folder, $asset) - { - return self::getFolderAssetSecurityMarksNameTemplate()->render([ - 'folder' => $folder, - 'asset' => $asset, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_source resource. - * - * @param string $folder - * @param string $source - * - * @return string The formatted folder_source resource. - * - * @experimental - */ - public static function folderSourceName($folder, $source) - { - return self::getFolderSourceNameTemplate()->render([ - 'folder' => $folder, - 'source' => $source, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_source_finding resource. - * - * @param string $folder - * @param string $source - * @param string $finding - * - * @return string The formatted folder_source_finding resource. - * - * @experimental - */ - public static function folderSourceFindingName($folder, $source, $finding) - { - return self::getFolderSourceFindingNameTemplate()->render([ - 'folder' => $folder, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_source_finding_securityMarks resource. - * - * @param string $folder - * @param string $source - * @param string $finding - * - * @return string The formatted folder_source_finding_securityMarks resource. - * - * @experimental - */ - public static function folderSourceFindingSecurityMarksName($folder, $source, $finding) - { - return self::getFolderSourceFindingSecurityMarksNameTemplate()->render([ - 'folder' => $folder, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * notification_config resource. - * - * @param string $organization - * @param string $notificationConfig - * - * @return string The formatted notification_config resource. - * - * @experimental - */ - public static function notificationConfigName($organization, $notificationConfig) - { - return self::getNotificationConfigNameTemplate()->render([ - 'organization' => $organization, - 'notification_config' => $notificationConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a organization - * resource. - * - * @param string $organization - * - * @return string The formatted organization resource. - * - * @experimental - */ - public static function organizationName($organization) - { - return self::getOrganizationNameTemplate()->render([ - 'organization' => $organization, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_asset_securityMarks resource. - * - * @param string $organization - * @param string $asset - * - * @return string The formatted organization_asset_securityMarks resource. - * - * @experimental - */ - public static function organizationAssetSecurityMarksName($organization, $asset) - { - return self::getOrganizationAssetSecurityMarksNameTemplate()->render([ - 'organization' => $organization, - 'asset' => $asset, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_settings resource. - * - * @param string $organization - * - * @return string The formatted organization_settings resource. - * - * @experimental - */ - public static function organizationSettingsName($organization) - { - return self::getOrganizationSettingsNameTemplate()->render([ - 'organization' => $organization, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_source resource. - * - * @param string $organization - * @param string $source - * - * @return string The formatted organization_source resource. - * - * @experimental - */ - public static function organizationSourceName($organization, $source) - { - return self::getOrganizationSourceNameTemplate()->render([ - 'organization' => $organization, - 'source' => $source, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_source_finding resource. - * - * @param string $organization - * @param string $source - * @param string $finding - * - * @return string The formatted organization_source_finding resource. - * - * @experimental - */ - public static function organizationSourceFindingName($organization, $source, $finding) - { - return self::getOrganizationSourceFindingNameTemplate()->render([ - 'organization' => $organization, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_source_finding_securityMarks resource. - * - * @param string $organization - * @param string $source - * @param string $finding - * - * @return string The formatted organization_source_finding_securityMarks resource. - * - * @experimental - */ - public static function organizationSourceFindingSecurityMarksName($organization, $source, $finding) - { - return self::getOrganizationSourceFindingSecurityMarksNameTemplate()->render([ - 'organization' => $organization, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a project - * resource. - * - * @param string $project - * - * @return string The formatted project resource. - * - * @experimental - */ - public static function projectName($project) - { - return self::getProjectNameTemplate()->render([ - 'project' => $project, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_asset_securityMarks resource. - * - * @param string $project - * @param string $asset - * - * @return string The formatted project_asset_securityMarks resource. - * - * @experimental - */ - public static function projectAssetSecurityMarksName($project, $asset) - { - return self::getProjectAssetSecurityMarksNameTemplate()->render([ - 'project' => $project, - 'asset' => $asset, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_source resource. - * - * @param string $project - * @param string $source - * - * @return string The formatted project_source resource. - * - * @experimental - */ - public static function projectSourceName($project, $source) - { - return self::getProjectSourceNameTemplate()->render([ - 'project' => $project, - 'source' => $source, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_source_finding resource. - * - * @param string $project - * @param string $source - * @param string $finding - * - * @return string The formatted project_source_finding resource. - * - * @experimental - */ - public static function projectSourceFindingName($project, $source, $finding) - { - return self::getProjectSourceFindingNameTemplate()->render([ - 'project' => $project, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_source_finding_securityMarks resource. - * - * @param string $project - * @param string $source - * @param string $finding - * - * @return string The formatted project_source_finding_securityMarks resource. - * - * @experimental - */ - public static function projectSourceFindingSecurityMarksName($project, $source, $finding) - { - return self::getProjectSourceFindingSecurityMarksNameTemplate()->render([ - 'project' => $project, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * security_marks resource. - * - * @param string $organization - * @param string $asset - * - * @return string The formatted security_marks resource. - * - * @experimental - */ - public static function securityMarksName($organization, $asset) - { - return self::getSecurityMarksNameTemplate()->render([ - 'organization' => $organization, - 'asset' => $asset, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a source - * resource. - * - * @param string $organization - * @param string $source - * - * @return string The formatted source resource. - * - * @experimental - */ - public static function sourceName($organization, $source) - { - return self::getSourceNameTemplate()->render([ - 'organization' => $organization, - 'source' => $source, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a topic - * resource. - * - * @param string $project - * @param string $topic - * - * @return string The formatted topic resource. - * - * @experimental - */ - public static function topicName($project, $topic) - { - return self::getTopicNameTemplate()->render([ - 'project' => $project, - 'topic' => $topic, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - finding: organizations/{organization}/sources/{source}/findings/{finding} - * - folder: folders/{folder} - * - folderAssetSecurityMarks: folders/{folder}/assets/{asset}/securityMarks - * - folderSource: folders/{folder}/sources/{source} - * - folderSourceFinding: folders/{folder}/sources/{source}/findings/{finding} - * - folderSourceFindingSecurityMarks: folders/{folder}/sources/{source}/findings/{finding}/securityMarks - * - notificationConfig: organizations/{organization}/notificationConfigs/{notification_config} - * - organization: organizations/{organization} - * - organizationAssetSecurityMarks: organizations/{organization}/assets/{asset}/securityMarks - * - organizationSettings: organizations/{organization}/organizationSettings - * - organizationSource: organizations/{organization}/sources/{source} - * - organizationSourceFinding: organizations/{organization}/sources/{source}/findings/{finding} - * - organizationSourceFindingSecurityMarks: organizations/{organization}/sources/{source}/findings/{finding}/securityMarks - * - project: projects/{project} - * - projectAssetSecurityMarks: projects/{project}/assets/{asset}/securityMarks - * - projectSource: projects/{project}/sources/{source} - * - projectSourceFinding: projects/{project}/sources/{source}/findings/{finding} - * - projectSourceFindingSecurityMarks: projects/{project}/sources/{source}/findings/{finding}/securityMarks - * - securityMarks: organizations/{organization}/assets/{asset}/securityMarks - * - source: organizations/{organization}/sources/{source} - * - topic: projects/{project}/topics/{topic} - * - * The optional $template argument can be supplied to specify a particular pattern, - * and must match one of the templates listed above. If no $template argument is - * provided, or if the $template argument does not match one of the templates - * listed, then parseName will check each of the supported templates, and return - * the first match. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - * - * @experimental - */ - public static function parseName($formattedName, $template = null) - { - $templateMap = self::getPathTemplateMap(); - if ($template) { - if (!isset($templateMap[$template])) { - throw new ValidationException("Template name $template does not exist"); - } - - return $templateMap[$template]->match($formattedName); - } - - foreach ($templateMap as $templateName => $pathTemplate) { - try { - return $pathTemplate->match($formattedName); - } catch (ValidationException $ex) { - // Swallow the exception to continue trying other path templates - } - } - - throw new ValidationException("Input did not match any known format. Input: $formattedName"); - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - * - * @experimental - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * Resume an existing long running operation that was previously started by a long - * running API method. If $methodName is not provided, or does not match a long - * running API method, then the operation can still be resumed, but the - * OperationResponse object will not deserialize the final response. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - * - * @experimental - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'securitycenter.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * Client method configuration, including retry settings. This option can be either - * a path to a JSON file, or a PHP array containing the decoded JSON data. By - * default this settings points to the default client config file, which is - * provided in the resources folder. - * @type string|TransportInterface $transport - * The transport used for executing network requests. May be either the string - * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. - * *Advanced usage*: Additionally, it is possible to pass in an already - * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * Configuration options that will be used to construct the transport. Options for - * each supported transport type should be passed in a key for that transport. For - * example: - * $transportConfig = [ - * 'grpc' => [...], - * 'rest' => [...], - * ]; - * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * A callable which returns the client cert as a string. This can be used to - * provide a certificate and private key to the transport layer for mTLS. - * } - * - * @throws ValidationException - * - * @experimental - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** - * Creates a finding. The corresponding source must exist for finding - * creation to succeed. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - * $findingId = 'finding_id'; - * $finding = new Finding(); - * $response = $securityCenterClient->createFinding($formattedParent, $findingId, $finding); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Resource name of the new finding's parent. Its format should be - * "organizations/[organization_id]/sources/[source_id]". - * @param string $findingId Required. Unique identifier provided by the client within the parent scope. - * @param Finding $finding Required. The Finding being created. The name and security_marks will be ignored as - * they are both output only fields on this resource. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1p1beta1\Finding - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function createFinding($parent, $findingId, $finding, array $optionalArgs = []) - { - $request = new CreateFindingRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setFindingId($findingId); - $request->setFinding($finding); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateFinding', Finding::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a notification config. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->organizationName('[ORGANIZATION]'); - * $configId = 'config_id'; - * $notificationConfig = new NotificationConfig(); - * $response = $securityCenterClient->createNotificationConfig($formattedParent, $configId, $notificationConfig); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Resource name of the new notification config's parent. Its format is - * "organizations/[organization_id]". - * @param string $configId Required. Unique identifier provided by the client within the parent scope. - * It must be between 1 and 128 characters, and contains alphanumeric - * characters, underscores or hyphens only. - * @param NotificationConfig $notificationConfig Required. The notification config being created. The name and the service account - * will be ignored as they are both output only fields on this resource. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function createNotificationConfig($parent, $configId, $notificationConfig, array $optionalArgs = []) - { - $request = new CreateNotificationConfigRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setConfigId($configId); - $request->setNotificationConfig($notificationConfig); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateNotificationConfig', NotificationConfig::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates a source. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->organizationName('[ORGANIZATION]'); - * $source = new Source(); - * $response = $securityCenterClient->createSource($formattedParent, $source); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Resource name of the new source's parent. Its format should be - * "organizations/[organization_id]". - * @param Source $source Required. The Source being created, only the display_name and description will be - * used. All other fields will be ignored. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1p1beta1\Source - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function createSource($parent, $source, array $optionalArgs = []) - { - $request = new CreateSourceRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setSource($source); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('CreateSource', Source::class, $optionalArgs, $request)->wait(); - } - - /** - * Deletes a notification config. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedName = $securityCenterClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); - * $securityCenterClient->deleteNotificationConfig($formattedName); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the notification config to delete. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]". - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function deleteNotificationConfig($name, array $optionalArgs = []) - { - $request = new DeleteNotificationConfigRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('DeleteNotificationConfig', GPBEmpty::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets the access control policy on the specified Source. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $resource = 'resource'; - * $response = $securityCenterClient->getIamPolicy($resource); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - * @param array $optionalArgs { - * Optional. - * - * @type GetPolicyOptions $options - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function getIamPolicy($resource, array $optionalArgs = []) - { - $request = new GetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['options'])) { - $request->setOptions($optionalArgs['options']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetIamPolicy', Policy::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets a notification config. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedName = $securityCenterClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); - * $response = $securityCenterClient->getNotificationConfig($formattedName); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the notification config to get. Its format is - * "organizations/[organization_id]/notificationConfigs/[config_id]". - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function getNotificationConfig($name, array $optionalArgs = []) - { - $request = new GetNotificationConfigRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetNotificationConfig', NotificationConfig::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets the settings for an organization. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedName = $securityCenterClient->organizationSettingsName('[ORGANIZATION]'); - * $response = $securityCenterClient->getOrganizationSettings($formattedName); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $name Required. Name of the organization to get organization settings for. Its format is - * "organizations/[organization_id]/organizationSettings". - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function getOrganizationSettings($name, array $optionalArgs = []) - { - $request = new GetOrganizationSettingsRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetOrganizationSettings', OrganizationSettings::class, $optionalArgs, $request)->wait(); - } - - /** - * Gets a source. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedName = $securityCenterClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - * $response = $securityCenterClient->getSource($formattedName); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $name Required. Relative resource name of the source. Its format is - * "organizations/[organization_id]/source/[source_id]". - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1p1beta1\Source - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function getSource($name, array $optionalArgs = []) - { - $request = new GetSourceRequest(); - $requestParamHeaders = []; - $request->setName($name); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('GetSource', Source::class, $optionalArgs, $request)->wait(); - } - - /** - * Filters an organization's assets and groups them by their specified - * properties. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); - * $groupBy = 'group_by'; - * // Iterate over pages of elements - * $pagedResponse = $securityCenterClient->groupAssets($formattedParent, $groupBy); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $securityCenterClient->groupAssets($formattedParent, $groupBy); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Name of the organization to groupBy. Its format is - * "organizations/[organization_id], folders/[folder_id], or - * projects/[project_id]". - * @param string $groupBy Required. Expression that defines what assets fields to use for grouping. The string - * value should follow SQL syntax: comma separated list of fields. For - * example: - * "security_center_properties.resource_project,security_center_properties.project". - * - * The following fields are supported when compare_duration is not set: - * - * * security_center_properties.resource_project - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_type - * * security_center_properties.resource_parent - * * security_center_properties.resource_parent_display_name - * - * The following fields are supported when compare_duration is set: - * - * * security_center_properties.resource_type - * * security_center_properties.resource_project_display_name - * * security_center_properties.resource_parent_display_name - * @param array $optionalArgs { - * Optional. - * - * @type string $filter - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * - * The supported operators are: - * - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * - * The supported value types are: - * - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * The following field and operator combinations are supported: - * - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_name_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * - * For example, `resource_properties.size = 100` is a valid filter string. - * - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * @type Duration $compareDuration - * When compare_duration is set, the GroupResult's "state_change" property is - * updated to indicate whether the asset was added, removed, or remained - * present during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * - * The state change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * - * Possible "state_change" values when compare_duration is specified: - * - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at reference_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at reference_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and reference_time. - * - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * @type Timestamp $readTime - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function groupAssets($parent, $groupBy, array $optionalArgs = []) - { - $request = new GroupAssetsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setGroupBy($groupBy); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['compareDuration'])) { - $request->setCompareDuration($optionalArgs['compareDuration']); - } - - if (isset($optionalArgs['readTime'])) { - $request->setReadTime($optionalArgs['readTime']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('GroupAssets', $optionalArgs, GroupAssetsResponse::class, $request); - } - - /** - * Filters an organization or source's findings and groups them by their - * specified properties. - * - * To group across all sources provide a `-` as the source id. - * Example: /v1/organizations/{organization_id}/sources/-/findings, - * /v1/folders/{folder_id}/sources/-/findings, - * /v1/projects/{project_id}/sources/-/findings - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - * $groupBy = 'group_by'; - * // Iterate over pages of elements - * $pagedResponse = $securityCenterClient->groupFindings($formattedParent, $groupBy); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $securityCenterClient->groupFindings($formattedParent, $groupBy); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Name of the source to groupBy. Its format is - * "organizations/[organization_id]/sources/[source_id]", - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]. To groupBy across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/-, - * or projects/{project_id}/sources/- - * @param string $groupBy Required. Expression that defines what assets fields to use for grouping (including - * `state_change`). The string value should follow SQL syntax: comma separated - * list of fields. For example: "parent,resource_name". - * - * The following fields are supported: - * - * * resource_name - * * category - * * state - * * parent - * * severity - * - * The following fields are supported when compare_duration is set: - * - * * state_change - * @param array $optionalArgs { - * Optional. - * - * @type string $filter - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * - * The supported operators are: - * - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * - * The supported value types are: - * - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * The following field and operator combinations are supported: - * - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * * severity: `=`, `:` - * - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * - * * security_marks.marks: `=`, `:` - * * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * - * For example, `source_properties.size = 100` is a valid filter string. - * - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * @type Timestamp $readTime - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * @type Duration $compareDuration - * When compare_duration is set, the GroupResult's "state_change" attribute is - * updated to indicate whether the finding had its state changed, the - * finding's state remained unchanged, or if the finding was added during the - * compare_duration period of time that precedes the read_time. This is the - * time between (read_time - compare_duration) and read_time. - * - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * - * Possible "state_change" values when compare_duration is specified: - * - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present - * at read_time. - * - * If this field is set then `state_change` must be a specified field in - * `group_by`. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function groupFindings($parent, $groupBy, array $optionalArgs = []) - { - $request = new GroupFindingsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $request->setGroupBy($groupBy); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['readTime'])) { - $request->setReadTime($optionalArgs['readTime']); - } - - if (isset($optionalArgs['compareDuration'])) { - $request->setCompareDuration($optionalArgs['compareDuration']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('GroupFindings', $optionalArgs, GroupFindingsResponse::class, $request); - } - - /** - * Lists an organization's assets. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); - * // Iterate over pages of elements - * $pagedResponse = $securityCenterClient->listAssets($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $securityCenterClient->listAssets($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Name of the organization assets should belong to. Its format is - * "organizations/[organization_id], folders/[folder_id], or - * projects/[project_id]". - * @param array $optionalArgs { - * Optional. - * - * @type string $filter - * Expression that defines the filter to apply across assets. - * The expression is a list of zero or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. The fields map to those - * defined in the Asset resource. Examples include: - * - * * name - * * security_center_properties.resource_name - * * resource_properties.a_property - * * security_marks.marks.marka - * - * The supported operators are: - * - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * - * The supported value types are: - * - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * The following are the allowed field and operator combinations: - * - * * name: `=` - * * update_time: `=`, `>`, `<`, `>=`, `<=` - * - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `update_time = "2019-06-10T16:07:18-07:00"` - * `update_time = 1560208038000` - * - * * create_time: `=`, `>`, `<`, `>=`, `<=` - * - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `create_time = "2019-06-10T16:07:18-07:00"` - * `create_time = 1560208038000` - * - * * iam_policy.policy_blob: `=`, `:` - * * resource_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * * security_marks.marks: `=`, `:` - * * security_center_properties.resource_name: `=`, `:` - * * security_center_properties.resource_display_name: `=`, `:` - * * security_center_properties.resource_type: `=`, `:` - * * security_center_properties.resource_parent: `=`, `:` - * * security_center_properties.resource_parent_display_name: `=`, `:` - * * security_center_properties.resource_project: `=`, `:` - * * security_center_properties.resource_project_display_name: `=`, `:` - * * security_center_properties.resource_owners: `=`, `:` - * - * For example, `resource_properties.size = 100` is a valid filter string. - * - * Use a partial match on the empty string to filter based on a property - * existing: `resource_properties.my_property : ""` - * - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-resource_properties.my_property : ""` - * @type string $orderBy - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,resource_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,resource_properties.a_property" and " - * name desc , resource_properties.a_property " are equivalent. - * - * The following fields are supported: - * name - * update_time - * resource_properties - * security_marks.marks - * security_center_properties.resource_name - * security_center_properties.resource_display_name - * security_center_properties.resource_parent - * security_center_properties.resource_parent_display_name - * security_center_properties.resource_project - * security_center_properties.resource_project_display_name - * security_center_properties.resource_type - * @type Timestamp $readTime - * Time used as a reference point when filtering assets. The filter is limited - * to assets existing at the supplied time and their values are those at that - * specific time. Absence of this field will default to the API's version of - * NOW. - * @type Duration $compareDuration - * When compare_duration is set, the ListAssetsResult's "state_change" - * attribute is updated to indicate whether the asset was added, removed, or - * remained present during the compare_duration period of time that precedes - * the read_time. This is the time between (read_time - compare_duration) and - * read_time. - * - * The state_change value is derived based on the presence of the asset at the - * two points in time. Intermediate state changes between the two times don't - * affect the result. For example, the results aren't affected if the asset is - * removed and re-created again. - * - * Possible "state_change" values when compare_duration is specified: - * - * * "ADDED": indicates that the asset was not present at the start of - * compare_duration, but present at read_time. - * * "REMOVED": indicates that the asset was present at the start of - * compare_duration, but not present at read_time. - * * "ACTIVE": indicates that the asset was present at both the - * start and the end of the time period defined by - * compare_duration and read_time. - * - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all assets present at - * read_time. - * @type FieldMask $fieldMask - * A field mask to specify the ListAssetsResult fields to be listed in the - * response. - * An empty field mask will list all fields. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function listAssets($parent, array $optionalArgs = []) - { - $request = new ListAssetsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - if (isset($optionalArgs['readTime'])) { - $request->setReadTime($optionalArgs['readTime']); - } - - if (isset($optionalArgs['compareDuration'])) { - $request->setCompareDuration($optionalArgs['compareDuration']); - } - - if (isset($optionalArgs['fieldMask'])) { - $request->setFieldMask($optionalArgs['fieldMask']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListAssets', $optionalArgs, ListAssetsResponse::class, $request); - } - - /** - * Lists an organization or source's findings. - * - * To list across all sources provide a `-` as the source id. - * Example: /v1p1beta1/organizations/{organization_id}/sources/-/findings - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - * // Iterate over pages of elements - * $pagedResponse = $securityCenterClient->listFindings($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $securityCenterClient->listFindings($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Name of the source the findings belong to. Its format is - * "organizations/[organization_id]/sources/[source_id], - * folders/[folder_id]/sources/[source_id], or - * projects/[project_id]/sources/[source_id]". To list across all sources - * provide a source_id of `-`. For example: - * organizations/{organization_id}/sources/-, folders/{folder_id}/sources/- or - * projects/{projects_id}/sources/- - * @param array $optionalArgs { - * Optional. - * - * @type string $filter - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * - * * name - * * source_properties.a_property - * * security_marks.marks.marka - * - * The supported operators are: - * - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * - * The supported value types are: - * - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * The following field and operator combinations are supported: - * - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * * severity: `=`, `:` - * - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * - * security_marks.marks: `=`, `:` - * source_properties: `=`, `:`, `>`, `<`, `>=`, `<=` - * - * For example, `source_properties.size = 100` is a valid filter string. - * - * Use a partial match on the empty string to filter based on a property - * existing: `source_properties.my_property : ""` - * - * Use a negated partial match on the empty string to filter based on a - * property not existing: `-source_properties.my_property : ""` - * @type string $orderBy - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,resource_properties.a_property". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,source_properties.a_property". Redundant space characters in the - * syntax are insignificant. "name desc,source_properties.a_property" and " - * name desc , source_properties.a_property " are equivalent. - * - * The following fields are supported: - * name - * parent - * state - * category - * resource_name - * event_time - * source_properties - * security_marks.marks - * @type Timestamp $readTime - * Time used as a reference point when filtering findings. The filter is - * limited to findings existing at the supplied time and their values are - * those at that specific time. Absence of this field will default to the - * API's version of NOW. - * @type Duration $compareDuration - * When compare_duration is set, the ListFindingsResult's "state_change" - * attribute is updated to indicate whether the finding had its state changed, - * the finding's state remained unchanged, or if the finding was added in any - * state during the compare_duration period of time that precedes the - * read_time. This is the time between (read_time - compare_duration) and - * read_time. - * - * The state_change value is derived based on the presence and state of the - * finding at the two points in time. Intermediate state changes between the - * two times don't affect the result. For example, the results aren't affected - * if the finding is made inactive and then active again. - * - * Possible "state_change" values when compare_duration is specified: - * - * * "CHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration, but changed its - * state at read_time. - * * "UNCHANGED": indicates that the finding was present and matched the given - * filter at the start of compare_duration and did not change - * state at read_time. - * * "ADDED": indicates that the finding did not match the given filter or - * was not present at the start of compare_duration, but was - * present at read_time. - * * "REMOVED": indicates that the finding was present and matched the - * filter at the start of compare_duration, but did not match - * the filter at read_time. - * - * If compare_duration is not specified, then the only possible state_change - * is "UNUSED", which will be the state_change set for all findings present at - * read_time. - * @type FieldMask $fieldMask - * A field mask to specify the Finding fields to be listed in the response. - * An empty field mask will list all fields. - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function listFindings($parent, array $optionalArgs = []) - { - $request = new ListFindingsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['filter'])) { - $request->setFilter($optionalArgs['filter']); - } - - if (isset($optionalArgs['orderBy'])) { - $request->setOrderBy($optionalArgs['orderBy']); - } - - if (isset($optionalArgs['readTime'])) { - $request->setReadTime($optionalArgs['readTime']); - } - - if (isset($optionalArgs['compareDuration'])) { - $request->setCompareDuration($optionalArgs['compareDuration']); - } - - if (isset($optionalArgs['fieldMask'])) { - $request->setFieldMask($optionalArgs['fieldMask']); - } - - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListFindings', $optionalArgs, ListFindingsResponse::class, $request); - } - - /** - * Lists notification configs. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->organizationName('[ORGANIZATION]'); - * // Iterate over pages of elements - * $pagedResponse = $securityCenterClient->listNotificationConfigs($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $securityCenterClient->listNotificationConfigs($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Name of the organization to list notification configs. - * Its format is "organizations/[organization_id]". - * @param array $optionalArgs { - * Optional. - * - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function listNotificationConfigs($parent, array $optionalArgs = []) - { - $request = new ListNotificationConfigsRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListNotificationConfigs', $optionalArgs, ListNotificationConfigsResponse::class, $request); - } - - /** - * Lists all sources belonging to an organization. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->projectName('[PROJECT]'); - * // Iterate over pages of elements - * $pagedResponse = $securityCenterClient->listSources($formattedParent); - * foreach ($pagedResponse->iteratePages() as $page) { - * foreach ($page as $element) { - * // doSomethingWith($element); - * } - * } - * // Alternatively: - * // Iterate through all elements - * $pagedResponse = $securityCenterClient->listSources($formattedParent); - * foreach ($pagedResponse->iterateAllElements() as $element) { - * // doSomethingWith($element); - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Resource name of the parent of sources to list. Its format should be - * "organizations/[organization_id], folders/[folder_id], or - * projects/[project_id]". - * @param array $optionalArgs { - * Optional. - * - * @type string $pageToken - * A page token is used to specify a page of values to be returned. - * If no page token is specified (the default), the first page - * of values will be returned. Any page token used here must have - * been generated by a previous call to the API. - * @type int $pageSize - * The maximum number of resources contained in the underlying API - * response. The API may return fewer values in a page, even if - * there are additional values to be retrieved. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\PagedListResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function listSources($parent, array $optionalArgs = []) - { - $request = new ListSourcesRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - if (isset($optionalArgs['pageToken'])) { - $request->setPageToken($optionalArgs['pageToken']); - } - - if (isset($optionalArgs['pageSize'])) { - $request->setPageSize($optionalArgs['pageSize']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->getPagedListResponse('ListSources', $optionalArgs, ListSourcesResponse::class, $request); - } - - /** - * Runs asset discovery. The discovery is tracked with a long-running - * operation. - * - * This API can only be called with limited frequency for an organization. If - * it is called too frequently the caller will receive a TOO_MANY_REQUESTS - * error. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedParent = $securityCenterClient->organizationName('[ORGANIZATION]'); - * $operationResponse = $securityCenterClient->runAssetDiscovery($formattedParent); - * $operationResponse->pollUntilComplete(); - * if ($operationResponse->operationSucceeded()) { - * $result = $operationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $operationResponse->getError(); - * // handleError($error) - * } - * // Alternatively: - * // start the operation, keep the operation name, and resume later - * $operationResponse = $securityCenterClient->runAssetDiscovery($formattedParent); - * $operationName = $operationResponse->getName(); - * // ... do other work - * $newOperationResponse = $securityCenterClient->resumeOperation($operationName, 'runAssetDiscovery'); - * while (!$newOperationResponse->isDone()) { - * // ... do other work - * $newOperationResponse->reload(); - * } - * if ($newOperationResponse->operationSucceeded()) { - * $result = $newOperationResponse->getResult(); - * // doSomethingWith($result) - * } else { - * $error = $newOperationResponse->getError(); - * // handleError($error) - * } - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $parent Required. Name of the organization to run asset discovery for. Its format is - * "organizations/[organization_id]". - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\ApiCore\OperationResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function runAssetDiscovery($parent, array $optionalArgs = []) - { - $request = new RunAssetDiscoveryRequest(); - $requestParamHeaders = []; - $request->setParent($parent); - $requestParamHeaders['parent'] = $parent; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startOperationsCall('RunAssetDiscovery', $optionalArgs, $request, $this->getOperationsClient())->wait(); - } - - /** - * Updates the state of a finding. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $formattedName = $securityCenterClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - * $state = State::STATE_UNSPECIFIED; - * $startTime = new Timestamp(); - * $response = $securityCenterClient->setFindingState($formattedName, $state, $startTime); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $name Required. The relative resource name of the finding. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}/finding/{finding_id}". - * @param int $state Required. The desired State of the finding. - * For allowed values, use constants defined on {@see \Google\Cloud\SecurityCenter\V1p1beta1\Finding\State} - * @param Timestamp $startTime Required. The time at which the updated state takes effect. - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1p1beta1\Finding - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function setFindingState($name, $state, $startTime, array $optionalArgs = []) - { - $request = new SetFindingStateRequest(); - $requestParamHeaders = []; - $request->setName($name); - $request->setState($state); - $request->setStartTime($startTime); - $requestParamHeaders['name'] = $name; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SetFindingState', Finding::class, $optionalArgs, $request)->wait(); - } - - /** - * Sets the access control policy on the specified Source. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $resource = 'resource'; - * $policy = new Policy(); - * $response = $securityCenterClient->setIamPolicy($resource, $policy); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - * @param Policy $policy REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * - * `paths: "bindings, etag"` - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\Policy - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function setIamPolicy($resource, $policy, array $optionalArgs = []) - { - $request = new SetIamPolicyRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPolicy($policy); - $requestParamHeaders['resource'] = $resource; - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('SetIamPolicy', Policy::class, $optionalArgs, $request)->wait(); - } - - /** - * Returns the permissions that a caller has on the specified source. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $resource = 'resource'; - * $permissions = []; - * $response = $securityCenterClient->testIamPermissions($resource, $permissions); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param string $resource REQUIRED: The resource for which the policy detail is being requested. - * See the operation documentation for the appropriate value for this field. - * @param string[] $permissions The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - * @param array $optionalArgs { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\Iam\V1\TestIamPermissionsResponse - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function testIamPermissions($resource, $permissions, array $optionalArgs = []) - { - $request = new TestIamPermissionsRequest(); - $requestParamHeaders = []; - $request->setResource($resource); - $request->setPermissions($permissions); - $requestParamHeaders['resource'] = $resource; - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('TestIamPermissions', TestIamPermissionsResponse::class, $optionalArgs, $request)->wait(); - } - - /** - * Creates or updates a finding. The corresponding source must exist for a - * finding creation to succeed. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $finding = new Finding(); - * $response = $securityCenterClient->updateFinding($finding); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param Finding $finding Required. The finding resource to update or create if it does not already exist. - * parent, security_marks, and update_time will be ignored. - * - * In the case of creation, the finding id portion of the name must be - * alphanumeric and less than or equal to 32 characters and greater than 0 - * characters in length. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The FieldMask to use when updating the finding resource. This field should - * not be specified when creating a finding. - * - * When updating a finding, an empty mask is treated as updating all mutable - * fields and replacing source_properties. Individual source_properties can - * be added/updated by using "source_properties." in the field - * mask. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1p1beta1\Finding - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function updateFinding($finding, array $optionalArgs = []) - { - $request = new UpdateFindingRequest(); - $requestParamHeaders = []; - $request->setFinding($finding); - $requestParamHeaders['finding.name'] = $finding->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateFinding', Finding::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates a notification config. The following update - * fields are allowed: description, pubsub_topic, streaming_config.filter - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $notificationConfig = new NotificationConfig(); - * $response = $securityCenterClient->updateNotificationConfig($notificationConfig); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param NotificationConfig $notificationConfig Required. The notification config to update. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The FieldMask to use when updating the notification config. - * - * If empty all mutable fields will be updated. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1p1beta1\NotificationConfig - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function updateNotificationConfig($notificationConfig, array $optionalArgs = []) - { - $request = new UpdateNotificationConfigRequest(); - $requestParamHeaders = []; - $request->setNotificationConfig($notificationConfig); - $requestParamHeaders['notification_config.name'] = $notificationConfig->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateNotificationConfig', NotificationConfig::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates an organization's settings. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $organizationSettings = new OrganizationSettings(); - * $response = $securityCenterClient->updateOrganizationSettings($organizationSettings); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param OrganizationSettings $organizationSettings Required. The organization settings resource to update. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The FieldMask to use when updating the settings resource. - * - * If empty all mutable fields will be updated. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1p1beta1\OrganizationSettings - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function updateOrganizationSettings($organizationSettings, array $optionalArgs = []) - { - $request = new UpdateOrganizationSettingsRequest(); - $requestParamHeaders = []; - $request->setOrganizationSettings($organizationSettings); - $requestParamHeaders['organization_settings.name'] = $organizationSettings->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateOrganizationSettings', OrganizationSettings::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates security marks. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $securityMarks = new SecurityMarks(); - * $response = $securityCenterClient->updateSecurityMarks($securityMarks); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param SecurityMarks $securityMarks Required. The security marks resource to update. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The FieldMask to use when updating the security marks resource. - * - * The field mask must not contain duplicate fields. - * If empty or set to "marks", all marks will be replaced. Individual - * marks can be updated using "marks.". - * @type Timestamp $startTime - * The time at which the updated SecurityMarks take effect. - * If not set uses current server time. Updates will be applied to the - * SecurityMarks that are active immediately preceding this time. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1p1beta1\SecurityMarks - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function updateSecurityMarks($securityMarks, array $optionalArgs = []) - { - $request = new UpdateSecurityMarksRequest(); - $requestParamHeaders = []; - $request->setSecurityMarks($securityMarks); - $requestParamHeaders['security_marks.name'] = $securityMarks->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - if (isset($optionalArgs['startTime'])) { - $request->setStartTime($optionalArgs['startTime']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateSecurityMarks', SecurityMarks::class, $optionalArgs, $request)->wait(); - } - - /** - * Updates a source. - * - * Sample code: - * ``` - * $securityCenterClient = new SecurityCenterClient(); - * try { - * $source = new Source(); - * $response = $securityCenterClient->updateSource($source); - * } finally { - * $securityCenterClient->close(); - * } - * ``` - * - * @param Source $source Required. The source resource to update. - * @param array $optionalArgs { - * Optional. - * - * @type FieldMask $updateMask - * The FieldMask to use when updating the source resource. - * - * If empty all mutable fields will be updated. - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return \Google\Cloud\SecurityCenter\V1p1beta1\Source - * - * @throws ApiException if the remote call fails - * - * @experimental - */ - public function updateSource($source, array $optionalArgs = []) - { - $request = new UpdateSourceRequest(); - $requestParamHeaders = []; - $request->setSource($source); - $requestParamHeaders['source.name'] = $source->getName(); - if (isset($optionalArgs['updateMask'])) { - $request->setUpdateMask($optionalArgs['updateMask']); - } - - $requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders); - $optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader(); - return $this->startCall('UpdateSource', Source::class, $optionalArgs, $request)->wait(); - } -} diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/SecurityCenterClient.php b/owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/SecurityCenterClient.php deleted file mode 100644 index f3d3c3c31148..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/SecurityCenterClient.php +++ /dev/null @@ -1,36 +0,0 @@ - [ - 'google.cloud.securitycenter.v1p1beta1.SecurityCenter' => [ - 'RunAssetDiscovery' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\SecurityCenter\V1p1beta1\RunAssetDiscoveryResponse', - 'metadataReturnType' => '\Google\Protobuf\GPBEmpty', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - ], - 'GroupAssets' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getGroupByResults', - ], - ], - 'GroupFindings' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getGroupByResults', - ], - ], - 'ListAssets' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getListAssetsResults', - ], - ], - 'ListFindings' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getListFindingsResults', - ], - ], - 'ListNotificationConfigs' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getNotificationConfigs', - ], - ], - 'ListSources' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getSources', - ], - ], - ], - ], -]; diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/resources/security_center_rest_client_config.php b/owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/resources/security_center_rest_client_config.php deleted file mode 100644 index 13e18b62b348..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/src/V1p1beta1/resources/security_center_rest_client_config.php +++ /dev/null @@ -1,460 +0,0 @@ - [ - 'google.cloud.securitycenter.v1p1beta1.SecurityCenter' => [ - 'CreateFinding' => [ - 'method' => 'post', - 'uriTemplate' => '/v1p1beta1/{parent=organizations/*/sources/*}/findings', - 'body' => 'finding', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'finding_id', - ], - ], - 'CreateNotificationConfig' => [ - 'method' => 'post', - 'uriTemplate' => '/v1p1beta1/{parent=organizations/*}/notificationConfigs', - 'body' => 'notification_config', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'config_id', - ], - ], - 'CreateSource' => [ - 'method' => 'post', - 'uriTemplate' => '/v1p1beta1/{parent=organizations/*}/sources', - 'body' => 'source', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteNotificationConfig' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1p1beta1/{name=organizations/*/notificationConfigs/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1p1beta1/{resource=organizations/*/sources/*}:getIamPolicy', - 'body' => '*', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'GetNotificationConfig' => [ - 'method' => 'get', - 'uriTemplate' => '/v1p1beta1/{name=organizations/*/notificationConfigs/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOrganizationSettings' => [ - 'method' => 'get', - 'uriTemplate' => '/v1p1beta1/{name=organizations/*/organizationSettings}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetSource' => [ - 'method' => 'get', - 'uriTemplate' => '/v1p1beta1/{name=organizations/*/sources/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GroupAssets' => [ - 'method' => 'post', - 'uriTemplate' => '/v1p1beta1/{parent=organizations/*}/assets:group', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1p1beta1/{parent=folders/*}/assets:group', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1p1beta1/{parent=projects/*}/assets:group', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'GroupFindings' => [ - 'method' => 'post', - 'uriTemplate' => '/v1p1beta1/{parent=organizations/*/sources/*}/findings:group', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1p1beta1/{parent=folders/*/sources/*}/findings:group', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1p1beta1/{parent=projects/*/sources/*}/findings:group', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListAssets' => [ - 'method' => 'get', - 'uriTemplate' => '/v1p1beta1/{parent=organizations/*}/assets', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1p1beta1/{parent=folders/*}/assets', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1p1beta1/{parent=projects/*}/assets', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListFindings' => [ - 'method' => 'get', - 'uriTemplate' => '/v1p1beta1/{parent=organizations/*/sources/*}/findings', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1p1beta1/{parent=folders/*/sources/*}/findings', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1p1beta1/{parent=projects/*/sources/*}/findings', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListNotificationConfigs' => [ - 'method' => 'get', - 'uriTemplate' => '/v1p1beta1/{parent=organizations/*}/notificationConfigs', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListSources' => [ - 'method' => 'get', - 'uriTemplate' => '/v1p1beta1/{parent=organizations/*}/sources', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1p1beta1/{parent=folders/*}/sources', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1p1beta1/{parent=projects/*}/sources', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'RunAssetDiscovery' => [ - 'method' => 'post', - 'uriTemplate' => '/v1p1beta1/{parent=organizations/*}/assets:runDiscovery', - 'body' => '*', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'SetFindingState' => [ - 'method' => 'post', - 'uriTemplate' => '/v1p1beta1/{name=organizations/*/sources/*/findings/*}:setState', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1p1beta1/{name=folders/*/sources/*/findings/*}:setState', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1p1beta1/{name=projects/*/sources/*/findings/*}:setState', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1p1beta1/{resource=organizations/*/sources/*}:setIamPolicy', - 'body' => '*', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v1p1beta1/{resource=organizations/*/sources/*}:testIamPermissions', - 'body' => '*', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'UpdateFinding' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1p1beta1/{finding.name=organizations/*/sources/*/findings/*}', - 'body' => 'finding', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v1p1beta1/{finding.name=folders/*/sources/*/findings/*}', - 'body' => 'finding', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v1p1beta1/{finding.name=projects/*/sources/*/findings/*}', - 'body' => 'finding', - ], - ], - 'placeholders' => [ - 'finding.name' => [ - 'getters' => [ - 'getFinding', - 'getName', - ], - ], - ], - ], - 'UpdateNotificationConfig' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1p1beta1/{notification_config.name=organizations/*/notificationConfigs/*}', - 'body' => 'notification_config', - 'placeholders' => [ - 'notification_config.name' => [ - 'getters' => [ - 'getNotificationConfig', - 'getName', - ], - ], - ], - ], - 'UpdateOrganizationSettings' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1p1beta1/{organization_settings.name=organizations/*/organizationSettings}', - 'body' => 'organization_settings', - 'placeholders' => [ - 'organization_settings.name' => [ - 'getters' => [ - 'getOrganizationSettings', - 'getName', - ], - ], - ], - ], - 'UpdateSecurityMarks' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1p1beta1/{security_marks.name=organizations/*/assets/*/securityMarks}', - 'body' => 'security_marks', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v1p1beta1/{security_marks.name=folders/*/assets/*/securityMarks}', - 'body' => 'security_marks', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v1p1beta1/{security_marks.name=projects/*/assets/*/securityMarks}', - 'body' => 'security_marks', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v1p1beta1/{security_marks.name=organizations/*/sources/*/findings/*/securityMarks}', - 'body' => 'security_marks', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v1p1beta1/{security_marks.name=folders/*/sources/*/findings/*/securityMarks}', - 'body' => 'security_marks', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v1p1beta1/{security_marks.name=projects/*/sources/*/findings/*/securityMarks}', - 'body' => 'security_marks', - ], - ], - 'placeholders' => [ - 'security_marks.name' => [ - 'getters' => [ - 'getSecurityMarks', - 'getName', - ], - ], - ], - ], - 'UpdateSource' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1p1beta1/{source.name=organizations/*/sources/*}', - 'body' => 'source', - 'placeholders' => [ - 'source.name' => [ - 'getters' => [ - 'getSource', - 'getName', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - 'CancelOperation' => [ - 'method' => 'post', - 'uriTemplate' => '/v1p1beta1/{name=organizations/*/operations/*}:cancel', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteOperation' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1p1beta1/{name=organizations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOperation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1p1beta1/{name=organizations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListOperations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1p1beta1/{name=organizations/*/operations}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/SecurityCenter/v1p1beta1/tests/Unit/V1p1beta1/SecurityCenterClientTest.php b/owl-bot-staging/SecurityCenter/v1p1beta1/tests/Unit/V1p1beta1/SecurityCenterClientTest.php deleted file mode 100644 index b5d5a2fef570..000000000000 --- a/owl-bot-staging/SecurityCenter/v1p1beta1/tests/Unit/V1p1beta1/SecurityCenterClientTest.php +++ /dev/null @@ -1,1692 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return SecurityCenterClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new SecurityCenterClient($options); - } - - /** @test */ - public function createFindingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $parent2 = 'parent21175163357'; - $resourceName = 'resourceName979421212'; - $category = 'category50511102'; - $externalUri = 'externalUri-1385596168'; - $canonicalName = 'canonicalName1385400054'; - $expectedResponse = new Finding(); - $expectedResponse->setName($name); - $expectedResponse->setParent($parent2); - $expectedResponse->setResourceName($resourceName); - $expectedResponse->setCategory($category); - $expectedResponse->setExternalUri($externalUri); - $expectedResponse->setCanonicalName($canonicalName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $findingId = 'findingId728776081'; - $finding = new Finding(); - $response = $gapicClient->createFinding($formattedParent, $findingId, $finding); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/CreateFinding', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getFindingId(); - $this->assertProtobufEquals($findingId, $actualValue); - $actualValue = $actualRequestObject->getFinding(); - $this->assertProtobufEquals($finding, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createFindingExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $findingId = 'findingId728776081'; - $finding = new Finding(); - try { - $gapicClient->createFinding($formattedParent, $findingId, $finding); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createNotificationConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $description = 'description-1724546052'; - $pubsubTopic = 'pubsubTopic-338126829'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new NotificationConfig(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setPubsubTopic($pubsubTopic); - $expectedResponse->setServiceAccount($serviceAccount); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); - $configId = 'configId-804450504'; - $notificationConfig = new NotificationConfig(); - $response = $gapicClient->createNotificationConfig($formattedParent, $configId, $notificationConfig); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/CreateNotificationConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getConfigId(); - $this->assertProtobufEquals($configId, $actualValue); - $actualValue = $actualRequestObject->getNotificationConfig(); - $this->assertProtobufEquals($notificationConfig, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createNotificationConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); - $configId = 'configId-804450504'; - $notificationConfig = new NotificationConfig(); - try { - $gapicClient->createNotificationConfig($formattedParent, $configId, $notificationConfig); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createSourceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $canonicalName = 'canonicalName1385400054'; - $expectedResponse = new Source(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setCanonicalName($canonicalName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); - $source = new Source(); - $response = $gapicClient->createSource($formattedParent, $source); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/CreateSource', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getSource(); - $this->assertProtobufEquals($source, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createSourceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); - $source = new Source(); - try { - $gapicClient->createSource($formattedParent, $source); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteNotificationConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); - $gapicClient->deleteNotificationConfig($formattedName); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/DeleteNotificationConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteNotificationConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); - try { - $gapicClient->deleteNotificationConfig($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $response = $gapicClient->getIamPolicy($resource); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/GetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - try { - $gapicClient->getIamPolicy($resource); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getNotificationConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $pubsubTopic = 'pubsubTopic-338126829'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new NotificationConfig(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setPubsubTopic($pubsubTopic); - $expectedResponse->setServiceAccount($serviceAccount); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); - $response = $gapicClient->getNotificationConfig($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/GetNotificationConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getNotificationConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[NOTIFICATION_CONFIG]'); - try { - $gapicClient->getNotificationConfig($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getOrganizationSettingsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $enableAssetDiscovery = false; - $expectedResponse = new OrganizationSettings(); - $expectedResponse->setName($name2); - $expectedResponse->setEnableAssetDiscovery($enableAssetDiscovery); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->organizationSettingsName('[ORGANIZATION]'); - $response = $gapicClient->getOrganizationSettings($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/GetOrganizationSettings', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getOrganizationSettingsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->organizationSettingsName('[ORGANIZATION]'); - try { - $gapicClient->getOrganizationSettings($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getSourceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $canonicalName = 'canonicalName1385400054'; - $expectedResponse = new Source(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setCanonicalName($canonicalName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $response = $gapicClient->getSource($formattedName); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/GetSource', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getSourceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - try { - $gapicClient->getSource($formattedName); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function groupAssetsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $totalSize = 705419236; - $groupByResultsElement = new GroupResult(); - $groupByResults = [ - $groupByResultsElement, - ]; - $expectedResponse = new GroupAssetsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTotalSize($totalSize); - $expectedResponse->setGroupByResults($groupByResults); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $groupBy = 'groupBy506361367'; - $response = $gapicClient->groupAssets($formattedParent, $groupBy); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getGroupByResults()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/GroupAssets', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getGroupBy(); - $this->assertProtobufEquals($groupBy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function groupAssetsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $groupBy = 'groupBy506361367'; - try { - $gapicClient->groupAssets($formattedParent, $groupBy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function groupFindingsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $totalSize = 705419236; - $groupByResultsElement = new GroupResult(); - $groupByResults = [ - $groupByResultsElement, - ]; - $expectedResponse = new GroupFindingsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTotalSize($totalSize); - $expectedResponse->setGroupByResults($groupByResults); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $groupBy = 'groupBy506361367'; - $response = $gapicClient->groupFindings($formattedParent, $groupBy); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getGroupByResults()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/GroupFindings', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getGroupBy(); - $this->assertProtobufEquals($groupBy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function groupFindingsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $groupBy = 'groupBy506361367'; - try { - $gapicClient->groupFindings($formattedParent, $groupBy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAssetsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $totalSize = 705419236; - $listAssetsResultsElement = new ListAssetsResult(); - $listAssetsResults = [ - $listAssetsResultsElement, - ]; - $expectedResponse = new ListAssetsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTotalSize($totalSize); - $expectedResponse->setListAssetsResults($listAssetsResults); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $response = $gapicClient->listAssets($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getListAssetsResults()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/ListAssets', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAssetsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - try { - $gapicClient->listAssets($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listFindingsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $totalSize = 705419236; - $listFindingsResultsElement = new ListFindingsResult(); - $listFindingsResults = [ - $listFindingsResultsElement, - ]; - $expectedResponse = new ListFindingsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTotalSize($totalSize); - $expectedResponse->setListFindingsResults($listFindingsResults); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $response = $gapicClient->listFindings($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getListFindingsResults()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/ListFindings', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listFindingsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - try { - $gapicClient->listFindings($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNotificationConfigsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $notificationConfigsElement = new NotificationConfig(); - $notificationConfigs = [ - $notificationConfigsElement, - ]; - $expectedResponse = new ListNotificationConfigsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setNotificationConfigs($notificationConfigs); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); - $response = $gapicClient->listNotificationConfigs($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getNotificationConfigs()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/ListNotificationConfigs', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNotificationConfigsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); - try { - $gapicClient->listNotificationConfigs($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listSourcesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $sourcesElement = new Source(); - $sources = [ - $sourcesElement, - ]; - $expectedResponse = new ListSourcesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setSources($sources); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $response = $gapicClient->listSources($formattedParent); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getSources()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/ListSources', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listSourcesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - try { - $gapicClient->listSources($formattedParent); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function runAssetDiscoveryTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/runAssetDiscoveryTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new RunAssetDiscoveryResponse(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/runAssetDiscoveryTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); - $response = $gapicClient->runAssetDiscovery($formattedParent); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/RunAssetDiscovery', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/runAssetDiscoveryTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function runAssetDiscoveryExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/runAssetDiscoveryTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); - $response = $gapicClient->runAssetDiscovery($formattedParent); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/runAssetDiscoveryTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function setFindingStateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $parent = 'parent-995424086'; - $resourceName = 'resourceName979421212'; - $category = 'category50511102'; - $externalUri = 'externalUri-1385596168'; - $canonicalName = 'canonicalName1385400054'; - $expectedResponse = new Finding(); - $expectedResponse->setName($name2); - $expectedResponse->setParent($parent); - $expectedResponse->setResourceName($resourceName); - $expectedResponse->setCategory($category); - $expectedResponse->setExternalUri($externalUri); - $expectedResponse->setCanonicalName($canonicalName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - $state = State::STATE_UNSPECIFIED; - $startTime = new Timestamp(); - $response = $gapicClient->setFindingState($formattedName, $state, $startTime); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/SetFindingState', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualRequestObject->getState(); - $this->assertProtobufEquals($state, $actualValue); - $actualValue = $actualRequestObject->getStartTime(); - $this->assertProtobufEquals($startTime, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setFindingStateExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - $state = State::STATE_UNSPECIFIED; - $startTime = new Timestamp(); - try { - $gapicClient->setFindingState($formattedName, $state, $startTime); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $response = $gapicClient->setIamPolicy($resource, $policy); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/SetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPolicy(); - $this->assertProtobufEquals($policy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - try { - $gapicClient->setIamPolicy($resource, $policy); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new TestIamPermissionsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $response = $gapicClient->testIamPermissions($resource, $permissions); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/TestIamPermissions', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPermissions(); - $this->assertProtobufEquals($permissions, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - try { - $gapicClient->testIamPermissions($resource, $permissions); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateFindingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $parent = 'parent-995424086'; - $resourceName = 'resourceName979421212'; - $category = 'category50511102'; - $externalUri = 'externalUri-1385596168'; - $canonicalName = 'canonicalName1385400054'; - $expectedResponse = new Finding(); - $expectedResponse->setName($name); - $expectedResponse->setParent($parent); - $expectedResponse->setResourceName($resourceName); - $expectedResponse->setCategory($category); - $expectedResponse->setExternalUri($externalUri); - $expectedResponse->setCanonicalName($canonicalName); - $transport->addResponse($expectedResponse); - // Mock request - $finding = new Finding(); - $response = $gapicClient->updateFinding($finding); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/UpdateFinding', $actualFuncCall); - $actualValue = $actualRequestObject->getFinding(); - $this->assertProtobufEquals($finding, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateFindingExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $finding = new Finding(); - try { - $gapicClient->updateFinding($finding); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateNotificationConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $description = 'description-1724546052'; - $pubsubTopic = 'pubsubTopic-338126829'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new NotificationConfig(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setPubsubTopic($pubsubTopic); - $expectedResponse->setServiceAccount($serviceAccount); - $transport->addResponse($expectedResponse); - // Mock request - $notificationConfig = new NotificationConfig(); - $response = $gapicClient->updateNotificationConfig($notificationConfig); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/UpdateNotificationConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getNotificationConfig(); - $this->assertProtobufEquals($notificationConfig, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateNotificationConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $notificationConfig = new NotificationConfig(); - try { - $gapicClient->updateNotificationConfig($notificationConfig); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateOrganizationSettingsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $enableAssetDiscovery = false; - $expectedResponse = new OrganizationSettings(); - $expectedResponse->setName($name); - $expectedResponse->setEnableAssetDiscovery($enableAssetDiscovery); - $transport->addResponse($expectedResponse); - // Mock request - $organizationSettings = new OrganizationSettings(); - $response = $gapicClient->updateOrganizationSettings($organizationSettings); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/UpdateOrganizationSettings', $actualFuncCall); - $actualValue = $actualRequestObject->getOrganizationSettings(); - $this->assertProtobufEquals($organizationSettings, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateOrganizationSettingsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $organizationSettings = new OrganizationSettings(); - try { - $gapicClient->updateOrganizationSettings($organizationSettings); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSecurityMarksTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $canonicalName = 'canonicalName1385400054'; - $expectedResponse = new SecurityMarks(); - $expectedResponse->setName($name); - $expectedResponse->setCanonicalName($canonicalName); - $transport->addResponse($expectedResponse); - // Mock request - $securityMarks = new SecurityMarks(); - $response = $gapicClient->updateSecurityMarks($securityMarks); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/UpdateSecurityMarks', $actualFuncCall); - $actualValue = $actualRequestObject->getSecurityMarks(); - $this->assertProtobufEquals($securityMarks, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSecurityMarksExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $securityMarks = new SecurityMarks(); - try { - $gapicClient->updateSecurityMarks($securityMarks); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSourceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $canonicalName = 'canonicalName1385400054'; - $expectedResponse = new Source(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setCanonicalName($canonicalName); - $transport->addResponse($expectedResponse); - // Mock request - $source = new Source(); - $response = $gapicClient->updateSource($source); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v1p1beta1.SecurityCenter/UpdateSource', $actualFuncCall); - $actualValue = $actualRequestObject->getSource(); - $this->assertProtobufEquals($source, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSourceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $source = new Source(); - try { - $gapicClient->updateSource($source); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Access.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Access.php deleted file mode 100644 index a41d008cd1f5..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Access.php +++ /dev/null @@ -1,46 +0,0 @@ -internalAddGeneratedFile( - ' -Á -+google/cloud/securitycenter/v2/access.protogoogle.cloud.securitycenter.v2"‰ -Access -principal_email (  - caller_ip ( B - caller_ip_geo ( 2+.google.cloud.securitycenter.v2.Geolocation -user_agent_family (  - -user_agent (  - service_name (  - method_name (  -principal_subject (  -service_account_key_name ( e -service_account_delegation_info - ( 2<.google.cloud.securitycenter.v2.ServiceAccountDelegationInfo - user_name ( "R -ServiceAccountDelegationInfo -principal_email (  -principal_subject ( "" - Geolocation - region_code ( Bå -"com.google.cloud.securitycenter.v2B AccessProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Application.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Application.php deleted file mode 100644 index dddd039a6a28..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Application.php +++ /dev/null @@ -1,30 +0,0 @@ -internalAddGeneratedFile( - ' -ú -0google/cloud/securitycenter/v2/application.protogoogle.cloud.securitycenter.v2"1 - Application -base_uri (  -full_uri ( Bê -"com.google.cloud.securitycenter.v2BApplicationProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/AttackExposure.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/AttackExposure.php deleted file mode 100644 index 3c66cf8645d5c829429744fc616c1a15ce227c1d..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1462 zcmbVM-EI;=7!{Bj$4KfLmGq)cu}Q(yCBa@TR>NNrQ(F>fFU%&JVRnFt!_H=Q7Okci zK7sGyqxckFoA?gS&a&Im(wN8%%W%H)o$uQ-=hYj3>Vs#nOFSZwBrY7CK{+MR7hH18 z861V-^vB`*84RtEqx6a=uL zIXeqV@D)Jy@xu|L7zPqa^|eg{hk8^}#ON0_-aZ^777#^o9Xk#^EGhS3RB-HJQm(+5 zGs15BT&-gtCgS?hhSYZKUNoYInB67;7Sxwq^cB>yCPb!tjZVsyMcasuj$t|0Xj#`p z?n5a;a=AN%g2+&Kb*(!hI8UGK6{~Cb)IOkuxlJ-fbIOHfT}*XBvZ^#4Y)I9+k!a?x zuGI^9@tQ8iZ@6wc?SZmNIn@`b-2va$z~29O#Mq3hOzkXl*;(eiw()eqsvV_XNL41f zW0RG>=RjfED#m?~4=@*`n1Pvc#;AiQOu0Xh4n_=z>RH*qiFk@x1-Mt+Fc%_{CT6-E zV-q~SVs1x}AY`(bQ?+-Ex2l&iBPrfiKMS?JgzAQQ%w?(OAgXQVel>E&b5PRvhq%s^ zPNvQrv5-W~^c4&o%tKEW^QukW*ah1Oc1Bzp&Tc@jX>K*ht?e$wm0f1KHuyt~%{%Wsh3HmUUVit!d}H+(~c6ZhXftMMC5fidV#eM#h)+9GnC2 E7n{-M&;S4c diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/AttackPath.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/AttackPath.php deleted file mode 100644 index f3fa8e4a833b05b10da3868eb04420fe6279a5b7..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2341 zcmcIm&2Jk;6vuWFmFFZlTY?-Ps%fZHx1wuggajJ`a^g)Iptcp8NJXoz#=B!@)Xna) zI~&QZeC3bf#FYc$z>WWep7;}(kNvO{0wM@syz^$}_ul)xulekY@H~X~(J}E!gc)(s zc!t7}b`Xgj^Pe%9o)i_8ZhZtxY1XGW+94|=R zR!p2EqHN|6pOL6_*=}LRu=COmF+0~KIDn5YNE~8^pyR>8Gs3Wo8Mclkj&&$-tl<)l zb=KYka6BBxs3Y+P91dOs;=eE%d(=TO!;Jqups`JT$|&~eEAG}lnqV&`{QC8?lf-uz z4SXan^nHgkA0dS)&OQhOPQyOR3>ye$I4jnPaLvb_)g`eL(U1kvfFCuCDPcLELehMc zsugf_f||-k!?%h+ zzT>*Nu}3_@%^Y4Rdk8;mz=!`fwAwv&Lzl^*FDHY3+1~vF0Ez%=>#!nnpEAB6QyjY z)^Ec`Cb8KpB-{bv)Vr|m(m3?+%$BZJq%?%PJeLE9iqf+u)OV>rjq5AY(&4Rr)KCkb`yt5W|9SjVa^V@ATbz9tnvy}e>Z&ya%&^^F&>bF(Qsu;pMs@Tr5n z%=eVUI@D4!Y==`b4We1fW0oqCzs8T{EFzi8+(DH~16av}u-QJiy<@_i5fA4LfplTb z!(-xQu^Zi9(=vtn*AmwBSv1q`LY0?<>@~bysTek%Ky~p<6)G>uEahfTuC{h;L+{|BoS$tI8~CV;hRa!S5y5- J<{ah#e*zGZ1l|Au diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/BackupDisasterRecovery.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/BackupDisasterRecovery.php deleted file mode 100644 index 40de3eea3460..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/BackupDisasterRecovery.php +++ /dev/null @@ -1,40 +0,0 @@ -internalAddGeneratedFile( - ' -è -=google/cloud/securitycenter/v2/backup_disaster_recovery.protogoogle.cloud.securitycenter.v2"† -BackupDisasterRecovery -backup_template (  -policies (  -host (  - applications (  - storage_pool (  -policy_options (  -profile (  - appliance (  - backup_type ( 6 -backup_create_time - ( 2.google.protobuf.TimestampBõ -"com.google.cloud.securitycenter.v2BBackupDisasterRecoveryProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/BigqueryExport.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/BigqueryExport.php deleted file mode 100644 index b3bd3445ab67..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/BigqueryExport.php +++ /dev/null @@ -1,40 +0,0 @@ -internalAddGeneratedFile( - ' -ª -4google/cloud/securitycenter/v2/bigquery_export.protogoogle.cloud.securitycenter.v2google/api/resource.protogoogle/protobuf/timestamp.proto" -BigQueryExport -name (  - description (  -filter (  -dataset ( 4 - create_time ( 2.google.protobuf.TimestampBàA4 - update_time ( 2.google.protobuf.TimestampBàA -most_recent_editor ( BàA - principal ( BàA:¡êA -,securitycenter.googleapis.com/BigQueryExportJorganizations/{organization}/locations/{location}/bigQueryExports/{export}>folders/{folder}/locations/{location}/bigQueryExports/{export}@projects/{project}/locations/{location}/bigQueryExports/{export}*bigQueryExports2bigQueryExportBí -"com.google.cloud.securitycenter.v2BBigQueryExportProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudDlpDataProfile.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudDlpDataProfile.php deleted file mode 100644 index 6e9a8949218ed768e71013944ee93ce9e4a5b91f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1395 zcmbtUU2oGc6s1Lg@FrA+2PPp+-UnJIL5j*-%7)T5E1g6ebzu@yq{wyM&M1p5$C)&y z{tKS@0sItx3a{|Q6E{iQwOgklk(W5mz2_dEdyn6~lcy4G;TDUSBAN|w{{rh%hNTi( zP!ZyOG8{66sW_87WXi<2*~Oi%hn;5I+kn(qB#JT%kAxV7tU^PP3@S0BiQ@W#vPd&k zIj`pX!61~ufM^l`{t)oYtPVmEIb*RTl;M_J|G+d!gZx$o={HhH|7ZcyKd#mgq9KW6 zoc(WxvI#kEj*Bi4hDRp-kW(CMqT#j8HtP#^Qjnkd-?xbuA$A`F_ zbF{1*B=@jZ37fBuv0^$=Q7z-00*q%Xe~Es!w=27tqrsO*Qt>>iqDm6>y>axL*Eazd&0s zS!NDPB#%v)*NR8_A)6Zt;|Q%tqF^KgeIeOe5z?Pj_a|w$u`!o0G2INt1C-782wi;{ z&(Sm2?l~PV@IJXt@Ue5`I*s;0+i8~W86~vZ?X~Pq`^5Iz-A<`ste{73uY2e;yi&3L z^*-7J-goe+uPq^z4WL^%Im{)U>I))_#C0=*KH$ei)n&hSedBv^y_NYd7r>nQuaQ~W zJg)wj2KW<)&McaT_~6l>#f==qvNG0|wFqNb5MzHU{9FHC!)@`IQ5{z=PnUPV^dAC@7H@WDK6sg%a?ZoI`ZtTrtu{tug#H4b CG2A5p diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudDlpInspection.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudDlpInspection.php deleted file mode 100644 index 510aecae86dc..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/CloudDlpInspection.php +++ /dev/null @@ -1,35 +0,0 @@ -internalAddGeneratedFile( - ' -á -9google/cloud/securitycenter/v2/cloud_dlp_inspection.protogoogle.cloud.securitycenter.v2"ˆ -CloudDlpInspection3 - inspect_job ( BúA -dlp.googleapis.com/DlpJob - info_type (  -info_type_count ( - full_scan (Bð -"com.google.cloud.securitycenter.v2BCloudDlpInspectionProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2êA| -dlp.googleapis.com/DlpJob$projects/{project}/dlpJobs/{dlp_job}9projects/{project}/locations/{location}/dlpJobs/{dlp_job}bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Compliance.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Compliance.php deleted file mode 100644 index 7a3d888c1bc9..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Compliance.php +++ /dev/null @@ -1,32 +0,0 @@ -internalAddGeneratedFile( - ' -ƒ -/google/cloud/securitycenter/v2/compliance.protogoogle.cloud.securitycenter.v2"< - -Compliance -standard (  -version (  -ids ( Bé -"com.google.cloud.securitycenter.v2BComplianceProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Connection.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Connection.php deleted file mode 100644 index 8da88c9e1a6041d5232e75785d9589c892575735..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1150 zcmb7D(Qeu>6djay)RVfDO%qR*%PN&hTOy@zVQdYN z`|g&ICg&gyUp7 z#T+6wk4T8Q31PDfuet-+YIX+4vNdK2N7#Wg#%3Y5P{@*r6=RfeBJL2T0(0xuwh*Hf zBS9E7H8%h>nBzDK5Qc59afwAR2}IzxHI45o8o$3q;}7i`04NON7`ho9_yVB(MaeiM z2*x51^6!MiBSMKFK}bH!SJmM(2xBbUA7ZBo)w-Z+=u(8MXE5bd*prCKDb(Rgn5PCK zhvIkC%V-e#O&lXmBEh&Pp^h`dA{(cwRL_>zDmpTS)l{S7JP=ujf+u+Mb_h8Z38yu! zTM;a>lUDZnEm`V#Kbd6LUP!B|8Bn#Ig6{=j{ijEzqqM=)rkdNPnzwf4YaW2L6Qvj6 zV1i>osPur*5sAtinternalAddGeneratedFile( - ' -µ -4google/cloud/securitycenter/v2/contact_details.protogoogle.cloud.securitycenter.v2"K -ContactDetails9 -contacts ( 2\'.google.cloud.securitycenter.v2.Contact" -Contact -email ( Bí -"com.google.cloud.securitycenter.v2BContactDetailsProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Container.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Container.php deleted file mode 100644 index d82267c96d98..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Container.php +++ /dev/null @@ -1,35 +0,0 @@ -internalAddGeneratedFile( - ' -‡ -.google/cloud/securitycenter/v2/container.protogoogle.cloud.securitycenter.v2google/protobuf/timestamp.proto"  - Container -name (  -uri (  -image_id ( 5 -labels ( 2%.google.cloud.securitycenter.v2.Label/ - create_time ( 2.google.protobuf.TimestampBè -"com.google.cloud.securitycenter.v2BContainerProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Database.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Database.php deleted file mode 100644 index 388dd983cbe9..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Database.php +++ /dev/null @@ -1,34 +0,0 @@ -internalAddGeneratedFile( - ' -¶ --google/cloud/securitycenter/v2/database.protogoogle.cloud.securitycenter.v2"s -Database -name (  - display_name (  - user_name (  -query (  -grantees (  -version ( Bç -"com.google.cloud.securitycenter.v2B DatabaseProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Exfiltration.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Exfiltration.php deleted file mode 100644 index 8b3c62fdd77b..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Exfiltration.php +++ /dev/null @@ -1,35 +0,0 @@ -internalAddGeneratedFile( - ' -® -1google/cloud/securitycenter/v2/exfiltration.protogoogle.cloud.securitycenter.v2"¯ - Exfiltration> -sources ( 2-.google.cloud.securitycenter.v2.ExfilResource> -targets ( 2-.google.cloud.securitycenter.v2.ExfilResource -total_exfiltrated_bytes ("1 - ExfilResource -name (  - -components ( Bë -"com.google.cloud.securitycenter.v2BExfiltrationProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ExternalSystem.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ExternalSystem.php deleted file mode 100644 index 3a7292ea5354..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ExternalSystem.php +++ /dev/null @@ -1,52 +0,0 @@ -internalAddGeneratedFile( - ' -Æ -4google/cloud/securitycenter/v2/external_system.protogoogle.cloud.securitycenter.v2google/protobuf/timestamp.proto"Ô -ExternalSystem -name (  - assignees (  - external_uid (  -status ( ? -external_system_update_time ( 2.google.protobuf.Timestamp -case_uri (  - case_priority ( , -case_sla ( 2.google.protobuf.Timestamp4 -case_create_time - ( 2.google.protobuf.Timestamp3 -case_close_time ( 2.google.protobuf.TimestampN - ticket_info ( 29.google.cloud.securitycenter.v2.ExternalSystem.TicketInfo - -TicketInfo - -id (  -assignee (  - description (  -uri (  -status ( / - update_time ( 2.google.protobuf.Timestamp:—êA“ -,securitycenter.googleapis.com/ExternalSystemaorganizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}vorganizations/{organization}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem}Ufolders/{folder}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}jfolders/{folder}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem}Wprojects/{project}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}lprojects/{project}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem}Bí -"com.google.cloud.securitycenter.v2BExternalSystemProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/File.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/File.php deleted file mode 100644 index 15ff948c6d2f..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/File.php +++ /dev/null @@ -1,38 +0,0 @@ -internalAddGeneratedFile( - ' -¬ -)google/cloud/securitycenter/v2/file.protogoogle.cloud.securitycenter.v2"ð -File -path (  -size ( -sha256 (  - hashed_size ( -partially_hashed ( -contents ( @ - disk_path ( 2-.google.cloud.securitycenter.v2.File.DiskPath9 -DiskPath -partition_uuid (  - relative_path ( Bã -"com.google.cloud.securitycenter.v2B FileProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Finding.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Finding.php deleted file mode 100644 index ce87104095b842c0fc52cec27e0d86325e3ee84f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 9093 zcmb_iOLN=E5su!{P?9NFcE;MQ4QuVS zz7dkP+B#Lkk3{u+H*`(cR$INJBjT&3+x0A)_$gH_R@8E(p_YnT<36YcZqGMKR_(ZM z$0ljhc6;q~K+K+Rg{LNQLgJ@SGU+4BX z3lyVSAHrxJX5JuV+C~tlI~)uBj8ypN^;))NszGRk@ZSR~&@IObEyK2cg86K#M}{2` z(7h;o)N{mi=Ud8_$=pH%^i!_ z?L7HtoLH`(&Gu*22f0eMM#MUftaZgAHFKs(f?)K~uf*{@SXNk5*BJv?7#ikr>67OM zJ)c}3FAr!vuV@8E0I^Ubrh7vC)9d3hXXO0u=Pch<4rK3(wpWCm1+jYs+jmR`0;uK$ z9$}kj449BxY|DWCHx4Yv8J}GaL`_(P>}1(vi0Fa~cornu>ra!eY0C)4;IPss2#gSN z|5)}}=@U$^Q~pLAQq4?bGn_07_ZZl2emFzBx8vEJ=bXG4V!NAF@*n~+bKEWI1=u@75XH{s>AgiR(3?>_;$!=Ue>{eWh~TPj06b?5nXKV{vdn_pZCTEkve{wJ zrnInW7xk)!DYZDr8Bm;7dw(aTk*rR)#oeAaFBP&}m z2@|SmnQF|mMplUElu(c@fJr%y8R~6LnuJzLYL{R}LjIXVo_dYaA0hsYM4Sw8oDt_i z1d-7L#$<%nreq+>v4!Zj644IjBziX{B|=TMB`l+>LxSrcrPpM>rNWF~h!M6Vh8;5! zq5GUg2qjry9miBbC}bp~*uV$$mLLQ|M>Z4N?dZ@?@K1%jY}vcCw(AB<2|`5{SdOUR zLR>a&*YD^atJ6Y3mS7WlIrdUcF08u27N%R;&bPU0PU$+DplTgtU6<(B_HC zr_hrvHGZDFS#jY8O?fz4*`OwnD81}ii#7LosMK@lpLC&y%>UL;oWlP znFzhBDqc#Mld4lCKHM!d58H}#T>li$^^sT6Vw^jm1%~IDEg#Sd@2}8Y?-4(=NPrjA zsf|Qtd*rcMqpce2GX|{uh?e6OXJLX7jF^y5sV>@UjLz{Xr4S+~;6R242}?*`LY`YSn+)jxEFNErzo29st-R6&c$J0aTiGn4EiruL4_H)k@ElqkOu_gT zv+0Qpc;HB;yhO8{G2+`y`D>Xn?>;KuLu9%UbqVlq*_0m3l%YW*nn%iQw9I_UTgh-b z#~2J)fWTW2IUF|d9R}NcB*TS0OS8VR2PuQ|qX4fl-EU>8k(a?V%Bu$5%jOt$&I0_! zsB?@|6cyd%36nBk&o)kZn*5SZl&|1TlxT|{H?)WFUFL#3&2asu5x&P(M!E+F8%@d& zXmNna1Xvx-_#4SvApDh;H5=L7;~K4Po*A=BQFt$9(fTV)sB;Or$n(BQ8bL`nw1I~q~H zTiHT0l$r*(`H0Q`flQwsBb6#z?H^S7XAQi;Y{L%)q2sbf{ehDPu9FbF?}?87)%cP7TC#!ss7Z@iS(GG~4C+ zD#{0huR4n2G=qC7bI|195(zR}*VTX!Wx4t_Wy5Zq#u;))lxy*(MrYSZ=jgW<_Zn%u#}vDBgec}7Jp5y{{hX{Bi4!0YQ1z= zs%ecsozn-M0=(7=xjjIbN7L`L-FL}Jin|XV$`AIFQ_38g+N=CAIlW#$(~O9&qU8R; z1ydH#41HS!oCKOXDDyuil_j)rP%f5sv@-lQwf^@Bv^c~>zeIQ7x1v_w)eC#Mdi|V* zU`gX$t(0p3?h0BuJlHFjYPr0&2a^FqsV!Q)P$}sU>HqH>;I;d4Jox8XnxCfNHGepZ?iawDBiky zoAWRJHhFiKT_H)aRG*4!R{;*SaChY}^Up}2DK44Bw@kQ56Rw&3I(eUiWU~wlKe`>89GDge?c2H9RL6T diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/GroupMembership.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/GroupMembership.php deleted file mode 100644 index f024cffe830972be98eb7bc3b1d6f54571ec0acf..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1104 zcmbW0-HOvd6vs^wapyuy5m`i*vvpy+pec0m!qh6;j|~yp1UFk$0wo{Qb|B3RlgUDr zzJt%n=|K}|LeDG&d@V3ae}!oa0I~;#2f?TRM3#d z5MZ!2&7x+C!;BNL3~?ebZ{D<; zGfp!$S>Q#0c{(RdS0^Bp_zRpeKg3`<-60l!WQQ!sPr zuwy`d@kiG{g{#^;ERnh$dN20@ugdNl^bfDyF z`w4n%zPGQPiTlwROs+>)&Y)*qT7!P|P7To0tv%QNVD%q3ZdV@ ChjEtx diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/IamBinding.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/IamBinding.php deleted file mode 100644 index c107744af2c6dc7352476ca66f45f5acb1b3bffd..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1059 zcmb7D(TdYR6g90>9AqtdkUlMU>%w+HQ;qnNTBU8eCBnAFt$mO{nIzNhK#~cQ$-*lA z8=w3X|3txma58Dr?Jg?jCCPBkx#!+{=FPk0GC@yaL}J3RAOU#SAT9|coC)T$5WH-; zBpiGeB{U@50I(-8p3GoqJF_E6OB&zgtxEEHpS7x zqj5mvm7&BDig85J1p5R=)BZUTIKTqCBcKAh83j+Bh znHN$YQh|kh9n*9{V=5>P>1Wwi7nV3oiKO4fF06T$dYLM>}WL^;p=q;HwUG zjK>}2I~Q1&U&`6@w{+v97X)S5Gr6l)3Cw9H=vNiJ_}?YzhXun>Yc=-QYFwGkuNp$T zRp>ob!)lfd4YbyQ`O^41-`H`Do+9dx(0$HA(x^y*hx!4kMI`bFZ&dUD=4({j;GQ78 zH<&q-@#5q7Vmcf+XU@>B-_swUYR|UonvPKI!|;4EAJ!}V9~x@P2>-)P|MAX_TJu!< z^uFkP+Xjo;D|S2HIH5A(`@>1R&h3M5mBWz=x1qvqY{NZJm&BNx-?spF6aO;*1;mvX s;AiEi5V0(!Vp;n#mNhrMnz~`HPRay4D}r?+hkwkVLKbmbqcuXm0V)|;W&i*H diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Indicator.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Indicator.php deleted file mode 100644 index 80bfebe13cb9a065901d43360cd5fa54ac8394ad..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1746 zcmbtU-A)rh7RYfJ927+oawtqM<*O8Ym4dL`;))x;t$rZg)33vn18< zEZ+MdUibhezJc*6oZW3V{ec)|Z@QiR=A83=XXd}Wi)%~%Ek+iCQUlul7CBk%Ws*J z#9fb!vm@jZ?zz@ppxXzyj@|-gFJ9B3jswGpXb*)^*{IOpwgX=hp!}Od@La02U3qkEzAdv0$MFz-ZUPqAgK0C)Sqo z>QLEjOiIL}i23URzcGT4mtkHUG?t$C(KFu`AT?8B!+M|eZFivcFzaa%eL9XL!Cw1+ zcI70%Jrb~yqN98AM_3zR7i+F(k}AVe_Rtfpv$7aI(1O;4WcWA9KA&3~}zHtdw~Mt1}aoS0NFZmtOE;whUOA zn25XqnMSozJ7}Jtm9^$&y{w(r8ufCqdRQ%&QupKxJevAmKRYd!8;z7CKZdobZ->?6 zaw=9>f<$Cw;ginternalAddGeneratedFile( - ' -¦ -3google/cloud/securitycenter/v2/kernel_rootkit.protogoogle.cloud.securitycenter.v2"× - KernelRootkit -name ( $ -unexpected_code_modification (. -&unexpected_read_only_data_modification (! -unexpected_ftrace_handler (! -unexpected_kprobe_handler ($ -unexpected_kernel_code_pages (& -unexpected_system_call_handler ($ -unexpected_interrupt_handler (( - unexpected_processes_in_runqueue (Bì -"com.google.cloud.securitycenter.v2BKernelRootkitProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Kubernetes.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Kubernetes.php deleted file mode 100644 index 1b674c4c93b5bdc56cfe02fe2d138a7d6852f6d1..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2621 zcmbtW-HzKt6efSW>FKhKOp!t^s_9bHETWD`K_G8al)r|s+a$`*iXuyq<4m%qUfc56 zix#w8@DAK^jd%zifH#2$;F>ctv9sB2yS2zooXPpVIrE+Gc+Qiryb}*TBpvEd-w5cO z%+5)0LW$?Qfor-pnT3l5^@-`8dX`Onm5^4S^!j7cZgt1^5z5@qH>pOJuDi5p#kAdU zUSZS>eJeOOsS{AYa#pRp3}@7LXh4}NxB(pFlrqmSDd`Lv&uL)Hjlj@5f<|w08hx}u zqaRlf08HCpj2y;v@DmXHc;U>pOu_;qz^?}un_7+)ScYx=h^MNNg<&&_@awUQ&@ltc zbqELa9g~*#iR9$54?GuDsF5hK0T%{E(YyR)j$!L9%1qz#0@oj4sHQDx5X;F|%KNKr zIi0m2WtpRsoH{?qL-=-!R*i7BDnR-?&eS8C<&9j#d z-1}t*VC^I231mHY&Wb6LDc`QD>YH~`*GP5X&XuQ-bKE&)#k7D|62N6t}; zV8t!L^+f`%x*!+|ywZSeclJFs16JG?OrIuT>I-D)*A!%UtpL&vuXCz=OWA=ee-UBX z_^;1lOE@H|z(+T2BDz7T;cF@Cut@m*o1k$|mhM7Ucp%C}WLEkX@_bbkb>pA^>$TEv zDaeXiHz4~G3nrx4t$ub>#+NM5;p!n`S7J)}qBJvH%)KumD$Y2kca%Kl&_8MyQc3}Knn#n-xILVTm2~O%6l_OMdVR5KkmXLtW=UbgCh54y=qy}W zO7=<;qmLxC^e3jedRDp{avmg*bH$+6!{B6m?$I}>+Jk%?^#QzJpNzkrj$aJg*X5mz z+C!9Afn9t!?l#-?X0t!(jSFez7UVj^{$xCx+dIHyv(i+K89!E?6Y}I zd9#D73xA~Vb;R7Gin&LP=ANb)pVZ^(Ur~U*nvCMnNQUS*8~u~MFG(~_uxQ#Qjiwz} fXIoTmbwB?!hk! diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Label.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Label.php deleted file mode 100644 index 966299706ef7..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Label.php +++ /dev/null @@ -1,31 +0,0 @@ -internalAddGeneratedFile( - ' -á -*google/cloud/securitycenter/v2/label.protogoogle.cloud.securitycenter.v2"$ -Label -name (  -value ( Bä -"com.google.cloud.securitycenter.v2B -LabelProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/LoadBalancer.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/LoadBalancer.php deleted file mode 100644 index 6c2bf9316606..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/LoadBalancer.php +++ /dev/null @@ -1,29 +0,0 @@ -internalAddGeneratedFile( - ' -è -2google/cloud/securitycenter/v2/load_balancer.protogoogle.cloud.securitycenter.v2" - LoadBalancer -name ( Bë -"com.google.cloud.securitycenter.v2BLoadBalancerProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/LogEntry.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/LogEntry.php deleted file mode 100644 index 443fbb6d129f86995e5d1fce14b248f0ca90c66d..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1183 zcmb7DU2hUW6cub5nMRYYFQgC66q}SLc8S}!K{Qe-)~Jw3crcrgVRqO~vdnB|XPcnm z!N231f5Sgw;;(Q%*lj8DATO}Xx#!+{?l~`Cr`IWX2K$s#i4~3DbOF^hg{c%u5Rt%X zKATYqiI}G>q0)!2H-Mi8BY4@n8Xf7n3O= zBA)06x$rGD036S0mSRF-f7ty<6^^jNVc)WZ7ltMLyv7oagEjyp!C3}Bi1^Zwfo}ln zPnu5?Mqs9}(qG3cn=sB4!wLJUSL(nSPBN;CH?gyv6U79FreMGcZJt8MX|Tts&=PcD zG1kziq7@0R%vu~LVUK1+vQ!B<)KG+Cs!A=*o95}Nt)XKx*mN@@v@v7{Dw)%}-651z z<&wAU+=gIT{tEvgS~=Z_X=xRnrwHAyb<1M6I(x-dJG_aaa^$!A#?7*cX?X&E?g0P) zj_Vydyl>6mubaWY2^tJMDlX^^!BY#HXotj%uUt~Ez)Ev3c(Lldjmfu0(Ojm|I^x}f z?jERVF6Xw!_X^nG0D1eM#&|}hny|>Ws(DYquBp<`Ro%Mg9RN>KXYL6RTw$goQh#Xw zI|DUUXk6d1lO7b4T6=4c_~jM4zbl}j15_ZksM39`_pm$ILk=rn-aBL=rkJ;4aX(r( zWjbB!5~tJl{TDx~hb~%9F~5k`h0df-^*H!d0K!%H%Jex%sN?sidgMqDvXUaSPJ_@m cnC@Bu&QD4gJ$J^wlY^}put;arC0GLR7ovKJ&Hw-a diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/MitreAttack.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/MitreAttack.php deleted file mode 100644 index 61d429ac69c1ed935f724fabfc0fd7e14a367ecc..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3313 zcmbtX>uwvz6|SV%j>fh;9$U72lUK45%V|P2O4AD+Cm8My$+32KHaoktXb>1s)XFAG zku141;1+(N{w~mW=%2nv(1++byGv>%qb<@3uuKonoXhup=gjeUKaAgw$rG!Q43kMW zO^&Uj_g4BgvBr~8I_ixE*3sw&3b?G@JC2s`X|x zdNWA&dV|sIcyF5YW|MyUzLyNsWU}{efA6%PP7>2i({Aq%mCQRK!|rJ^9d~<))d*@{ zl6H@~X}8nJ9Cd7T)Y0c0bz1w+3F!^G)2Zd5L!S8~ePJbwu+qsaDMz=gNs`Vc z!{=Gv=-|WRQvu?5I+5Qi-yg>_@^DzLMVCVgHY_WV*3z zt$@F8f0n=bZRQi!Jw66qjDWc!!|BFK=JJ0@F(T__fAcugjZglcEN_r2?~=(BlH9li z=&f%5b(vf)K)FL$#O+AhCiZn8Y+0AWp}$~^tcAi>zR#uB+_wc?VjJXkD71=0TNp>Q zgsTEi_z_)3Yw62Ka@TO%7FyFw>^fN$hr*5{seHP^Zjh^i2({FaKyR1PTM){YbVWlL zp>6K+%=A-si`;NTUHBT#TU_J)D{P(Iv_s)Qyi$}^jN(XbtCk4cl(5@`f*TP+A|9M& z>0M=OgxJb;1=I%hC$~A-cBx z4+s{`Ibrw6dL-w5Re$753TON<>rh#e!C-^Lk&plyOXk2CI z(e~Lc*{LZN<);nhn*vq&I<&gbkg zc>vUUAQXVtG(r^zA6&p20J))hbC@FCWRLRH$aScc|b#9}iN|e(Fr~yZLP?QN2 z7_~767(YcbY-T+2hy(393gf(YAEB1!>ei78=&#uWa##9IS%Yx84bXT7Cs#HQb{NdJ z#ms8Tm)t(UhWxbLEHG1Wq^SD5ZRkz(nUgh-b=FD0V%uaB!l0B&5-wv#zhL*tow+26 zZ$beRiM#Y0_Kl=qJQZILdf&IAyANwV@)3; zGJplIx#j%wcKj_mEzeJbESS8?Y#`CwADKj|XbWI7yY2`t^|K`T-E=eJrYgSNlBBO%>7KAfx%U^X8>N`7Ji8 zs$mZrn+LomUFd3Pm|vntd_keh;1TnE)YlT$F#ng4fvLglIneM@?hp%!%3GN`9t?QM zZq8u#CeiP*$phB|0X+zlMo09;g`4nfEp&aR&EK;M`6AaAhzGhHp4JQW+9HhdE`#L1 zul=+{wqYOtFY8Z@miDP^Wet{Izs#4o`64zt-Fq{-xU6@_ec0E}?|I{+=NAwDvb@>I zHuXxjsaNKkx}B~3mDc{>=LVf(mtQRNxk(4M`Ja}zawpYl=A~La@1|O9?H^sv{=4wa a)5SLXWxgbrcItn-PiL0->imIxAmm@gTdt=7 diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/MuteConfig.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/MuteConfig.php deleted file mode 100644 index 6b092319f8dde5cbc38a27d12f36aa49a24a6e3c..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1908 zcmb7F-A)rh6t)x_84Qy3rV;}Kl28b4O*JMi0_lIM0*x&snoXMR?zD{A?rdgfNr3bX zyzwQx;8A=EZ{;aGvp?OIKe0ERnLXz_bH4Ma|i2x8&xDHg{ByPOGT zG8=dOUXO5WvVlu&!c~kb2YCOWjjNSLdl_6k=5v#1xX)PMCVA6lzLocg>2oShP2vc` z^CyM;z!#)rGN(uTY5gV+zU~EFBIUljPQM zh$(GXT?RC4T=GVp}D0Y@ATWH7&_10lCffGl|N1Z?6#@ zZ3@*C#=yNfVnE}|9U75Vw5$)C!PiR`4x+MDuj^+yQ;#=H8pPHmUwrm4HklM-)noBI?v4YX_ zy~B33Q$EKAe3pfi|s~vKBZlxFN;6ZD0ii9AvI7k zPlYCwPeLef8SfhoJ%b0&94~)9z8wY)Cu|V#X^?cEq4IIu@S2~^%os3U-UYVNW41*& zz=VstYOabQ6>MrZz4c2j#`vu&XmBd9X7ErP&{Yjw}D91k} zQ+kq=t10_tGxhaDD6dHIvZQ@>bzVTVVPs4S!R>BcJ-C=!tOwIV4W@6J1$(_V>Qb9wrygtUw>I^_GHks= HG(_kxM~sfp diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/NotificationConfig.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/NotificationConfig.php deleted file mode 100644 index 8493156c21bb8b0be2c0431fb1fded35438987c9..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1778 zcmbtUO-~a+7?$!89Z<}2u%ePFl2DB9nwl81h}wcwOr%u^2i@3AXJ^ZpWo9!w+XP5& z{u4hq z2&Y|g7?(7l7)i=m19KM8maT&Tz|aASBZLX8)+_IbL_U(pt7<%NJ;n2O2JpPS(kcKr zL~#ta`*7DaEI0;G{i389QVe6MLSnc?;|66^QWVl7RpuHDP#6;hGwK^845w+r^g)eb zQe1%sGxc4HxN6H9>?T-GJEgkhZKb6$6nYyZ#)3wYi@I`k-4>C({-&1VN)|SSqX8_M z99?%L$u%fNLi(daD2Pl1Th)1|0G-~+JEwi+hfBUhDfTi;^IQf$u7YR(%MxqBytFmH>_L9n?b7`13>ih#5n0xT zV2fWTfi+4KYX(fD%*&6#vEnsr4ov&m+|=mvIcqBuXES}X8(`5w4q zE^HH4MU8E>BhGH>XWa#}F%fNwNdsZb6DIQ$`sw&ddEEL8ZpKm&bU;}vTZR0jx}Gjo zGPsMXv`5RZce+r9{confk}tH19`;hY)iZBs+j|DEQPa*_PWa!*el8eQy@(F-M1dm5qZfDQnE0BxCUv;Y7A diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/NotificationMessage.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/NotificationMessage.php deleted file mode 100644 index 73c3a92b57a720400ba01eb0097e750523dd3410..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1310 zcmbVM%We}f6eZPo#qK zLwo^imV63Jz5tKs(WDIonAOO-_uO-j&+&^_@kNZDK%WVwh-OomT!Ow}5G$!Al@UzR zAYclpoW(q1$_3~R;B0UXZ+a)^yQVdfsiF)+C}kM27L8;&Z6%DRit9_tgl4KW_gX?~ z9&k!Dmts6)NkT&A+9?PLVh&Mw3XyW%RpnsGB`X5#R{gKy3h(;ty;A{!_ zG{;4s5tuJdClRNRXfu?;K2OG6aLq}?Kbb{45RfQg2IppNkP4a+g{)y9D02=V$INQ? zV`+rxK*?~JX=QZsPqJkNiToZ*sN%7fYG_I^4wV+e*Q5RQ!YY`uXenG{1>42tgygZBrDe8OI}FxdOEF?I5viI zD(=}PP4w*!dj8)|s_*2jt~H^%YC?DJJwDt3t%_B0WA1&ep+{@%RR`2qu``t-;Ndv4 zaiaz`=RqB#?I72;v1JY(dVbUWGdH)mkGHo>^Zk-Yc2G*8e{;C>r6TbYMofffk; E0%O6xegFUf diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/OrgPolicy.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/OrgPolicy.php deleted file mode 100644 index f07f984864f3..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/OrgPolicy.php +++ /dev/null @@ -1,31 +0,0 @@ -internalAddGeneratedFile( - ' - -/google/cloud/securitycenter/v2/org_policy.protogoogle.cloud.securitycenter.v2"Ö - OrgPolicy -name ( :ºêA¶ -orgpolicy.googleapis.com/Policy7organizations/{organization}/policies/{constraint_name}+folders/{folder}/policies/{constraint_name}-projects/{project}/policies/{constraint_name}Bè -"com.google.cloud.securitycenter.v2BOrgPolicyProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Process.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Process.php deleted file mode 100644 index 757c7052e2d7..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Process.php +++ /dev/null @@ -1,44 +0,0 @@ -internalAddGeneratedFile( - ' -é -,google/cloud/securitycenter/v2/process.protogoogle.cloud.securitycenter.v2"õ -Process -name ( 4 -binary ( 2$.google.cloud.securitycenter.v2.File7 - libraries ( 2$.google.cloud.securitycenter.v2.File4 -script ( 2$.google.cloud.securitycenter.v2.File -args (  -arguments_truncated (J - env_variables ( 23.google.cloud.securitycenter.v2.EnvironmentVariable -env_variables_truncated ( -pid ( - -parent_pid - ("0 -EnvironmentVariable -name (  -val ( Bæ -"com.google.cloud.securitycenter.v2B ProcessProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Resource.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Resource.php deleted file mode 100644 index bd8db04f5de9caa50cdbea5390cac3f6883121e0..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 3212 zcmbtW-*4Mg6kd}4JZaO+?ba-V%FCv;V{0mcK*(Jgj^lWl+BhUm2UU>eI=88jYg_)& z(W1WbfcR5*=9Pbde}Grska$Mom3yxp*GXH#MqXkcpYz@Cob%m#&+`|~u>%iT30cV1 zeAH(T&shH$v5sr|wr-p3VQ_SWTvoSF9K%FznPqD-+msbntTmJeIMlNPS4SK>u3J3*eK>4=qD)ji~Eea+W;5(ViA1f7nugALzUJeU$Je zx^LJPO9Es|M;lMr5R>>ma%^0I9d<~oMT&w8(rb{cEY0lIkf*zbwB`Eet+#|5A`&nD$G>{koNFz><22#D(Wu3-%dS&TJby$7qK{fSAJen~+# zQ616)+{AB??nnK{$dN(4Mh7{VaWoenW04Z>!*cjO>P+M?&pe0OP<0;eZwB}6@uVEX z9ahc!&S!`aZFitq#(6>zrSCJ4O*Dr2V$6$(I9u7Cv`_+~jGyJiLW~M4$%Qpj4e)X3 z71A^Z{(nGgW)~wd63lA4ZU<2nvz1TY5|a<3i|@nIIC+4y(GOc${1EPpeU1nuoZ{V2 z_j&O#01k=pnH&8|KWAWZMA*#NaQj5Fv;jK7>QD!+9XKB5LE2uOm|k*=ltbJYOCnHA z7Z$wWFuY#K@j&QiD=*#wxs!llzJy%7k0@uV>ulxocK{x4P)fM?DXd(ZNV2Bap0&k~ z;WmvNAv!s%1Pl!up%J&29`2>TGO#fGPS25Dn6~Ub8g^=DQrgMja`L5#QHnpNAU|$o z6qqMVsPz6IG;)=RdngHVWf=uuM3FSZ%W1rf^pYz5kcO2c4q-?`d+YG9Eq3H?TM*S2 zue?;7a!pi~uUewoZFX9s(5N@WTK*P3g7T8kQsuV9Hya1M(vX|^6q5rW*1Eh~6WjST zK0>qPz15aqiGq?RCs&?--5Cv=V(!E0xRu|<3pSMeG{GPrc|nl7O(j3W6yYv^&~1zA z9^d38aZhY2s??Udt^6!=7k8R|>vXFfq1|XvVslIZOOD#(?81oo559%P(W`e2io&kk ztr6Dy4V=eV=J()^B+JsSs77wPyi%9jdpP}7SmyWm1G%Zb7OQGUZ0|P&v4iWd3`=_r zp)Gghx}s7d`AqeX6qN9^JV960#kf;ssBEPUUeOCI4zo|T2KM+ItvLoBrAJ30=Wu)6 z@KbtCqJwleew2rUv_Plv@_yylp+hekwc}Ykbm`$?`_J@)5QO7sB{^;shU4}thco!* c^zDz<<6-YvIL0QX-Ww-g>KV?Z7jOaa4|PTO%>V!Z diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ResourceValueConfig.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ResourceValueConfig.php deleted file mode 100644 index 8b11b3f6e6532c3e03dc7998ff68b2531b6af5e7..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2522 zcmbVO-EJC36fWR6_E1M?-KtwEx#KiaNE9zB?M1b&TVcS2$~M&4w2D?;Ez1C-E<4-Z zStJti0KMo7^bz_Tz3Nl+I+wlcUC+$^1ZHF zgK|LZ(5HN66PFXeJgt;{5(S!5%L$2TGj~Wwnk<8mYfVVtSvJAV&hZ)H*1+PH(Ugcr zO&}WGB}AiFIYh{ItRTP_F>+4;*CZ}_g)n@)u6ZvDPkXa4465>NrxRl77%5$#A;p3G3q3+ed=-McOX>P zM}(&oi#MewaajRJhqx5=sOvYHJi^=$$zpYkeZoWEJ(PV5fO-1MSixV_qs9p(&fu7g zttn-`uD@B;8<5*l6MEOrx@E(RyCbEfQSEX zq1}Ym1^p}UqYdFHHG?yyZKZ)8_)GRvv+({wOh8>OCgtI?wOo(ueB`=HZ zdsLi|0SzZBA>T#6#Uu1dQe%}^@+kK+nZ=d??aGTvI%QkWewERG%f7Dunnj;qGkjzr z@Oq%ZC0R}?EYPd8m_M>y`Vy`o<_6_gi;wg4h*-#gnA9q=jrhKtD?csf-hgtLozzHv z-VOih2T9$i?JO-;*+a#PMz?)+QEQmJ>giR(ygKi88nxC*t5Gk!r);5( z=dI@RLPkMo^9<&PtFuB@xsP(E?H>v`@%MTAyiwRV{wIST0+;`zkIe zB?>WMT6vw_k3e)?qUicEjIQ@8{Y~L&_Qm7$x_TB}{tL6ht#g8mjBfKenj`cdpTS+V diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecurityMarks.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecurityMarks.php deleted file mode 100644 index c7a94ee486ec..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecurityMarks.php +++ /dev/null @@ -1,37 +0,0 @@ -internalAddGeneratedFile( - ' -½ -3google/cloud/securitycenter/v2/security_marks.protogoogle.cloud.securitycenter.v2"î - SecurityMarks -name ( G -marks ( 28.google.cloud.securitycenter.v2.SecurityMarks.MarksEntry -canonical_name ( , - -MarksEntry -key (  -value ( :8:¿êA» -+securitycenter.googleapis.com/SecurityMarks9organizations/{organization}/assets/{asset}/securityMarksNorganizations/{organization}/sources/{source}/findings/{finding}/securityMarkscorganizations/{organization}/sources/{source}/locations/{location}/findings/{finding}/securityMarks-folders/{folder}/assets/{asset}/securityMarksBfolders/{folder}/sources/{source}/findings/{finding}/securityMarksWfolders/{folder}/sources/{source}/locations/{location}/findings/{finding}/securityMarks/projects/{project}/assets/{asset}/securityMarksDprojects/{project}/sources/{source}/findings/{finding}/securityMarksYprojects/{project}/sources/{source}/locations/{location}/findings/{finding}/securityMarksBì -"com.google.cloud.securitycenter.v2BSecurityMarksProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecurityPosture.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecurityPosture.php deleted file mode 100644 index f11372408da3..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecurityPosture.php +++ /dev/null @@ -1,41 +0,0 @@ -internalAddGeneratedFile( - ' -» -5google/cloud/securitycenter/v2/security_posture.protogoogle.cloud.securitycenter.v2"è -SecurityPosture -name (  - revision_id ( # -posture_deployment_resource (  -posture_deployment (  -changed_policy (  - -policy_set (  -policy ( ` -policy_drift_details ( 2B.google.cloud.securitycenter.v2.SecurityPosture.PolicyDriftDetailsS -PolicyDriftDetails -field (  -expected_value (  -detected_value ( Bî -"com.google.cloud.securitycenter.v2BSecurityPostureProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecuritycenterService.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/SecuritycenterService.php deleted file mode 100644 index b0afb9ba07b805f8868f9c68b4c46e350d21bca8..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 28020 zcmd@-TWlQHb={??$E9ArdQp^Zt;TwJMeRzXr&pq+B_&c)^q@sWb{0$)%jJ+-Yq`7K znWaMuEb0U>kj712+YJ&oMcTAMiu9QnY5LI^2nrN|kmjQ)(3U`v)W}csRRjgv^sDzd zbMKuyduNt(f9fB~yZ4-XUiZB2nc0h%TMt{{xy*#qaM~5mna#{BWxR(@rqynG&1$or znd!{UIqgifxzMWBopvshxq3Hq=kEQ?wW~MoA3&gPv(v6Rh0J`jIbV13)q1ltn|GaR zr(N@ws!qdm+WAFW`K0VR?ZsNv$&q~kXjB#)w^gY+nTg5K+m2V6t$3B`34(HZ45OT$ zl2A@RurB~mtyf$(BY!hRF@wh-gZ^uEX6m(S#`P*5`g5@6mTQfgSF6-(uOVhfGIN!> z>mW?wwR4?D)vGld84Pf@QFV?!pP@MM+Jmho63$45(>RIcg=95-12f#H)TggHZna%& zdCm4DT3RT~JDx9P{K?Vh*|r#6Z7y?^(pV^jh#bjy?T#bvp2@TwuhVW^Aar8{%l^Nn zH4-egYSYC=qlu-^Y`BF&z*B%C3UI7mLt0D*GhTD*v!l+#%3`hAP6m3 zS8L42-zvhWri-3esXm&lcn?>PYqU21s~xAkbnVlvW;=ldqiDPKX=+fMa@4sdv_lW$wUkSK5yf9L^{j zr)mqGI+5S%O=OCC_tdOg}g|js8qFkt1J944D+{R;h>nzWBP#rx#4RIEiVDZJ}B{?w=3?W_}u!iQz%wcBYX`BTE{QdScodl&iWB) z90m8Iehk48%jh##!D3z?xk&mLd82)Z9P8J>^bsRFZVP3`4x9qJ zxhf?CbrFAPNY28e-AN7*!K+|E@as(SSrdT) z0?Ok)uvNgK2>f4CU_WIboQHEpt}Be3CydzeM0ZBQ2;pw9iN+{J4fnwgO*mpIu}utz zH=@eFGqbJDww-c~0dhScls^EM7221QIzS z>l0uP-6Ak`j`VxBfKBIG9H3w&_4ecnz#eDqn+fVTaeV8D4JPcLqT$) z-R!hjDDrcQ)dfi<{eZi`#(BI;d1grn(GUXALjI)eH6J;R!3{We!>7O|@|laetb-fT zNB!34Q(%`uB+Iz2f$bbG&Z0YYkLOy)OkRf|L@GltD5h^~pvnrBZ$2?3k-!9csPkDb z6Kd8GYW_L}21MYyh>14NvAvqZcfXKe_Z+If8T7S=*It5KK!3H_L0K_QF8YRUfNkoE z0nqozS)yJL9s>QOj$rO~H{Y5k@Hvut7t-fb)^Df4?prn23mTQazI)6t0!(VksVJAq zQ&KJ!rw8_gNMhQ(0yYbEHJ7b1X%T4BD3<2K)Z+x*F7BRtiU0u`<|&E9{f-sK-Ba+A zQCXi$fgvm|*%$j-T$@x~(h`!@zf(!$ht13aas=v;>hQ-0k6rFulw<_=85 zN9(?}gN@Dhtkd@07tG-*05_L#T}(XJfISpCdE3D<2HXIz6Ez}CuZowgI8!8SW!=DCQW1Vm$C z3s*8}m<|GhXV@e=t}lGS2A>8yB_w6kghGAy!2v9_(Y;`gtRJ6f?6pV?46;q%d-fOu z159%A674xz%nJY!2|>(T2>P$wUm9axfGXNoqUirDKCa<>*q1;=71%?0E~j?%3`ubX zAMbwaP1G}pq=|`S66|b*8_ZlZJ(Tp(B6^3B!%dAuUwV`1%V-U&d`TeD=JFP5K42l~ zsbW(4D4LJaf?A@UpB5s%Xd;RR7_YNtG#OkV^jq^Z;`>`O{?8#_N_y|yFk<|Mdt;L_3QK6lFDN!k<|B|-NB^bX*H7<)&LlXl?r5pbw`Kaiz+un79`=!-*YpBUkn z!Q}`EwBz)J6xfPr!wz(9Xu1s6VGqtoGDbB{5+;CB^m|B&A8(;4ridn(u9Hp^Eu#|U zvVm*|^I)JucB8p0c0*lrSqrrg8GZ6l2^ZfjuuZw9B$aB6M!$@&NAli4Ee$F@CR$FH z(4bG4m-a{r^4ohTB|&)R#3=oEN>G9@-y=zXi~<}bDVzmx(jq$Ol*AswZI7g)`cR2Uc#Fm8v8 zMY0hOjiT0{q*jXC=*{(To83Bp=EpyKC;fKH8o|>bkLi~qP2pa|&1aYM+*V02WqD;` zCb%sxq_U+u){QPW^1MEbix0lH4s2KNe&IQzO!arpL(gzPVZtEi4?9_Z*7u}13C_{` zp~$Oul^j1m*~I|;-X$4>S}C$Q0V3olX)D)7K+E|#I_=^XW*84xs+X-o7a&=xS_H?f zqauR2W*wFNL+SSP@fbT$YRhm~{Q%wf5+w&t6oQPg>5E5qk{5`a1G!dzl)TQ4h1fT~Kmt-kN8Dk{;IoatcJS^uU z0Z&?%s9vA$E+Dq`oCp%o8V&OsIOu*p1&{Hm5_lj06D;sC7xqYY8J_SLA6EE@g2?(1 z8K04;wcqXogVfT(2{ybO?*NA(xvln)eOteeoa;emvzk8Ius=mZyy`Df)7Lysx;bFg2uW*T+NjeGkdnKt`xU0 zeNcBv1fR1GiaaTDU(PenT42L9@DI~qr*2fn9JzH+oQLr3G0DKJ@1W2?MsEnM-$-R? z=*1T#YL+XUjBH+syC?@PozBugOJKE@po2P-rD2so=@qU4gCC&em-2htcd_PBp+cCX z^Ur;vbly#8X{xA|j^Hw}G|pyeo~T{R-4@FIL|2R94rZx?Rivn3Kar)Wva+fR-a}dH zg$aZpX9e-eEDhi4vS`f2SN}x{o}&#vm=}--P@<=nS%w!G;A!P(2=>+m`YeOa=`5}b z+;`JpkeWl-E1Ug!6r{)YEp; zvmO-wG6nWh{x$s@XdKUu1U1R-bxC$!_9StuTG8psam@AQEG^@;K!LGlwe>tg0Kbz4 zPoX)jQK{;H=S|^11j2buT2QI(8m_`!!=BtV?8#k!m;zhye4GE&g}LUDmUDR-bNXNh zt10^K8Q8^jyFOXC7%!cLFVc?;W`|TK40QdF=2vVL`fJ@rvJDewD@sB54z+QPv*ogIq$oaHT01^>ticL ze~^S^EWAg;Pkbn8@e9{w{Is=C1Zo|@AFd-tDI^faLL8AAEa$WujWPhS)QqB=St_A9 zwpl802Vty?0w&HVV7!b1{y)hm{yvSSS#?v%@FF+nsQ!)?jGI?4wV|44z*XiMu;)Aj z_MB(Dl?J*_#wt()i{^_&@9M!`(hs=G^y9r0*n~vFirEt} zq(GN)#^YA9r$kl{Lt4P<;|Lwiz`4kco#V&7t6V+<`@`lfj zlMwNrX}OQC=Gj4n2yPe%0(`wNZWX&!@4R@AY>WDMPRk9upjhd;`xUtXRH$<{X%Wlb>pJkEYg7)c7}hj4s652O~KT*3(uNVs{nA5Fy3l~;FwW-1sR2S z$Mj|&^JKJ76V4W-OprbOjpq{G(oJ|>lw`6=5&}|I2Ehs&tx_SPV8ezFnctuo8%!ZT*TG7yv6k5DUGl-dVrmh?qPP2+n?BXBhrP^Du~x?Bxpt=sDylx|ivi}l{E zGz_!iX%KXy+vdFNY;>#j`@o+t=NVKEF`cIXz*QQ{c}j3ht1F80d^gRi6}?ua>m0v` z)~}V>77CUUuT~hGuNoQq30AGBtD^B9V$}+R2y`JMJ}Db+uq+aD(Ens703O#uMfD<4 z|C0mSYETIdd?fT)A9~oAl|XAG92(Fe&u4|ZpDw%<$NOpkxy2c;!>|+4!ZXYJTg3~% zpJD|}9Bb0FElbKt)JaNzuT*-06)+*Y5rnJ<#Wy*Fm{UzP;hI~_QIK57#zt#20w(3p zDpKY(jb6z5A*a%1R@3N#WFfWLM4wQ~x$qb0u}e(q6s;tnvD_6Fb6FS*Ithlc|C$`L z9JroAX z%P5D*NII!0-{@mAO5KZMzaT?tb-_i2JDzFBW#tX)Dv^%?Jn;Y7NL1(8d=o+CTcc2! z@}f|sVa&P|(4Yg1v-^2A6-9OrEIr2dSFOvz_FBjo`$IHSzZq%R@9Tz|%i@<@_YuwI zd#HiHUDPmr`%>Z_Gg7io3+^%hcOTe*NWke8H1_k^LQZCU6MYAn=q9WJGO$F5{`EdK zOJOiE#X2yd*g&saV}W);$Co#KME9;5D93cx5;|o%GmD^Ll#Sd*+I1K6;CoAFLu+FZ zn@eXy3uxXQ{vZY5ee^yoY!FU+q2{{ywSn*`&#r3p`XjuA8^H51Rxj2-4*aB}OapMlRJ-9-b3tos|Y{q|s#!2a*xm-A#hf;JphqlNVN%TS zchTeLR1xx%IC0e{L&a8~3}*dK|4MP6Bfsb{q`m)GXTL~1kFrp&JiqD|yicA((pTc* zmR3Q1aH-U?KiSJJqT~bD5o^a!*&mDEF|eARIeNu@DH;A%@KUyKMeijTYR}9(vR_WP zLGRqaZ=;I~dOF5w@63F0AuZ?UA%496K8n{nnEixKz#sM5^v;Yeh;RAJ1wKk$y2G4Q zOdNXY3HUDBG>S|3x?8OPech%PUq)yn9V0fKT9GgrEKVTghD~!`Gq{No_|^4bJ2eBG zZLo_;W3Nqx;I@-whT!YSkM3DOoAN33juHXC*=N%U7GaUzitqw9;EUa)G@^djzCzBR z5s4_OZU{$gI${t)7}!xa@EbOrXXyeSmy%01ok<9x5-h13DK~A}tL_FLlNQoG{Ba7s z%455VE%_)VdJH^-q_?rkQ4OY~BbNV;M&_x#hkJeI{#O(vKQYEWQFv49pHKq1U+fP? zouEHY+mpojHH-BpNmRE8B%Cho1bxN6*?ptnaP+#x49h%3viK{ONlGkOeUE#6wGQy2M|zAn6m)--vL}chw9EA>=SxXXP0+Lc$>mbr zo=UodsEuU1!JlpL9}N~CTQ=XUQdRKBdBta)hmt+hZ2jB%mEw^6aCAuS-&@a8NqL=K z;M#PO0}@J?3(C{jrF$%j@n!5S;o4FV{cwzfufYBHz(?SGg=MF4a0WDs%4GRRjJ;mA z=^UnRufR0~yTr$Qi^bFKnB&T1)}|fb?$`o4dy~c|*eTWRB6zW2oA~0m&0@L%bzFHk z?6e!u1(fzA5coaR|70hY^l;3#{^DxxUE|J$O|BFnr8snu&)CO^ccWh$&hIjR+G*&; zC&g#Dh_r8o|A%7kq35;SLO%cMtFN+#nE%T7O2>Ohe_rZ1da;`~*K9A0ez*=;=ymeE zcNQ^oIXW~Y{dg4niKt2Z>io%6=_Uo^&%2|y)6X}3x4?eE3Q-aI5v$hB1(}`J%s11| zPLLn1%8ilVyx{xNHznjA*iZO^Y4)>L{_k4RCDZ7Kt$v<9K#>#*1WTbHqbU^7n&LdL z<=s_z-4$M3aErZ=4xW_zyN|{HT^3rr{$29&&x;>7y_|WRJV)>Eafth>$Mhdjc+q=I z&c|m#zRiMlk#aX5gAwT->v3=`6}r*NKc<&a{%<-g&#Xrd$7`NC;{QU*F#Sy~;U~QC Vg;A}l`S~uglK#xrGFS%Se*s<}D?|VQ diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Simulation.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Simulation.php deleted file mode 100644 index eb916ed5113f..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Simulation.php +++ /dev/null @@ -1,40 +0,0 @@ -internalAddGeneratedFile( - ' -³ -/google/cloud/securitycenter/v2/simulation.protogoogle.cloud.securitycenter.v2google/api/resource.proto-google/cloud/securitycenter/v2/resource.proto4google/cloud/securitycenter/v2/valued_resource.protogoogle/protobuf/timestamp.proto"Ê - -Simulation -name ( 4 - create_time ( 2.google.protobuf.TimestampBàAd -resource_value_configs_metadata ( 2;.google.cloud.securitycenter.v2.ResourceValueConfigMetadataE -cloud_provider (2-.google.cloud.securitycenter.v2.CloudProvider:ÊêAÆ -(securitycenter.googleapis.com/Simulation5organizations/{organization}/simulations/{simulation}Jorganizations/{organization}/locations/{location}/simulations/{simluation}* simulations2 -simulationBé -"com.google.cloud.securitycenter.v2BSimulationProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Source.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Source.php deleted file mode 100644 index d08497f18dee..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/Source.php +++ /dev/null @@ -1,34 +0,0 @@ -internalAddGeneratedFile( - ' -½ -+google/cloud/securitycenter/v2/source.protogoogle.cloud.securitycenter.v2"ý -Source -name (  - display_name (  - description (  -canonical_name ( :¡êA -$securitycenter.googleapis.com/Source-organizations/{organization}/sources/{source}!folders/{folder}/sources/{source}#projects/{project}/sources/{source}Bå -"com.google.cloud.securitycenter.v2B SourceProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ToxicCombination.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ToxicCombination.php deleted file mode 100644 index 628745d06027..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ToxicCombination.php +++ /dev/null @@ -1,30 +0,0 @@ -internalAddGeneratedFile( - ' -Ÿ -6google/cloud/securitycenter/v2/toxic_combination.protogoogle.cloud.securitycenter.v2"K -ToxicCombination -attack_exposure_score ( -related_findings ( Bï -"com.google.cloud.securitycenter.v2BToxicCombinationProtoPZJcloud.google.com/go/securitycenter/apiv2/securitycenterpb;securitycenterpbªGoogle.Cloud.SecurityCenter.V2ÊGoogle\\Cloud\\SecurityCenter\\V2ê!Google::Cloud::SecurityCenter::V2bproto3' - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ValuedResource.php b/owl-bot-staging/SecurityCenter/v2/proto/src/GPBMetadata/Google/Cloud/Securitycenter/V2/ValuedResource.php deleted file mode 100644 index 936e64c1da32cd998e0a24646556da851a645cfa..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1720 zcmbVM;ZD;~6m|m?uP~P)Iwc{ONy1RodINL2s$od z#3UB%c)cESp-IjiY#~>Muv~{n^%Gbr*G|@WC?%e2A{F)t>02moTEy$-DKb45vw?|h zhTQyxlD{x44|R1H1^%)~0Dx_rBkC9?g4M?EA!0_?V1`x|SX#-)(wZ?Wt*sOQFfD^p z*cO<_BS>%sAb%XMV__3gW-$I*$5h8QX4tUsC2wyB_6&<64sp}B=h-I1#D;!A-8NBf z69$;R@47=c9Xl{AuHiGp+0kl#i?(5DWkgLEJB+vu?y9PN#3EjOOKx+N)`!DAmLxj>DFO7DLny8Q%C!? z>VA4g{gS*ceolg|sVN3T8V;s1*NJ?bIO&wQeZ$6={5}$!=C3Ayhk1(6Ju5sK{|rZh z5%$XC#PG%nGL)=Iq#M8%F+ExpzSO%v z6ClgEx@8k~mjqHb#1)#;NPKu7T&8e=Ip=*ct+{+0Tz2D=ayo@+!`I|$Rj92j)K+ee z)V3s)TW%{qLI-W6$B`fhE*e+l>*QJhqN)N#RpT(K+EzMuh2+29h=gS;P`L?F{G%WW L&p^9|U0mtc$t#7UD>IB7#>5|c4AX=_S4LI@);wksQxbUdSx<%6S%EUEf& zLpqt>^a*m;SLj_|qgQ>7PVf2x-E$-v+mHg~1~_N;JG*jBCh6> z4&OfI{nvzdT-&#G+vMB9$q8|J-R?PtN!&co?^O9pwZTg}a$^-;Jv(r9Qsld~-8IR& zZrVX--6MM78vdzHET6dR{la=bFzFF(!^Gu0g9os*9`PJaCw!^4eMo$*qxo8^#E@Dd zMQYVYkXp^cCV*~gp2s(b5#cA`@y7|;rlIqmule}vq2Z~9W%!0>8t*W-E&fC^J%R}5 zZBGJA_YK?PsYBJ$$=YK+#H6+l9UE)0#mBMLXnC+SEt%$LX=ZDOc)DvizU|h~v{>vC ze^6Aqvi3MSmckh){8|`ev3M@XE#7wnGJHDEyTlJ%Ym>!I0p1V(YF$vdL39lR>+5Sh zr&v5o>kNfu_4I`i=Q65p`06Aa|pWkJL|-;Vrpe@;M(rUsBSI;4l>a>uYt-a4jj(6+TL6_JcS%0zaG!F_cVIB5t# zi2S*`aMNyk#O>py8kUN}rv7M{o$NH?&Ttu+c}HAZ?P#aj8M=~d0t|)qDcn-z`hltl z4Y^WMk1F+=B+9$8w3GRSn}$@mdYnn%{Y)LA79JgDlH3eT?8&9QOp3b!Gom6lWKk$* zCUU{%y#tuW=V|hoy)8=7TtX6hq1<%9-@n4}S z$Yo)>Ea9mOFeg;-P`M^FaDRe^QK_m2mFjUNGnre1*)uYvVJejFh+A`zLdj-LGn@Mz zvx+Vs6Krc9Q9a#u!=6lV`!KKhKDLe8CptJEj)4H&NX4lagjnM=@L(M$q#|yk`7~Qy72WCQELMPB?91TkO`1Z$R$*L z%2L~kDF6J5phxJ=z8Rr6w+WM2ScgPZe{w~bI`!cWVMVvC6QhG)S^AChPt~XoDZ$f) zr&mOiS@Uuw$k4>P^urwk(Z0Ag&^|0h62ZRqG1lz=z{>rafEy!xxd*p}Mnez})TSgh zs>)ca+=k`R?TXYmt||xEJ9l7ZbW7OT7euMjz(%?SOQU<`DsA1=d8gXmt9sPdCS=0U zhN!m+_aY#%dRQwp_rV7IJCtiC7Jt>0PX@#K7h|^3W`QqDoJ%!k-j^U z6=`RzDt94!kx`{up`wC9chN2lDTx|-p=+pfxgIQxQ<{gnM|DY2F2qw5im=71@rDRTlsfhF| zz{!U-408+#r8HV+nI^b2K(r9n<;;MEp312(9ZwQB;YKussC2}Q6m|iob%&?}mF0%a z{8Q8bs(Q0X#f8|pPh5{`44olnb3a37d`jS!U@o3C)WMjr0SjKx?in6+R(%`-qgm)q zEC_7=#`!frm=L*Dxa|d9)JuE?sDaaUwGKgf4+CJ4ZU3Es9Ex-d@{xgVn;V(t*f3g4 ze7_%>$HSc6TkqQA?*z>;@Tm~bP~qdjX>X1%{Fc05VsC^zdn4rIs)+2hk#83Mhz(lN zD`N1B2u)h}j`%CN8iEvy45e5cg(()Bh4vIH)W)O1B>W^C&WC3CkIwPTG90$w!+U^# E0oidV*8l(j diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Access.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Access.php deleted file mode 100644 index 47690622e2e4..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Access.php +++ /dev/null @@ -1,521 +0,0 @@ -google.cloud.securitycenter.v2.Access - */ -class Access extends \Google\Protobuf\Internal\Message -{ - /** - * Associated email, such as "foo@google.com". - * The email address of the authenticated user or a service account acting on - * behalf of a third party principal making the request. For third party - * identity callers, the `principal_subject` field is populated instead of - * this field. For privacy reasons, the principal email address is sometimes - * redacted. For more information, see [Caller identities in audit - * logs](https://cloud.google.com/logging/docs/audit#user-id). - * - * Generated from protobuf field string principal_email = 1; - */ - protected $principal_email = ''; - /** - * Caller's IP address, such as "1.1.1.1". - * - * Generated from protobuf field string caller_ip = 2; - */ - protected $caller_ip = ''; - /** - * The caller IP's geolocation, which identifies where the call came from. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Geolocation caller_ip_geo = 3; - */ - protected $caller_ip_geo = null; - /** - * Type of user agent associated with the finding. For example, an operating - * system shell or an embedded or standalone application. - * - * Generated from protobuf field string user_agent_family = 4; - */ - protected $user_agent_family = ''; - /** - * The caller's user agent string associated with the finding. - * - * Generated from protobuf field string user_agent = 5; - */ - protected $user_agent = ''; - /** - * This is the API service that the service account made a call to, e.g. - * "iam.googleapis.com" - * - * Generated from protobuf field string service_name = 6; - */ - protected $service_name = ''; - /** - * The method that the service account called, e.g. "SetIamPolicy". - * - * Generated from protobuf field string method_name = 7; - */ - protected $method_name = ''; - /** - * A string that represents the principal_subject that is associated with the - * identity. Unlike `principal_email`, `principal_subject` supports principals - * that aren't associated with email addresses, such as third party - * principals. For most identities, the format is - * `principal://iam.googleapis.com/{identity pool name}/subject/{subject}`. - * Some GKE identities, such as GKE_WORKLOAD, FREEFORM, and GKE_HUB_WORKLOAD, - * still use the legacy format `serviceAccount:{identity pool - * name}[{subject}]`. - * - * Generated from protobuf field string principal_subject = 8; - */ - protected $principal_subject = ''; - /** - * The name of the service account key that was used to create or exchange - * credentials when authenticating the service account that made the request. - * This is a scheme-less URI full resource name. For example: - * "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}". - * - * Generated from protobuf field string service_account_key_name = 9; - */ - protected $service_account_key_name = ''; - /** - * The identity delegation history of an authenticated service account that - * made the request. The `serviceAccountDelegationInfo[]` object contains - * information about the real authorities that try to access Google Cloud - * resources by delegating on a service account. When multiple authorities are - * present, they are guaranteed to be sorted based on the original ordering of - * the identity delegation events. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ServiceAccountDelegationInfo service_account_delegation_info = 10; - */ - private $service_account_delegation_info; - /** - * A string that represents a username. The username provided depends on the - * type of the finding and is likely not an IAM principal. For example, this - * can be a system username if the finding is related to a virtual machine, or - * it can be an application login username. - * - * Generated from protobuf field string user_name = 11; - */ - protected $user_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $principal_email - * Associated email, such as "foo@google.com". - * The email address of the authenticated user or a service account acting on - * behalf of a third party principal making the request. For third party - * identity callers, the `principal_subject` field is populated instead of - * this field. For privacy reasons, the principal email address is sometimes - * redacted. For more information, see [Caller identities in audit - * logs](https://cloud.google.com/logging/docs/audit#user-id). - * @type string $caller_ip - * Caller's IP address, such as "1.1.1.1". - * @type \Google\Cloud\SecurityCenter\V2\Geolocation $caller_ip_geo - * The caller IP's geolocation, which identifies where the call came from. - * @type string $user_agent_family - * Type of user agent associated with the finding. For example, an operating - * system shell or an embedded or standalone application. - * @type string $user_agent - * The caller's user agent string associated with the finding. - * @type string $service_name - * This is the API service that the service account made a call to, e.g. - * "iam.googleapis.com" - * @type string $method_name - * The method that the service account called, e.g. "SetIamPolicy". - * @type string $principal_subject - * A string that represents the principal_subject that is associated with the - * identity. Unlike `principal_email`, `principal_subject` supports principals - * that aren't associated with email addresses, such as third party - * principals. For most identities, the format is - * `principal://iam.googleapis.com/{identity pool name}/subject/{subject}`. - * Some GKE identities, such as GKE_WORKLOAD, FREEFORM, and GKE_HUB_WORKLOAD, - * still use the legacy format `serviceAccount:{identity pool - * name}[{subject}]`. - * @type string $service_account_key_name - * The name of the service account key that was used to create or exchange - * credentials when authenticating the service account that made the request. - * This is a scheme-less URI full resource name. For example: - * "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}". - * @type array<\Google\Cloud\SecurityCenter\V2\ServiceAccountDelegationInfo>|\Google\Protobuf\Internal\RepeatedField $service_account_delegation_info - * The identity delegation history of an authenticated service account that - * made the request. The `serviceAccountDelegationInfo[]` object contains - * information about the real authorities that try to access Google Cloud - * resources by delegating on a service account. When multiple authorities are - * present, they are guaranteed to be sorted based on the original ordering of - * the identity delegation events. - * @type string $user_name - * A string that represents a username. The username provided depends on the - * type of the finding and is likely not an IAM principal. For example, this - * can be a system username if the finding is related to a virtual machine, or - * it can be an application login username. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Access::initOnce(); - parent::__construct($data); - } - - /** - * Associated email, such as "foo@google.com". - * The email address of the authenticated user or a service account acting on - * behalf of a third party principal making the request. For third party - * identity callers, the `principal_subject` field is populated instead of - * this field. For privacy reasons, the principal email address is sometimes - * redacted. For more information, see [Caller identities in audit - * logs](https://cloud.google.com/logging/docs/audit#user-id). - * - * Generated from protobuf field string principal_email = 1; - * @return string - */ - public function getPrincipalEmail() - { - return $this->principal_email; - } - - /** - * Associated email, such as "foo@google.com". - * The email address of the authenticated user or a service account acting on - * behalf of a third party principal making the request. For third party - * identity callers, the `principal_subject` field is populated instead of - * this field. For privacy reasons, the principal email address is sometimes - * redacted. For more information, see [Caller identities in audit - * logs](https://cloud.google.com/logging/docs/audit#user-id). - * - * Generated from protobuf field string principal_email = 1; - * @param string $var - * @return $this - */ - public function setPrincipalEmail($var) - { - GPBUtil::checkString($var, True); - $this->principal_email = $var; - - return $this; - } - - /** - * Caller's IP address, such as "1.1.1.1". - * - * Generated from protobuf field string caller_ip = 2; - * @return string - */ - public function getCallerIp() - { - return $this->caller_ip; - } - - /** - * Caller's IP address, such as "1.1.1.1". - * - * Generated from protobuf field string caller_ip = 2; - * @param string $var - * @return $this - */ - public function setCallerIp($var) - { - GPBUtil::checkString($var, True); - $this->caller_ip = $var; - - return $this; - } - - /** - * The caller IP's geolocation, which identifies where the call came from. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Geolocation caller_ip_geo = 3; - * @return \Google\Cloud\SecurityCenter\V2\Geolocation|null - */ - public function getCallerIpGeo() - { - return $this->caller_ip_geo; - } - - public function hasCallerIpGeo() - { - return isset($this->caller_ip_geo); - } - - public function clearCallerIpGeo() - { - unset($this->caller_ip_geo); - } - - /** - * The caller IP's geolocation, which identifies where the call came from. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Geolocation caller_ip_geo = 3; - * @param \Google\Cloud\SecurityCenter\V2\Geolocation $var - * @return $this - */ - public function setCallerIpGeo($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Geolocation::class); - $this->caller_ip_geo = $var; - - return $this; - } - - /** - * Type of user agent associated with the finding. For example, an operating - * system shell or an embedded or standalone application. - * - * Generated from protobuf field string user_agent_family = 4; - * @return string - */ - public function getUserAgentFamily() - { - return $this->user_agent_family; - } - - /** - * Type of user agent associated with the finding. For example, an operating - * system shell or an embedded or standalone application. - * - * Generated from protobuf field string user_agent_family = 4; - * @param string $var - * @return $this - */ - public function setUserAgentFamily($var) - { - GPBUtil::checkString($var, True); - $this->user_agent_family = $var; - - return $this; - } - - /** - * The caller's user agent string associated with the finding. - * - * Generated from protobuf field string user_agent = 5; - * @return string - */ - public function getUserAgent() - { - return $this->user_agent; - } - - /** - * The caller's user agent string associated with the finding. - * - * Generated from protobuf field string user_agent = 5; - * @param string $var - * @return $this - */ - public function setUserAgent($var) - { - GPBUtil::checkString($var, True); - $this->user_agent = $var; - - return $this; - } - - /** - * This is the API service that the service account made a call to, e.g. - * "iam.googleapis.com" - * - * Generated from protobuf field string service_name = 6; - * @return string - */ - public function getServiceName() - { - return $this->service_name; - } - - /** - * This is the API service that the service account made a call to, e.g. - * "iam.googleapis.com" - * - * Generated from protobuf field string service_name = 6; - * @param string $var - * @return $this - */ - public function setServiceName($var) - { - GPBUtil::checkString($var, True); - $this->service_name = $var; - - return $this; - } - - /** - * The method that the service account called, e.g. "SetIamPolicy". - * - * Generated from protobuf field string method_name = 7; - * @return string - */ - public function getMethodName() - { - return $this->method_name; - } - - /** - * The method that the service account called, e.g. "SetIamPolicy". - * - * Generated from protobuf field string method_name = 7; - * @param string $var - * @return $this - */ - public function setMethodName($var) - { - GPBUtil::checkString($var, True); - $this->method_name = $var; - - return $this; - } - - /** - * A string that represents the principal_subject that is associated with the - * identity. Unlike `principal_email`, `principal_subject` supports principals - * that aren't associated with email addresses, such as third party - * principals. For most identities, the format is - * `principal://iam.googleapis.com/{identity pool name}/subject/{subject}`. - * Some GKE identities, such as GKE_WORKLOAD, FREEFORM, and GKE_HUB_WORKLOAD, - * still use the legacy format `serviceAccount:{identity pool - * name}[{subject}]`. - * - * Generated from protobuf field string principal_subject = 8; - * @return string - */ - public function getPrincipalSubject() - { - return $this->principal_subject; - } - - /** - * A string that represents the principal_subject that is associated with the - * identity. Unlike `principal_email`, `principal_subject` supports principals - * that aren't associated with email addresses, such as third party - * principals. For most identities, the format is - * `principal://iam.googleapis.com/{identity pool name}/subject/{subject}`. - * Some GKE identities, such as GKE_WORKLOAD, FREEFORM, and GKE_HUB_WORKLOAD, - * still use the legacy format `serviceAccount:{identity pool - * name}[{subject}]`. - * - * Generated from protobuf field string principal_subject = 8; - * @param string $var - * @return $this - */ - public function setPrincipalSubject($var) - { - GPBUtil::checkString($var, True); - $this->principal_subject = $var; - - return $this; - } - - /** - * The name of the service account key that was used to create or exchange - * credentials when authenticating the service account that made the request. - * This is a scheme-less URI full resource name. For example: - * "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}". - * - * Generated from protobuf field string service_account_key_name = 9; - * @return string - */ - public function getServiceAccountKeyName() - { - return $this->service_account_key_name; - } - - /** - * The name of the service account key that was used to create or exchange - * credentials when authenticating the service account that made the request. - * This is a scheme-less URI full resource name. For example: - * "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}". - * - * Generated from protobuf field string service_account_key_name = 9; - * @param string $var - * @return $this - */ - public function setServiceAccountKeyName($var) - { - GPBUtil::checkString($var, True); - $this->service_account_key_name = $var; - - return $this; - } - - /** - * The identity delegation history of an authenticated service account that - * made the request. The `serviceAccountDelegationInfo[]` object contains - * information about the real authorities that try to access Google Cloud - * resources by delegating on a service account. When multiple authorities are - * present, they are guaranteed to be sorted based on the original ordering of - * the identity delegation events. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ServiceAccountDelegationInfo service_account_delegation_info = 10; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getServiceAccountDelegationInfo() - { - return $this->service_account_delegation_info; - } - - /** - * The identity delegation history of an authenticated service account that - * made the request. The `serviceAccountDelegationInfo[]` object contains - * information about the real authorities that try to access Google Cloud - * resources by delegating on a service account. When multiple authorities are - * present, they are guaranteed to be sorted based on the original ordering of - * the identity delegation events. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ServiceAccountDelegationInfo service_account_delegation_info = 10; - * @param array<\Google\Cloud\SecurityCenter\V2\ServiceAccountDelegationInfo>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setServiceAccountDelegationInfo($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ServiceAccountDelegationInfo::class); - $this->service_account_delegation_info = $arr; - - return $this; - } - - /** - * A string that represents a username. The username provided depends on the - * type of the finding and is likely not an IAM principal. For example, this - * can be a system username if the finding is related to a virtual machine, or - * it can be an application login username. - * - * Generated from protobuf field string user_name = 11; - * @return string - */ - public function getUserName() - { - return $this->user_name; - } - - /** - * A string that represents a username. The username provided depends on the - * type of the finding and is likely not an IAM principal. For example, this - * can be a system username if the finding is related to a virtual machine, or - * it can be an application login username. - * - * Generated from protobuf field string user_name = 11; - * @param string $var - * @return $this - */ - public function setUserName($var) - { - GPBUtil::checkString($var, True); - $this->user_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Application.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Application.php deleted file mode 100644 index 6dca97cc5b28..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Application.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.securitycenter.v2.Application - */ -class Application extends \Google\Protobuf\Internal\Message -{ - /** - * The base URI that identifies the network location of the application in - * which the vulnerability was detected. For example, `http://example.com`. - * - * Generated from protobuf field string base_uri = 1; - */ - protected $base_uri = ''; - /** - * The full URI with payload that could be used to reproduce the - * vulnerability. For example, `http://example.com?p=aMmYgI6H`. - * - * Generated from protobuf field string full_uri = 2; - */ - protected $full_uri = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $base_uri - * The base URI that identifies the network location of the application in - * which the vulnerability was detected. For example, `http://example.com`. - * @type string $full_uri - * The full URI with payload that could be used to reproduce the - * vulnerability. For example, `http://example.com?p=aMmYgI6H`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Application::initOnce(); - parent::__construct($data); - } - - /** - * The base URI that identifies the network location of the application in - * which the vulnerability was detected. For example, `http://example.com`. - * - * Generated from protobuf field string base_uri = 1; - * @return string - */ - public function getBaseUri() - { - return $this->base_uri; - } - - /** - * The base URI that identifies the network location of the application in - * which the vulnerability was detected. For example, `http://example.com`. - * - * Generated from protobuf field string base_uri = 1; - * @param string $var - * @return $this - */ - public function setBaseUri($var) - { - GPBUtil::checkString($var, True); - $this->base_uri = $var; - - return $this; - } - - /** - * The full URI with payload that could be used to reproduce the - * vulnerability. For example, `http://example.com?p=aMmYgI6H`. - * - * Generated from protobuf field string full_uri = 2; - * @return string - */ - public function getFullUri() - { - return $this->full_uri; - } - - /** - * The full URI with payload that could be used to reproduce the - * vulnerability. For example, `http://example.com?p=aMmYgI6H`. - * - * Generated from protobuf field string full_uri = 2; - * @param string $var - * @return $this - */ - public function setFullUri($var) - { - GPBUtil::checkString($var, True); - $this->full_uri = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackExposure.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackExposure.php deleted file mode 100644 index 1c7ab996ecca..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackExposure.php +++ /dev/null @@ -1,313 +0,0 @@ -google.cloud.securitycenter.v2.AttackExposure - */ -class AttackExposure extends \Google\Protobuf\Internal\Message -{ - /** - * A number between 0 (inclusive) and infinity that represents how important - * this finding is to remediate. The higher the score, the more important it - * is to remediate. - * - * Generated from protobuf field double score = 1; - */ - protected $score = 0.0; - /** - * The most recent time the attack exposure was updated on this finding. - * - * Generated from protobuf field .google.protobuf.Timestamp latest_calculation_time = 2; - */ - protected $latest_calculation_time = null; - /** - * The resource name of the attack path simulation result that contains the - * details regarding this attack exposure score. - * Example: organizations/123/simulations/456/attackExposureResults/789 - * - * Generated from protobuf field string attack_exposure_result = 3; - */ - protected $attack_exposure_result = ''; - /** - * Output only. What state this AttackExposure is in. This captures whether or - * not an attack exposure has been calculated or not. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.AttackExposure.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * The number of high value resources that are exposed as a result of this - * finding. - * - * Generated from protobuf field int32 exposed_high_value_resources_count = 5; - */ - protected $exposed_high_value_resources_count = 0; - /** - * The number of medium value resources that are exposed as a result of this - * finding. - * - * Generated from protobuf field int32 exposed_medium_value_resources_count = 6; - */ - protected $exposed_medium_value_resources_count = 0; - /** - * The number of high value resources that are exposed as a result of this - * finding. - * - * Generated from protobuf field int32 exposed_low_value_resources_count = 7; - */ - protected $exposed_low_value_resources_count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type float $score - * A number between 0 (inclusive) and infinity that represents how important - * this finding is to remediate. The higher the score, the more important it - * is to remediate. - * @type \Google\Protobuf\Timestamp $latest_calculation_time - * The most recent time the attack exposure was updated on this finding. - * @type string $attack_exposure_result - * The resource name of the attack path simulation result that contains the - * details regarding this attack exposure score. - * Example: organizations/123/simulations/456/attackExposureResults/789 - * @type int $state - * Output only. What state this AttackExposure is in. This captures whether or - * not an attack exposure has been calculated or not. - * @type int $exposed_high_value_resources_count - * The number of high value resources that are exposed as a result of this - * finding. - * @type int $exposed_medium_value_resources_count - * The number of medium value resources that are exposed as a result of this - * finding. - * @type int $exposed_low_value_resources_count - * The number of high value resources that are exposed as a result of this - * finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\AttackExposure::initOnce(); - parent::__construct($data); - } - - /** - * A number between 0 (inclusive) and infinity that represents how important - * this finding is to remediate. The higher the score, the more important it - * is to remediate. - * - * Generated from protobuf field double score = 1; - * @return float - */ - public function getScore() - { - return $this->score; - } - - /** - * A number between 0 (inclusive) and infinity that represents how important - * this finding is to remediate. The higher the score, the more important it - * is to remediate. - * - * Generated from protobuf field double score = 1; - * @param float $var - * @return $this - */ - public function setScore($var) - { - GPBUtil::checkDouble($var); - $this->score = $var; - - return $this; - } - - /** - * The most recent time the attack exposure was updated on this finding. - * - * Generated from protobuf field .google.protobuf.Timestamp latest_calculation_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getLatestCalculationTime() - { - return $this->latest_calculation_time; - } - - public function hasLatestCalculationTime() - { - return isset($this->latest_calculation_time); - } - - public function clearLatestCalculationTime() - { - unset($this->latest_calculation_time); - } - - /** - * The most recent time the attack exposure was updated on this finding. - * - * Generated from protobuf field .google.protobuf.Timestamp latest_calculation_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setLatestCalculationTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->latest_calculation_time = $var; - - return $this; - } - - /** - * The resource name of the attack path simulation result that contains the - * details regarding this attack exposure score. - * Example: organizations/123/simulations/456/attackExposureResults/789 - * - * Generated from protobuf field string attack_exposure_result = 3; - * @return string - */ - public function getAttackExposureResult() - { - return $this->attack_exposure_result; - } - - /** - * The resource name of the attack path simulation result that contains the - * details regarding this attack exposure score. - * Example: organizations/123/simulations/456/attackExposureResults/789 - * - * Generated from protobuf field string attack_exposure_result = 3; - * @param string $var - * @return $this - */ - public function setAttackExposureResult($var) - { - GPBUtil::checkString($var, True); - $this->attack_exposure_result = $var; - - return $this; - } - - /** - * Output only. What state this AttackExposure is in. This captures whether or - * not an attack exposure has been calculated or not. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.AttackExposure.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. What state this AttackExposure is in. This captures whether or - * not an attack exposure has been calculated or not. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.AttackExposure.State state = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\AttackExposure\State::class); - $this->state = $var; - - return $this; - } - - /** - * The number of high value resources that are exposed as a result of this - * finding. - * - * Generated from protobuf field int32 exposed_high_value_resources_count = 5; - * @return int - */ - public function getExposedHighValueResourcesCount() - { - return $this->exposed_high_value_resources_count; - } - - /** - * The number of high value resources that are exposed as a result of this - * finding. - * - * Generated from protobuf field int32 exposed_high_value_resources_count = 5; - * @param int $var - * @return $this - */ - public function setExposedHighValueResourcesCount($var) - { - GPBUtil::checkInt32($var); - $this->exposed_high_value_resources_count = $var; - - return $this; - } - - /** - * The number of medium value resources that are exposed as a result of this - * finding. - * - * Generated from protobuf field int32 exposed_medium_value_resources_count = 6; - * @return int - */ - public function getExposedMediumValueResourcesCount() - { - return $this->exposed_medium_value_resources_count; - } - - /** - * The number of medium value resources that are exposed as a result of this - * finding. - * - * Generated from protobuf field int32 exposed_medium_value_resources_count = 6; - * @param int $var - * @return $this - */ - public function setExposedMediumValueResourcesCount($var) - { - GPBUtil::checkInt32($var); - $this->exposed_medium_value_resources_count = $var; - - return $this; - } - - /** - * The number of high value resources that are exposed as a result of this - * finding. - * - * Generated from protobuf field int32 exposed_low_value_resources_count = 7; - * @return int - */ - public function getExposedLowValueResourcesCount() - { - return $this->exposed_low_value_resources_count; - } - - /** - * The number of high value resources that are exposed as a result of this - * finding. - * - * Generated from protobuf field int32 exposed_low_value_resources_count = 7; - * @param int $var - * @return $this - */ - public function setExposedLowValueResourcesCount($var) - { - GPBUtil::checkInt32($var); - $this->exposed_low_value_resources_count = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackExposure/State.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackExposure/State.php deleted file mode 100644 index 1b5c43e6e677..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackExposure/State.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.securitycenter.v2.AttackExposure.State - */ -class State -{ - /** - * The state is not specified. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The attack exposure has been calculated. - * - * Generated from protobuf enum CALCULATED = 1; - */ - const CALCULATED = 1; - /** - * The attack exposure has not been calculated. - * - * Generated from protobuf enum NOT_CALCULATED = 2; - */ - const NOT_CALCULATED = 2; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::CALCULATED => 'CALCULATED', - self::NOT_CALCULATED => 'NOT_CALCULATED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\SecurityCenter\V2\AttackExposure_State::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath.php deleted file mode 100644 index bb00ddfd9c43..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath.php +++ /dev/null @@ -1,139 +0,0 @@ -google.cloud.securitycenter.v2.AttackPath - */ -class AttackPath extends \Google\Protobuf\Internal\Message -{ - /** - * The attack path name, for example, - * `organizations/12/simulations/34/valuedResources/56/attackPaths/78` - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * A list of nodes that exist in this attack path. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathNode path_nodes = 2; - */ - private $path_nodes; - /** - * A list of the edges between nodes in this attack path. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathEdge edges = 3; - */ - private $edges; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The attack path name, for example, - * `organizations/12/simulations/34/valuedResources/56/attackPaths/78` - * @type array<\Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode>|\Google\Protobuf\Internal\RepeatedField $path_nodes - * A list of nodes that exist in this attack path. - * @type array<\Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathEdge>|\Google\Protobuf\Internal\RepeatedField $edges - * A list of the edges between nodes in this attack path. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\AttackPath::initOnce(); - parent::__construct($data); - } - - /** - * The attack path name, for example, - * `organizations/12/simulations/34/valuedResources/56/attackPaths/78` - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The attack path name, for example, - * `organizations/12/simulations/34/valuedResources/56/attackPaths/78` - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * A list of nodes that exist in this attack path. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathNode path_nodes = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPathNodes() - { - return $this->path_nodes; - } - - /** - * A list of nodes that exist in this attack path. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathNode path_nodes = 2; - * @param array<\Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPathNodes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode::class); - $this->path_nodes = $arr; - - return $this; - } - - /** - * A list of the edges between nodes in this attack path. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathEdge edges = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getEdges() - { - return $this->edges; - } - - /** - * A list of the edges between nodes in this attack path. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathEdge edges = 3; - * @param array<\Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathEdge>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setEdges($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathEdge::class); - $this->edges = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathEdge.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathEdge.php deleted file mode 100644 index e16a8769ae8e..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathEdge.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.securitycenter.v2.AttackPath.AttackPathEdge - */ -class AttackPathEdge extends \Google\Protobuf\Internal\Message -{ - /** - * The attack node uuid of the source node. - * - * Generated from protobuf field string source = 1; - */ - protected $source = ''; - /** - * The attack node uuid of the destination node. - * - * Generated from protobuf field string destination = 2; - */ - protected $destination = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $source - * The attack node uuid of the source node. - * @type string $destination - * The attack node uuid of the destination node. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\AttackPath::initOnce(); - parent::__construct($data); - } - - /** - * The attack node uuid of the source node. - * - * Generated from protobuf field string source = 1; - * @return string - */ - public function getSource() - { - return $this->source; - } - - /** - * The attack node uuid of the source node. - * - * Generated from protobuf field string source = 1; - * @param string $var - * @return $this - */ - public function setSource($var) - { - GPBUtil::checkString($var, True); - $this->source = $var; - - return $this; - } - - /** - * The attack node uuid of the destination node. - * - * Generated from protobuf field string destination = 2; - * @return string - */ - public function getDestination() - { - return $this->destination; - } - - /** - * The attack node uuid of the destination node. - * - * Generated from protobuf field string destination = 2; - * @param string $var - * @return $this - */ - public function setDestination($var) - { - GPBUtil::checkString($var, True); - $this->destination = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AttackPathEdge::class, \Google\Cloud\SecurityCenter\V2\AttackPath_AttackPathEdge::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode.php deleted file mode 100644 index 972723b60ce9..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode.php +++ /dev/null @@ -1,256 +0,0 @@ -google.cloud.securitycenter.v2.AttackPath.AttackPathNode - */ -class AttackPathNode extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the resource at this point in the attack path. - * The format of the name follows the Cloud Asset Inventory [resource - * name - * format]("https://cloud.google.com/asset-inventory/docs/resource-name-format") - * - * Generated from protobuf field string resource = 1; - */ - protected $resource = ''; - /** - * The [supported resource - * type](https://cloud.google.com/asset-inventory/docs/supported-asset-types") - * - * Generated from protobuf field string resource_type = 2; - */ - protected $resource_type = ''; - /** - * Human-readable name of this resource. - * - * Generated from protobuf field string display_name = 3; - */ - protected $display_name = ''; - /** - * The findings associated with this node in the attack path. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathNode.PathNodeAssociatedFinding associated_findings = 4; - */ - private $associated_findings; - /** - * Unique id of the attack path node. - * - * Generated from protobuf field string uuid = 5; - */ - protected $uuid = ''; - /** - * A list of attack step nodes that exist in this attack path node. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathNode.AttackStepNode attack_steps = 6; - */ - private $attack_steps; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $resource - * The name of the resource at this point in the attack path. - * The format of the name follows the Cloud Asset Inventory [resource - * name - * format]("https://cloud.google.com/asset-inventory/docs/resource-name-format") - * @type string $resource_type - * The [supported resource - * type](https://cloud.google.com/asset-inventory/docs/supported-asset-types") - * @type string $display_name - * Human-readable name of this resource. - * @type array<\Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode\PathNodeAssociatedFinding>|\Google\Protobuf\Internal\RepeatedField $associated_findings - * The findings associated with this node in the attack path. - * @type string $uuid - * Unique id of the attack path node. - * @type array<\Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode\AttackStepNode>|\Google\Protobuf\Internal\RepeatedField $attack_steps - * A list of attack step nodes that exist in this attack path node. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\AttackPath::initOnce(); - parent::__construct($data); - } - - /** - * The name of the resource at this point in the attack path. - * The format of the name follows the Cloud Asset Inventory [resource - * name - * format]("https://cloud.google.com/asset-inventory/docs/resource-name-format") - * - * Generated from protobuf field string resource = 1; - * @return string - */ - public function getResource() - { - return $this->resource; - } - - /** - * The name of the resource at this point in the attack path. - * The format of the name follows the Cloud Asset Inventory [resource - * name - * format]("https://cloud.google.com/asset-inventory/docs/resource-name-format") - * - * Generated from protobuf field string resource = 1; - * @param string $var - * @return $this - */ - public function setResource($var) - { - GPBUtil::checkString($var, True); - $this->resource = $var; - - return $this; - } - - /** - * The [supported resource - * type](https://cloud.google.com/asset-inventory/docs/supported-asset-types") - * - * Generated from protobuf field string resource_type = 2; - * @return string - */ - public function getResourceType() - { - return $this->resource_type; - } - - /** - * The [supported resource - * type](https://cloud.google.com/asset-inventory/docs/supported-asset-types") - * - * Generated from protobuf field string resource_type = 2; - * @param string $var - * @return $this - */ - public function setResourceType($var) - { - GPBUtil::checkString($var, True); - $this->resource_type = $var; - - return $this; - } - - /** - * Human-readable name of this resource. - * - * Generated from protobuf field string display_name = 3; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Human-readable name of this resource. - * - * Generated from protobuf field string display_name = 3; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * The findings associated with this node in the attack path. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathNode.PathNodeAssociatedFinding associated_findings = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAssociatedFindings() - { - return $this->associated_findings; - } - - /** - * The findings associated with this node in the attack path. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathNode.PathNodeAssociatedFinding associated_findings = 4; - * @param array<\Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode\PathNodeAssociatedFinding>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAssociatedFindings($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode\PathNodeAssociatedFinding::class); - $this->associated_findings = $arr; - - return $this; - } - - /** - * Unique id of the attack path node. - * - * Generated from protobuf field string uuid = 5; - * @return string - */ - public function getUuid() - { - return $this->uuid; - } - - /** - * Unique id of the attack path node. - * - * Generated from protobuf field string uuid = 5; - * @param string $var - * @return $this - */ - public function setUuid($var) - { - GPBUtil::checkString($var, True); - $this->uuid = $var; - - return $this; - } - - /** - * A list of attack step nodes that exist in this attack path node. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathNode.AttackStepNode attack_steps = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAttackSteps() - { - return $this->attack_steps; - } - - /** - * A list of attack step nodes that exist in this attack path node. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath.AttackPathNode.AttackStepNode attack_steps = 6; - * @param array<\Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode\AttackStepNode>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAttackSteps($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode\AttackStepNode::class); - $this->attack_steps = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AttackPathNode::class, \Google\Cloud\SecurityCenter\V2\AttackPath_AttackPathNode::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/AttackStepNode.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/AttackStepNode.php deleted file mode 100644 index a6ac0b4f49f2..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/AttackStepNode.php +++ /dev/null @@ -1,206 +0,0 @@ -google.cloud.securitycenter.v2.AttackPath.AttackPathNode.AttackStepNode - */ -class AttackStepNode extends \Google\Protobuf\Internal\Message -{ - /** - * Unique ID for one Node - * - * Generated from protobuf field string uuid = 1; - */ - protected $uuid = ''; - /** - * Attack step type. Can be either AND, OR or DEFENSE - * - * Generated from protobuf field .google.cloud.securitycenter.v2.AttackPath.AttackPathNode.NodeType type = 2; - */ - protected $type = 0; - /** - * User friendly name of the attack step - * - * Generated from protobuf field string display_name = 3; - */ - protected $display_name = ''; - /** - * Attack step labels for metadata - * - * Generated from protobuf field map labels = 4; - */ - private $labels; - /** - * Attack step description - * - * Generated from protobuf field string description = 5; - */ - protected $description = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $uuid - * Unique ID for one Node - * @type int $type - * Attack step type. Can be either AND, OR or DEFENSE - * @type string $display_name - * User friendly name of the attack step - * @type array|\Google\Protobuf\Internal\MapField $labels - * Attack step labels for metadata - * @type string $description - * Attack step description - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\AttackPath::initOnce(); - parent::__construct($data); - } - - /** - * Unique ID for one Node - * - * Generated from protobuf field string uuid = 1; - * @return string - */ - public function getUuid() - { - return $this->uuid; - } - - /** - * Unique ID for one Node - * - * Generated from protobuf field string uuid = 1; - * @param string $var - * @return $this - */ - public function setUuid($var) - { - GPBUtil::checkString($var, True); - $this->uuid = $var; - - return $this; - } - - /** - * Attack step type. Can be either AND, OR or DEFENSE - * - * Generated from protobuf field .google.cloud.securitycenter.v2.AttackPath.AttackPathNode.NodeType type = 2; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Attack step type. Can be either AND, OR or DEFENSE - * - * Generated from protobuf field .google.cloud.securitycenter.v2.AttackPath.AttackPathNode.NodeType type = 2; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\AttackPath\AttackPathNode\NodeType::class); - $this->type = $var; - - return $this; - } - - /** - * User friendly name of the attack step - * - * Generated from protobuf field string display_name = 3; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * User friendly name of the attack step - * - * Generated from protobuf field string display_name = 3; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Attack step labels for metadata - * - * Generated from protobuf field map labels = 4; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Attack step labels for metadata - * - * Generated from protobuf field map labels = 4; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->labels = $arr; - - return $this; - } - - /** - * Attack step description - * - * Generated from protobuf field string description = 5; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Attack step description - * - * Generated from protobuf field string description = 5; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AttackStepNode::class, \Google\Cloud\SecurityCenter\V2\AttackPath_AttackPathNode_AttackStepNode::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/NodeType.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/NodeType.php deleted file mode 100644 index 56621f5a2508..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/NodeType.php +++ /dev/null @@ -1,78 +0,0 @@ -google.cloud.securitycenter.v2.AttackPath.AttackPathNode.NodeType - */ -class NodeType -{ - /** - * Type not specified - * - * Generated from protobuf enum NODE_TYPE_UNSPECIFIED = 0; - */ - const NODE_TYPE_UNSPECIFIED = 0; - /** - * Incoming edge joined with AND - * - * Generated from protobuf enum NODE_TYPE_AND = 1; - */ - const NODE_TYPE_AND = 1; - /** - * Incoming edge joined with OR - * - * Generated from protobuf enum NODE_TYPE_OR = 2; - */ - const NODE_TYPE_OR = 2; - /** - * Incoming edge is defense - * - * Generated from protobuf enum NODE_TYPE_DEFENSE = 3; - */ - const NODE_TYPE_DEFENSE = 3; - /** - * Incoming edge is attacker - * - * Generated from protobuf enum NODE_TYPE_ATTACKER = 4; - */ - const NODE_TYPE_ATTACKER = 4; - - private static $valueToName = [ - self::NODE_TYPE_UNSPECIFIED => 'NODE_TYPE_UNSPECIFIED', - self::NODE_TYPE_AND => 'NODE_TYPE_AND', - self::NODE_TYPE_OR => 'NODE_TYPE_OR', - self::NODE_TYPE_DEFENSE => 'NODE_TYPE_DEFENSE', - self::NODE_TYPE_ATTACKER => 'NODE_TYPE_ATTACKER', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(NodeType::class, \Google\Cloud\SecurityCenter\V2\AttackPath_AttackPathNode_NodeType::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/PathNodeAssociatedFinding.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/PathNodeAssociatedFinding.php deleted file mode 100644 index 3faa12e371ff..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/AttackPath/AttackPathNode/PathNodeAssociatedFinding.php +++ /dev/null @@ -1,142 +0,0 @@ -google.cloud.securitycenter.v2.AttackPath.AttackPathNode.PathNodeAssociatedFinding - */ -class PathNodeAssociatedFinding extends \Google\Protobuf\Internal\Message -{ - /** - * Canonical name of the associated findings. Example: - * organizations/123/sources/456/findings/789 - * - * Generated from protobuf field string canonical_finding = 1; - */ - protected $canonical_finding = ''; - /** - * The additional taxonomy group within findings from a given source. - * - * Generated from protobuf field string finding_category = 2; - */ - protected $finding_category = ''; - /** - * Full resource name of the finding. - * - * Generated from protobuf field string name = 3; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $canonical_finding - * Canonical name of the associated findings. Example: - * organizations/123/sources/456/findings/789 - * @type string $finding_category - * The additional taxonomy group within findings from a given source. - * @type string $name - * Full resource name of the finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\AttackPath::initOnce(); - parent::__construct($data); - } - - /** - * Canonical name of the associated findings. Example: - * organizations/123/sources/456/findings/789 - * - * Generated from protobuf field string canonical_finding = 1; - * @return string - */ - public function getCanonicalFinding() - { - return $this->canonical_finding; - } - - /** - * Canonical name of the associated findings. Example: - * organizations/123/sources/456/findings/789 - * - * Generated from protobuf field string canonical_finding = 1; - * @param string $var - * @return $this - */ - public function setCanonicalFinding($var) - { - GPBUtil::checkString($var, True); - $this->canonical_finding = $var; - - return $this; - } - - /** - * The additional taxonomy group within findings from a given source. - * - * Generated from protobuf field string finding_category = 2; - * @return string - */ - public function getFindingCategory() - { - return $this->finding_category; - } - - /** - * The additional taxonomy group within findings from a given source. - * - * Generated from protobuf field string finding_category = 2; - * @param string $var - * @return $this - */ - public function setFindingCategory($var) - { - GPBUtil::checkString($var, True); - $this->finding_category = $var; - - return $this; - } - - /** - * Full resource name of the finding. - * - * Generated from protobuf field string name = 3; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Full resource name of the finding. - * - * Generated from protobuf field string name = 3; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PathNodeAssociatedFinding::class, \Google\Cloud\SecurityCenter\V2\AttackPath_AttackPathNode_PathNodeAssociatedFinding::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BackupDisasterRecovery.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BackupDisasterRecovery.php deleted file mode 100644 index c95abc803328..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BackupDisasterRecovery.php +++ /dev/null @@ -1,495 +0,0 @@ -google.cloud.securitycenter.v2.BackupDisasterRecovery - */ -class BackupDisasterRecovery extends \Google\Protobuf\Internal\Message -{ - /** - * The name of a Backup and DR template which comprises one or more backup - * policies. See the [Backup and DR - * documentation](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#temp) - * for more information. For example, `snap-ov`. - * - * Generated from protobuf field string backup_template = 1; - */ - protected $backup_template = ''; - /** - * The names of Backup and DR policies that are associated with a template - * and that define when to run a backup, how frequently to run a backup, and - * how long to retain the backup image. For example, `onvaults`. - * - * Generated from protobuf field repeated string policies = 2; - */ - private $policies; - /** - * The name of a Backup and DR host, which is managed by the backup and - * recovery appliance and known to the management console. The host can be of - * type Generic (for example, Compute Engine, SQL Server, Oracle DB, SMB file - * system, etc.), vCenter, or an ESX server. See the [Backup and DR - * documentation on - * hosts](https://cloud.google.com/backup-disaster-recovery/docs/configuration/manage-hosts-and-their-applications) - * for more information. For example, `centos7-01`. - * - * Generated from protobuf field string host = 3; - */ - protected $host = ''; - /** - * The names of Backup and DR applications. An application is a VM, database, - * or file system on a managed host monitored by a backup and recovery - * appliance. For example, `centos7-01-vol00`, `centos7-01-vol01`, - * `centos7-01-vol02`. - * - * Generated from protobuf field repeated string applications = 4; - */ - private $applications; - /** - * The name of the Backup and DR storage pool that the backup and recovery - * appliance is storing data in. The storage pool could be of type Cloud, - * Primary, Snapshot, or OnVault. See the [Backup and DR documentation on - * storage - * pools](https://cloud.google.com/backup-disaster-recovery/docs/concepts/storage-pools). - * For example, `DiskPoolOne`. - * - * Generated from protobuf field string storage_pool = 5; - */ - protected $storage_pool = ''; - /** - * The names of Backup and DR advanced policy options of a policy applying to - * an application. See the [Backup and DR documentation on policy - * options](https://cloud.google.com/backup-disaster-recovery/docs/create-plan/policy-settings). - * For example, `skipofflineappsincongrp, nounmap`. - * - * Generated from protobuf field repeated string policy_options = 6; - */ - private $policy_options; - /** - * The name of the Backup and DR resource profile that specifies the storage - * media for backups of application and VM data. See the [Backup and DR - * documentation on - * profiles](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#profile). - * For example, `GCP`. - * - * Generated from protobuf field string profile = 7; - */ - protected $profile = ''; - /** - * The name of the Backup and DR appliance that captures, moves, and manages - * the lifecycle of backup data. For example, `backup-server-57137`. - * - * Generated from protobuf field string appliance = 8; - */ - protected $appliance = ''; - /** - * The backup type of the Backup and DR image. - * For example, `Snapshot`, `Remote Snapshot`, `OnVault`. - * - * Generated from protobuf field string backup_type = 9; - */ - protected $backup_type = ''; - /** - * The timestamp at which the Backup and DR backup was created. - * - * Generated from protobuf field .google.protobuf.Timestamp backup_create_time = 10; - */ - protected $backup_create_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $backup_template - * The name of a Backup and DR template which comprises one or more backup - * policies. See the [Backup and DR - * documentation](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#temp) - * for more information. For example, `snap-ov`. - * @type array|\Google\Protobuf\Internal\RepeatedField $policies - * The names of Backup and DR policies that are associated with a template - * and that define when to run a backup, how frequently to run a backup, and - * how long to retain the backup image. For example, `onvaults`. - * @type string $host - * The name of a Backup and DR host, which is managed by the backup and - * recovery appliance and known to the management console. The host can be of - * type Generic (for example, Compute Engine, SQL Server, Oracle DB, SMB file - * system, etc.), vCenter, or an ESX server. See the [Backup and DR - * documentation on - * hosts](https://cloud.google.com/backup-disaster-recovery/docs/configuration/manage-hosts-and-their-applications) - * for more information. For example, `centos7-01`. - * @type array|\Google\Protobuf\Internal\RepeatedField $applications - * The names of Backup and DR applications. An application is a VM, database, - * or file system on a managed host monitored by a backup and recovery - * appliance. For example, `centos7-01-vol00`, `centos7-01-vol01`, - * `centos7-01-vol02`. - * @type string $storage_pool - * The name of the Backup and DR storage pool that the backup and recovery - * appliance is storing data in. The storage pool could be of type Cloud, - * Primary, Snapshot, or OnVault. See the [Backup and DR documentation on - * storage - * pools](https://cloud.google.com/backup-disaster-recovery/docs/concepts/storage-pools). - * For example, `DiskPoolOne`. - * @type array|\Google\Protobuf\Internal\RepeatedField $policy_options - * The names of Backup and DR advanced policy options of a policy applying to - * an application. See the [Backup and DR documentation on policy - * options](https://cloud.google.com/backup-disaster-recovery/docs/create-plan/policy-settings). - * For example, `skipofflineappsincongrp, nounmap`. - * @type string $profile - * The name of the Backup and DR resource profile that specifies the storage - * media for backups of application and VM data. See the [Backup and DR - * documentation on - * profiles](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#profile). - * For example, `GCP`. - * @type string $appliance - * The name of the Backup and DR appliance that captures, moves, and manages - * the lifecycle of backup data. For example, `backup-server-57137`. - * @type string $backup_type - * The backup type of the Backup and DR image. - * For example, `Snapshot`, `Remote Snapshot`, `OnVault`. - * @type \Google\Protobuf\Timestamp $backup_create_time - * The timestamp at which the Backup and DR backup was created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\BackupDisasterRecovery::initOnce(); - parent::__construct($data); - } - - /** - * The name of a Backup and DR template which comprises one or more backup - * policies. See the [Backup and DR - * documentation](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#temp) - * for more information. For example, `snap-ov`. - * - * Generated from protobuf field string backup_template = 1; - * @return string - */ - public function getBackupTemplate() - { - return $this->backup_template; - } - - /** - * The name of a Backup and DR template which comprises one or more backup - * policies. See the [Backup and DR - * documentation](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#temp) - * for more information. For example, `snap-ov`. - * - * Generated from protobuf field string backup_template = 1; - * @param string $var - * @return $this - */ - public function setBackupTemplate($var) - { - GPBUtil::checkString($var, True); - $this->backup_template = $var; - - return $this; - } - - /** - * The names of Backup and DR policies that are associated with a template - * and that define when to run a backup, how frequently to run a backup, and - * how long to retain the backup image. For example, `onvaults`. - * - * Generated from protobuf field repeated string policies = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPolicies() - { - return $this->policies; - } - - /** - * The names of Backup and DR policies that are associated with a template - * and that define when to run a backup, how frequently to run a backup, and - * how long to retain the backup image. For example, `onvaults`. - * - * Generated from protobuf field repeated string policies = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPolicies($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->policies = $arr; - - return $this; - } - - /** - * The name of a Backup and DR host, which is managed by the backup and - * recovery appliance and known to the management console. The host can be of - * type Generic (for example, Compute Engine, SQL Server, Oracle DB, SMB file - * system, etc.), vCenter, or an ESX server. See the [Backup and DR - * documentation on - * hosts](https://cloud.google.com/backup-disaster-recovery/docs/configuration/manage-hosts-and-their-applications) - * for more information. For example, `centos7-01`. - * - * Generated from protobuf field string host = 3; - * @return string - */ - public function getHost() - { - return $this->host; - } - - /** - * The name of a Backup and DR host, which is managed by the backup and - * recovery appliance and known to the management console. The host can be of - * type Generic (for example, Compute Engine, SQL Server, Oracle DB, SMB file - * system, etc.), vCenter, or an ESX server. See the [Backup and DR - * documentation on - * hosts](https://cloud.google.com/backup-disaster-recovery/docs/configuration/manage-hosts-and-their-applications) - * for more information. For example, `centos7-01`. - * - * Generated from protobuf field string host = 3; - * @param string $var - * @return $this - */ - public function setHost($var) - { - GPBUtil::checkString($var, True); - $this->host = $var; - - return $this; - } - - /** - * The names of Backup and DR applications. An application is a VM, database, - * or file system on a managed host monitored by a backup and recovery - * appliance. For example, `centos7-01-vol00`, `centos7-01-vol01`, - * `centos7-01-vol02`. - * - * Generated from protobuf field repeated string applications = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getApplications() - { - return $this->applications; - } - - /** - * The names of Backup and DR applications. An application is a VM, database, - * or file system on a managed host monitored by a backup and recovery - * appliance. For example, `centos7-01-vol00`, `centos7-01-vol01`, - * `centos7-01-vol02`. - * - * Generated from protobuf field repeated string applications = 4; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setApplications($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->applications = $arr; - - return $this; - } - - /** - * The name of the Backup and DR storage pool that the backup and recovery - * appliance is storing data in. The storage pool could be of type Cloud, - * Primary, Snapshot, or OnVault. See the [Backup and DR documentation on - * storage - * pools](https://cloud.google.com/backup-disaster-recovery/docs/concepts/storage-pools). - * For example, `DiskPoolOne`. - * - * Generated from protobuf field string storage_pool = 5; - * @return string - */ - public function getStoragePool() - { - return $this->storage_pool; - } - - /** - * The name of the Backup and DR storage pool that the backup and recovery - * appliance is storing data in. The storage pool could be of type Cloud, - * Primary, Snapshot, or OnVault. See the [Backup and DR documentation on - * storage - * pools](https://cloud.google.com/backup-disaster-recovery/docs/concepts/storage-pools). - * For example, `DiskPoolOne`. - * - * Generated from protobuf field string storage_pool = 5; - * @param string $var - * @return $this - */ - public function setStoragePool($var) - { - GPBUtil::checkString($var, True); - $this->storage_pool = $var; - - return $this; - } - - /** - * The names of Backup and DR advanced policy options of a policy applying to - * an application. See the [Backup and DR documentation on policy - * options](https://cloud.google.com/backup-disaster-recovery/docs/create-plan/policy-settings). - * For example, `skipofflineappsincongrp, nounmap`. - * - * Generated from protobuf field repeated string policy_options = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPolicyOptions() - { - return $this->policy_options; - } - - /** - * The names of Backup and DR advanced policy options of a policy applying to - * an application. See the [Backup and DR documentation on policy - * options](https://cloud.google.com/backup-disaster-recovery/docs/create-plan/policy-settings). - * For example, `skipofflineappsincongrp, nounmap`. - * - * Generated from protobuf field repeated string policy_options = 6; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPolicyOptions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->policy_options = $arr; - - return $this; - } - - /** - * The name of the Backup and DR resource profile that specifies the storage - * media for backups of application and VM data. See the [Backup and DR - * documentation on - * profiles](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#profile). - * For example, `GCP`. - * - * Generated from protobuf field string profile = 7; - * @return string - */ - public function getProfile() - { - return $this->profile; - } - - /** - * The name of the Backup and DR resource profile that specifies the storage - * media for backups of application and VM data. See the [Backup and DR - * documentation on - * profiles](https://cloud.google.com/backup-disaster-recovery/docs/concepts/backup-plan#profile). - * For example, `GCP`. - * - * Generated from protobuf field string profile = 7; - * @param string $var - * @return $this - */ - public function setProfile($var) - { - GPBUtil::checkString($var, True); - $this->profile = $var; - - return $this; - } - - /** - * The name of the Backup and DR appliance that captures, moves, and manages - * the lifecycle of backup data. For example, `backup-server-57137`. - * - * Generated from protobuf field string appliance = 8; - * @return string - */ - public function getAppliance() - { - return $this->appliance; - } - - /** - * The name of the Backup and DR appliance that captures, moves, and manages - * the lifecycle of backup data. For example, `backup-server-57137`. - * - * Generated from protobuf field string appliance = 8; - * @param string $var - * @return $this - */ - public function setAppliance($var) - { - GPBUtil::checkString($var, True); - $this->appliance = $var; - - return $this; - } - - /** - * The backup type of the Backup and DR image. - * For example, `Snapshot`, `Remote Snapshot`, `OnVault`. - * - * Generated from protobuf field string backup_type = 9; - * @return string - */ - public function getBackupType() - { - return $this->backup_type; - } - - /** - * The backup type of the Backup and DR image. - * For example, `Snapshot`, `Remote Snapshot`, `OnVault`. - * - * Generated from protobuf field string backup_type = 9; - * @param string $var - * @return $this - */ - public function setBackupType($var) - { - GPBUtil::checkString($var, True); - $this->backup_type = $var; - - return $this; - } - - /** - * The timestamp at which the Backup and DR backup was created. - * - * Generated from protobuf field .google.protobuf.Timestamp backup_create_time = 10; - * @return \Google\Protobuf\Timestamp|null - */ - public function getBackupCreateTime() - { - return $this->backup_create_time; - } - - public function hasBackupCreateTime() - { - return isset($this->backup_create_time); - } - - public function clearBackupCreateTime() - { - unset($this->backup_create_time); - } - - /** - * The timestamp at which the Backup and DR backup was created. - * - * Generated from protobuf field .google.protobuf.Timestamp backup_create_time = 10; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setBackupCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->backup_create_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BatchCreateResourceValueConfigsRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BatchCreateResourceValueConfigsRequest.php deleted file mode 100644 index bfc8a78bedf8..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BatchCreateResourceValueConfigsRequest.php +++ /dev/null @@ -1,127 +0,0 @@ -google.cloud.securitycenter.v2.BatchCreateResourceValueConfigsRequest - */ -class BatchCreateResourceValueConfigsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the new ResourceValueConfig's parent. - * The parent field in the CreateResourceValueConfigRequest - * messages must either be empty or match this field. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The resource value configs to be created. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.CreateResourceValueConfigRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - private $requests; - - /** - * @param string $parent Required. Resource name of the new ResourceValueConfig's parent. - * The parent field in the CreateResourceValueConfigRequest - * messages must either be empty or match this field. Please see - * {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. - * @param \Google\Cloud\SecurityCenter\V2\CreateResourceValueConfigRequest[] $requests Required. The resource value configs to be created. - * - * @return \Google\Cloud\SecurityCenter\V2\BatchCreateResourceValueConfigsRequest - * - * @experimental - */ - public static function build(string $parent, array $requests): self - { - return (new self()) - ->setParent($parent) - ->setRequests($requests); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the new ResourceValueConfig's parent. - * The parent field in the CreateResourceValueConfigRequest - * messages must either be empty or match this field. - * @type array<\Google\Cloud\SecurityCenter\V2\CreateResourceValueConfigRequest>|\Google\Protobuf\Internal\RepeatedField $requests - * Required. The resource value configs to be created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the new ResourceValueConfig's parent. - * The parent field in the CreateResourceValueConfigRequest - * messages must either be empty or match this field. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the new ResourceValueConfig's parent. - * The parent field in the CreateResourceValueConfigRequest - * messages must either be empty or match this field. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The resource value configs to be created. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.CreateResourceValueConfigRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRequests() - { - return $this->requests; - } - - /** - * Required. The resource value configs to be created. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.CreateResourceValueConfigRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param array<\Google\Cloud\SecurityCenter\V2\CreateResourceValueConfigRequest>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRequests($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\CreateResourceValueConfigRequest::class); - $this->requests = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BatchCreateResourceValueConfigsResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BatchCreateResourceValueConfigsResponse.php deleted file mode 100644 index 660411064214..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BatchCreateResourceValueConfigsResponse.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.securitycenter.v2.BatchCreateResourceValueConfigsResponse - */ -class BatchCreateResourceValueConfigsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The resource value configs created - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_configs = 1; - */ - private $resource_value_configs; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V2\ResourceValueConfig>|\Google\Protobuf\Internal\RepeatedField $resource_value_configs - * The resource value configs created - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * The resource value configs created - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_configs = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getResourceValueConfigs() - { - return $this->resource_value_configs; - } - - /** - * The resource value configs created - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_configs = 1; - * @param array<\Google\Cloud\SecurityCenter\V2\ResourceValueConfig>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setResourceValueConfigs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ResourceValueConfig::class); - $this->resource_value_configs = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BigQueryExport.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BigQueryExport.php deleted file mode 100644 index 4f52487609e8..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BigQueryExport.php +++ /dev/null @@ -1,457 +0,0 @@ -google.cloud.securitycenter.v2.BigQueryExport - */ -class BigQueryExport extends \Google\Protobuf\Internal\Message -{ - /** - * The relative resource name of this export. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name. - * The following list shows some examples: - * + - * `organizations/{organization_id}/locations/{location_id}/bigQueryExports/{export_id}` - * + `folders/{folder_id}/locations/{location_id}/bigQueryExports/{export_id}` - * + - * `projects/{project_id}/locations/{location_id}/bigQueryExports/{export_id}` - * This field is provided in responses, and is ignored when provided in create - * requests. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The description of the export (max of 1024 characters). - * - * Generated from protobuf field string description = 2; - */ - protected $description = ''; - /** - * Expression that defines the filter to apply across create/update events - * of findings. The expression is a list of zero or more restrictions combined - * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` - * has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 3; - */ - protected $filter = ''; - /** - * The dataset to write findings' updates to. Its format is - * "projects/[project_id]/datasets/[bigquery_dataset_id]". - * BigQuery Dataset unique ID must contain only letters (a-z, A-Z), numbers - * (0-9), or underscores (_). - * - * Generated from protobuf field string dataset = 4; - */ - protected $dataset = ''; - /** - * Output only. The time at which the BigQuery export was created. - * This field is set by the server and will be ignored if provided on export - * on creation. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The most recent time at which the BigQuery export was updated. - * This field is set by the server and will be ignored if provided on export - * creation or update. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. Email address of the user who last edited the BigQuery export. - * This field is set by the server and will be ignored if provided on export - * creation or update. - * - * Generated from protobuf field string most_recent_editor = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $most_recent_editor = ''; - /** - * Output only. The service account that needs permission to create table and - * upload data to the BigQuery dataset. - * - * Generated from protobuf field string principal = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $principal = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The relative resource name of this export. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name. - * The following list shows some examples: - * + - * `organizations/{organization_id}/locations/{location_id}/bigQueryExports/{export_id}` - * + `folders/{folder_id}/locations/{location_id}/bigQueryExports/{export_id}` - * + - * `projects/{project_id}/locations/{location_id}/bigQueryExports/{export_id}` - * This field is provided in responses, and is ignored when provided in create - * requests. - * @type string $description - * The description of the export (max of 1024 characters). - * @type string $filter - * Expression that defines the filter to apply across create/update events - * of findings. The expression is a list of zero or more restrictions combined - * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` - * has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * @type string $dataset - * The dataset to write findings' updates to. Its format is - * "projects/[project_id]/datasets/[bigquery_dataset_id]". - * BigQuery Dataset unique ID must contain only letters (a-z, A-Z), numbers - * (0-9), or underscores (_). - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time at which the BigQuery export was created. - * This field is set by the server and will be ignored if provided on export - * on creation. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The most recent time at which the BigQuery export was updated. - * This field is set by the server and will be ignored if provided on export - * creation or update. - * @type string $most_recent_editor - * Output only. Email address of the user who last edited the BigQuery export. - * This field is set by the server and will be ignored if provided on export - * creation or update. - * @type string $principal - * Output only. The service account that needs permission to create table and - * upload data to the BigQuery dataset. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\BigqueryExport::initOnce(); - parent::__construct($data); - } - - /** - * The relative resource name of this export. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name. - * The following list shows some examples: - * + - * `organizations/{organization_id}/locations/{location_id}/bigQueryExports/{export_id}` - * + `folders/{folder_id}/locations/{location_id}/bigQueryExports/{export_id}` - * + - * `projects/{project_id}/locations/{location_id}/bigQueryExports/{export_id}` - * This field is provided in responses, and is ignored when provided in create - * requests. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The relative resource name of this export. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name. - * The following list shows some examples: - * + - * `organizations/{organization_id}/locations/{location_id}/bigQueryExports/{export_id}` - * + `folders/{folder_id}/locations/{location_id}/bigQueryExports/{export_id}` - * + - * `projects/{project_id}/locations/{location_id}/bigQueryExports/{export_id}` - * This field is provided in responses, and is ignored when provided in create - * requests. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The description of the export (max of 1024 characters). - * - * Generated from protobuf field string description = 2; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * The description of the export (max of 1024 characters). - * - * Generated from protobuf field string description = 2; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Expression that defines the filter to apply across create/update events - * of findings. The expression is a list of zero or more restrictions combined - * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` - * has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 3; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Expression that defines the filter to apply across create/update events - * of findings. The expression is a list of zero or more restrictions combined - * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` - * has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 3; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * The dataset to write findings' updates to. Its format is - * "projects/[project_id]/datasets/[bigquery_dataset_id]". - * BigQuery Dataset unique ID must contain only letters (a-z, A-Z), numbers - * (0-9), or underscores (_). - * - * Generated from protobuf field string dataset = 4; - * @return string - */ - public function getDataset() - { - return $this->dataset; - } - - /** - * The dataset to write findings' updates to. Its format is - * "projects/[project_id]/datasets/[bigquery_dataset_id]". - * BigQuery Dataset unique ID must contain only letters (a-z, A-Z), numbers - * (0-9), or underscores (_). - * - * Generated from protobuf field string dataset = 4; - * @param string $var - * @return $this - */ - public function setDataset($var) - { - GPBUtil::checkString($var, True); - $this->dataset = $var; - - return $this; - } - - /** - * Output only. The time at which the BigQuery export was created. - * This field is set by the server and will be ignored if provided on export - * on creation. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The time at which the BigQuery export was created. - * This field is set by the server and will be ignored if provided on export - * on creation. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The most recent time at which the BigQuery export was updated. - * This field is set by the server and will be ignored if provided on export - * creation or update. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. The most recent time at which the BigQuery export was updated. - * This field is set by the server and will be ignored if provided on export - * creation or update. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Output only. Email address of the user who last edited the BigQuery export. - * This field is set by the server and will be ignored if provided on export - * creation or update. - * - * Generated from protobuf field string most_recent_editor = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getMostRecentEditor() - { - return $this->most_recent_editor; - } - - /** - * Output only. Email address of the user who last edited the BigQuery export. - * This field is set by the server and will be ignored if provided on export - * creation or update. - * - * Generated from protobuf field string most_recent_editor = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setMostRecentEditor($var) - { - GPBUtil::checkString($var, True); - $this->most_recent_editor = $var; - - return $this; - } - - /** - * Output only. The service account that needs permission to create table and - * upload data to the BigQuery dataset. - * - * Generated from protobuf field string principal = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getPrincipal() - { - return $this->principal; - } - - /** - * Output only. The service account that needs permission to create table and - * upload data to the BigQuery dataset. - * - * Generated from protobuf field string principal = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setPrincipal($var) - { - GPBUtil::checkString($var, True); - $this->principal = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BulkMuteFindingsRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BulkMuteFindingsRequest.php deleted file mode 100644 index 8a1d92e384e0..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BulkMuteFindingsRequest.php +++ /dev/null @@ -1,215 +0,0 @@ -google.cloud.securitycenter.v2.BulkMuteFindingsRequest - */ -class BulkMuteFindingsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent, at which bulk action needs to be applied. If no - * location is specified, findings are updated in global. The following list - * shows some examples: - * + `organizations/[organization_id]` - * + `organizations/[organization_id]/locations/[location_id]` - * + `folders/[folder_id]` - * + `folders/[folder_id]/locations/[location_id]` - * + `projects/[project_id]` - * + `projects/[project_id]/locations/[location_id]` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Expression that identifies findings that should be updated. - * The expression is a list of zero or more restrictions combined - * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` - * has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 2; - */ - protected $filter = ''; - - /** - * @param string $parent Required. The parent, at which bulk action needs to be applied. If no - * location is specified, findings are updated in global. The following list - * shows some examples: - * - * + `organizations/[organization_id]` - * + `organizations/[organization_id]/locations/[location_id]` - * + `folders/[folder_id]` - * + `folders/[folder_id]/locations/[location_id]` - * + `projects/[project_id]` - * + `projects/[project_id]/locations/[location_id]` - * - * @return \Google\Cloud\SecurityCenter\V2\BulkMuteFindingsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent, at which bulk action needs to be applied. If no - * location is specified, findings are updated in global. The following list - * shows some examples: - * + `organizations/[organization_id]` - * + `organizations/[organization_id]/locations/[location_id]` - * + `folders/[folder_id]` - * + `folders/[folder_id]/locations/[location_id]` - * + `projects/[project_id]` - * + `projects/[project_id]/locations/[location_id]` - * @type string $filter - * Expression that identifies findings that should be updated. - * The expression is a list of zero or more restrictions combined - * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` - * has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent, at which bulk action needs to be applied. If no - * location is specified, findings are updated in global. The following list - * shows some examples: - * + `organizations/[organization_id]` - * + `organizations/[organization_id]/locations/[location_id]` - * + `folders/[folder_id]` - * + `folders/[folder_id]/locations/[location_id]` - * + `projects/[project_id]` - * + `projects/[project_id]/locations/[location_id]` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent, at which bulk action needs to be applied. If no - * location is specified, findings are updated in global. The following list - * shows some examples: - * + `organizations/[organization_id]` - * + `organizations/[organization_id]/locations/[location_id]` - * + `folders/[folder_id]` - * + `folders/[folder_id]/locations/[location_id]` - * + `projects/[project_id]` - * + `projects/[project_id]/locations/[location_id]` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Expression that identifies findings that should be updated. - * The expression is a list of zero or more restrictions combined - * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` - * has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 2; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Expression that identifies findings that should be updated. - * The expression is a list of zero or more restrictions combined - * via logical operators `AND` and `OR`. Parentheses are supported, and `OR` - * has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 2; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BulkMuteFindingsResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BulkMuteFindingsResponse.php deleted file mode 100644 index f42b0ef30f73..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/BulkMuteFindingsResponse.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.securitycenter.v2.BulkMuteFindingsResponse - */ -class BulkMuteFindingsResponse extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpDataProfile.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpDataProfile.php deleted file mode 100644 index 9a1e04dc8d8a..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpDataProfile.php +++ /dev/null @@ -1,106 +0,0 @@ -google.cloud.securitycenter.v2.CloudDlpDataProfile - */ -class CloudDlpDataProfile extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the data profile, for example, - * `projects/123/locations/europe/tableProfiles/8383929`. - * - * Generated from protobuf field string data_profile = 1 [(.google.api.resource_reference) = { - */ - protected $data_profile = ''; - /** - * The resource hierarchy level at which the data profile was generated. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudDlpDataProfile.ParentType parent_type = 2; - */ - protected $parent_type = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $data_profile - * Name of the data profile, for example, - * `projects/123/locations/europe/tableProfiles/8383929`. - * @type int $parent_type - * The resource hierarchy level at which the data profile was generated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\CloudDlpDataProfile::initOnce(); - parent::__construct($data); - } - - /** - * Name of the data profile, for example, - * `projects/123/locations/europe/tableProfiles/8383929`. - * - * Generated from protobuf field string data_profile = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getDataProfile() - { - return $this->data_profile; - } - - /** - * Name of the data profile, for example, - * `projects/123/locations/europe/tableProfiles/8383929`. - * - * Generated from protobuf field string data_profile = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setDataProfile($var) - { - GPBUtil::checkString($var, True); - $this->data_profile = $var; - - return $this; - } - - /** - * The resource hierarchy level at which the data profile was generated. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudDlpDataProfile.ParentType parent_type = 2; - * @return int - */ - public function getParentType() - { - return $this->parent_type; - } - - /** - * The resource hierarchy level at which the data profile was generated. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudDlpDataProfile.ParentType parent_type = 2; - * @param int $var - * @return $this - */ - public function setParentType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\CloudDlpDataProfile\ParentType::class); - $this->parent_type = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpDataProfile/ParentType.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpDataProfile/ParentType.php deleted file mode 100644 index 03f58e8fc723..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpDataProfile/ParentType.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.securitycenter.v2.CloudDlpDataProfile.ParentType - */ -class ParentType -{ - /** - * Unspecified parent type. - * - * Generated from protobuf enum PARENT_TYPE_UNSPECIFIED = 0; - */ - const PARENT_TYPE_UNSPECIFIED = 0; - /** - * Organization-level configurations. - * - * Generated from protobuf enum ORGANIZATION = 1; - */ - const ORGANIZATION = 1; - /** - * Project-level configurations. - * - * Generated from protobuf enum PROJECT = 2; - */ - const PROJECT = 2; - - private static $valueToName = [ - self::PARENT_TYPE_UNSPECIFIED => 'PARENT_TYPE_UNSPECIFIED', - self::ORGANIZATION => 'ORGANIZATION', - self::PROJECT => 'PROJECT', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ParentType::class, \Google\Cloud\SecurityCenter\V2\CloudDlpDataProfile_ParentType::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpInspection.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpInspection.php deleted file mode 100644 index 8efb07526191..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudDlpInspection.php +++ /dev/null @@ -1,187 +0,0 @@ -google.cloud.securitycenter.v2.CloudDlpInspection - */ -class CloudDlpInspection extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the inspection job, for example, - * `projects/123/locations/europe/dlpJobs/i-8383929`. - * - * Generated from protobuf field string inspect_job = 1 [(.google.api.resource_reference) = { - */ - protected $inspect_job = ''; - /** - * The type of information (or - * *[infoType](https://cloud.google.com/dlp/docs/infotypes-reference)*) found, - * for example, `EMAIL_ADDRESS` or `STREET_ADDRESS`. - * - * Generated from protobuf field string info_type = 2; - */ - protected $info_type = ''; - /** - * The number of times Cloud DLP found this infoType within this job - * and resource. - * - * Generated from protobuf field int64 info_type_count = 3; - */ - protected $info_type_count = 0; - /** - * Whether Cloud DLP scanned the complete resource or a sampled subset. - * - * Generated from protobuf field bool full_scan = 4; - */ - protected $full_scan = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $inspect_job - * Name of the inspection job, for example, - * `projects/123/locations/europe/dlpJobs/i-8383929`. - * @type string $info_type - * The type of information (or - * *[infoType](https://cloud.google.com/dlp/docs/infotypes-reference)*) found, - * for example, `EMAIL_ADDRESS` or `STREET_ADDRESS`. - * @type int|string $info_type_count - * The number of times Cloud DLP found this infoType within this job - * and resource. - * @type bool $full_scan - * Whether Cloud DLP scanned the complete resource or a sampled subset. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\CloudDlpInspection::initOnce(); - parent::__construct($data); - } - - /** - * Name of the inspection job, for example, - * `projects/123/locations/europe/dlpJobs/i-8383929`. - * - * Generated from protobuf field string inspect_job = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getInspectJob() - { - return $this->inspect_job; - } - - /** - * Name of the inspection job, for example, - * `projects/123/locations/europe/dlpJobs/i-8383929`. - * - * Generated from protobuf field string inspect_job = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setInspectJob($var) - { - GPBUtil::checkString($var, True); - $this->inspect_job = $var; - - return $this; - } - - /** - * The type of information (or - * *[infoType](https://cloud.google.com/dlp/docs/infotypes-reference)*) found, - * for example, `EMAIL_ADDRESS` or `STREET_ADDRESS`. - * - * Generated from protobuf field string info_type = 2; - * @return string - */ - public function getInfoType() - { - return $this->info_type; - } - - /** - * The type of information (or - * *[infoType](https://cloud.google.com/dlp/docs/infotypes-reference)*) found, - * for example, `EMAIL_ADDRESS` or `STREET_ADDRESS`. - * - * Generated from protobuf field string info_type = 2; - * @param string $var - * @return $this - */ - public function setInfoType($var) - { - GPBUtil::checkString($var, True); - $this->info_type = $var; - - return $this; - } - - /** - * The number of times Cloud DLP found this infoType within this job - * and resource. - * - * Generated from protobuf field int64 info_type_count = 3; - * @return int|string - */ - public function getInfoTypeCount() - { - return $this->info_type_count; - } - - /** - * The number of times Cloud DLP found this infoType within this job - * and resource. - * - * Generated from protobuf field int64 info_type_count = 3; - * @param int|string $var - * @return $this - */ - public function setInfoTypeCount($var) - { - GPBUtil::checkInt64($var); - $this->info_type_count = $var; - - return $this; - } - - /** - * Whether Cloud DLP scanned the complete resource or a sampled subset. - * - * Generated from protobuf field bool full_scan = 4; - * @return bool - */ - public function getFullScan() - { - return $this->full_scan; - } - - /** - * Whether Cloud DLP scanned the complete resource or a sampled subset. - * - * Generated from protobuf field bool full_scan = 4; - * @param bool $var - * @return $this - */ - public function setFullScan($var) - { - GPBUtil::checkBool($var); - $this->full_scan = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudLoggingEntry.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudLoggingEntry.php deleted file mode 100644 index 4ba37ea34ec1..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CloudLoggingEntry.php +++ /dev/null @@ -1,196 +0,0 @@ -google.cloud.securitycenter.v2.CloudLoggingEntry - */ -class CloudLoggingEntry extends \Google\Protobuf\Internal\Message -{ - /** - * A unique identifier for the log entry. - * - * Generated from protobuf field string insert_id = 1; - */ - protected $insert_id = ''; - /** - * The type of the log (part of `log_name`. `log_name` is the resource name of - * the log to which this log entry belongs). For example: - * `cloudresourcemanager.googleapis.com/activity` Note that this field is not - * URL-encoded, unlike in `LogEntry`. - * - * Generated from protobuf field string log_id = 2; - */ - protected $log_id = ''; - /** - * The organization, folder, or project of the monitored resource that - * produced this log entry. - * - * Generated from protobuf field string resource_container = 3; - */ - protected $resource_container = ''; - /** - * The time the event described by the log entry occurred. - * - * Generated from protobuf field .google.protobuf.Timestamp timestamp = 4; - */ - protected $timestamp = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $insert_id - * A unique identifier for the log entry. - * @type string $log_id - * The type of the log (part of `log_name`. `log_name` is the resource name of - * the log to which this log entry belongs). For example: - * `cloudresourcemanager.googleapis.com/activity` Note that this field is not - * URL-encoded, unlike in `LogEntry`. - * @type string $resource_container - * The organization, folder, or project of the monitored resource that - * produced this log entry. - * @type \Google\Protobuf\Timestamp $timestamp - * The time the event described by the log entry occurred. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\LogEntry::initOnce(); - parent::__construct($data); - } - - /** - * A unique identifier for the log entry. - * - * Generated from protobuf field string insert_id = 1; - * @return string - */ - public function getInsertId() - { - return $this->insert_id; - } - - /** - * A unique identifier for the log entry. - * - * Generated from protobuf field string insert_id = 1; - * @param string $var - * @return $this - */ - public function setInsertId($var) - { - GPBUtil::checkString($var, True); - $this->insert_id = $var; - - return $this; - } - - /** - * The type of the log (part of `log_name`. `log_name` is the resource name of - * the log to which this log entry belongs). For example: - * `cloudresourcemanager.googleapis.com/activity` Note that this field is not - * URL-encoded, unlike in `LogEntry`. - * - * Generated from protobuf field string log_id = 2; - * @return string - */ - public function getLogId() - { - return $this->log_id; - } - - /** - * The type of the log (part of `log_name`. `log_name` is the resource name of - * the log to which this log entry belongs). For example: - * `cloudresourcemanager.googleapis.com/activity` Note that this field is not - * URL-encoded, unlike in `LogEntry`. - * - * Generated from protobuf field string log_id = 2; - * @param string $var - * @return $this - */ - public function setLogId($var) - { - GPBUtil::checkString($var, True); - $this->log_id = $var; - - return $this; - } - - /** - * The organization, folder, or project of the monitored resource that - * produced this log entry. - * - * Generated from protobuf field string resource_container = 3; - * @return string - */ - public function getResourceContainer() - { - return $this->resource_container; - } - - /** - * The organization, folder, or project of the monitored resource that - * produced this log entry. - * - * Generated from protobuf field string resource_container = 3; - * @param string $var - * @return $this - */ - public function setResourceContainer($var) - { - GPBUtil::checkString($var, True); - $this->resource_container = $var; - - return $this; - } - - /** - * The time the event described by the log entry occurred. - * - * Generated from protobuf field .google.protobuf.Timestamp timestamp = 4; - * @return \Google\Protobuf\Timestamp|null - */ - public function getTimestamp() - { - return $this->timestamp; - } - - public function hasTimestamp() - { - return isset($this->timestamp); - } - - public function clearTimestamp() - { - unset($this->timestamp); - } - - /** - * The time the event described by the log entry occurred. - * - * Generated from protobuf field .google.protobuf.Timestamp timestamp = 4; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setTimestamp($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->timestamp = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Compliance.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Compliance.php deleted file mode 100644 index fbc12e9a7e38..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Compliance.php +++ /dev/null @@ -1,140 +0,0 @@ -google.cloud.securitycenter.v2.Compliance - */ -class Compliance extends \Google\Protobuf\Internal\Message -{ - /** - * Industry-wide compliance standards or benchmarks, such as CIS, PCI, and - * OWASP. - * - * Generated from protobuf field string standard = 1; - */ - protected $standard = ''; - /** - * Version of the standard or benchmark, for example, 1.1 - * - * Generated from protobuf field string version = 2; - */ - protected $version = ''; - /** - * Policies within the standard or benchmark, for example, A.12.4.1 - * - * Generated from protobuf field repeated string ids = 3; - */ - private $ids; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $standard - * Industry-wide compliance standards or benchmarks, such as CIS, PCI, and - * OWASP. - * @type string $version - * Version of the standard or benchmark, for example, 1.1 - * @type array|\Google\Protobuf\Internal\RepeatedField $ids - * Policies within the standard or benchmark, for example, A.12.4.1 - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Compliance::initOnce(); - parent::__construct($data); - } - - /** - * Industry-wide compliance standards or benchmarks, such as CIS, PCI, and - * OWASP. - * - * Generated from protobuf field string standard = 1; - * @return string - */ - public function getStandard() - { - return $this->standard; - } - - /** - * Industry-wide compliance standards or benchmarks, such as CIS, PCI, and - * OWASP. - * - * Generated from protobuf field string standard = 1; - * @param string $var - * @return $this - */ - public function setStandard($var) - { - GPBUtil::checkString($var, True); - $this->standard = $var; - - return $this; - } - - /** - * Version of the standard or benchmark, for example, 1.1 - * - * Generated from protobuf field string version = 2; - * @return string - */ - public function getVersion() - { - return $this->version; - } - - /** - * Version of the standard or benchmark, for example, 1.1 - * - * Generated from protobuf field string version = 2; - * @param string $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkString($var, True); - $this->version = $var; - - return $this; - } - - /** - * Policies within the standard or benchmark, for example, A.12.4.1 - * - * Generated from protobuf field repeated string ids = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getIds() - { - return $this->ids; - } - - /** - * Policies within the standard or benchmark, for example, A.12.4.1 - * - * Generated from protobuf field repeated string ids = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setIds($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->ids = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Connection.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Connection.php deleted file mode 100644 index c7097b6c8384..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Connection.php +++ /dev/null @@ -1,211 +0,0 @@ -google.cloud.securitycenter.v2.Connection - */ -class Connection extends \Google\Protobuf\Internal\Message -{ - /** - * Destination IP address. Not present for sockets that are listening and not - * connected. - * - * Generated from protobuf field string destination_ip = 1; - */ - protected $destination_ip = ''; - /** - * Destination port. Not present for sockets that are listening and not - * connected. - * - * Generated from protobuf field int32 destination_port = 2; - */ - protected $destination_port = 0; - /** - * Source IP address. - * - * Generated from protobuf field string source_ip = 3; - */ - protected $source_ip = ''; - /** - * Source port. - * - * Generated from protobuf field int32 source_port = 4; - */ - protected $source_port = 0; - /** - * IANA Internet Protocol Number such as TCP(6) and UDP(17). - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Connection.Protocol protocol = 5; - */ - protected $protocol = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $destination_ip - * Destination IP address. Not present for sockets that are listening and not - * connected. - * @type int $destination_port - * Destination port. Not present for sockets that are listening and not - * connected. - * @type string $source_ip - * Source IP address. - * @type int $source_port - * Source port. - * @type int $protocol - * IANA Internet Protocol Number such as TCP(6) and UDP(17). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Connection::initOnce(); - parent::__construct($data); - } - - /** - * Destination IP address. Not present for sockets that are listening and not - * connected. - * - * Generated from protobuf field string destination_ip = 1; - * @return string - */ - public function getDestinationIp() - { - return $this->destination_ip; - } - - /** - * Destination IP address. Not present for sockets that are listening and not - * connected. - * - * Generated from protobuf field string destination_ip = 1; - * @param string $var - * @return $this - */ - public function setDestinationIp($var) - { - GPBUtil::checkString($var, True); - $this->destination_ip = $var; - - return $this; - } - - /** - * Destination port. Not present for sockets that are listening and not - * connected. - * - * Generated from protobuf field int32 destination_port = 2; - * @return int - */ - public function getDestinationPort() - { - return $this->destination_port; - } - - /** - * Destination port. Not present for sockets that are listening and not - * connected. - * - * Generated from protobuf field int32 destination_port = 2; - * @param int $var - * @return $this - */ - public function setDestinationPort($var) - { - GPBUtil::checkInt32($var); - $this->destination_port = $var; - - return $this; - } - - /** - * Source IP address. - * - * Generated from protobuf field string source_ip = 3; - * @return string - */ - public function getSourceIp() - { - return $this->source_ip; - } - - /** - * Source IP address. - * - * Generated from protobuf field string source_ip = 3; - * @param string $var - * @return $this - */ - public function setSourceIp($var) - { - GPBUtil::checkString($var, True); - $this->source_ip = $var; - - return $this; - } - - /** - * Source port. - * - * Generated from protobuf field int32 source_port = 4; - * @return int - */ - public function getSourcePort() - { - return $this->source_port; - } - - /** - * Source port. - * - * Generated from protobuf field int32 source_port = 4; - * @param int $var - * @return $this - */ - public function setSourcePort($var) - { - GPBUtil::checkInt32($var); - $this->source_port = $var; - - return $this; - } - - /** - * IANA Internet Protocol Number such as TCP(6) and UDP(17). - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Connection.Protocol protocol = 5; - * @return int - */ - public function getProtocol() - { - return $this->protocol; - } - - /** - * IANA Internet Protocol Number such as TCP(6) and UDP(17). - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Connection.Protocol protocol = 5; - * @param int $var - * @return $this - */ - public function setProtocol($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Connection\Protocol::class); - $this->protocol = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Connection/Protocol.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Connection/Protocol.php deleted file mode 100644 index 6a3acec59537..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Connection/Protocol.php +++ /dev/null @@ -1,85 +0,0 @@ -google.cloud.securitycenter.v2.Connection.Protocol - */ -class Protocol -{ - /** - * Unspecified protocol (not HOPOPT). - * - * Generated from protobuf enum PROTOCOL_UNSPECIFIED = 0; - */ - const PROTOCOL_UNSPECIFIED = 0; - /** - * Internet Control Message Protocol. - * - * Generated from protobuf enum ICMP = 1; - */ - const ICMP = 1; - /** - * Transmission Control Protocol. - * - * Generated from protobuf enum TCP = 6; - */ - const TCP = 6; - /** - * User Datagram Protocol. - * - * Generated from protobuf enum UDP = 17; - */ - const UDP = 17; - /** - * Generic Routing Encapsulation. - * - * Generated from protobuf enum GRE = 47; - */ - const GRE = 47; - /** - * Encap Security Payload. - * - * Generated from protobuf enum ESP = 50; - */ - const ESP = 50; - - private static $valueToName = [ - self::PROTOCOL_UNSPECIFIED => 'PROTOCOL_UNSPECIFIED', - self::ICMP => 'ICMP', - self::TCP => 'TCP', - self::UDP => 'UDP', - self::GRE => 'GRE', - self::ESP => 'ESP', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Protocol::class, \Google\Cloud\SecurityCenter\V2\Connection_Protocol::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Contact.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Contact.php deleted file mode 100644 index ee0ee7e41e87..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Contact.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.securitycenter.v2.Contact - */ -class Contact extends \Google\Protobuf\Internal\Message -{ - /** - * An email address. For example, "`person123@company.com`". - * - * Generated from protobuf field string email = 1; - */ - protected $email = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $email - * An email address. For example, "`person123@company.com`". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\ContactDetails::initOnce(); - parent::__construct($data); - } - - /** - * An email address. For example, "`person123@company.com`". - * - * Generated from protobuf field string email = 1; - * @return string - */ - public function getEmail() - { - return $this->email; - } - - /** - * An email address. For example, "`person123@company.com`". - * - * Generated from protobuf field string email = 1; - * @param string $var - * @return $this - */ - public function setEmail($var) - { - GPBUtil::checkString($var, True); - $this->email = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ContactDetails.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ContactDetails.php deleted file mode 100644 index 79a31f59f3dc..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ContactDetails.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.securitycenter.v2.ContactDetails - */ -class ContactDetails extends \Google\Protobuf\Internal\Message -{ - /** - * A list of contacts - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Contact contacts = 1; - */ - private $contacts; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V2\Contact>|\Google\Protobuf\Internal\RepeatedField $contacts - * A list of contacts - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\ContactDetails::initOnce(); - parent::__construct($data); - } - - /** - * A list of contacts - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Contact contacts = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getContacts() - { - return $this->contacts; - } - - /** - * A list of contacts - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Contact contacts = 1; - * @param array<\Google\Cloud\SecurityCenter\V2\Contact>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setContacts($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Contact::class); - $this->contacts = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Container.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Container.php deleted file mode 100644 index fe9ed184436a..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Container.php +++ /dev/null @@ -1,221 +0,0 @@ -google.cloud.securitycenter.v2.Container - */ -class Container extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the container. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Container image URI provided when configuring a pod or container. This - * string can identify a container image version using mutable tags. - * - * Generated from protobuf field string uri = 2; - */ - protected $uri = ''; - /** - * Optional container image ID, if provided by the container runtime. Uniquely - * identifies the container image launched using a container image digest. - * - * Generated from protobuf field string image_id = 3; - */ - protected $image_id = ''; - /** - * Container labels, as provided by the container runtime. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Label labels = 4; - */ - private $labels; - /** - * The time that the container was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5; - */ - protected $create_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Name of the container. - * @type string $uri - * Container image URI provided when configuring a pod or container. This - * string can identify a container image version using mutable tags. - * @type string $image_id - * Optional container image ID, if provided by the container runtime. Uniquely - * identifies the container image launched using a container image digest. - * @type array<\Google\Cloud\SecurityCenter\V2\Label>|\Google\Protobuf\Internal\RepeatedField $labels - * Container labels, as provided by the container runtime. - * @type \Google\Protobuf\Timestamp $create_time - * The time that the container was created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Container::initOnce(); - parent::__construct($data); - } - - /** - * Name of the container. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Name of the container. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Container image URI provided when configuring a pod or container. This - * string can identify a container image version using mutable tags. - * - * Generated from protobuf field string uri = 2; - * @return string - */ - public function getUri() - { - return $this->uri; - } - - /** - * Container image URI provided when configuring a pod or container. This - * string can identify a container image version using mutable tags. - * - * Generated from protobuf field string uri = 2; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->uri = $var; - - return $this; - } - - /** - * Optional container image ID, if provided by the container runtime. Uniquely - * identifies the container image launched using a container image digest. - * - * Generated from protobuf field string image_id = 3; - * @return string - */ - public function getImageId() - { - return $this->image_id; - } - - /** - * Optional container image ID, if provided by the container runtime. Uniquely - * identifies the container image launched using a container image digest. - * - * Generated from protobuf field string image_id = 3; - * @param string $var - * @return $this - */ - public function setImageId($var) - { - GPBUtil::checkString($var, True); - $this->image_id = $var; - - return $this; - } - - /** - * Container labels, as provided by the container runtime. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Label labels = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Container labels, as provided by the container runtime. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Label labels = 4; - * @param array<\Google\Cloud\SecurityCenter\V2\Label>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Label::class); - $this->labels = $arr; - - return $this; - } - - /** - * The time that the container was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * The time that the container was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 5; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateBigQueryExportRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateBigQueryExportRequest.php deleted file mode 100644 index 67573501164e..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateBigQueryExportRequest.php +++ /dev/null @@ -1,193 +0,0 @@ -google.cloud.securitycenter.v2.CreateBigQueryExportRequest - */ -class CreateBigQueryExportRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the parent resource of the new BigQuery export. Its - * format is "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The BigQuery export being created. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.BigQueryExport big_query_export = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $big_query_export = null; - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * - * Generated from protobuf field string big_query_export_id = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $big_query_export_id = ''; - - /** - * @param string $parent Required. The name of the parent resource of the new BigQuery export. Its - * format is "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". Please see - * {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. - * @param \Google\Cloud\SecurityCenter\V2\BigQueryExport $bigQueryExport Required. The BigQuery export being created. - * @param string $bigQueryExportId Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * - * @return \Google\Cloud\SecurityCenter\V2\CreateBigQueryExportRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\SecurityCenter\V2\BigQueryExport $bigQueryExport, string $bigQueryExportId): self - { - return (new self()) - ->setParent($parent) - ->setBigQueryExport($bigQueryExport) - ->setBigQueryExportId($bigQueryExportId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The name of the parent resource of the new BigQuery export. Its - * format is "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * @type \Google\Cloud\SecurityCenter\V2\BigQueryExport $big_query_export - * Required. The BigQuery export being created. - * @type string $big_query_export_id - * Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the parent resource of the new BigQuery export. Its - * format is "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The name of the parent resource of the new BigQuery export. Its - * format is "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The BigQuery export being created. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.BigQueryExport big_query_export = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V2\BigQueryExport|null - */ - public function getBigQueryExport() - { - return $this->big_query_export; - } - - public function hasBigQueryExport() - { - return isset($this->big_query_export); - } - - public function clearBigQueryExport() - { - unset($this->big_query_export); - } - - /** - * Required. The BigQuery export being created. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.BigQueryExport big_query_export = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V2\BigQueryExport $var - * @return $this - */ - public function setBigQueryExport($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\BigQueryExport::class); - $this->big_query_export = $var; - - return $this; - } - - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * - * Generated from protobuf field string big_query_export_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getBigQueryExportId() - { - return $this->big_query_export_id; - } - - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * - * Generated from protobuf field string big_query_export_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setBigQueryExportId($var) - { - GPBUtil::checkString($var, True); - $this->big_query_export_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateFindingRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateFindingRequest.php deleted file mode 100644 index 8974b4f9387f..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateFindingRequest.php +++ /dev/null @@ -1,203 +0,0 @@ -google.cloud.securitycenter.v2.CreateFindingRequest - */ -class CreateFindingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the new finding's parent. The following list - * shows some examples of the format: - * + - * `organizations/[organization_id]/sources/[source_id]` - * + - * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must be alphanumeric and less than or equal to 32 characters and - * greater than 0 characters in length. - * - * Generated from protobuf field string finding_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $finding_id = ''; - /** - * Required. The Finding being created. The name and security_marks will be - * ignored as they are both output only fields on this resource. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $finding = null; - - /** - * @param string $parent Required. Resource name of the new finding's parent. The following list - * shows some examples of the format: - * + - * `organizations/[organization_id]/sources/[source_id]` - * + - * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` - * Please see {@see SecurityCenterClient::sourceName()} for help formatting this field. - * @param \Google\Cloud\SecurityCenter\V2\Finding $finding Required. The Finding being created. The name and security_marks will be - * ignored as they are both output only fields on this resource. - * @param string $findingId Required. Unique identifier provided by the client within the parent scope. - * It must be alphanumeric and less than or equal to 32 characters and - * greater than 0 characters in length. - * - * @return \Google\Cloud\SecurityCenter\V2\CreateFindingRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\SecurityCenter\V2\Finding $finding, string $findingId): self - { - return (new self()) - ->setParent($parent) - ->setFinding($finding) - ->setFindingId($findingId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the new finding's parent. The following list - * shows some examples of the format: - * + - * `organizations/[organization_id]/sources/[source_id]` - * + - * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` - * @type string $finding_id - * Required. Unique identifier provided by the client within the parent scope. - * It must be alphanumeric and less than or equal to 32 characters and - * greater than 0 characters in length. - * @type \Google\Cloud\SecurityCenter\V2\Finding $finding - * Required. The Finding being created. The name and security_marks will be - * ignored as they are both output only fields on this resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the new finding's parent. The following list - * shows some examples of the format: - * + - * `organizations/[organization_id]/sources/[source_id]` - * + - * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the new finding's parent. The following list - * shows some examples of the format: - * + - * `organizations/[organization_id]/sources/[source_id]` - * + - * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must be alphanumeric and less than or equal to 32 characters and - * greater than 0 characters in length. - * - * Generated from protobuf field string finding_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getFindingId() - { - return $this->finding_id; - } - - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must be alphanumeric and less than or equal to 32 characters and - * greater than 0 characters in length. - * - * Generated from protobuf field string finding_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setFindingId($var) - { - GPBUtil::checkString($var, True); - $this->finding_id = $var; - - return $this; - } - - /** - * Required. The Finding being created. The name and security_marks will be - * ignored as they are both output only fields on this resource. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V2\Finding|null - */ - public function getFinding() - { - return $this->finding; - } - - public function hasFinding() - { - return isset($this->finding); - } - - public function clearFinding() - { - unset($this->finding); - } - - /** - * Required. The Finding being created. The name and security_marks will be - * ignored as they are both output only fields on this resource. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V2\Finding $var - * @return $this - */ - public function setFinding($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Finding::class); - $this->finding = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateMuteConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateMuteConfigRequest.php deleted file mode 100644 index 137dd1b119c6..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateMuteConfigRequest.php +++ /dev/null @@ -1,193 +0,0 @@ -google.cloud.securitycenter.v2.CreateMuteConfigRequest - */ -class CreateMuteConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the new mute configs's parent. Its format is - * "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The mute config being created. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.MuteConfig mute_config = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $mute_config = null; - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * - * Generated from protobuf field string mute_config_id = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $mute_config_id = ''; - - /** - * @param string $parent Required. Resource name of the new mute configs's parent. Its format is - * "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". Please see - * {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. - * @param \Google\Cloud\SecurityCenter\V2\MuteConfig $muteConfig Required. The mute config being created. - * @param string $muteConfigId Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * - * @return \Google\Cloud\SecurityCenter\V2\CreateMuteConfigRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\SecurityCenter\V2\MuteConfig $muteConfig, string $muteConfigId): self - { - return (new self()) - ->setParent($parent) - ->setMuteConfig($muteConfig) - ->setMuteConfigId($muteConfigId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the new mute configs's parent. Its format is - * "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * @type \Google\Cloud\SecurityCenter\V2\MuteConfig $mute_config - * Required. The mute config being created. - * @type string $mute_config_id - * Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the new mute configs's parent. Its format is - * "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the new mute configs's parent. Its format is - * "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The mute config being created. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.MuteConfig mute_config = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V2\MuteConfig|null - */ - public function getMuteConfig() - { - return $this->mute_config; - } - - public function hasMuteConfig() - { - return isset($this->mute_config); - } - - public function clearMuteConfig() - { - unset($this->mute_config); - } - - /** - * Required. The mute config being created. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.MuteConfig mute_config = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V2\MuteConfig $var - * @return $this - */ - public function setMuteConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\MuteConfig::class); - $this->mute_config = $var; - - return $this; - } - - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * - * Generated from protobuf field string mute_config_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getMuteConfigId() - { - return $this->mute_config_id; - } - - /** - * Required. Unique identifier provided by the client within the parent scope. - * It must consist of only lowercase letters, numbers, and hyphens, must start - * with a letter, must end with either a letter or a number, and must be 63 - * characters or less. - * - * Generated from protobuf field string mute_config_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setMuteConfigId($var) - { - GPBUtil::checkString($var, True); - $this->mute_config_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateNotificationConfigRequest.php deleted file mode 100644 index aade0d29f8d1..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateNotificationConfigRequest.php +++ /dev/null @@ -1,203 +0,0 @@ -google.cloud.securitycenter.v2.CreateNotificationConfigRequest - */ -class CreateNotificationConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the new notification config's parent. Its format - * is "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. - * Unique identifier provided by the client within the parent scope. - * It must be between 1 and 128 characters and contain alphanumeric - * characters, underscores, or hyphens only. - * - * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $config_id = ''; - /** - * Required. The notification config being created. The name and the service - * account will be ignored as they are both output only fields on this - * resource. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.NotificationConfig notification_config = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $notification_config = null; - - /** - * @param string $parent Required. Resource name of the new notification config's parent. Its format - * is "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". Please see - * {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. - * @param \Google\Cloud\SecurityCenter\V2\NotificationConfig $notificationConfig Required. The notification config being created. The name and the service - * account will be ignored as they are both output only fields on this - * resource. - * @param string $configId Required. - * Unique identifier provided by the client within the parent scope. - * It must be between 1 and 128 characters and contain alphanumeric - * characters, underscores, or hyphens only. - * - * @return \Google\Cloud\SecurityCenter\V2\CreateNotificationConfigRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\SecurityCenter\V2\NotificationConfig $notificationConfig, string $configId): self - { - return (new self()) - ->setParent($parent) - ->setNotificationConfig($notificationConfig) - ->setConfigId($configId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the new notification config's parent. Its format - * is "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * @type string $config_id - * Required. - * Unique identifier provided by the client within the parent scope. - * It must be between 1 and 128 characters and contain alphanumeric - * characters, underscores, or hyphens only. - * @type \Google\Cloud\SecurityCenter\V2\NotificationConfig $notification_config - * Required. The notification config being created. The name and the service - * account will be ignored as they are both output only fields on this - * resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the new notification config's parent. Its format - * is "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the new notification config's parent. Its format - * is "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. - * Unique identifier provided by the client within the parent scope. - * It must be between 1 and 128 characters and contain alphanumeric - * characters, underscores, or hyphens only. - * - * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getConfigId() - { - return $this->config_id; - } - - /** - * Required. - * Unique identifier provided by the client within the parent scope. - * It must be between 1 and 128 characters and contain alphanumeric - * characters, underscores, or hyphens only. - * - * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setConfigId($var) - { - GPBUtil::checkString($var, True); - $this->config_id = $var; - - return $this; - } - - /** - * Required. The notification config being created. The name and the service - * account will be ignored as they are both output only fields on this - * resource. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.NotificationConfig notification_config = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V2\NotificationConfig|null - */ - public function getNotificationConfig() - { - return $this->notification_config; - } - - public function hasNotificationConfig() - { - return isset($this->notification_config); - } - - public function clearNotificationConfig() - { - unset($this->notification_config); - } - - /** - * Required. The notification config being created. The name and the service - * account will be ignored as they are both output only fields on this - * resource. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.NotificationConfig notification_config = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V2\NotificationConfig $var - * @return $this - */ - public function setNotificationConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\NotificationConfig::class); - $this->notification_config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateResourceValueConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateResourceValueConfigRequest.php deleted file mode 100644 index 28978595801a..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateResourceValueConfigRequest.php +++ /dev/null @@ -1,111 +0,0 @@ -google.cloud.securitycenter.v2.CreateResourceValueConfigRequest - */ -class CreateResourceValueConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the new ResourceValueConfig's parent. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The resource value config being created. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_config = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $resource_value_config = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the new ResourceValueConfig's parent. - * @type \Google\Cloud\SecurityCenter\V2\ResourceValueConfig $resource_value_config - * Required. The resource value config being created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the new ResourceValueConfig's parent. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the new ResourceValueConfig's parent. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The resource value config being created. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_config = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V2\ResourceValueConfig|null - */ - public function getResourceValueConfig() - { - return $this->resource_value_config; - } - - public function hasResourceValueConfig() - { - return isset($this->resource_value_config); - } - - public function clearResourceValueConfig() - { - unset($this->resource_value_config); - } - - /** - * Required. The resource value config being created. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_config = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V2\ResourceValueConfig $var - * @return $this - */ - public function setResourceValueConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ResourceValueConfig::class); - $this->resource_value_config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateSourceRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateSourceRequest.php deleted file mode 100644 index b6617f605ad1..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/CreateSourceRequest.php +++ /dev/null @@ -1,137 +0,0 @@ -google.cloud.securitycenter.v2.CreateSourceRequest - */ -class CreateSourceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the new source's parent. Its format should be - * "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The Source being created, only the display_name and description - * will be used. All other fields will be ignored. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Source source = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $source = null; - - /** - * @param string $parent Required. Resource name of the new source's parent. Its format should be - * "organizations/[organization_id]". Please see - * {@see SecurityCenterClient::organizationName()} for help formatting this field. - * @param \Google\Cloud\SecurityCenter\V2\Source $source Required. The Source being created, only the display_name and description - * will be used. All other fields will be ignored. - * - * @return \Google\Cloud\SecurityCenter\V2\CreateSourceRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\SecurityCenter\V2\Source $source): self - { - return (new self()) - ->setParent($parent) - ->setSource($source); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the new source's parent. Its format should be - * "organizations/[organization_id]". - * @type \Google\Cloud\SecurityCenter\V2\Source $source - * Required. The Source being created, only the display_name and description - * will be used. All other fields will be ignored. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the new source's parent. Its format should be - * "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the new source's parent. Its format should be - * "organizations/[organization_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Required. The Source being created, only the display_name and description - * will be used. All other fields will be ignored. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Source source = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V2\Source|null - */ - public function getSource() - { - return $this->source; - } - - public function hasSource() - { - return isset($this->source); - } - - public function clearSource() - { - unset($this->source); - } - - /** - * Required. The Source being created, only the display_name and description - * will be used. All other fields will be ignored. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Source source = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V2\Source $var - * @return $this - */ - public function setSource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Source::class); - $this->source = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve.php deleted file mode 100644 index 97f7f34d10df..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve.php +++ /dev/null @@ -1,330 +0,0 @@ -google.cloud.securitycenter.v2.Cve - */ -class Cve extends \Google\Protobuf\Internal\Message -{ - /** - * The unique identifier for the vulnerability. e.g. CVE-2021-34527 - * - * Generated from protobuf field string id = 1; - */ - protected $id = ''; - /** - * Additional information about the CVE. - * e.g. https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527 - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Reference references = 2; - */ - private $references; - /** - * Describe Common Vulnerability Scoring System specified at - * https://www.first.org/cvss/v3.1/specification-document - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3 cvssv3 = 3; - */ - protected $cvssv3 = null; - /** - * Whether upstream fix is available for the CVE. - * - * Generated from protobuf field bool upstream_fix_available = 4; - */ - protected $upstream_fix_available = false; - /** - * The potential impact of the vulnerability if it was to be exploited. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cve.RiskRating impact = 5; - */ - protected $impact = 0; - /** - * The exploitation activity of the vulnerability in the wild. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cve.ExploitationActivity exploitation_activity = 6; - */ - protected $exploitation_activity = 0; - /** - * Whether or not the vulnerability has been observed in the wild. - * - * Generated from protobuf field bool observed_in_the_wild = 7; - */ - protected $observed_in_the_wild = false; - /** - * Whether or not the vulnerability was zero day when the finding was - * published. - * - * Generated from protobuf field bool zero_day = 8; - */ - protected $zero_day = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $id - * The unique identifier for the vulnerability. e.g. CVE-2021-34527 - * @type array<\Google\Cloud\SecurityCenter\V2\Reference>|\Google\Protobuf\Internal\RepeatedField $references - * Additional information about the CVE. - * e.g. https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527 - * @type \Google\Cloud\SecurityCenter\V2\Cvssv3 $cvssv3 - * Describe Common Vulnerability Scoring System specified at - * https://www.first.org/cvss/v3.1/specification-document - * @type bool $upstream_fix_available - * Whether upstream fix is available for the CVE. - * @type int $impact - * The potential impact of the vulnerability if it was to be exploited. - * @type int $exploitation_activity - * The exploitation activity of the vulnerability in the wild. - * @type bool $observed_in_the_wild - * Whether or not the vulnerability has been observed in the wild. - * @type bool $zero_day - * Whether or not the vulnerability was zero day when the finding was - * published. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Vulnerability::initOnce(); - parent::__construct($data); - } - - /** - * The unique identifier for the vulnerability. e.g. CVE-2021-34527 - * - * Generated from protobuf field string id = 1; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * The unique identifier for the vulnerability. e.g. CVE-2021-34527 - * - * Generated from protobuf field string id = 1; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - - /** - * Additional information about the CVE. - * e.g. https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527 - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Reference references = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getReferences() - { - return $this->references; - } - - /** - * Additional information about the CVE. - * e.g. https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527 - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Reference references = 2; - * @param array<\Google\Cloud\SecurityCenter\V2\Reference>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setReferences($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Reference::class); - $this->references = $arr; - - return $this; - } - - /** - * Describe Common Vulnerability Scoring System specified at - * https://www.first.org/cvss/v3.1/specification-document - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3 cvssv3 = 3; - * @return \Google\Cloud\SecurityCenter\V2\Cvssv3|null - */ - public function getCvssv3() - { - return $this->cvssv3; - } - - public function hasCvssv3() - { - return isset($this->cvssv3); - } - - public function clearCvssv3() - { - unset($this->cvssv3); - } - - /** - * Describe Common Vulnerability Scoring System specified at - * https://www.first.org/cvss/v3.1/specification-document - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3 cvssv3 = 3; - * @param \Google\Cloud\SecurityCenter\V2\Cvssv3 $var - * @return $this - */ - public function setCvssv3($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Cvssv3::class); - $this->cvssv3 = $var; - - return $this; - } - - /** - * Whether upstream fix is available for the CVE. - * - * Generated from protobuf field bool upstream_fix_available = 4; - * @return bool - */ - public function getUpstreamFixAvailable() - { - return $this->upstream_fix_available; - } - - /** - * Whether upstream fix is available for the CVE. - * - * Generated from protobuf field bool upstream_fix_available = 4; - * @param bool $var - * @return $this - */ - public function setUpstreamFixAvailable($var) - { - GPBUtil::checkBool($var); - $this->upstream_fix_available = $var; - - return $this; - } - - /** - * The potential impact of the vulnerability if it was to be exploited. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cve.RiskRating impact = 5; - * @return int - */ - public function getImpact() - { - return $this->impact; - } - - /** - * The potential impact of the vulnerability if it was to be exploited. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cve.RiskRating impact = 5; - * @param int $var - * @return $this - */ - public function setImpact($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cve\RiskRating::class); - $this->impact = $var; - - return $this; - } - - /** - * The exploitation activity of the vulnerability in the wild. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cve.ExploitationActivity exploitation_activity = 6; - * @return int - */ - public function getExploitationActivity() - { - return $this->exploitation_activity; - } - - /** - * The exploitation activity of the vulnerability in the wild. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cve.ExploitationActivity exploitation_activity = 6; - * @param int $var - * @return $this - */ - public function setExploitationActivity($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cve\ExploitationActivity::class); - $this->exploitation_activity = $var; - - return $this; - } - - /** - * Whether or not the vulnerability has been observed in the wild. - * - * Generated from protobuf field bool observed_in_the_wild = 7; - * @return bool - */ - public function getObservedInTheWild() - { - return $this->observed_in_the_wild; - } - - /** - * Whether or not the vulnerability has been observed in the wild. - * - * Generated from protobuf field bool observed_in_the_wild = 7; - * @param bool $var - * @return $this - */ - public function setObservedInTheWild($var) - { - GPBUtil::checkBool($var); - $this->observed_in_the_wild = $var; - - return $this; - } - - /** - * Whether or not the vulnerability was zero day when the finding was - * published. - * - * Generated from protobuf field bool zero_day = 8; - * @return bool - */ - public function getZeroDay() - { - return $this->zero_day; - } - - /** - * Whether or not the vulnerability was zero day when the finding was - * published. - * - * Generated from protobuf field bool zero_day = 8; - * @param bool $var - * @return $this - */ - public function setZeroDay($var) - { - GPBUtil::checkBool($var); - $this->zero_day = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve/ExploitationActivity.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve/ExploitationActivity.php deleted file mode 100644 index a9c02c71ba55..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve/ExploitationActivity.php +++ /dev/null @@ -1,87 +0,0 @@ -google.cloud.securitycenter.v2.Cve.ExploitationActivity - */ -class ExploitationActivity -{ - /** - * Invalid or empty value. - * - * Generated from protobuf enum EXPLOITATION_ACTIVITY_UNSPECIFIED = 0; - */ - const EXPLOITATION_ACTIVITY_UNSPECIFIED = 0; - /** - * Exploitation has been reported or confirmed to widely occur. - * - * Generated from protobuf enum WIDE = 1; - */ - const WIDE = 1; - /** - * Limited reported or confirmed exploitation activities. - * - * Generated from protobuf enum CONFIRMED = 2; - */ - const CONFIRMED = 2; - /** - * Exploit is publicly available. - * - * Generated from protobuf enum AVAILABLE = 3; - */ - const AVAILABLE = 3; - /** - * No known exploitation activity, but has a high potential for - * exploitation. - * - * Generated from protobuf enum ANTICIPATED = 4; - */ - const ANTICIPATED = 4; - /** - * No known exploitation activity. - * - * Generated from protobuf enum NO_KNOWN = 5; - */ - const NO_KNOWN = 5; - - private static $valueToName = [ - self::EXPLOITATION_ACTIVITY_UNSPECIFIED => 'EXPLOITATION_ACTIVITY_UNSPECIFIED', - self::WIDE => 'WIDE', - self::CONFIRMED => 'CONFIRMED', - self::AVAILABLE => 'AVAILABLE', - self::ANTICIPATED => 'ANTICIPATED', - self::NO_KNOWN => 'NO_KNOWN', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ExploitationActivity::class, \Google\Cloud\SecurityCenter\V2\Cve_ExploitationActivity::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve/RiskRating.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve/RiskRating.php deleted file mode 100644 index 29d2e11af4b2..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cve/RiskRating.php +++ /dev/null @@ -1,83 +0,0 @@ -google.cloud.securitycenter.v2.Cve.RiskRating - */ -class RiskRating -{ - /** - * Invalid or empty value. - * - * Generated from protobuf enum RISK_RATING_UNSPECIFIED = 0; - */ - const RISK_RATING_UNSPECIFIED = 0; - /** - * Exploitation would have little to no security impact. - * - * Generated from protobuf enum LOW = 1; - */ - const LOW = 1; - /** - * Exploitation would enable attackers to perform activities, or could allow - * attackers to have a direct impact, but would require additional steps. - * - * Generated from protobuf enum MEDIUM = 2; - */ - const MEDIUM = 2; - /** - * Exploitation would enable attackers to have a notable direct impact - * without needing to overcome any major mitigating factors. - * - * Generated from protobuf enum HIGH = 3; - */ - const HIGH = 3; - /** - * Exploitation would fundamentally undermine the security of affected - * systems, enable actors to perform significant attacks with minimal - * effort, with little to no mitigating factors to overcome. - * - * Generated from protobuf enum CRITICAL = 4; - */ - const CRITICAL = 4; - - private static $valueToName = [ - self::RISK_RATING_UNSPECIFIED => 'RISK_RATING_UNSPECIFIED', - self::LOW => 'LOW', - self::MEDIUM => 'MEDIUM', - self::HIGH => 'HIGH', - self::CRITICAL => 'CRITICAL', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(RiskRating::class, \Google\Cloud\SecurityCenter\V2\Cve_RiskRating::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3.php deleted file mode 100644 index ab89232be139..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3.php +++ /dev/null @@ -1,391 +0,0 @@ -google.cloud.securitycenter.v2.Cvssv3 - */ -class Cvssv3 extends \Google\Protobuf\Internal\Message -{ - /** - * The base score is a function of the base metric scores. - * - * Generated from protobuf field double base_score = 1; - */ - protected $base_score = 0.0; - /** - * Base Metrics - * Represents the intrinsic characteristics of a vulnerability that are - * constant over time and across user environments. - * This metric reflects the context by which vulnerability exploitation is - * possible. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.AttackVector attack_vector = 2; - */ - protected $attack_vector = 0; - /** - * This metric describes the conditions beyond the attacker's control that - * must exist in order to exploit the vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.AttackComplexity attack_complexity = 3; - */ - protected $attack_complexity = 0; - /** - * This metric describes the level of privileges an attacker must possess - * before successfully exploiting the vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.PrivilegesRequired privileges_required = 4; - */ - protected $privileges_required = 0; - /** - * This metric captures the requirement for a human user, other than the - * attacker, to participate in the successful compromise of the vulnerable - * component. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.UserInteraction user_interaction = 5; - */ - protected $user_interaction = 0; - /** - * The Scope metric captures whether a vulnerability in one vulnerable - * component impacts resources in components beyond its security scope. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Scope scope = 6; - */ - protected $scope = 0; - /** - * This metric measures the impact to the confidentiality of the information - * resources managed by a software component due to a successfully exploited - * vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Impact confidentiality_impact = 7; - */ - protected $confidentiality_impact = 0; - /** - * This metric measures the impact to integrity of a successfully exploited - * vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Impact integrity_impact = 8; - */ - protected $integrity_impact = 0; - /** - * This metric measures the impact to the availability of the impacted - * component resulting from a successfully exploited vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Impact availability_impact = 9; - */ - protected $availability_impact = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type float $base_score - * The base score is a function of the base metric scores. - * @type int $attack_vector - * Base Metrics - * Represents the intrinsic characteristics of a vulnerability that are - * constant over time and across user environments. - * This metric reflects the context by which vulnerability exploitation is - * possible. - * @type int $attack_complexity - * This metric describes the conditions beyond the attacker's control that - * must exist in order to exploit the vulnerability. - * @type int $privileges_required - * This metric describes the level of privileges an attacker must possess - * before successfully exploiting the vulnerability. - * @type int $user_interaction - * This metric captures the requirement for a human user, other than the - * attacker, to participate in the successful compromise of the vulnerable - * component. - * @type int $scope - * The Scope metric captures whether a vulnerability in one vulnerable - * component impacts resources in components beyond its security scope. - * @type int $confidentiality_impact - * This metric measures the impact to the confidentiality of the information - * resources managed by a software component due to a successfully exploited - * vulnerability. - * @type int $integrity_impact - * This metric measures the impact to integrity of a successfully exploited - * vulnerability. - * @type int $availability_impact - * This metric measures the impact to the availability of the impacted - * component resulting from a successfully exploited vulnerability. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Vulnerability::initOnce(); - parent::__construct($data); - } - - /** - * The base score is a function of the base metric scores. - * - * Generated from protobuf field double base_score = 1; - * @return float - */ - public function getBaseScore() - { - return $this->base_score; - } - - /** - * The base score is a function of the base metric scores. - * - * Generated from protobuf field double base_score = 1; - * @param float $var - * @return $this - */ - public function setBaseScore($var) - { - GPBUtil::checkDouble($var); - $this->base_score = $var; - - return $this; - } - - /** - * Base Metrics - * Represents the intrinsic characteristics of a vulnerability that are - * constant over time and across user environments. - * This metric reflects the context by which vulnerability exploitation is - * possible. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.AttackVector attack_vector = 2; - * @return int - */ - public function getAttackVector() - { - return $this->attack_vector; - } - - /** - * Base Metrics - * Represents the intrinsic characteristics of a vulnerability that are - * constant over time and across user environments. - * This metric reflects the context by which vulnerability exploitation is - * possible. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.AttackVector attack_vector = 2; - * @param int $var - * @return $this - */ - public function setAttackVector($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cvssv3\AttackVector::class); - $this->attack_vector = $var; - - return $this; - } - - /** - * This metric describes the conditions beyond the attacker's control that - * must exist in order to exploit the vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.AttackComplexity attack_complexity = 3; - * @return int - */ - public function getAttackComplexity() - { - return $this->attack_complexity; - } - - /** - * This metric describes the conditions beyond the attacker's control that - * must exist in order to exploit the vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.AttackComplexity attack_complexity = 3; - * @param int $var - * @return $this - */ - public function setAttackComplexity($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cvssv3\AttackComplexity::class); - $this->attack_complexity = $var; - - return $this; - } - - /** - * This metric describes the level of privileges an attacker must possess - * before successfully exploiting the vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.PrivilegesRequired privileges_required = 4; - * @return int - */ - public function getPrivilegesRequired() - { - return $this->privileges_required; - } - - /** - * This metric describes the level of privileges an attacker must possess - * before successfully exploiting the vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.PrivilegesRequired privileges_required = 4; - * @param int $var - * @return $this - */ - public function setPrivilegesRequired($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cvssv3\PrivilegesRequired::class); - $this->privileges_required = $var; - - return $this; - } - - /** - * This metric captures the requirement for a human user, other than the - * attacker, to participate in the successful compromise of the vulnerable - * component. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.UserInteraction user_interaction = 5; - * @return int - */ - public function getUserInteraction() - { - return $this->user_interaction; - } - - /** - * This metric captures the requirement for a human user, other than the - * attacker, to participate in the successful compromise of the vulnerable - * component. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.UserInteraction user_interaction = 5; - * @param int $var - * @return $this - */ - public function setUserInteraction($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cvssv3\UserInteraction::class); - $this->user_interaction = $var; - - return $this; - } - - /** - * The Scope metric captures whether a vulnerability in one vulnerable - * component impacts resources in components beyond its security scope. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Scope scope = 6; - * @return int - */ - public function getScope() - { - return $this->scope; - } - - /** - * The Scope metric captures whether a vulnerability in one vulnerable - * component impacts resources in components beyond its security scope. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Scope scope = 6; - * @param int $var - * @return $this - */ - public function setScope($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cvssv3\Scope::class); - $this->scope = $var; - - return $this; - } - - /** - * This metric measures the impact to the confidentiality of the information - * resources managed by a software component due to a successfully exploited - * vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Impact confidentiality_impact = 7; - * @return int - */ - public function getConfidentialityImpact() - { - return $this->confidentiality_impact; - } - - /** - * This metric measures the impact to the confidentiality of the information - * resources managed by a software component due to a successfully exploited - * vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Impact confidentiality_impact = 7; - * @param int $var - * @return $this - */ - public function setConfidentialityImpact($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cvssv3\Impact::class); - $this->confidentiality_impact = $var; - - return $this; - } - - /** - * This metric measures the impact to integrity of a successfully exploited - * vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Impact integrity_impact = 8; - * @return int - */ - public function getIntegrityImpact() - { - return $this->integrity_impact; - } - - /** - * This metric measures the impact to integrity of a successfully exploited - * vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Impact integrity_impact = 8; - * @param int $var - * @return $this - */ - public function setIntegrityImpact($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cvssv3\Impact::class); - $this->integrity_impact = $var; - - return $this; - } - - /** - * This metric measures the impact to the availability of the impacted - * component resulting from a successfully exploited vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Impact availability_impact = 9; - * @return int - */ - public function getAvailabilityImpact() - { - return $this->availability_impact; - } - - /** - * This metric measures the impact to the availability of the impacted - * component resulting from a successfully exploited vulnerability. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cvssv3.Impact availability_impact = 9; - * @param int $var - * @return $this - */ - public function setAvailabilityImpact($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Cvssv3\Impact::class); - $this->availability_impact = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/AttackComplexity.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/AttackComplexity.php deleted file mode 100644 index 5c6149504883..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/AttackComplexity.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.securitycenter.v2.Cvssv3.AttackComplexity - */ -class AttackComplexity -{ - /** - * Invalid value. - * - * Generated from protobuf enum ATTACK_COMPLEXITY_UNSPECIFIED = 0; - */ - const ATTACK_COMPLEXITY_UNSPECIFIED = 0; - /** - * Specialized access conditions or extenuating circumstances do not exist. - * An attacker can expect repeatable success when attacking the vulnerable - * component. - * - * Generated from protobuf enum ATTACK_COMPLEXITY_LOW = 1; - */ - const ATTACK_COMPLEXITY_LOW = 1; - /** - * A successful attack depends on conditions beyond the attacker's control. - * That is, a successful attack cannot be accomplished at will, but requires - * the attacker to invest in some measurable amount of effort in preparation - * or execution against the vulnerable component before a successful attack - * can be expected. - * - * Generated from protobuf enum ATTACK_COMPLEXITY_HIGH = 2; - */ - const ATTACK_COMPLEXITY_HIGH = 2; - - private static $valueToName = [ - self::ATTACK_COMPLEXITY_UNSPECIFIED => 'ATTACK_COMPLEXITY_UNSPECIFIED', - self::ATTACK_COMPLEXITY_LOW => 'ATTACK_COMPLEXITY_LOW', - self::ATTACK_COMPLEXITY_HIGH => 'ATTACK_COMPLEXITY_HIGH', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AttackComplexity::class, \Google\Cloud\SecurityCenter\V2\Cvssv3_AttackComplexity::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/AttackVector.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/AttackVector.php deleted file mode 100644 index c6839e85e27f..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/AttackVector.php +++ /dev/null @@ -1,84 +0,0 @@ -google.cloud.securitycenter.v2.Cvssv3.AttackVector - */ -class AttackVector -{ - /** - * Invalid value. - * - * Generated from protobuf enum ATTACK_VECTOR_UNSPECIFIED = 0; - */ - const ATTACK_VECTOR_UNSPECIFIED = 0; - /** - * The vulnerable component is bound to the network stack and the set of - * possible attackers extends beyond the other options listed below, up to - * and including the entire Internet. - * - * Generated from protobuf enum ATTACK_VECTOR_NETWORK = 1; - */ - const ATTACK_VECTOR_NETWORK = 1; - /** - * The vulnerable component is bound to the network stack, but the attack is - * limited at the protocol level to a logically adjacent topology. - * - * Generated from protobuf enum ATTACK_VECTOR_ADJACENT = 2; - */ - const ATTACK_VECTOR_ADJACENT = 2; - /** - * The vulnerable component is not bound to the network stack and the - * attacker's path is via read/write/execute capabilities. - * - * Generated from protobuf enum ATTACK_VECTOR_LOCAL = 3; - */ - const ATTACK_VECTOR_LOCAL = 3; - /** - * The attack requires the attacker to physically touch or manipulate the - * vulnerable component. - * - * Generated from protobuf enum ATTACK_VECTOR_PHYSICAL = 4; - */ - const ATTACK_VECTOR_PHYSICAL = 4; - - private static $valueToName = [ - self::ATTACK_VECTOR_UNSPECIFIED => 'ATTACK_VECTOR_UNSPECIFIED', - self::ATTACK_VECTOR_NETWORK => 'ATTACK_VECTOR_NETWORK', - self::ATTACK_VECTOR_ADJACENT => 'ATTACK_VECTOR_ADJACENT', - self::ATTACK_VECTOR_LOCAL => 'ATTACK_VECTOR_LOCAL', - self::ATTACK_VECTOR_PHYSICAL => 'ATTACK_VECTOR_PHYSICAL', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AttackVector::class, \Google\Cloud\SecurityCenter\V2\Cvssv3_AttackVector::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/Impact.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/Impact.php deleted file mode 100644 index 53d4f5e41900..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/Impact.php +++ /dev/null @@ -1,73 +0,0 @@ -google.cloud.securitycenter.v2.Cvssv3.Impact - */ -class Impact -{ - /** - * Invalid value. - * - * Generated from protobuf enum IMPACT_UNSPECIFIED = 0; - */ - const IMPACT_UNSPECIFIED = 0; - /** - * High impact. - * - * Generated from protobuf enum IMPACT_HIGH = 1; - */ - const IMPACT_HIGH = 1; - /** - * Low impact. - * - * Generated from protobuf enum IMPACT_LOW = 2; - */ - const IMPACT_LOW = 2; - /** - * No impact. - * - * Generated from protobuf enum IMPACT_NONE = 3; - */ - const IMPACT_NONE = 3; - - private static $valueToName = [ - self::IMPACT_UNSPECIFIED => 'IMPACT_UNSPECIFIED', - self::IMPACT_HIGH => 'IMPACT_HIGH', - self::IMPACT_LOW => 'IMPACT_LOW', - self::IMPACT_NONE => 'IMPACT_NONE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Impact::class, \Google\Cloud\SecurityCenter\V2\Cvssv3_Impact::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/PrivilegesRequired.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/PrivilegesRequired.php deleted file mode 100644 index 859e56b93885..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/PrivilegesRequired.php +++ /dev/null @@ -1,79 +0,0 @@ -google.cloud.securitycenter.v2.Cvssv3.PrivilegesRequired - */ -class PrivilegesRequired -{ - /** - * Invalid value. - * - * Generated from protobuf enum PRIVILEGES_REQUIRED_UNSPECIFIED = 0; - */ - const PRIVILEGES_REQUIRED_UNSPECIFIED = 0; - /** - * The attacker is unauthorized prior to attack, and therefore does not - * require any access to settings or files of the vulnerable system to - * carry out an attack. - * - * Generated from protobuf enum PRIVILEGES_REQUIRED_NONE = 1; - */ - const PRIVILEGES_REQUIRED_NONE = 1; - /** - * The attacker requires privileges that provide basic user capabilities - * that could normally affect only settings and files owned by a user. - * Alternatively, an attacker with Low privileges has the ability to access - * only non-sensitive resources. - * - * Generated from protobuf enum PRIVILEGES_REQUIRED_LOW = 2; - */ - const PRIVILEGES_REQUIRED_LOW = 2; - /** - * The attacker requires privileges that provide significant (e.g., - * administrative) control over the vulnerable component allowing access to - * component-wide settings and files. - * - * Generated from protobuf enum PRIVILEGES_REQUIRED_HIGH = 3; - */ - const PRIVILEGES_REQUIRED_HIGH = 3; - - private static $valueToName = [ - self::PRIVILEGES_REQUIRED_UNSPECIFIED => 'PRIVILEGES_REQUIRED_UNSPECIFIED', - self::PRIVILEGES_REQUIRED_NONE => 'PRIVILEGES_REQUIRED_NONE', - self::PRIVILEGES_REQUIRED_LOW => 'PRIVILEGES_REQUIRED_LOW', - self::PRIVILEGES_REQUIRED_HIGH => 'PRIVILEGES_REQUIRED_HIGH', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PrivilegesRequired::class, \Google\Cloud\SecurityCenter\V2\Cvssv3_PrivilegesRequired::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/Scope.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/Scope.php deleted file mode 100644 index 146b335e704a..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/Scope.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.securitycenter.v2.Cvssv3.Scope - */ -class Scope -{ - /** - * Invalid value. - * - * Generated from protobuf enum SCOPE_UNSPECIFIED = 0; - */ - const SCOPE_UNSPECIFIED = 0; - /** - * An exploited vulnerability can only affect resources managed by the same - * security authority. - * - * Generated from protobuf enum SCOPE_UNCHANGED = 1; - */ - const SCOPE_UNCHANGED = 1; - /** - * An exploited vulnerability can affect resources beyond the security scope - * managed by the security authority of the vulnerable component. - * - * Generated from protobuf enum SCOPE_CHANGED = 2; - */ - const SCOPE_CHANGED = 2; - - private static $valueToName = [ - self::SCOPE_UNSPECIFIED => 'SCOPE_UNSPECIFIED', - self::SCOPE_UNCHANGED => 'SCOPE_UNCHANGED', - self::SCOPE_CHANGED => 'SCOPE_CHANGED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Scope::class, \Google\Cloud\SecurityCenter\V2\Cvssv3_Scope::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/UserInteraction.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/UserInteraction.php deleted file mode 100644 index fb1f4798ae49..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Cvssv3/UserInteraction.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.securitycenter.v2.Cvssv3.UserInteraction - */ -class UserInteraction -{ - /** - * Invalid value. - * - * Generated from protobuf enum USER_INTERACTION_UNSPECIFIED = 0; - */ - const USER_INTERACTION_UNSPECIFIED = 0; - /** - * The vulnerable system can be exploited without interaction from any user. - * - * Generated from protobuf enum USER_INTERACTION_NONE = 1; - */ - const USER_INTERACTION_NONE = 1; - /** - * Successful exploitation of this vulnerability requires a user to take - * some action before the vulnerability can be exploited. - * - * Generated from protobuf enum USER_INTERACTION_REQUIRED = 2; - */ - const USER_INTERACTION_REQUIRED = 2; - - private static $valueToName = [ - self::USER_INTERACTION_UNSPECIFIED => 'USER_INTERACTION_UNSPECIFIED', - self::USER_INTERACTION_NONE => 'USER_INTERACTION_NONE', - self::USER_INTERACTION_REQUIRED => 'USER_INTERACTION_REQUIRED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(UserInteraction::class, \Google\Cloud\SecurityCenter\V2\Cvssv3_UserInteraction::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Database.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Database.php deleted file mode 100644 index f4fd26f90546..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Database.php +++ /dev/null @@ -1,287 +0,0 @@ -google.cloud.securitycenter.v2.Database - */ -class Database extends \Google\Protobuf\Internal\Message -{ - /** - * Some database resources may not have the [full resource - * name](https://google.aip.dev/122#full-resource-names) populated because - * these resource types are not yet supported by Cloud Asset Inventory (e.g. - * Cloud SQL databases). In these cases only the display name will be - * provided. - * The [full resource name](https://google.aip.dev/122#full-resource-names) of - * the database that the user connected to, if it is supported by Cloud Asset - * Inventory. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The human-readable name of the database that the user connected to. - * - * Generated from protobuf field string display_name = 2; - */ - protected $display_name = ''; - /** - * The username used to connect to the database. The username might not be an - * IAM principal and does not have a set format. - * - * Generated from protobuf field string user_name = 3; - */ - protected $user_name = ''; - /** - * The SQL statement that is associated with the database access. - * - * Generated from protobuf field string query = 4; - */ - protected $query = ''; - /** - * The target usernames, roles, or groups of an SQL privilege grant, which is - * not an IAM policy change. - * - * Generated from protobuf field repeated string grantees = 5; - */ - private $grantees; - /** - * The version of the database, for example, POSTGRES_14. - * See [the complete - * list](https://cloud.google.com/sql/docs/mysql/admin-api/rest/v1/SqlDatabaseVersion). - * - * Generated from protobuf field string version = 6; - */ - protected $version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Some database resources may not have the [full resource - * name](https://google.aip.dev/122#full-resource-names) populated because - * these resource types are not yet supported by Cloud Asset Inventory (e.g. - * Cloud SQL databases). In these cases only the display name will be - * provided. - * The [full resource name](https://google.aip.dev/122#full-resource-names) of - * the database that the user connected to, if it is supported by Cloud Asset - * Inventory. - * @type string $display_name - * The human-readable name of the database that the user connected to. - * @type string $user_name - * The username used to connect to the database. The username might not be an - * IAM principal and does not have a set format. - * @type string $query - * The SQL statement that is associated with the database access. - * @type array|\Google\Protobuf\Internal\RepeatedField $grantees - * The target usernames, roles, or groups of an SQL privilege grant, which is - * not an IAM policy change. - * @type string $version - * The version of the database, for example, POSTGRES_14. - * See [the complete - * list](https://cloud.google.com/sql/docs/mysql/admin-api/rest/v1/SqlDatabaseVersion). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Database::initOnce(); - parent::__construct($data); - } - - /** - * Some database resources may not have the [full resource - * name](https://google.aip.dev/122#full-resource-names) populated because - * these resource types are not yet supported by Cloud Asset Inventory (e.g. - * Cloud SQL databases). In these cases only the display name will be - * provided. - * The [full resource name](https://google.aip.dev/122#full-resource-names) of - * the database that the user connected to, if it is supported by Cloud Asset - * Inventory. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Some database resources may not have the [full resource - * name](https://google.aip.dev/122#full-resource-names) populated because - * these resource types are not yet supported by Cloud Asset Inventory (e.g. - * Cloud SQL databases). In these cases only the display name will be - * provided. - * The [full resource name](https://google.aip.dev/122#full-resource-names) of - * the database that the user connected to, if it is supported by Cloud Asset - * Inventory. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The human-readable name of the database that the user connected to. - * - * Generated from protobuf field string display_name = 2; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * The human-readable name of the database that the user connected to. - * - * Generated from protobuf field string display_name = 2; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * The username used to connect to the database. The username might not be an - * IAM principal and does not have a set format. - * - * Generated from protobuf field string user_name = 3; - * @return string - */ - public function getUserName() - { - return $this->user_name; - } - - /** - * The username used to connect to the database. The username might not be an - * IAM principal and does not have a set format. - * - * Generated from protobuf field string user_name = 3; - * @param string $var - * @return $this - */ - public function setUserName($var) - { - GPBUtil::checkString($var, True); - $this->user_name = $var; - - return $this; - } - - /** - * The SQL statement that is associated with the database access. - * - * Generated from protobuf field string query = 4; - * @return string - */ - public function getQuery() - { - return $this->query; - } - - /** - * The SQL statement that is associated with the database access. - * - * Generated from protobuf field string query = 4; - * @param string $var - * @return $this - */ - public function setQuery($var) - { - GPBUtil::checkString($var, True); - $this->query = $var; - - return $this; - } - - /** - * The target usernames, roles, or groups of an SQL privilege grant, which is - * not an IAM policy change. - * - * Generated from protobuf field repeated string grantees = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getGrantees() - { - return $this->grantees; - } - - /** - * The target usernames, roles, or groups of an SQL privilege grant, which is - * not an IAM policy change. - * - * Generated from protobuf field repeated string grantees = 5; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setGrantees($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->grantees = $arr; - - return $this; - } - - /** - * The version of the database, for example, POSTGRES_14. - * See [the complete - * list](https://cloud.google.com/sql/docs/mysql/admin-api/rest/v1/SqlDatabaseVersion). - * - * Generated from protobuf field string version = 6; - * @return string - */ - public function getVersion() - { - return $this->version; - } - - /** - * The version of the database, for example, POSTGRES_14. - * See [the complete - * list](https://cloud.google.com/sql/docs/mysql/admin-api/rest/v1/SqlDatabaseVersion). - * - * Generated from protobuf field string version = 6; - * @param string $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkString($var, True); - $this->version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteBigQueryExportRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteBigQueryExportRequest.php deleted file mode 100644 index e36cbc8fff97..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteBigQueryExportRequest.php +++ /dev/null @@ -1,107 +0,0 @@ -google.cloud.securitycenter.v2.DeleteBigQueryExportRequest - */ -class DeleteBigQueryExportRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the BigQuery export to delete. The following list - * shows some examples of the format: - * + - * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` - * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` - * + `projects/{project}/locations/{location}/bigQueryExports/{export_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of the BigQuery export to delete. The following list - * shows some examples of the format: - * - * + - * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` - * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` - * + `projects/{project}/locations/{location}/bigQueryExports/{export_id}` - * Please see {@see SecurityCenterClient::bigQueryExportName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V2\DeleteBigQueryExportRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the BigQuery export to delete. The following list - * shows some examples of the format: - * + - * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` - * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` - * + `projects/{project}/locations/{location}/bigQueryExports/{export_id}` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the BigQuery export to delete. The following list - * shows some examples of the format: - * + - * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` - * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` - * + `projects/{project}/locations/{location}/bigQueryExports/{export_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of the BigQuery export to delete. The following list - * shows some examples of the format: - * + - * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` - * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` - * + `projects/{project}/locations/{location}/bigQueryExports/{export_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteMuteConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteMuteConfigRequest.php deleted file mode 100644 index 3eadf8908955..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteMuteConfigRequest.php +++ /dev/null @@ -1,123 +0,0 @@ -google.cloud.securitycenter.v2.DeleteMuteConfigRequest - */ -class DeleteMuteConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the mute config to delete. The following list shows some - * examples of the format: - * + `organizations/{organization}/muteConfigs/{config_id}` - * + - * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` - * + `folders/{folder}/muteConfigs/{config_id}` - * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` - * + `projects/{project}/muteConfigs/{config_id}` - * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the mute config to delete. The following list shows some - * examples of the format: - * - * + `organizations/{organization}/muteConfigs/{config_id}` - * + - * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` - * + `folders/{folder}/muteConfigs/{config_id}` - * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` - * + `projects/{project}/muteConfigs/{config_id}` - * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` - * Please see {@see SecurityCenterClient::muteConfigName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V2\DeleteMuteConfigRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the mute config to delete. The following list shows some - * examples of the format: - * + `organizations/{organization}/muteConfigs/{config_id}` - * + - * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` - * + `folders/{folder}/muteConfigs/{config_id}` - * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` - * + `projects/{project}/muteConfigs/{config_id}` - * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the mute config to delete. The following list shows some - * examples of the format: - * + `organizations/{organization}/muteConfigs/{config_id}` - * + - * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` - * + `folders/{folder}/muteConfigs/{config_id}` - * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` - * + `projects/{project}/muteConfigs/{config_id}` - * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the mute config to delete. The following list shows some - * examples of the format: - * + `organizations/{organization}/muteConfigs/{config_id}` - * + - * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` - * + `folders/{folder}/muteConfigs/{config_id}` - * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` - * + `projects/{project}/muteConfigs/{config_id}` - * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteNotificationConfigRequest.php deleted file mode 100644 index 5cf5f3371b41..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteNotificationConfigRequest.php +++ /dev/null @@ -1,117 +0,0 @@ -google.cloud.securitycenter.v2.DeleteNotificationConfigRequest - */ -class DeleteNotificationConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the notification config to delete. The following list - * shows some examples of the format: - * + - * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` - * + - * `folders/[folder_id]/locations/[location_id]notificationConfigs/[config_id]` - * + - * `projects/[project_id]/locations/[location_id]notificationConfigs/[config_id]` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the notification config to delete. The following list - * shows some examples of the format: - * - * + - * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` - * + - * `folders/[folder_id]/locations/[location_id]notificationConfigs/[config_id]` - * + - * `projects/[project_id]/locations/[location_id]notificationConfigs/[config_id]` - * Please see {@see SecurityCenterClient::notificationConfigName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V2\DeleteNotificationConfigRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the notification config to delete. The following list - * shows some examples of the format: - * + - * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` - * + - * `folders/[folder_id]/locations/[location_id]notificationConfigs/[config_id]` - * + - * `projects/[project_id]/locations/[location_id]notificationConfigs/[config_id]` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the notification config to delete. The following list - * shows some examples of the format: - * + - * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` - * + - * `folders/[folder_id]/locations/[location_id]notificationConfigs/[config_id]` - * + - * `projects/[project_id]/locations/[location_id]notificationConfigs/[config_id]` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the notification config to delete. The following list - * shows some examples of the format: - * + - * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` - * + - * `folders/[folder_id]/locations/[location_id]notificationConfigs/[config_id]` - * + - * `projects/[project_id]/locations/[location_id]notificationConfigs/[config_id]` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteResourceValueConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteResourceValueConfigRequest.php deleted file mode 100644 index 37b404916549..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/DeleteResourceValueConfigRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.cloud.securitycenter.v2.DeleteResourceValueConfigRequest - */ -class DeleteResourceValueConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the ResourceValueConfig to delete - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the ResourceValueConfig to delete - * Please see {@see SecurityCenterClient::resourceValueConfigName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V2\DeleteResourceValueConfigRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the ResourceValueConfig to delete - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the ResourceValueConfig to delete - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the ResourceValueConfig to delete - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/EnvironmentVariable.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/EnvironmentVariable.php deleted file mode 100644 index 2ea98dfa0ed5..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/EnvironmentVariable.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.securitycenter.v2.EnvironmentVariable - */ -class EnvironmentVariable extends \Google\Protobuf\Internal\Message -{ - /** - * Environment variable name as a JSON encoded string. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Environment variable value as a JSON encoded string. - * - * Generated from protobuf field string val = 2; - */ - protected $val = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Environment variable name as a JSON encoded string. - * @type string $val - * Environment variable value as a JSON encoded string. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Process::initOnce(); - parent::__construct($data); - } - - /** - * Environment variable name as a JSON encoded string. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Environment variable name as a JSON encoded string. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Environment variable value as a JSON encoded string. - * - * Generated from protobuf field string val = 2; - * @return string - */ - public function getVal() - { - return $this->val; - } - - /** - * Environment variable value as a JSON encoded string. - * - * Generated from protobuf field string val = 2; - * @param string $var - * @return $this - */ - public function setVal($var) - { - GPBUtil::checkString($var, True); - $this->val = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExfilResource.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExfilResource.php deleted file mode 100644 index 446c1ad60b44..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExfilResource.php +++ /dev/null @@ -1,121 +0,0 @@ -google.cloud.securitycenter.v2.ExfilResource - */ -class ExfilResource extends \Google\Protobuf\Internal\Message -{ - /** - * The resource's [full resource - * name](https://cloud.google.com/apis/design/resource_names#full_resource_name). - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Subcomponents of the asset that was exfiltrated, like URIs used during - * exfiltration, table names, databases, and filenames. For example, multiple - * tables might have been exfiltrated from the same Cloud SQL instance, or - * multiple files might have been exfiltrated from the same Cloud Storage - * bucket. - * - * Generated from protobuf field repeated string components = 2; - */ - private $components; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The resource's [full resource - * name](https://cloud.google.com/apis/design/resource_names#full_resource_name). - * @type array|\Google\Protobuf\Internal\RepeatedField $components - * Subcomponents of the asset that was exfiltrated, like URIs used during - * exfiltration, table names, databases, and filenames. For example, multiple - * tables might have been exfiltrated from the same Cloud SQL instance, or - * multiple files might have been exfiltrated from the same Cloud Storage - * bucket. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Exfiltration::initOnce(); - parent::__construct($data); - } - - /** - * The resource's [full resource - * name](https://cloud.google.com/apis/design/resource_names#full_resource_name). - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The resource's [full resource - * name](https://cloud.google.com/apis/design/resource_names#full_resource_name). - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Subcomponents of the asset that was exfiltrated, like URIs used during - * exfiltration, table names, databases, and filenames. For example, multiple - * tables might have been exfiltrated from the same Cloud SQL instance, or - * multiple files might have been exfiltrated from the same Cloud Storage - * bucket. - * - * Generated from protobuf field repeated string components = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getComponents() - { - return $this->components; - } - - /** - * Subcomponents of the asset that was exfiltrated, like URIs used during - * exfiltration, table names, databases, and filenames. For example, multiple - * tables might have been exfiltrated from the same Cloud SQL instance, or - * multiple files might have been exfiltrated from the same Cloud Storage - * bucket. - * - * Generated from protobuf field repeated string components = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setComponents($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->components = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Exfiltration.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Exfiltration.php deleted file mode 100644 index a0325fa01d65..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Exfiltration.php +++ /dev/null @@ -1,150 +0,0 @@ -google.cloud.securitycenter.v2.Exfiltration - */ -class Exfiltration extends \Google\Protobuf\Internal\Message -{ - /** - * If there are multiple sources, then the data is considered "joined" between - * them. For instance, BigQuery can join multiple tables, and each - * table would be considered a source. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ExfilResource sources = 1; - */ - private $sources; - /** - * If there are multiple targets, each target would get a complete copy of the - * "joined" source data. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ExfilResource targets = 2; - */ - private $targets; - /** - * Total exfiltrated bytes processed for the entire job. - * - * Generated from protobuf field int64 total_exfiltrated_bytes = 3; - */ - protected $total_exfiltrated_bytes = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V2\ExfilResource>|\Google\Protobuf\Internal\RepeatedField $sources - * If there are multiple sources, then the data is considered "joined" between - * them. For instance, BigQuery can join multiple tables, and each - * table would be considered a source. - * @type array<\Google\Cloud\SecurityCenter\V2\ExfilResource>|\Google\Protobuf\Internal\RepeatedField $targets - * If there are multiple targets, each target would get a complete copy of the - * "joined" source data. - * @type int|string $total_exfiltrated_bytes - * Total exfiltrated bytes processed for the entire job. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Exfiltration::initOnce(); - parent::__construct($data); - } - - /** - * If there are multiple sources, then the data is considered "joined" between - * them. For instance, BigQuery can join multiple tables, and each - * table would be considered a source. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ExfilResource sources = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSources() - { - return $this->sources; - } - - /** - * If there are multiple sources, then the data is considered "joined" between - * them. For instance, BigQuery can join multiple tables, and each - * table would be considered a source. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ExfilResource sources = 1; - * @param array<\Google\Cloud\SecurityCenter\V2\ExfilResource>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSources($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ExfilResource::class); - $this->sources = $arr; - - return $this; - } - - /** - * If there are multiple targets, each target would get a complete copy of the - * "joined" source data. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ExfilResource targets = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTargets() - { - return $this->targets; - } - - /** - * If there are multiple targets, each target would get a complete copy of the - * "joined" source data. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ExfilResource targets = 2; - * @param array<\Google\Cloud\SecurityCenter\V2\ExfilResource>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTargets($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ExfilResource::class); - $this->targets = $arr; - - return $this; - } - - /** - * Total exfiltrated bytes processed for the entire job. - * - * Generated from protobuf field int64 total_exfiltrated_bytes = 3; - * @return int|string - */ - public function getTotalExfiltratedBytes() - { - return $this->total_exfiltrated_bytes; - } - - /** - * Total exfiltrated bytes processed for the entire job. - * - * Generated from protobuf field int64 total_exfiltrated_bytes = 3; - * @param int|string $var - * @return $this - */ - public function setTotalExfiltratedBytes($var) - { - GPBUtil::checkInt64($var); - $this->total_exfiltrated_bytes = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExternalSystem.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExternalSystem.php deleted file mode 100644 index 9c074ab1c339..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExternalSystem.php +++ /dev/null @@ -1,513 +0,0 @@ -google.cloud.securitycenter.v2.ExternalSystem - */ -class ExternalSystem extends \Google\Protobuf\Internal\Message -{ - /** - * Full resource name of the external system. The following list - * shows some examples: - * + `organizations/1234/sources/5678/findings/123456/externalSystems/jira` - * + - * `organizations/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` - * + `folders/1234/sources/5678/findings/123456/externalSystems/jira` - * + - * `folders/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` - * + `projects/1234/sources/5678/findings/123456/externalSystems/jira` - * + - * `projects/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * References primary/secondary etc assignees in the external system. - * - * Generated from protobuf field repeated string assignees = 2; - */ - private $assignees; - /** - * The identifier that's used to track the finding's corresponding case in the - * external system. - * - * Generated from protobuf field string external_uid = 3; - */ - protected $external_uid = ''; - /** - * The most recent status of the finding's corresponding case, as reported by - * the external system. - * - * Generated from protobuf field string status = 4; - */ - protected $status = ''; - /** - * The time when the case was last updated, as reported by the external - * system. - * - * Generated from protobuf field .google.protobuf.Timestamp external_system_update_time = 5; - */ - protected $external_system_update_time = null; - /** - * The link to the finding's corresponding case in the external system. - * - * Generated from protobuf field string case_uri = 6; - */ - protected $case_uri = ''; - /** - * The priority of the finding's corresponding case in the external system. - * - * Generated from protobuf field string case_priority = 7; - */ - protected $case_priority = ''; - /** - * The SLA of the finding's corresponding case in the external system. - * - * Generated from protobuf field .google.protobuf.Timestamp case_sla = 9; - */ - protected $case_sla = null; - /** - * The time when the case was created, as reported by the external system. - * - * Generated from protobuf field .google.protobuf.Timestamp case_create_time = 10; - */ - protected $case_create_time = null; - /** - * The time when the case was closed, as reported by the external system. - * - * Generated from protobuf field .google.protobuf.Timestamp case_close_time = 11; - */ - protected $case_close_time = null; - /** - * Information about the ticket, if any, that is being used to track the - * resolution of the issue that is identified by this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ExternalSystem.TicketInfo ticket_info = 8; - */ - protected $ticket_info = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Full resource name of the external system. The following list - * shows some examples: - * + `organizations/1234/sources/5678/findings/123456/externalSystems/jira` - * + - * `organizations/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` - * + `folders/1234/sources/5678/findings/123456/externalSystems/jira` - * + - * `folders/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` - * + `projects/1234/sources/5678/findings/123456/externalSystems/jira` - * + - * `projects/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` - * @type array|\Google\Protobuf\Internal\RepeatedField $assignees - * References primary/secondary etc assignees in the external system. - * @type string $external_uid - * The identifier that's used to track the finding's corresponding case in the - * external system. - * @type string $status - * The most recent status of the finding's corresponding case, as reported by - * the external system. - * @type \Google\Protobuf\Timestamp $external_system_update_time - * The time when the case was last updated, as reported by the external - * system. - * @type string $case_uri - * The link to the finding's corresponding case in the external system. - * @type string $case_priority - * The priority of the finding's corresponding case in the external system. - * @type \Google\Protobuf\Timestamp $case_sla - * The SLA of the finding's corresponding case in the external system. - * @type \Google\Protobuf\Timestamp $case_create_time - * The time when the case was created, as reported by the external system. - * @type \Google\Protobuf\Timestamp $case_close_time - * The time when the case was closed, as reported by the external system. - * @type \Google\Cloud\SecurityCenter\V2\ExternalSystem\TicketInfo $ticket_info - * Information about the ticket, if any, that is being used to track the - * resolution of the issue that is identified by this finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\ExternalSystem::initOnce(); - parent::__construct($data); - } - - /** - * Full resource name of the external system. The following list - * shows some examples: - * + `organizations/1234/sources/5678/findings/123456/externalSystems/jira` - * + - * `organizations/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` - * + `folders/1234/sources/5678/findings/123456/externalSystems/jira` - * + - * `folders/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` - * + `projects/1234/sources/5678/findings/123456/externalSystems/jira` - * + - * `projects/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Full resource name of the external system. The following list - * shows some examples: - * + `organizations/1234/sources/5678/findings/123456/externalSystems/jira` - * + - * `organizations/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` - * + `folders/1234/sources/5678/findings/123456/externalSystems/jira` - * + - * `folders/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` - * + `projects/1234/sources/5678/findings/123456/externalSystems/jira` - * + - * `projects/1234/sources/5678/locations/us/findings/123456/externalSystems/jira` - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * References primary/secondary etc assignees in the external system. - * - * Generated from protobuf field repeated string assignees = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAssignees() - { - return $this->assignees; - } - - /** - * References primary/secondary etc assignees in the external system. - * - * Generated from protobuf field repeated string assignees = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAssignees($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->assignees = $arr; - - return $this; - } - - /** - * The identifier that's used to track the finding's corresponding case in the - * external system. - * - * Generated from protobuf field string external_uid = 3; - * @return string - */ - public function getExternalUid() - { - return $this->external_uid; - } - - /** - * The identifier that's used to track the finding's corresponding case in the - * external system. - * - * Generated from protobuf field string external_uid = 3; - * @param string $var - * @return $this - */ - public function setExternalUid($var) - { - GPBUtil::checkString($var, True); - $this->external_uid = $var; - - return $this; - } - - /** - * The most recent status of the finding's corresponding case, as reported by - * the external system. - * - * Generated from protobuf field string status = 4; - * @return string - */ - public function getStatus() - { - return $this->status; - } - - /** - * The most recent status of the finding's corresponding case, as reported by - * the external system. - * - * Generated from protobuf field string status = 4; - * @param string $var - * @return $this - */ - public function setStatus($var) - { - GPBUtil::checkString($var, True); - $this->status = $var; - - return $this; - } - - /** - * The time when the case was last updated, as reported by the external - * system. - * - * Generated from protobuf field .google.protobuf.Timestamp external_system_update_time = 5; - * @return \Google\Protobuf\Timestamp|null - */ - public function getExternalSystemUpdateTime() - { - return $this->external_system_update_time; - } - - public function hasExternalSystemUpdateTime() - { - return isset($this->external_system_update_time); - } - - public function clearExternalSystemUpdateTime() - { - unset($this->external_system_update_time); - } - - /** - * The time when the case was last updated, as reported by the external - * system. - * - * Generated from protobuf field .google.protobuf.Timestamp external_system_update_time = 5; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setExternalSystemUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->external_system_update_time = $var; - - return $this; - } - - /** - * The link to the finding's corresponding case in the external system. - * - * Generated from protobuf field string case_uri = 6; - * @return string - */ - public function getCaseUri() - { - return $this->case_uri; - } - - /** - * The link to the finding's corresponding case in the external system. - * - * Generated from protobuf field string case_uri = 6; - * @param string $var - * @return $this - */ - public function setCaseUri($var) - { - GPBUtil::checkString($var, True); - $this->case_uri = $var; - - return $this; - } - - /** - * The priority of the finding's corresponding case in the external system. - * - * Generated from protobuf field string case_priority = 7; - * @return string - */ - public function getCasePriority() - { - return $this->case_priority; - } - - /** - * The priority of the finding's corresponding case in the external system. - * - * Generated from protobuf field string case_priority = 7; - * @param string $var - * @return $this - */ - public function setCasePriority($var) - { - GPBUtil::checkString($var, True); - $this->case_priority = $var; - - return $this; - } - - /** - * The SLA of the finding's corresponding case in the external system. - * - * Generated from protobuf field .google.protobuf.Timestamp case_sla = 9; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCaseSla() - { - return $this->case_sla; - } - - public function hasCaseSla() - { - return isset($this->case_sla); - } - - public function clearCaseSla() - { - unset($this->case_sla); - } - - /** - * The SLA of the finding's corresponding case in the external system. - * - * Generated from protobuf field .google.protobuf.Timestamp case_sla = 9; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCaseSla($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->case_sla = $var; - - return $this; - } - - /** - * The time when the case was created, as reported by the external system. - * - * Generated from protobuf field .google.protobuf.Timestamp case_create_time = 10; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCaseCreateTime() - { - return $this->case_create_time; - } - - public function hasCaseCreateTime() - { - return isset($this->case_create_time); - } - - public function clearCaseCreateTime() - { - unset($this->case_create_time); - } - - /** - * The time when the case was created, as reported by the external system. - * - * Generated from protobuf field .google.protobuf.Timestamp case_create_time = 10; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCaseCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->case_create_time = $var; - - return $this; - } - - /** - * The time when the case was closed, as reported by the external system. - * - * Generated from protobuf field .google.protobuf.Timestamp case_close_time = 11; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCaseCloseTime() - { - return $this->case_close_time; - } - - public function hasCaseCloseTime() - { - return isset($this->case_close_time); - } - - public function clearCaseCloseTime() - { - unset($this->case_close_time); - } - - /** - * The time when the case was closed, as reported by the external system. - * - * Generated from protobuf field .google.protobuf.Timestamp case_close_time = 11; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCaseCloseTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->case_close_time = $var; - - return $this; - } - - /** - * Information about the ticket, if any, that is being used to track the - * resolution of the issue that is identified by this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ExternalSystem.TicketInfo ticket_info = 8; - * @return \Google\Cloud\SecurityCenter\V2\ExternalSystem\TicketInfo|null - */ - public function getTicketInfo() - { - return $this->ticket_info; - } - - public function hasTicketInfo() - { - return isset($this->ticket_info); - } - - public function clearTicketInfo() - { - unset($this->ticket_info); - } - - /** - * Information about the ticket, if any, that is being used to track the - * resolution of the issue that is identified by this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ExternalSystem.TicketInfo ticket_info = 8; - * @param \Google\Cloud\SecurityCenter\V2\ExternalSystem\TicketInfo $var - * @return $this - */ - public function setTicketInfo($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ExternalSystem\TicketInfo::class); - $this->ticket_info = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExternalSystem/TicketInfo.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExternalSystem/TicketInfo.php deleted file mode 100644 index b6c42581fe6c..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ExternalSystem/TicketInfo.php +++ /dev/null @@ -1,255 +0,0 @@ -google.cloud.securitycenter.v2.ExternalSystem.TicketInfo - */ -class TicketInfo extends \Google\Protobuf\Internal\Message -{ - /** - * The identifier of the ticket in the ticket system. - * - * Generated from protobuf field string id = 1; - */ - protected $id = ''; - /** - * The assignee of the ticket in the ticket system. - * - * Generated from protobuf field string assignee = 2; - */ - protected $assignee = ''; - /** - * The description of the ticket in the ticket system. - * - * Generated from protobuf field string description = 3; - */ - protected $description = ''; - /** - * The link to the ticket in the ticket system. - * - * Generated from protobuf field string uri = 4; - */ - protected $uri = ''; - /** - * The latest status of the ticket, as reported by the ticket system. - * - * Generated from protobuf field string status = 5; - */ - protected $status = ''; - /** - * The time when the ticket was last updated, as reported by the ticket - * system. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6; - */ - protected $update_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $id - * The identifier of the ticket in the ticket system. - * @type string $assignee - * The assignee of the ticket in the ticket system. - * @type string $description - * The description of the ticket in the ticket system. - * @type string $uri - * The link to the ticket in the ticket system. - * @type string $status - * The latest status of the ticket, as reported by the ticket system. - * @type \Google\Protobuf\Timestamp $update_time - * The time when the ticket was last updated, as reported by the ticket - * system. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\ExternalSystem::initOnce(); - parent::__construct($data); - } - - /** - * The identifier of the ticket in the ticket system. - * - * Generated from protobuf field string id = 1; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * The identifier of the ticket in the ticket system. - * - * Generated from protobuf field string id = 1; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - - /** - * The assignee of the ticket in the ticket system. - * - * Generated from protobuf field string assignee = 2; - * @return string - */ - public function getAssignee() - { - return $this->assignee; - } - - /** - * The assignee of the ticket in the ticket system. - * - * Generated from protobuf field string assignee = 2; - * @param string $var - * @return $this - */ - public function setAssignee($var) - { - GPBUtil::checkString($var, True); - $this->assignee = $var; - - return $this; - } - - /** - * The description of the ticket in the ticket system. - * - * Generated from protobuf field string description = 3; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * The description of the ticket in the ticket system. - * - * Generated from protobuf field string description = 3; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * The link to the ticket in the ticket system. - * - * Generated from protobuf field string uri = 4; - * @return string - */ - public function getUri() - { - return $this->uri; - } - - /** - * The link to the ticket in the ticket system. - * - * Generated from protobuf field string uri = 4; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->uri = $var; - - return $this; - } - - /** - * The latest status of the ticket, as reported by the ticket system. - * - * Generated from protobuf field string status = 5; - * @return string - */ - public function getStatus() - { - return $this->status; - } - - /** - * The latest status of the ticket, as reported by the ticket system. - * - * Generated from protobuf field string status = 5; - * @param string $var - * @return $this - */ - public function setStatus($var) - { - GPBUtil::checkString($var, True); - $this->status = $var; - - return $this; - } - - /** - * The time when the ticket was last updated, as reported by the ticket - * system. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * The time when the ticket was last updated, as reported by the ticket - * system. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 6; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(TicketInfo::class, \Google\Cloud\SecurityCenter\V2\ExternalSystem_TicketInfo::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/File.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/File.php deleted file mode 100644 index c69daaf28e6f..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/File.php +++ /dev/null @@ -1,298 +0,0 @@ -google.cloud.securitycenter.v2.File - */ -class File extends \Google\Protobuf\Internal\Message -{ - /** - * Absolute path of the file as a JSON encoded string. - * - * Generated from protobuf field string path = 1; - */ - protected $path = ''; - /** - * Size of the file in bytes. - * - * Generated from protobuf field int64 size = 2; - */ - protected $size = 0; - /** - * SHA256 hash of the first hashed_size bytes of the file encoded as a - * hex string. If hashed_size == size, sha256 represents the SHA256 hash - * of the entire file. - * - * Generated from protobuf field string sha256 = 3; - */ - protected $sha256 = ''; - /** - * The length in bytes of the file prefix that was hashed. If - * hashed_size == size, any hashes reported represent the entire - * file. - * - * Generated from protobuf field int64 hashed_size = 4; - */ - protected $hashed_size = 0; - /** - * True when the hash covers only a prefix of the file. - * - * Generated from protobuf field bool partially_hashed = 5; - */ - protected $partially_hashed = false; - /** - * Prefix of the file contents as a JSON-encoded string. - * - * Generated from protobuf field string contents = 6; - */ - protected $contents = ''; - /** - * Path of the file in terms of underlying disk/partition identifiers. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.File.DiskPath disk_path = 7; - */ - protected $disk_path = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $path - * Absolute path of the file as a JSON encoded string. - * @type int|string $size - * Size of the file in bytes. - * @type string $sha256 - * SHA256 hash of the first hashed_size bytes of the file encoded as a - * hex string. If hashed_size == size, sha256 represents the SHA256 hash - * of the entire file. - * @type int|string $hashed_size - * The length in bytes of the file prefix that was hashed. If - * hashed_size == size, any hashes reported represent the entire - * file. - * @type bool $partially_hashed - * True when the hash covers only a prefix of the file. - * @type string $contents - * Prefix of the file contents as a JSON-encoded string. - * @type \Google\Cloud\SecurityCenter\V2\File\DiskPath $disk_path - * Path of the file in terms of underlying disk/partition identifiers. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\File::initOnce(); - parent::__construct($data); - } - - /** - * Absolute path of the file as a JSON encoded string. - * - * Generated from protobuf field string path = 1; - * @return string - */ - public function getPath() - { - return $this->path; - } - - /** - * Absolute path of the file as a JSON encoded string. - * - * Generated from protobuf field string path = 1; - * @param string $var - * @return $this - */ - public function setPath($var) - { - GPBUtil::checkString($var, True); - $this->path = $var; - - return $this; - } - - /** - * Size of the file in bytes. - * - * Generated from protobuf field int64 size = 2; - * @return int|string - */ - public function getSize() - { - return $this->size; - } - - /** - * Size of the file in bytes. - * - * Generated from protobuf field int64 size = 2; - * @param int|string $var - * @return $this - */ - public function setSize($var) - { - GPBUtil::checkInt64($var); - $this->size = $var; - - return $this; - } - - /** - * SHA256 hash of the first hashed_size bytes of the file encoded as a - * hex string. If hashed_size == size, sha256 represents the SHA256 hash - * of the entire file. - * - * Generated from protobuf field string sha256 = 3; - * @return string - */ - public function getSha256() - { - return $this->sha256; - } - - /** - * SHA256 hash of the first hashed_size bytes of the file encoded as a - * hex string. If hashed_size == size, sha256 represents the SHA256 hash - * of the entire file. - * - * Generated from protobuf field string sha256 = 3; - * @param string $var - * @return $this - */ - public function setSha256($var) - { - GPBUtil::checkString($var, True); - $this->sha256 = $var; - - return $this; - } - - /** - * The length in bytes of the file prefix that was hashed. If - * hashed_size == size, any hashes reported represent the entire - * file. - * - * Generated from protobuf field int64 hashed_size = 4; - * @return int|string - */ - public function getHashedSize() - { - return $this->hashed_size; - } - - /** - * The length in bytes of the file prefix that was hashed. If - * hashed_size == size, any hashes reported represent the entire - * file. - * - * Generated from protobuf field int64 hashed_size = 4; - * @param int|string $var - * @return $this - */ - public function setHashedSize($var) - { - GPBUtil::checkInt64($var); - $this->hashed_size = $var; - - return $this; - } - - /** - * True when the hash covers only a prefix of the file. - * - * Generated from protobuf field bool partially_hashed = 5; - * @return bool - */ - public function getPartiallyHashed() - { - return $this->partially_hashed; - } - - /** - * True when the hash covers only a prefix of the file. - * - * Generated from protobuf field bool partially_hashed = 5; - * @param bool $var - * @return $this - */ - public function setPartiallyHashed($var) - { - GPBUtil::checkBool($var); - $this->partially_hashed = $var; - - return $this; - } - - /** - * Prefix of the file contents as a JSON-encoded string. - * - * Generated from protobuf field string contents = 6; - * @return string - */ - public function getContents() - { - return $this->contents; - } - - /** - * Prefix of the file contents as a JSON-encoded string. - * - * Generated from protobuf field string contents = 6; - * @param string $var - * @return $this - */ - public function setContents($var) - { - GPBUtil::checkString($var, True); - $this->contents = $var; - - return $this; - } - - /** - * Path of the file in terms of underlying disk/partition identifiers. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.File.DiskPath disk_path = 7; - * @return \Google\Cloud\SecurityCenter\V2\File\DiskPath|null - */ - public function getDiskPath() - { - return $this->disk_path; - } - - public function hasDiskPath() - { - return isset($this->disk_path); - } - - public function clearDiskPath() - { - unset($this->disk_path); - } - - /** - * Path of the file in terms of underlying disk/partition identifiers. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.File.DiskPath disk_path = 7; - * @param \Google\Cloud\SecurityCenter\V2\File\DiskPath $var - * @return $this - */ - public function setDiskPath($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\File\DiskPath::class); - $this->disk_path = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/File/DiskPath.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/File/DiskPath.php deleted file mode 100644 index 94f841f5981c..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/File/DiskPath.php +++ /dev/null @@ -1,112 +0,0 @@ -google.cloud.securitycenter.v2.File.DiskPath - */ -class DiskPath extends \Google\Protobuf\Internal\Message -{ - /** - * UUID of the partition (format - * https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid) - * - * Generated from protobuf field string partition_uuid = 1; - */ - protected $partition_uuid = ''; - /** - * Relative path of the file in the partition as a JSON encoded string. - * Example: /home/user1/executable_file.sh - * - * Generated from protobuf field string relative_path = 2; - */ - protected $relative_path = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $partition_uuid - * UUID of the partition (format - * https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid) - * @type string $relative_path - * Relative path of the file in the partition as a JSON encoded string. - * Example: /home/user1/executable_file.sh - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\File::initOnce(); - parent::__construct($data); - } - - /** - * UUID of the partition (format - * https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid) - * - * Generated from protobuf field string partition_uuid = 1; - * @return string - */ - public function getPartitionUuid() - { - return $this->partition_uuid; - } - - /** - * UUID of the partition (format - * https://wiki.archlinux.org/title/persistent_block_device_naming#by-uuid) - * - * Generated from protobuf field string partition_uuid = 1; - * @param string $var - * @return $this - */ - public function setPartitionUuid($var) - { - GPBUtil::checkString($var, True); - $this->partition_uuid = $var; - - return $this; - } - - /** - * Relative path of the file in the partition as a JSON encoded string. - * Example: /home/user1/executable_file.sh - * - * Generated from protobuf field string relative_path = 2; - * @return string - */ - public function getRelativePath() - { - return $this->relative_path; - } - - /** - * Relative path of the file in the partition as a JSON encoded string. - * Example: /home/user1/executable_file.sh - * - * Generated from protobuf field string relative_path = 2; - * @param string $var - * @return $this - */ - public function setRelativePath($var) - { - GPBUtil::checkString($var, True); - $this->relative_path = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(DiskPath::class, \Google\Cloud\SecurityCenter\V2\File_DiskPath::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding.php deleted file mode 100644 index a7ea154b1943..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding.php +++ /dev/null @@ -1,2302 +0,0 @@ -google.cloud.securitycenter.v2.Finding - */ -class Finding extends \Google\Protobuf\Internal\Message -{ - /** - * The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. The following list shows some examples: - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` - * + - * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Output only. The canonical name of the finding. The following list shows - * some examples: - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` - * + - * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * The prefix is the closest CRM ancestor of the resource associated with the - * finding. - * - * Generated from protobuf field string canonical_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $canonical_name = ''; - /** - * The relative resource name of the source and location the finding belongs - * to. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * This field is immutable after creation time. The following list shows some - * examples: - * + `organizations/{organization_id}/sources/{source_id}` - * + `folders/{folders_id}/sources/{source_id}` - * + `projects/{projects_id}/sources/{source_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}` - * + `folders/{folders_id}/sources/{source_id}/locations/{location_id}` - * + `projects/{projects_id}/sources/{source_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 3; - */ - protected $parent = ''; - /** - * Immutable. For findings on Google Cloud resources, the full resource - * name of the Google Cloud resource this finding is for. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * When the finding is for a non-Google Cloud resource, the resourceName can - * be a customer or partner defined string. - * - * Generated from protobuf field string resource_name = 4 [(.google.api.field_behavior) = IMMUTABLE]; - */ - protected $resource_name = ''; - /** - * Output only. The state of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Immutable. The additional taxonomy group within findings from a given - * source. Example: "XSS_FLASH_INJECTION" - * - * Generated from protobuf field string category = 7 [(.google.api.field_behavior) = IMMUTABLE]; - */ - protected $category = ''; - /** - * The URI that, if available, points to a web page outside of Security - * Command Center where additional information about the finding can be found. - * This field is guaranteed to be either empty or a well formed URL. - * - * Generated from protobuf field string external_uri = 8; - */ - protected $external_uri = ''; - /** - * Source specific properties. These properties are managed by the source - * that writes the finding. The key names in the source_properties map must be - * between 1 and 255 characters, and must start with a letter and contain - * alphanumeric characters or underscores only. - * - * Generated from protobuf field map source_properties = 9; - */ - private $source_properties; - /** - * Output only. User specified security marks. These marks are entirely - * managed by the user and come from the SecurityMarks resource that belongs - * to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityMarks security_marks = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $security_marks = null; - /** - * The time the finding was first detected. If an existing finding is updated, - * then this is the time the update occurred. - * For example, if the finding represents an open firewall, this property - * captures the time the detector believes the firewall became open. The - * accuracy is determined by the detector. If the finding is later resolved, - * then this time reflects when the finding was resolved. This must not - * be set to a value greater than the current timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp event_time = 11; - */ - protected $event_time = null; - /** - * Output only. The time at which the finding was created in Security Command - * Center. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * The severity of the finding. This field is managed by the source that - * writes the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.Severity severity = 14; - */ - protected $severity = 0; - /** - * Indicates the mute state of a finding (either muted, unmuted - * or undefined). Unlike other attributes of a finding, a finding provider - * shouldn't set the value of mute. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.Mute mute = 15; - */ - protected $mute = 0; - /** - * The class of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.FindingClass finding_class = 16; - */ - protected $finding_class = 0; - /** - * Represents what's commonly known as an *indicator of compromise* (IoC) in - * computer forensics. This is an artifact observed on a network or in an - * operating system that, with high confidence, indicates a computer - * intrusion. For more information, see [Indicator of - * compromise](https://en.wikipedia.org/wiki/Indicator_of_compromise). - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator indicator = 17; - */ - protected $indicator = null; - /** - * Represents vulnerability-specific fields like CVE and CVSS scores. - * CVE stands for Common Vulnerabilities and Exposures - * (https://cve.mitre.org/about/) - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Vulnerability vulnerability = 18; - */ - protected $vulnerability = null; - /** - * Output only. The most recent time this finding was muted or unmuted. - * - * Generated from protobuf field .google.protobuf.Timestamp mute_update_time = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $mute_update_time = null; - /** - * Output only. Third party SIEM/SOAR fields within SCC, contains external - * system information and external system finding fields. - * - * Generated from protobuf field map external_systems = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $external_systems; - /** - * MITRE ATT&CK tactics and techniques related to this finding. - * See: https://attack.mitre.org - * - * Generated from protobuf field .google.cloud.securitycenter.v2.MitreAttack mitre_attack = 21; - */ - protected $mitre_attack = null; - /** - * Access details associated with the finding, such as more information on the - * caller, which method was accessed, and from where. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Access access = 22; - */ - protected $access = null; - /** - * Contains information about the IP connection associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Connection connections = 23; - */ - private $connections; - /** - * Records additional information about the mute operation, for example, the - * [mute - * configuration](https://cloud.google.com/security-command-center/docs/how-to-mute-findings) - * that muted the finding and the user who muted the finding. - * - * Generated from protobuf field string mute_initiator = 24; - */ - protected $mute_initiator = ''; - /** - * Represents operating system processes associated with the Finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Process processes = 25; - */ - private $processes; - /** - * Output only. Map containing the points of contact for the given finding. - * The key represents the type of contact, while the value contains a list of - * all the contacts that pertain. Please refer to: - * https://cloud.google.com/resource-manager/docs/managing-notification-contacts#notification-categories - * { - * "security": { - * "contacts": [ - * { - * "email": "person1@company.com" - * }, - * { - * "email": "person2@company.com" - * } - * ] - * } - * } - * - * Generated from protobuf field map contacts = 26 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $contacts; - /** - * Contains compliance information for security standards associated to the - * finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Compliance compliances = 27; - */ - private $compliances; - /** - * Output only. The human readable display name of the finding source such as - * "Event Threat Detection" or "Security Health Analytics". - * - * Generated from protobuf field string parent_display_name = 29 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $parent_display_name = ''; - /** - * Contains more details about the finding. - * - * Generated from protobuf field string description = 30; - */ - protected $description = ''; - /** - * Represents exfiltrations associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Exfiltration exfiltration = 31; - */ - protected $exfiltration = null; - /** - * Represents IAM bindings associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.IamBinding iam_bindings = 32; - */ - private $iam_bindings; - /** - * Steps to address the finding. - * - * Generated from protobuf field string next_steps = 33; - */ - protected $next_steps = ''; - /** - * Unique identifier of the module which generated the finding. - * Example: - * folders/598186756061/securityHealthAnalyticsSettings/customModules/56799441161885 - * - * Generated from protobuf field string module_name = 34; - */ - protected $module_name = ''; - /** - * Containers associated with the finding. This field provides information for - * both Kubernetes and non-Kubernetes containers. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Container containers = 35; - */ - private $containers; - /** - * Kubernetes resources associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes kubernetes = 36; - */ - protected $kubernetes = null; - /** - * Database associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Database database = 37; - */ - protected $database = null; - /** - * The results of an attack path simulation relevant to this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.AttackExposure attack_exposure = 38; - */ - protected $attack_exposure = null; - /** - * File associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.File files = 39; - */ - private $files; - /** - * Cloud Data Loss Prevention (Cloud DLP) inspection results that are - * associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudDlpInspection cloud_dlp_inspection = 40; - */ - protected $cloud_dlp_inspection = null; - /** - * Cloud DLP data profile that is associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudDlpDataProfile cloud_dlp_data_profile = 41; - */ - protected $cloud_dlp_data_profile = null; - /** - * Signature of the kernel rootkit. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.KernelRootkit kernel_rootkit = 42; - */ - protected $kernel_rootkit = null; - /** - * Contains information about the org policies associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.OrgPolicy org_policies = 43; - */ - private $org_policies; - /** - * Represents an application associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Application application = 45; - */ - protected $application = null; - /** - * Fields related to Backup and DR findings. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.BackupDisasterRecovery backup_disaster_recovery = 47; - */ - protected $backup_disaster_recovery = null; - /** - * The security posture associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityPosture security_posture = 48; - */ - protected $security_posture = null; - /** - * Log entries that are relevant to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.LogEntry log_entries = 49; - */ - private $log_entries; - /** - * The load balancers associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.LoadBalancer load_balancers = 50; - */ - private $load_balancers; - /** - * Fields related to Cloud Armor findings. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudArmor cloud_armor = 51; - */ - protected $cloud_armor = null; - /** - * Notebook associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Notebook notebook = 55; - */ - protected $notebook = null; - /** - * Contains details about a group of security issues that, when the issues - * occur together, represent a greater risk than when the issues occur - * independently. A group of such issues is referred to as a toxic - * combination. - * This field cannot be updated. Its value is ignored in all update requests. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ToxicCombination toxic_combination = 56; - */ - protected $toxic_combination = null; - /** - * Contains details about groups of which this finding is a member. A group is - * a collection of findings that are related in some way. - * This field cannot be updated. Its value is ignored in all update requests. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.GroupMembership group_memberships = 57; - */ - private $group_memberships; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. The following list shows some examples: - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` - * + - * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * @type string $canonical_name - * Output only. The canonical name of the finding. The following list shows - * some examples: - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` - * + - * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * The prefix is the closest CRM ancestor of the resource associated with the - * finding. - * @type string $parent - * The relative resource name of the source and location the finding belongs - * to. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * This field is immutable after creation time. The following list shows some - * examples: - * + `organizations/{organization_id}/sources/{source_id}` - * + `folders/{folders_id}/sources/{source_id}` - * + `projects/{projects_id}/sources/{source_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}` - * + `folders/{folders_id}/sources/{source_id}/locations/{location_id}` - * + `projects/{projects_id}/sources/{source_id}/locations/{location_id}` - * @type string $resource_name - * Immutable. For findings on Google Cloud resources, the full resource - * name of the Google Cloud resource this finding is for. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * When the finding is for a non-Google Cloud resource, the resourceName can - * be a customer or partner defined string. - * @type int $state - * Output only. The state of the finding. - * @type string $category - * Immutable. The additional taxonomy group within findings from a given - * source. Example: "XSS_FLASH_INJECTION" - * @type string $external_uri - * The URI that, if available, points to a web page outside of Security - * Command Center where additional information about the finding can be found. - * This field is guaranteed to be either empty or a well formed URL. - * @type array|\Google\Protobuf\Internal\MapField $source_properties - * Source specific properties. These properties are managed by the source - * that writes the finding. The key names in the source_properties map must be - * between 1 and 255 characters, and must start with a letter and contain - * alphanumeric characters or underscores only. - * @type \Google\Cloud\SecurityCenter\V2\SecurityMarks $security_marks - * Output only. User specified security marks. These marks are entirely - * managed by the user and come from the SecurityMarks resource that belongs - * to the finding. - * @type \Google\Protobuf\Timestamp $event_time - * The time the finding was first detected. If an existing finding is updated, - * then this is the time the update occurred. - * For example, if the finding represents an open firewall, this property - * captures the time the detector believes the firewall became open. The - * accuracy is determined by the detector. If the finding is later resolved, - * then this time reflects when the finding was resolved. This must not - * be set to a value greater than the current timestamp. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time at which the finding was created in Security Command - * Center. - * @type int $severity - * The severity of the finding. This field is managed by the source that - * writes the finding. - * @type int $mute - * Indicates the mute state of a finding (either muted, unmuted - * or undefined). Unlike other attributes of a finding, a finding provider - * shouldn't set the value of mute. - * @type int $finding_class - * The class of the finding. - * @type \Google\Cloud\SecurityCenter\V2\Indicator $indicator - * Represents what's commonly known as an *indicator of compromise* (IoC) in - * computer forensics. This is an artifact observed on a network or in an - * operating system that, with high confidence, indicates a computer - * intrusion. For more information, see [Indicator of - * compromise](https://en.wikipedia.org/wiki/Indicator_of_compromise). - * @type \Google\Cloud\SecurityCenter\V2\Vulnerability $vulnerability - * Represents vulnerability-specific fields like CVE and CVSS scores. - * CVE stands for Common Vulnerabilities and Exposures - * (https://cve.mitre.org/about/) - * @type \Google\Protobuf\Timestamp $mute_update_time - * Output only. The most recent time this finding was muted or unmuted. - * @type array|\Google\Protobuf\Internal\MapField $external_systems - * Output only. Third party SIEM/SOAR fields within SCC, contains external - * system information and external system finding fields. - * @type \Google\Cloud\SecurityCenter\V2\MitreAttack $mitre_attack - * MITRE ATT&CK tactics and techniques related to this finding. - * See: https://attack.mitre.org - * @type \Google\Cloud\SecurityCenter\V2\Access $access - * Access details associated with the finding, such as more information on the - * caller, which method was accessed, and from where. - * @type array<\Google\Cloud\SecurityCenter\V2\Connection>|\Google\Protobuf\Internal\RepeatedField $connections - * Contains information about the IP connection associated with the finding. - * @type string $mute_initiator - * Records additional information about the mute operation, for example, the - * [mute - * configuration](https://cloud.google.com/security-command-center/docs/how-to-mute-findings) - * that muted the finding and the user who muted the finding. - * @type array<\Google\Cloud\SecurityCenter\V2\Process>|\Google\Protobuf\Internal\RepeatedField $processes - * Represents operating system processes associated with the Finding. - * @type array|\Google\Protobuf\Internal\MapField $contacts - * Output only. Map containing the points of contact for the given finding. - * The key represents the type of contact, while the value contains a list of - * all the contacts that pertain. Please refer to: - * https://cloud.google.com/resource-manager/docs/managing-notification-contacts#notification-categories - * { - * "security": { - * "contacts": [ - * { - * "email": "person1@company.com" - * }, - * { - * "email": "person2@company.com" - * } - * ] - * } - * } - * @type array<\Google\Cloud\SecurityCenter\V2\Compliance>|\Google\Protobuf\Internal\RepeatedField $compliances - * Contains compliance information for security standards associated to the - * finding. - * @type string $parent_display_name - * Output only. The human readable display name of the finding source such as - * "Event Threat Detection" or "Security Health Analytics". - * @type string $description - * Contains more details about the finding. - * @type \Google\Cloud\SecurityCenter\V2\Exfiltration $exfiltration - * Represents exfiltrations associated with the finding. - * @type array<\Google\Cloud\SecurityCenter\V2\IamBinding>|\Google\Protobuf\Internal\RepeatedField $iam_bindings - * Represents IAM bindings associated with the finding. - * @type string $next_steps - * Steps to address the finding. - * @type string $module_name - * Unique identifier of the module which generated the finding. - * Example: - * folders/598186756061/securityHealthAnalyticsSettings/customModules/56799441161885 - * @type array<\Google\Cloud\SecurityCenter\V2\Container>|\Google\Protobuf\Internal\RepeatedField $containers - * Containers associated with the finding. This field provides information for - * both Kubernetes and non-Kubernetes containers. - * @type \Google\Cloud\SecurityCenter\V2\Kubernetes $kubernetes - * Kubernetes resources associated with the finding. - * @type \Google\Cloud\SecurityCenter\V2\Database $database - * Database associated with the finding. - * @type \Google\Cloud\SecurityCenter\V2\AttackExposure $attack_exposure - * The results of an attack path simulation relevant to this finding. - * @type array<\Google\Cloud\SecurityCenter\V2\File>|\Google\Protobuf\Internal\RepeatedField $files - * File associated with the finding. - * @type \Google\Cloud\SecurityCenter\V2\CloudDlpInspection $cloud_dlp_inspection - * Cloud Data Loss Prevention (Cloud DLP) inspection results that are - * associated with the finding. - * @type \Google\Cloud\SecurityCenter\V2\CloudDlpDataProfile $cloud_dlp_data_profile - * Cloud DLP data profile that is associated with the finding. - * @type \Google\Cloud\SecurityCenter\V2\KernelRootkit $kernel_rootkit - * Signature of the kernel rootkit. - * @type array<\Google\Cloud\SecurityCenter\V2\OrgPolicy>|\Google\Protobuf\Internal\RepeatedField $org_policies - * Contains information about the org policies associated with the finding. - * @type \Google\Cloud\SecurityCenter\V2\Application $application - * Represents an application associated with the finding. - * @type \Google\Cloud\SecurityCenter\V2\BackupDisasterRecovery $backup_disaster_recovery - * Fields related to Backup and DR findings. - * @type \Google\Cloud\SecurityCenter\V2\SecurityPosture $security_posture - * The security posture associated with the finding. - * @type array<\Google\Cloud\SecurityCenter\V2\LogEntry>|\Google\Protobuf\Internal\RepeatedField $log_entries - * Log entries that are relevant to the finding. - * @type array<\Google\Cloud\SecurityCenter\V2\LoadBalancer>|\Google\Protobuf\Internal\RepeatedField $load_balancers - * The load balancers associated with the finding. - * @type \Google\Cloud\SecurityCenter\V2\CloudArmor $cloud_armor - * Fields related to Cloud Armor findings. - * @type \Google\Cloud\SecurityCenter\V2\Notebook $notebook - * Notebook associated with the finding. - * @type \Google\Cloud\SecurityCenter\V2\ToxicCombination $toxic_combination - * Contains details about a group of security issues that, when the issues - * occur together, represent a greater risk than when the issues occur - * independently. A group of such issues is referred to as a toxic - * combination. - * This field cannot be updated. Its value is ignored in all update requests. - * @type array<\Google\Cloud\SecurityCenter\V2\GroupMembership>|\Google\Protobuf\Internal\RepeatedField $group_memberships - * Contains details about groups of which this finding is a member. A group is - * a collection of findings that are related in some way. - * This field cannot be updated. Its value is ignored in all update requests. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Finding::initOnce(); - parent::__construct($data); - } - - /** - * The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. The following list shows some examples: - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` - * + - * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. The following list shows some examples: - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` - * + - * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. The canonical name of the finding. The following list shows - * some examples: - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` - * + - * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * The prefix is the closest CRM ancestor of the resource associated with the - * finding. - * - * Generated from protobuf field string canonical_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getCanonicalName() - { - return $this->canonical_name; - } - - /** - * Output only. The canonical name of the finding. The following list shows - * some examples: - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` - * + - * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * The prefix is the closest CRM ancestor of the resource associated with the - * finding. - * - * Generated from protobuf field string canonical_name = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setCanonicalName($var) - { - GPBUtil::checkString($var, True); - $this->canonical_name = $var; - - return $this; - } - - /** - * The relative resource name of the source and location the finding belongs - * to. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * This field is immutable after creation time. The following list shows some - * examples: - * + `organizations/{organization_id}/sources/{source_id}` - * + `folders/{folders_id}/sources/{source_id}` - * + `projects/{projects_id}/sources/{source_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}` - * + `folders/{folders_id}/sources/{source_id}/locations/{location_id}` - * + `projects/{projects_id}/sources/{source_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 3; - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * The relative resource name of the source and location the finding belongs - * to. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * This field is immutable after creation time. The following list shows some - * examples: - * + `organizations/{organization_id}/sources/{source_id}` - * + `folders/{folders_id}/sources/{source_id}` - * + `projects/{projects_id}/sources/{source_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}` - * + `folders/{folders_id}/sources/{source_id}/locations/{location_id}` - * + `projects/{projects_id}/sources/{source_id}/locations/{location_id}` - * - * Generated from protobuf field string parent = 3; - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Immutable. For findings on Google Cloud resources, the full resource - * name of the Google Cloud resource this finding is for. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * When the finding is for a non-Google Cloud resource, the resourceName can - * be a customer or partner defined string. - * - * Generated from protobuf field string resource_name = 4 [(.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getResourceName() - { - return $this->resource_name; - } - - /** - * Immutable. For findings on Google Cloud resources, the full resource - * name of the Google Cloud resource this finding is for. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * When the finding is for a non-Google Cloud resource, the resourceName can - * be a customer or partner defined string. - * - * Generated from protobuf field string resource_name = 4 [(.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setResourceName($var) - { - GPBUtil::checkString($var, True); - $this->resource_name = $var; - - return $this; - } - - /** - * Output only. The state of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The state of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Finding\State::class); - $this->state = $var; - - return $this; - } - - /** - * Immutable. The additional taxonomy group within findings from a given - * source. Example: "XSS_FLASH_INJECTION" - * - * Generated from protobuf field string category = 7 [(.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getCategory() - { - return $this->category; - } - - /** - * Immutable. The additional taxonomy group within findings from a given - * source. Example: "XSS_FLASH_INJECTION" - * - * Generated from protobuf field string category = 7 [(.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setCategory($var) - { - GPBUtil::checkString($var, True); - $this->category = $var; - - return $this; - } - - /** - * The URI that, if available, points to a web page outside of Security - * Command Center where additional information about the finding can be found. - * This field is guaranteed to be either empty or a well formed URL. - * - * Generated from protobuf field string external_uri = 8; - * @return string - */ - public function getExternalUri() - { - return $this->external_uri; - } - - /** - * The URI that, if available, points to a web page outside of Security - * Command Center where additional information about the finding can be found. - * This field is guaranteed to be either empty or a well formed URL. - * - * Generated from protobuf field string external_uri = 8; - * @param string $var - * @return $this - */ - public function setExternalUri($var) - { - GPBUtil::checkString($var, True); - $this->external_uri = $var; - - return $this; - } - - /** - * Source specific properties. These properties are managed by the source - * that writes the finding. The key names in the source_properties map must be - * between 1 and 255 characters, and must start with a letter and contain - * alphanumeric characters or underscores only. - * - * Generated from protobuf field map source_properties = 9; - * @return \Google\Protobuf\Internal\MapField - */ - public function getSourceProperties() - { - return $this->source_properties; - } - - /** - * Source specific properties. These properties are managed by the source - * that writes the finding. The key names in the source_properties map must be - * between 1 and 255 characters, and must start with a letter and contain - * alphanumeric characters or underscores only. - * - * Generated from protobuf field map source_properties = 9; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setSourceProperties($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Value::class); - $this->source_properties = $arr; - - return $this; - } - - /** - * Output only. User specified security marks. These marks are entirely - * managed by the user and come from the SecurityMarks resource that belongs - * to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityMarks security_marks = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\SecurityCenter\V2\SecurityMarks|null - */ - public function getSecurityMarks() - { - return $this->security_marks; - } - - public function hasSecurityMarks() - { - return isset($this->security_marks); - } - - public function clearSecurityMarks() - { - unset($this->security_marks); - } - - /** - * Output only. User specified security marks. These marks are entirely - * managed by the user and come from the SecurityMarks resource that belongs - * to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityMarks security_marks = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\SecurityCenter\V2\SecurityMarks $var - * @return $this - */ - public function setSecurityMarks($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\SecurityMarks::class); - $this->security_marks = $var; - - return $this; - } - - /** - * The time the finding was first detected. If an existing finding is updated, - * then this is the time the update occurred. - * For example, if the finding represents an open firewall, this property - * captures the time the detector believes the firewall became open. The - * accuracy is determined by the detector. If the finding is later resolved, - * then this time reflects when the finding was resolved. This must not - * be set to a value greater than the current timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp event_time = 11; - * @return \Google\Protobuf\Timestamp|null - */ - public function getEventTime() - { - return $this->event_time; - } - - public function hasEventTime() - { - return isset($this->event_time); - } - - public function clearEventTime() - { - unset($this->event_time); - } - - /** - * The time the finding was first detected. If an existing finding is updated, - * then this is the time the update occurred. - * For example, if the finding represents an open firewall, this property - * captures the time the detector believes the firewall became open. The - * accuracy is determined by the detector. If the finding is later resolved, - * then this time reflects when the finding was resolved. This must not - * be set to a value greater than the current timestamp. - * - * Generated from protobuf field .google.protobuf.Timestamp event_time = 11; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setEventTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->event_time = $var; - - return $this; - } - - /** - * Output only. The time at which the finding was created in Security Command - * Center. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The time at which the finding was created in Security Command - * Center. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * The severity of the finding. This field is managed by the source that - * writes the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.Severity severity = 14; - * @return int - */ - public function getSeverity() - { - return $this->severity; - } - - /** - * The severity of the finding. This field is managed by the source that - * writes the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.Severity severity = 14; - * @param int $var - * @return $this - */ - public function setSeverity($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Finding\Severity::class); - $this->severity = $var; - - return $this; - } - - /** - * Indicates the mute state of a finding (either muted, unmuted - * or undefined). Unlike other attributes of a finding, a finding provider - * shouldn't set the value of mute. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.Mute mute = 15; - * @return int - */ - public function getMute() - { - return $this->mute; - } - - /** - * Indicates the mute state of a finding (either muted, unmuted - * or undefined). Unlike other attributes of a finding, a finding provider - * shouldn't set the value of mute. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.Mute mute = 15; - * @param int $var - * @return $this - */ - public function setMute($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Finding\Mute::class); - $this->mute = $var; - - return $this; - } - - /** - * The class of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.FindingClass finding_class = 16; - * @return int - */ - public function getFindingClass() - { - return $this->finding_class; - } - - /** - * The class of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.FindingClass finding_class = 16; - * @param int $var - * @return $this - */ - public function setFindingClass($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Finding\FindingClass::class); - $this->finding_class = $var; - - return $this; - } - - /** - * Represents what's commonly known as an *indicator of compromise* (IoC) in - * computer forensics. This is an artifact observed on a network or in an - * operating system that, with high confidence, indicates a computer - * intrusion. For more information, see [Indicator of - * compromise](https://en.wikipedia.org/wiki/Indicator_of_compromise). - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator indicator = 17; - * @return \Google\Cloud\SecurityCenter\V2\Indicator|null - */ - public function getIndicator() - { - return $this->indicator; - } - - public function hasIndicator() - { - return isset($this->indicator); - } - - public function clearIndicator() - { - unset($this->indicator); - } - - /** - * Represents what's commonly known as an *indicator of compromise* (IoC) in - * computer forensics. This is an artifact observed on a network or in an - * operating system that, with high confidence, indicates a computer - * intrusion. For more information, see [Indicator of - * compromise](https://en.wikipedia.org/wiki/Indicator_of_compromise). - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator indicator = 17; - * @param \Google\Cloud\SecurityCenter\V2\Indicator $var - * @return $this - */ - public function setIndicator($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Indicator::class); - $this->indicator = $var; - - return $this; - } - - /** - * Represents vulnerability-specific fields like CVE and CVSS scores. - * CVE stands for Common Vulnerabilities and Exposures - * (https://cve.mitre.org/about/) - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Vulnerability vulnerability = 18; - * @return \Google\Cloud\SecurityCenter\V2\Vulnerability|null - */ - public function getVulnerability() - { - return $this->vulnerability; - } - - public function hasVulnerability() - { - return isset($this->vulnerability); - } - - public function clearVulnerability() - { - unset($this->vulnerability); - } - - /** - * Represents vulnerability-specific fields like CVE and CVSS scores. - * CVE stands for Common Vulnerabilities and Exposures - * (https://cve.mitre.org/about/) - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Vulnerability vulnerability = 18; - * @param \Google\Cloud\SecurityCenter\V2\Vulnerability $var - * @return $this - */ - public function setVulnerability($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Vulnerability::class); - $this->vulnerability = $var; - - return $this; - } - - /** - * Output only. The most recent time this finding was muted or unmuted. - * - * Generated from protobuf field .google.protobuf.Timestamp mute_update_time = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getMuteUpdateTime() - { - return $this->mute_update_time; - } - - public function hasMuteUpdateTime() - { - return isset($this->mute_update_time); - } - - public function clearMuteUpdateTime() - { - unset($this->mute_update_time); - } - - /** - * Output only. The most recent time this finding was muted or unmuted. - * - * Generated from protobuf field .google.protobuf.Timestamp mute_update_time = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setMuteUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->mute_update_time = $var; - - return $this; - } - - /** - * Output only. Third party SIEM/SOAR fields within SCC, contains external - * system information and external system finding fields. - * - * Generated from protobuf field map external_systems = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getExternalSystems() - { - return $this->external_systems; - } - - /** - * Output only. Third party SIEM/SOAR fields within SCC, contains external - * system information and external system finding fields. - * - * Generated from protobuf field map external_systems = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setExternalSystems($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ExternalSystem::class); - $this->external_systems = $arr; - - return $this; - } - - /** - * MITRE ATT&CK tactics and techniques related to this finding. - * See: https://attack.mitre.org - * - * Generated from protobuf field .google.cloud.securitycenter.v2.MitreAttack mitre_attack = 21; - * @return \Google\Cloud\SecurityCenter\V2\MitreAttack|null - */ - public function getMitreAttack() - { - return $this->mitre_attack; - } - - public function hasMitreAttack() - { - return isset($this->mitre_attack); - } - - public function clearMitreAttack() - { - unset($this->mitre_attack); - } - - /** - * MITRE ATT&CK tactics and techniques related to this finding. - * See: https://attack.mitre.org - * - * Generated from protobuf field .google.cloud.securitycenter.v2.MitreAttack mitre_attack = 21; - * @param \Google\Cloud\SecurityCenter\V2\MitreAttack $var - * @return $this - */ - public function setMitreAttack($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\MitreAttack::class); - $this->mitre_attack = $var; - - return $this; - } - - /** - * Access details associated with the finding, such as more information on the - * caller, which method was accessed, and from where. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Access access = 22; - * @return \Google\Cloud\SecurityCenter\V2\Access|null - */ - public function getAccess() - { - return $this->access; - } - - public function hasAccess() - { - return isset($this->access); - } - - public function clearAccess() - { - unset($this->access); - } - - /** - * Access details associated with the finding, such as more information on the - * caller, which method was accessed, and from where. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Access access = 22; - * @param \Google\Cloud\SecurityCenter\V2\Access $var - * @return $this - */ - public function setAccess($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Access::class); - $this->access = $var; - - return $this; - } - - /** - * Contains information about the IP connection associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Connection connections = 23; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getConnections() - { - return $this->connections; - } - - /** - * Contains information about the IP connection associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Connection connections = 23; - * @param array<\Google\Cloud\SecurityCenter\V2\Connection>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setConnections($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Connection::class); - $this->connections = $arr; - - return $this; - } - - /** - * Records additional information about the mute operation, for example, the - * [mute - * configuration](https://cloud.google.com/security-command-center/docs/how-to-mute-findings) - * that muted the finding and the user who muted the finding. - * - * Generated from protobuf field string mute_initiator = 24; - * @return string - */ - public function getMuteInitiator() - { - return $this->mute_initiator; - } - - /** - * Records additional information about the mute operation, for example, the - * [mute - * configuration](https://cloud.google.com/security-command-center/docs/how-to-mute-findings) - * that muted the finding and the user who muted the finding. - * - * Generated from protobuf field string mute_initiator = 24; - * @param string $var - * @return $this - */ - public function setMuteInitiator($var) - { - GPBUtil::checkString($var, True); - $this->mute_initiator = $var; - - return $this; - } - - /** - * Represents operating system processes associated with the Finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Process processes = 25; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getProcesses() - { - return $this->processes; - } - - /** - * Represents operating system processes associated with the Finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Process processes = 25; - * @param array<\Google\Cloud\SecurityCenter\V2\Process>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setProcesses($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Process::class); - $this->processes = $arr; - - return $this; - } - - /** - * Output only. Map containing the points of contact for the given finding. - * The key represents the type of contact, while the value contains a list of - * all the contacts that pertain. Please refer to: - * https://cloud.google.com/resource-manager/docs/managing-notification-contacts#notification-categories - * { - * "security": { - * "contacts": [ - * { - * "email": "person1@company.com" - * }, - * { - * "email": "person2@company.com" - * } - * ] - * } - * } - * - * Generated from protobuf field map contacts = 26 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getContacts() - { - return $this->contacts; - } - - /** - * Output only. Map containing the points of contact for the given finding. - * The key represents the type of contact, while the value contains a list of - * all the contacts that pertain. Please refer to: - * https://cloud.google.com/resource-manager/docs/managing-notification-contacts#notification-categories - * { - * "security": { - * "contacts": [ - * { - * "email": "person1@company.com" - * }, - * { - * "email": "person2@company.com" - * } - * ] - * } - * } - * - * Generated from protobuf field map contacts = 26 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setContacts($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ContactDetails::class); - $this->contacts = $arr; - - return $this; - } - - /** - * Contains compliance information for security standards associated to the - * finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Compliance compliances = 27; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getCompliances() - { - return $this->compliances; - } - - /** - * Contains compliance information for security standards associated to the - * finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Compliance compliances = 27; - * @param array<\Google\Cloud\SecurityCenter\V2\Compliance>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setCompliances($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Compliance::class); - $this->compliances = $arr; - - return $this; - } - - /** - * Output only. The human readable display name of the finding source such as - * "Event Threat Detection" or "Security Health Analytics". - * - * Generated from protobuf field string parent_display_name = 29 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getParentDisplayName() - { - return $this->parent_display_name; - } - - /** - * Output only. The human readable display name of the finding source such as - * "Event Threat Detection" or "Security Health Analytics". - * - * Generated from protobuf field string parent_display_name = 29 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setParentDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->parent_display_name = $var; - - return $this; - } - - /** - * Contains more details about the finding. - * - * Generated from protobuf field string description = 30; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Contains more details about the finding. - * - * Generated from protobuf field string description = 30; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Represents exfiltrations associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Exfiltration exfiltration = 31; - * @return \Google\Cloud\SecurityCenter\V2\Exfiltration|null - */ - public function getExfiltration() - { - return $this->exfiltration; - } - - public function hasExfiltration() - { - return isset($this->exfiltration); - } - - public function clearExfiltration() - { - unset($this->exfiltration); - } - - /** - * Represents exfiltrations associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Exfiltration exfiltration = 31; - * @param \Google\Cloud\SecurityCenter\V2\Exfiltration $var - * @return $this - */ - public function setExfiltration($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Exfiltration::class); - $this->exfiltration = $var; - - return $this; - } - - /** - * Represents IAM bindings associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.IamBinding iam_bindings = 32; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getIamBindings() - { - return $this->iam_bindings; - } - - /** - * Represents IAM bindings associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.IamBinding iam_bindings = 32; - * @param array<\Google\Cloud\SecurityCenter\V2\IamBinding>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setIamBindings($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\IamBinding::class); - $this->iam_bindings = $arr; - - return $this; - } - - /** - * Steps to address the finding. - * - * Generated from protobuf field string next_steps = 33; - * @return string - */ - public function getNextSteps() - { - return $this->next_steps; - } - - /** - * Steps to address the finding. - * - * Generated from protobuf field string next_steps = 33; - * @param string $var - * @return $this - */ - public function setNextSteps($var) - { - GPBUtil::checkString($var, True); - $this->next_steps = $var; - - return $this; - } - - /** - * Unique identifier of the module which generated the finding. - * Example: - * folders/598186756061/securityHealthAnalyticsSettings/customModules/56799441161885 - * - * Generated from protobuf field string module_name = 34; - * @return string - */ - public function getModuleName() - { - return $this->module_name; - } - - /** - * Unique identifier of the module which generated the finding. - * Example: - * folders/598186756061/securityHealthAnalyticsSettings/customModules/56799441161885 - * - * Generated from protobuf field string module_name = 34; - * @param string $var - * @return $this - */ - public function setModuleName($var) - { - GPBUtil::checkString($var, True); - $this->module_name = $var; - - return $this; - } - - /** - * Containers associated with the finding. This field provides information for - * both Kubernetes and non-Kubernetes containers. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Container containers = 35; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getContainers() - { - return $this->containers; - } - - /** - * Containers associated with the finding. This field provides information for - * both Kubernetes and non-Kubernetes containers. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Container containers = 35; - * @param array<\Google\Cloud\SecurityCenter\V2\Container>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setContainers($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Container::class); - $this->containers = $arr; - - return $this; - } - - /** - * Kubernetes resources associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes kubernetes = 36; - * @return \Google\Cloud\SecurityCenter\V2\Kubernetes|null - */ - public function getKubernetes() - { - return $this->kubernetes; - } - - public function hasKubernetes() - { - return isset($this->kubernetes); - } - - public function clearKubernetes() - { - unset($this->kubernetes); - } - - /** - * Kubernetes resources associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes kubernetes = 36; - * @param \Google\Cloud\SecurityCenter\V2\Kubernetes $var - * @return $this - */ - public function setKubernetes($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Kubernetes::class); - $this->kubernetes = $var; - - return $this; - } - - /** - * Database associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Database database = 37; - * @return \Google\Cloud\SecurityCenter\V2\Database|null - */ - public function getDatabase() - { - return $this->database; - } - - public function hasDatabase() - { - return isset($this->database); - } - - public function clearDatabase() - { - unset($this->database); - } - - /** - * Database associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Database database = 37; - * @param \Google\Cloud\SecurityCenter\V2\Database $var - * @return $this - */ - public function setDatabase($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Database::class); - $this->database = $var; - - return $this; - } - - /** - * The results of an attack path simulation relevant to this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.AttackExposure attack_exposure = 38; - * @return \Google\Cloud\SecurityCenter\V2\AttackExposure|null - */ - public function getAttackExposure() - { - return $this->attack_exposure; - } - - public function hasAttackExposure() - { - return isset($this->attack_exposure); - } - - public function clearAttackExposure() - { - unset($this->attack_exposure); - } - - /** - * The results of an attack path simulation relevant to this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.AttackExposure attack_exposure = 38; - * @param \Google\Cloud\SecurityCenter\V2\AttackExposure $var - * @return $this - */ - public function setAttackExposure($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\AttackExposure::class); - $this->attack_exposure = $var; - - return $this; - } - - /** - * File associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.File files = 39; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getFiles() - { - return $this->files; - } - - /** - * File associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.File files = 39; - * @param array<\Google\Cloud\SecurityCenter\V2\File>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setFiles($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\File::class); - $this->files = $arr; - - return $this; - } - - /** - * Cloud Data Loss Prevention (Cloud DLP) inspection results that are - * associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudDlpInspection cloud_dlp_inspection = 40; - * @return \Google\Cloud\SecurityCenter\V2\CloudDlpInspection|null - */ - public function getCloudDlpInspection() - { - return $this->cloud_dlp_inspection; - } - - public function hasCloudDlpInspection() - { - return isset($this->cloud_dlp_inspection); - } - - public function clearCloudDlpInspection() - { - unset($this->cloud_dlp_inspection); - } - - /** - * Cloud Data Loss Prevention (Cloud DLP) inspection results that are - * associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudDlpInspection cloud_dlp_inspection = 40; - * @param \Google\Cloud\SecurityCenter\V2\CloudDlpInspection $var - * @return $this - */ - public function setCloudDlpInspection($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\CloudDlpInspection::class); - $this->cloud_dlp_inspection = $var; - - return $this; - } - - /** - * Cloud DLP data profile that is associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudDlpDataProfile cloud_dlp_data_profile = 41; - * @return \Google\Cloud\SecurityCenter\V2\CloudDlpDataProfile|null - */ - public function getCloudDlpDataProfile() - { - return $this->cloud_dlp_data_profile; - } - - public function hasCloudDlpDataProfile() - { - return isset($this->cloud_dlp_data_profile); - } - - public function clearCloudDlpDataProfile() - { - unset($this->cloud_dlp_data_profile); - } - - /** - * Cloud DLP data profile that is associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudDlpDataProfile cloud_dlp_data_profile = 41; - * @param \Google\Cloud\SecurityCenter\V2\CloudDlpDataProfile $var - * @return $this - */ - public function setCloudDlpDataProfile($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\CloudDlpDataProfile::class); - $this->cloud_dlp_data_profile = $var; - - return $this; - } - - /** - * Signature of the kernel rootkit. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.KernelRootkit kernel_rootkit = 42; - * @return \Google\Cloud\SecurityCenter\V2\KernelRootkit|null - */ - public function getKernelRootkit() - { - return $this->kernel_rootkit; - } - - public function hasKernelRootkit() - { - return isset($this->kernel_rootkit); - } - - public function clearKernelRootkit() - { - unset($this->kernel_rootkit); - } - - /** - * Signature of the kernel rootkit. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.KernelRootkit kernel_rootkit = 42; - * @param \Google\Cloud\SecurityCenter\V2\KernelRootkit $var - * @return $this - */ - public function setKernelRootkit($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\KernelRootkit::class); - $this->kernel_rootkit = $var; - - return $this; - } - - /** - * Contains information about the org policies associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.OrgPolicy org_policies = 43; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getOrgPolicies() - { - return $this->org_policies; - } - - /** - * Contains information about the org policies associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.OrgPolicy org_policies = 43; - * @param array<\Google\Cloud\SecurityCenter\V2\OrgPolicy>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setOrgPolicies($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\OrgPolicy::class); - $this->org_policies = $arr; - - return $this; - } - - /** - * Represents an application associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Application application = 45; - * @return \Google\Cloud\SecurityCenter\V2\Application|null - */ - public function getApplication() - { - return $this->application; - } - - public function hasApplication() - { - return isset($this->application); - } - - public function clearApplication() - { - unset($this->application); - } - - /** - * Represents an application associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Application application = 45; - * @param \Google\Cloud\SecurityCenter\V2\Application $var - * @return $this - */ - public function setApplication($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Application::class); - $this->application = $var; - - return $this; - } - - /** - * Fields related to Backup and DR findings. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.BackupDisasterRecovery backup_disaster_recovery = 47; - * @return \Google\Cloud\SecurityCenter\V2\BackupDisasterRecovery|null - */ - public function getBackupDisasterRecovery() - { - return $this->backup_disaster_recovery; - } - - public function hasBackupDisasterRecovery() - { - return isset($this->backup_disaster_recovery); - } - - public function clearBackupDisasterRecovery() - { - unset($this->backup_disaster_recovery); - } - - /** - * Fields related to Backup and DR findings. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.BackupDisasterRecovery backup_disaster_recovery = 47; - * @param \Google\Cloud\SecurityCenter\V2\BackupDisasterRecovery $var - * @return $this - */ - public function setBackupDisasterRecovery($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\BackupDisasterRecovery::class); - $this->backup_disaster_recovery = $var; - - return $this; - } - - /** - * The security posture associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityPosture security_posture = 48; - * @return \Google\Cloud\SecurityCenter\V2\SecurityPosture|null - */ - public function getSecurityPosture() - { - return $this->security_posture; - } - - public function hasSecurityPosture() - { - return isset($this->security_posture); - } - - public function clearSecurityPosture() - { - unset($this->security_posture); - } - - /** - * The security posture associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityPosture security_posture = 48; - * @param \Google\Cloud\SecurityCenter\V2\SecurityPosture $var - * @return $this - */ - public function setSecurityPosture($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\SecurityPosture::class); - $this->security_posture = $var; - - return $this; - } - - /** - * Log entries that are relevant to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.LogEntry log_entries = 49; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLogEntries() - { - return $this->log_entries; - } - - /** - * Log entries that are relevant to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.LogEntry log_entries = 49; - * @param array<\Google\Cloud\SecurityCenter\V2\LogEntry>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLogEntries($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\LogEntry::class); - $this->log_entries = $arr; - - return $this; - } - - /** - * The load balancers associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.LoadBalancer load_balancers = 50; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLoadBalancers() - { - return $this->load_balancers; - } - - /** - * The load balancers associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.LoadBalancer load_balancers = 50; - * @param array<\Google\Cloud\SecurityCenter\V2\LoadBalancer>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLoadBalancers($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\LoadBalancer::class); - $this->load_balancers = $arr; - - return $this; - } - - /** - * Fields related to Cloud Armor findings. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudArmor cloud_armor = 51; - * @return \Google\Cloud\SecurityCenter\V2\CloudArmor|null - */ - public function getCloudArmor() - { - return $this->cloud_armor; - } - - public function hasCloudArmor() - { - return isset($this->cloud_armor); - } - - public function clearCloudArmor() - { - unset($this->cloud_armor); - } - - /** - * Fields related to Cloud Armor findings. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudArmor cloud_armor = 51; - * @param \Google\Cloud\SecurityCenter\V2\CloudArmor $var - * @return $this - */ - public function setCloudArmor($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\CloudArmor::class); - $this->cloud_armor = $var; - - return $this; - } - - /** - * Notebook associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Notebook notebook = 55; - * @return \Google\Cloud\SecurityCenter\V2\Notebook|null - */ - public function getNotebook() - { - return $this->notebook; - } - - public function hasNotebook() - { - return isset($this->notebook); - } - - public function clearNotebook() - { - unset($this->notebook); - } - - /** - * Notebook associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Notebook notebook = 55; - * @param \Google\Cloud\SecurityCenter\V2\Notebook $var - * @return $this - */ - public function setNotebook($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Notebook::class); - $this->notebook = $var; - - return $this; - } - - /** - * Contains details about a group of security issues that, when the issues - * occur together, represent a greater risk than when the issues occur - * independently. A group of such issues is referred to as a toxic - * combination. - * This field cannot be updated. Its value is ignored in all update requests. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ToxicCombination toxic_combination = 56; - * @return \Google\Cloud\SecurityCenter\V2\ToxicCombination|null - */ - public function getToxicCombination() - { - return $this->toxic_combination; - } - - public function hasToxicCombination() - { - return isset($this->toxic_combination); - } - - public function clearToxicCombination() - { - unset($this->toxic_combination); - } - - /** - * Contains details about a group of security issues that, when the issues - * occur together, represent a greater risk than when the issues occur - * independently. A group of such issues is referred to as a toxic - * combination. - * This field cannot be updated. Its value is ignored in all update requests. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ToxicCombination toxic_combination = 56; - * @param \Google\Cloud\SecurityCenter\V2\ToxicCombination $var - * @return $this - */ - public function setToxicCombination($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ToxicCombination::class); - $this->toxic_combination = $var; - - return $this; - } - - /** - * Contains details about groups of which this finding is a member. A group is - * a collection of findings that are related in some way. - * This field cannot be updated. Its value is ignored in all update requests. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.GroupMembership group_memberships = 57; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getGroupMemberships() - { - return $this->group_memberships; - } - - /** - * Contains details about groups of which this finding is a member. A group is - * a collection of findings that are related in some way. - * This field cannot be updated. Its value is ignored in all update requests. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.GroupMembership group_memberships = 57; - * @param array<\Google\Cloud\SecurityCenter\V2\GroupMembership>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setGroupMemberships($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\GroupMembership::class); - $this->group_memberships = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/FindingClass.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/FindingClass.php deleted file mode 100644 index 371e6709d428..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/FindingClass.php +++ /dev/null @@ -1,103 +0,0 @@ -google.cloud.securitycenter.v2.Finding.FindingClass - */ -class FindingClass -{ - /** - * Unspecified finding class. - * - * Generated from protobuf enum FINDING_CLASS_UNSPECIFIED = 0; - */ - const FINDING_CLASS_UNSPECIFIED = 0; - /** - * Describes unwanted or malicious activity. - * - * Generated from protobuf enum THREAT = 1; - */ - const THREAT = 1; - /** - * Describes a potential weakness in software that increases risk to - * Confidentiality & Integrity & Availability. - * - * Generated from protobuf enum VULNERABILITY = 2; - */ - const VULNERABILITY = 2; - /** - * Describes a potential weakness in cloud resource/asset configuration that - * increases risk. - * - * Generated from protobuf enum MISCONFIGURATION = 3; - */ - const MISCONFIGURATION = 3; - /** - * Describes a security observation that is for informational purposes. - * - * Generated from protobuf enum OBSERVATION = 4; - */ - const OBSERVATION = 4; - /** - * Describes an error that prevents some SCC functionality. - * - * Generated from protobuf enum SCC_ERROR = 5; - */ - const SCC_ERROR = 5; - /** - * Describes a potential security risk due to a change in the security - * posture. - * - * Generated from protobuf enum POSTURE_VIOLATION = 6; - */ - const POSTURE_VIOLATION = 6; - /** - * Describes a combination of security issues that represent a more severe - * security problem when taken together. - * - * Generated from protobuf enum TOXIC_COMBINATION = 7; - */ - const TOXIC_COMBINATION = 7; - - private static $valueToName = [ - self::FINDING_CLASS_UNSPECIFIED => 'FINDING_CLASS_UNSPECIFIED', - self::THREAT => 'THREAT', - self::VULNERABILITY => 'VULNERABILITY', - self::MISCONFIGURATION => 'MISCONFIGURATION', - self::OBSERVATION => 'OBSERVATION', - self::SCC_ERROR => 'SCC_ERROR', - self::POSTURE_VIOLATION => 'POSTURE_VIOLATION', - self::TOXIC_COMBINATION => 'TOXIC_COMBINATION', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(FindingClass::class, \Google\Cloud\SecurityCenter\V2\Finding_FindingClass::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/Mute.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/Mute.php deleted file mode 100644 index 1f10f5dfe266..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/Mute.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.securitycenter.v2.Finding.Mute - */ -class Mute -{ - /** - * Unspecified. - * - * Generated from protobuf enum MUTE_UNSPECIFIED = 0; - */ - const MUTE_UNSPECIFIED = 0; - /** - * Finding has been muted. - * - * Generated from protobuf enum MUTED = 1; - */ - const MUTED = 1; - /** - * Finding has been unmuted. - * - * Generated from protobuf enum UNMUTED = 2; - */ - const UNMUTED = 2; - /** - * Finding has never been muted/unmuted. - * - * Generated from protobuf enum UNDEFINED = 3; - */ - const UNDEFINED = 3; - - private static $valueToName = [ - self::MUTE_UNSPECIFIED => 'MUTE_UNSPECIFIED', - self::MUTED => 'MUTED', - self::UNMUTED => 'UNMUTED', - self::UNDEFINED => 'UNDEFINED', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Mute::class, \Google\Cloud\SecurityCenter\V2\Finding_Mute::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/Severity.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/Severity.php deleted file mode 100644 index 24567f407c53..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/Severity.php +++ /dev/null @@ -1,116 +0,0 @@ -google.cloud.securitycenter.v2.Finding.Severity - */ -class Severity -{ - /** - * This value is used for findings when a source doesn't write a severity - * value. - * - * Generated from protobuf enum SEVERITY_UNSPECIFIED = 0; - */ - const SEVERITY_UNSPECIFIED = 0; - /** - * Vulnerability: - * A critical vulnerability is easily discoverable by an external actor, - * exploitable, and results in the direct ability to execute arbitrary code, - * exfiltrate data, and otherwise gain additional access and privileges to - * cloud resources and workloads. Examples include publicly accessible - * unprotected user data and public SSH access with weak or no - * passwords. - * Threat: - * Indicates a threat that is able to access, modify, or delete data or - * execute unauthorized code within existing resources. - * - * Generated from protobuf enum CRITICAL = 1; - */ - const CRITICAL = 1; - /** - * Vulnerability: - * A high risk vulnerability can be easily discovered and exploited in - * combination with other vulnerabilities in order to gain direct access and - * the ability to execute arbitrary code, exfiltrate data, and otherwise - * gain additional access and privileges to cloud resources and workloads. - * An example is a database with weak or no passwords that is only - * accessible internally. This database could easily be compromised by an - * actor that had access to the internal network. - * Threat: - * Indicates a threat that is able to create new computational resources in - * an environment but not able to access data or execute code in existing - * resources. - * - * Generated from protobuf enum HIGH = 2; - */ - const HIGH = 2; - /** - * Vulnerability: - * A medium risk vulnerability could be used by an actor to gain access to - * resources or privileges that enable them to eventually (through multiple - * steps or a complex exploit) gain access and the ability to execute - * arbitrary code or exfiltrate data. An example is a service account with - * access to more projects than it should have. If an actor gains access to - * the service account, they could potentially use that access to manipulate - * a project the service account was not intended to. - * Threat: - * Indicates a threat that is able to cause operational impact but may not - * access data or execute unauthorized code. - * - * Generated from protobuf enum MEDIUM = 3; - */ - const MEDIUM = 3; - /** - * Vulnerability: - * A low risk vulnerability hampers a security organization's ability to - * detect vulnerabilities or active threats in their deployment, or prevents - * the root cause investigation of security issues. An example is monitoring - * and logs being disabled for resource configurations and access. - * Threat: - * Indicates a threat that has obtained minimal access to an environment but - * is not able to access data, execute code, or create resources. - * - * Generated from protobuf enum LOW = 4; - */ - const LOW = 4; - - private static $valueToName = [ - self::SEVERITY_UNSPECIFIED => 'SEVERITY_UNSPECIFIED', - self::CRITICAL => 'CRITICAL', - self::HIGH => 'HIGH', - self::MEDIUM => 'MEDIUM', - self::LOW => 'LOW', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Severity::class, \Google\Cloud\SecurityCenter\V2\Finding_Severity::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/State.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/State.php deleted file mode 100644 index 2638592fa61a..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Finding/State.php +++ /dev/null @@ -1,65 +0,0 @@ -google.cloud.securitycenter.v2.Finding.State - */ -class State -{ - /** - * Unspecified state. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The finding requires attention and has not been addressed yet. - * - * Generated from protobuf enum ACTIVE = 1; - */ - const ACTIVE = 1; - /** - * The finding has been fixed, triaged as a non-issue or otherwise addressed - * and is no longer active. - * - * Generated from protobuf enum INACTIVE = 2; - */ - const INACTIVE = 2; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - self::INACTIVE => 'INACTIVE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(State::class, \Google\Cloud\SecurityCenter\V2\Finding_State::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Geolocation.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Geolocation.php deleted file mode 100644 index 7b27b438ecde..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Geolocation.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.securitycenter.v2.Geolocation - */ -class Geolocation extends \Google\Protobuf\Internal\Message -{ - /** - * A CLDR. - * - * Generated from protobuf field string region_code = 1; - */ - protected $region_code = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $region_code - * A CLDR. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Access::initOnce(); - parent::__construct($data); - } - - /** - * A CLDR. - * - * Generated from protobuf field string region_code = 1; - * @return string - */ - public function getRegionCode() - { - return $this->region_code; - } - - /** - * A CLDR. - * - * Generated from protobuf field string region_code = 1; - * @param string $var - * @return $this - */ - public function setRegionCode($var) - { - GPBUtil::checkString($var, True); - $this->region_code = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetBigQueryExportRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetBigQueryExportRequest.php deleted file mode 100644 index f0ea3c80ccba..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetBigQueryExportRequest.php +++ /dev/null @@ -1,107 +0,0 @@ -google.cloud.securitycenter.v2.GetBigQueryExportRequest - */ -class GetBigQueryExportRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the BigQuery export to retrieve. The following list shows - * some examples of the format: - * + - * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` - * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` - * + `projects/{project}locations/{location}//bigQueryExports/{export_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the BigQuery export to retrieve. The following list shows - * some examples of the format: - * - * + - * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` - * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` - * + `projects/{project}locations/{location}//bigQueryExports/{export_id}` - * Please see {@see SecurityCenterClient::bigQueryExportName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V2\GetBigQueryExportRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the BigQuery export to retrieve. The following list shows - * some examples of the format: - * + - * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` - * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` - * + `projects/{project}locations/{location}//bigQueryExports/{export_id}` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the BigQuery export to retrieve. The following list shows - * some examples of the format: - * + - * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` - * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` - * + `projects/{project}locations/{location}//bigQueryExports/{export_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the BigQuery export to retrieve. The following list shows - * some examples of the format: - * + - * `organizations/{organization}/locations/{location}/bigQueryExports/{export_id}` - * + `folders/{folder}/locations/{location}/bigQueryExports/{export_id}` - * + `projects/{project}locations/{location}//bigQueryExports/{export_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetMuteConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetMuteConfigRequest.php deleted file mode 100644 index 654e9634e259..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetMuteConfigRequest.php +++ /dev/null @@ -1,123 +0,0 @@ -google.cloud.securitycenter.v2.GetMuteConfigRequest - */ -class GetMuteConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the mute config to retrieve. The following list shows - * some examples of the format: - * + `organizations/{organization}/muteConfigs/{config_id}` - * + - * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` - * + `folders/{folder}/muteConfigs/{config_id}` - * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` - * + `projects/{project}/muteConfigs/{config_id}` - * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the mute config to retrieve. The following list shows - * some examples of the format: - * - * + `organizations/{organization}/muteConfigs/{config_id}` - * + - * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` - * + `folders/{folder}/muteConfigs/{config_id}` - * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` - * + `projects/{project}/muteConfigs/{config_id}` - * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` - * Please see {@see SecurityCenterClient::muteConfigName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V2\GetMuteConfigRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the mute config to retrieve. The following list shows - * some examples of the format: - * + `organizations/{organization}/muteConfigs/{config_id}` - * + - * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` - * + `folders/{folder}/muteConfigs/{config_id}` - * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` - * + `projects/{project}/muteConfigs/{config_id}` - * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the mute config to retrieve. The following list shows - * some examples of the format: - * + `organizations/{organization}/muteConfigs/{config_id}` - * + - * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` - * + `folders/{folder}/muteConfigs/{config_id}` - * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` - * + `projects/{project}/muteConfigs/{config_id}` - * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the mute config to retrieve. The following list shows - * some examples of the format: - * + `organizations/{organization}/muteConfigs/{config_id}` - * + - * `organizations/{organization}/locations/{location}/muteConfigs/{config_id}` - * + `folders/{folder}/muteConfigs/{config_id}` - * + `folders/{folder}/locations/{location}/muteConfigs/{config_id}` - * + `projects/{project}/muteConfigs/{config_id}` - * + `projects/{project}/locations/{location}/muteConfigs/{config_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetNotificationConfigRequest.php deleted file mode 100644 index 5199b55491b9..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetNotificationConfigRequest.php +++ /dev/null @@ -1,117 +0,0 @@ -google.cloud.securitycenter.v2.GetNotificationConfigRequest - */ -class GetNotificationConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the notification config to get. The following list shows - * some examples of the format: - * + - * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` - * + - * `folders/[folder_id]/locations/[location_id]/notificationConfigs/[config_id]` - * + - * `projects/[project_id]/locations/[location_id]/notificationConfigs/[config_id]` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the notification config to get. The following list shows - * some examples of the format: - * - * + - * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` - * + - * `folders/[folder_id]/locations/[location_id]/notificationConfigs/[config_id]` - * + - * `projects/[project_id]/locations/[location_id]/notificationConfigs/[config_id]` - * Please see {@see SecurityCenterClient::notificationConfigName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V2\GetNotificationConfigRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the notification config to get. The following list shows - * some examples of the format: - * + - * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` - * + - * `folders/[folder_id]/locations/[location_id]/notificationConfigs/[config_id]` - * + - * `projects/[project_id]/locations/[location_id]/notificationConfigs/[config_id]` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the notification config to get. The following list shows - * some examples of the format: - * + - * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` - * + - * `folders/[folder_id]/locations/[location_id]/notificationConfigs/[config_id]` - * + - * `projects/[project_id]/locations/[location_id]/notificationConfigs/[config_id]` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the notification config to get. The following list shows - * some examples of the format: - * + - * `organizations/[organization_id]/locations/[location_id]/notificationConfigs/[config_id]` - * + - * `folders/[folder_id]/locations/[location_id]/notificationConfigs/[config_id]` - * + - * `projects/[project_id]/locations/[location_id]/notificationConfigs/[config_id]` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetResourceValueConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetResourceValueConfigRequest.php deleted file mode 100644 index cd092f990b0f..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetResourceValueConfigRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.securitycenter.v2.GetResourceValueConfigRequest - */ -class GetResourceValueConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the resource value config to retrieve. Its format is - * organizations/{organization}/resourceValueConfigs/{config_id}. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Name of the resource value config to retrieve. Its format is - * organizations/{organization}/resourceValueConfigs/{config_id}. Please see - * {@see SecurityCenterClient::resourceValueConfigName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V2\GetResourceValueConfigRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Name of the resource value config to retrieve. Its format is - * organizations/{organization}/resourceValueConfigs/{config_id}. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the resource value config to retrieve. Its format is - * organizations/{organization}/resourceValueConfigs/{config_id}. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Name of the resource value config to retrieve. Its format is - * organizations/{organization}/resourceValueConfigs/{config_id}. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetSimulationRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetSimulationRequest.php deleted file mode 100644 index 48849de351ad..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetSimulationRequest.php +++ /dev/null @@ -1,99 +0,0 @@ -google.cloud.securitycenter.v2.GetSimulationRequest - */ -class GetSimulationRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The organization name or simulation name of this simulation - * Valid format: - * "organizations/{organization}/simulations/latest" - * "organizations/{organization}/simulations/{simulation}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The organization name or simulation name of this simulation - * - * Valid format: - * "organizations/{organization}/simulations/latest" - * "organizations/{organization}/simulations/{simulation}" - * Please see {@see SecurityCenterClient::simulationName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V2\GetSimulationRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The organization name or simulation name of this simulation - * Valid format: - * "organizations/{organization}/simulations/latest" - * "organizations/{organization}/simulations/{simulation}" - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The organization name or simulation name of this simulation - * Valid format: - * "organizations/{organization}/simulations/latest" - * "organizations/{organization}/simulations/{simulation}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The organization name or simulation name of this simulation - * Valid format: - * "organizations/{organization}/simulations/latest" - * "organizations/{organization}/simulations/{simulation}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetSourceRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetSourceRequest.php deleted file mode 100644 index cd90dcc92cf9..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetSourceRequest.php +++ /dev/null @@ -1,86 +0,0 @@ -google.cloud.securitycenter.v2.GetSourceRequest - */ -class GetSourceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Relative resource name of the source. Its format is - * "organizations/[organization_id]/source/[source_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. Relative resource name of the source. Its format is - * "organizations/[organization_id]/source/[source_id]". Please see - * {@see SecurityCenterClient::sourceName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V2\GetSourceRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Relative resource name of the source. Its format is - * "organizations/[organization_id]/source/[source_id]". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Relative resource name of the source. Its format is - * "organizations/[organization_id]/source/[source_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Relative resource name of the source. Its format is - * "organizations/[organization_id]/source/[source_id]". - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetValuedResourceRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetValuedResourceRequest.php deleted file mode 100644 index fae32a7a0a52..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GetValuedResourceRequest.php +++ /dev/null @@ -1,92 +0,0 @@ -google.cloud.securitycenter.v2.GetValuedResourceRequest - */ -class GetValuedResourceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of this valued resource - * Valid format: - * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The name of this valued resource - * - * Valid format: - * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" - * Please see {@see SecurityCenterClient::valuedResourceName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V2\GetValuedResourceRequest - * - * @experimental - */ - public static function build(string $name): self - { - return (new self()) - ->setName($name); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of this valued resource - * Valid format: - * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of this valued resource - * Valid format: - * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The name of this valued resource - * Valid format: - * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupFindingsRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupFindingsRequest.php deleted file mode 100644 index 1ab125053017..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupFindingsRequest.php +++ /dev/null @@ -1,473 +0,0 @@ -google.cloud.securitycenter.v2.GroupFindingsRequest - */ -class GroupFindingsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the source to groupBy. If no location is specified, - * finding is assumed to be in global. - * The following list shows some examples: - * + `organizations/[organization_id]/sources/[source_id]` - * + - * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` - * + `folders/[folder_id]/sources/[source_id]` - * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` - * + `projects/[project_id]/sources/[source_id]` - * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` - * To groupBy across all sources provide a source_id of `-`. The following - * list shows some examples: - * + `organizations/{organization_id}/sources/-` - * + `organizations/{organization_id}/sources/-/locations/[location_id]` - * + `folders/{folder_id}/sources/-` - * + `folders/{folder_id}/sources/-/locations/[location_id]` - * + `projects/{project_id}/sources/-` - * + `projects/{project_id}/sources/-/locations/[location_id]` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * severity: `=`, `:` - * * security_marks.marks: `=`, `:` - * * resource: - * * resource.name: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.type: `=`, `:` - * - * Generated from protobuf field string filter = 2; - */ - protected $filter = ''; - /** - * Required. Expression that defines what assets fields to use for grouping. - * The string value should follow SQL syntax: comma separated list of fields. - * For example: "parent,resource_name". - * - * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $group_by = ''; - /** - * The value returned by the last `GroupFindingsResponse`; indicates - * that this is a continuation of a prior `GroupFindings` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 7; - */ - protected $page_token = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 8; - */ - protected $page_size = 0; - - /** - * @param string $parent Required. Name of the source to groupBy. If no location is specified, - * finding is assumed to be in global. - * The following list shows some examples: - * - * + `organizations/[organization_id]/sources/[source_id]` - * + - * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` - * + `folders/[folder_id]/sources/[source_id]` - * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` - * + `projects/[project_id]/sources/[source_id]` - * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` - * - * To groupBy across all sources provide a source_id of `-`. The following - * list shows some examples: - * - * + `organizations/{organization_id}/sources/-` - * + `organizations/{organization_id}/sources/-/locations/[location_id]` - * + `folders/{folder_id}/sources/-` - * + `folders/{folder_id}/sources/-/locations/[location_id]` - * + `projects/{project_id}/sources/-` - * + `projects/{project_id}/sources/-/locations/[location_id]` - * Please see {@see SecurityCenterClient::sourceName()} for help formatting this field. - * @param string $groupBy Required. Expression that defines what assets fields to use for grouping. - * The string value should follow SQL syntax: comma separated list of fields. - * For example: "parent,resource_name". - * - * @return \Google\Cloud\SecurityCenter\V2\GroupFindingsRequest - * - * @experimental - */ - public static function build(string $parent, string $groupBy): self - { - return (new self()) - ->setParent($parent) - ->setGroupBy($groupBy); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Name of the source to groupBy. If no location is specified, - * finding is assumed to be in global. - * The following list shows some examples: - * + `organizations/[organization_id]/sources/[source_id]` - * + - * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` - * + `folders/[folder_id]/sources/[source_id]` - * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` - * + `projects/[project_id]/sources/[source_id]` - * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` - * To groupBy across all sources provide a source_id of `-`. The following - * list shows some examples: - * + `organizations/{organization_id}/sources/-` - * + `organizations/{organization_id}/sources/-/locations/[location_id]` - * + `folders/{folder_id}/sources/-` - * + `folders/{folder_id}/sources/-/locations/[location_id]` - * + `projects/{project_id}/sources/-` - * + `projects/{project_id}/sources/-/locations/[location_id]` - * @type string $filter - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * severity: `=`, `:` - * * security_marks.marks: `=`, `:` - * * resource: - * * resource.name: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.type: `=`, `:` - * @type string $group_by - * Required. Expression that defines what assets fields to use for grouping. - * The string value should follow SQL syntax: comma separated list of fields. - * For example: "parent,resource_name". - * @type string $page_token - * The value returned by the last `GroupFindingsResponse`; indicates - * that this is a continuation of a prior `GroupFindings` call, and - * that the system should return the next page of data. - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the source to groupBy. If no location is specified, - * finding is assumed to be in global. - * The following list shows some examples: - * + `organizations/[organization_id]/sources/[source_id]` - * + - * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` - * + `folders/[folder_id]/sources/[source_id]` - * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` - * + `projects/[project_id]/sources/[source_id]` - * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` - * To groupBy across all sources provide a source_id of `-`. The following - * list shows some examples: - * + `organizations/{organization_id}/sources/-` - * + `organizations/{organization_id}/sources/-/locations/[location_id]` - * + `folders/{folder_id}/sources/-` - * + `folders/{folder_id}/sources/-/locations/[location_id]` - * + `projects/{project_id}/sources/-` - * + `projects/{project_id}/sources/-/locations/[location_id]` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Name of the source to groupBy. If no location is specified, - * finding is assumed to be in global. - * The following list shows some examples: - * + `organizations/[organization_id]/sources/[source_id]` - * + - * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` - * + `folders/[folder_id]/sources/[source_id]` - * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` - * + `projects/[project_id]/sources/[source_id]` - * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` - * To groupBy across all sources provide a source_id of `-`. The following - * list shows some examples: - * + `organizations/{organization_id}/sources/-` - * + `organizations/{organization_id}/sources/-/locations/[location_id]` - * + `folders/{folder_id}/sources/-` - * + `folders/{folder_id}/sources/-/locations/[location_id]` - * + `projects/{project_id}/sources/-` - * + `projects/{project_id}/sources/-/locations/[location_id]` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * severity: `=`, `:` - * * security_marks.marks: `=`, `:` - * * resource: - * * resource.name: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.type: `=`, `:` - * - * Generated from protobuf field string filter = 2; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * severity: `=`, `:` - * * security_marks.marks: `=`, `:` - * * resource: - * * resource.name: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.type: `=`, `:` - * - * Generated from protobuf field string filter = 2; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Required. Expression that defines what assets fields to use for grouping. - * The string value should follow SQL syntax: comma separated list of fields. - * For example: "parent,resource_name". - * - * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getGroupBy() - { - return $this->group_by; - } - - /** - * Required. Expression that defines what assets fields to use for grouping. - * The string value should follow SQL syntax: comma separated list of fields. - * For example: "parent,resource_name". - * - * Generated from protobuf field string group_by = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setGroupBy($var) - { - GPBUtil::checkString($var, True); - $this->group_by = $var; - - return $this; - } - - /** - * The value returned by the last `GroupFindingsResponse`; indicates - * that this is a continuation of a prior `GroupFindings` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 7; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `GroupFindingsResponse`; indicates - * that this is a continuation of a prior `GroupFindings` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 7; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 8; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 8; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupFindingsResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupFindingsResponse.php deleted file mode 100644 index 7a788afbb0c1..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupFindingsResponse.php +++ /dev/null @@ -1,147 +0,0 @@ -google.cloud.securitycenter.v2.GroupFindingsResponse - */ -class GroupFindingsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.GroupResult group_by_results = 1; - */ - private $group_by_results; - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - */ - protected $next_page_token = ''; - /** - * The total number of results matching the query. - * - * Generated from protobuf field int32 total_size = 4; - */ - protected $total_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V2\GroupResult>|\Google\Protobuf\Internal\RepeatedField $group_by_results - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * @type string $next_page_token - * Token to retrieve the next page of results, or empty if there are no more - * results. - * @type int $total_size - * The total number of results matching the query. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.GroupResult group_by_results = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getGroupByResults() - { - return $this->group_by_results; - } - - /** - * Group results. There exists an element for each existing unique - * combination of property/values. The element contains a count for the number - * of times those specific property/values appear. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.GroupResult group_by_results = 1; - * @param array<\Google\Cloud\SecurityCenter\V2\GroupResult>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setGroupByResults($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\GroupResult::class); - $this->group_by_results = $arr; - - return $this; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * The total number of results matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @return int - */ - public function getTotalSize() - { - return $this->total_size; - } - - /** - * The total number of results matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @param int $var - * @return $this - */ - public function setTotalSize($var) - { - GPBUtil::checkInt32($var); - $this->total_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupMembership.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupMembership.php deleted file mode 100644 index 0aa6e9447a72..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupMembership.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.securitycenter.v2.GroupMembership - */ -class GroupMembership extends \Google\Protobuf\Internal\Message -{ - /** - * Type of group. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.GroupMembership.GroupType group_type = 1; - */ - protected $group_type = 0; - /** - * ID of the group. - * - * Generated from protobuf field string group_id = 2; - */ - protected $group_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $group_type - * Type of group. - * @type string $group_id - * ID of the group. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\GroupMembership::initOnce(); - parent::__construct($data); - } - - /** - * Type of group. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.GroupMembership.GroupType group_type = 1; - * @return int - */ - public function getGroupType() - { - return $this->group_type; - } - - /** - * Type of group. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.GroupMembership.GroupType group_type = 1; - * @param int $var - * @return $this - */ - public function setGroupType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\GroupMembership\GroupType::class); - $this->group_type = $var; - - return $this; - } - - /** - * ID of the group. - * - * Generated from protobuf field string group_id = 2; - * @return string - */ - public function getGroupId() - { - return $this->group_id; - } - - /** - * ID of the group. - * - * Generated from protobuf field string group_id = 2; - * @param string $var - * @return $this - */ - public function setGroupId($var) - { - GPBUtil::checkString($var, True); - $this->group_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupMembership/GroupType.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupMembership/GroupType.php deleted file mode 100644 index 669e285de554..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupMembership/GroupType.php +++ /dev/null @@ -1,57 +0,0 @@ -google.cloud.securitycenter.v2.GroupMembership.GroupType - */ -class GroupType -{ - /** - * Default value. - * - * Generated from protobuf enum GROUP_TYPE_UNSPECIFIED = 0; - */ - const GROUP_TYPE_UNSPECIFIED = 0; - /** - * Group represents a toxic combination. - * - * Generated from protobuf enum GROUP_TYPE_TOXIC_COMBINATION = 1; - */ - const GROUP_TYPE_TOXIC_COMBINATION = 1; - - private static $valueToName = [ - self::GROUP_TYPE_UNSPECIFIED => 'GROUP_TYPE_UNSPECIFIED', - self::GROUP_TYPE_TOXIC_COMBINATION => 'GROUP_TYPE_TOXIC_COMBINATION', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(GroupType::class, \Google\Cloud\SecurityCenter\V2\GroupMembership_GroupType::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupResult.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupResult.php deleted file mode 100644 index 967cde22d6ee..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/GroupResult.php +++ /dev/null @@ -1,101 +0,0 @@ -google.cloud.securitycenter.v2.GroupResult - */ -class GroupResult extends \Google\Protobuf\Internal\Message -{ - /** - * Properties matching the groupBy fields in the request. - * - * Generated from protobuf field map properties = 1; - */ - private $properties; - /** - * Total count of resources for the given properties. - * - * Generated from protobuf field int64 count = 2; - */ - protected $count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\MapField $properties - * Properties matching the groupBy fields in the request. - * @type int|string $count - * Total count of resources for the given properties. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Properties matching the groupBy fields in the request. - * - * Generated from protobuf field map properties = 1; - * @return \Google\Protobuf\Internal\MapField - */ - public function getProperties() - { - return $this->properties; - } - - /** - * Properties matching the groupBy fields in the request. - * - * Generated from protobuf field map properties = 1; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setProperties($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Value::class); - $this->properties = $arr; - - return $this; - } - - /** - * Total count of resources for the given properties. - * - * Generated from protobuf field int64 count = 2; - * @return int|string - */ - public function getCount() - { - return $this->count; - } - - /** - * Total count of resources for the given properties. - * - * Generated from protobuf field int64 count = 2; - * @param int|string $var - * @return $this - */ - public function setCount($var) - { - GPBUtil::checkInt64($var); - $this->count = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/IamBinding.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/IamBinding.php deleted file mode 100644 index ad104e3b8b40..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/IamBinding.php +++ /dev/null @@ -1,144 +0,0 @@ -google.cloud.securitycenter.v2.IamBinding - */ -class IamBinding extends \Google\Protobuf\Internal\Message -{ - /** - * The action that was performed on a Binding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.IamBinding.Action action = 1; - */ - protected $action = 0; - /** - * Role that is assigned to "members". - * For example, "roles/viewer", "roles/editor", or "roles/owner". - * - * Generated from protobuf field string role = 2; - */ - protected $role = ''; - /** - * A single identity requesting access for a Cloud Platform resource, for - * example, "foo@google.com". - * - * Generated from protobuf field string member = 3; - */ - protected $member = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $action - * The action that was performed on a Binding. - * @type string $role - * Role that is assigned to "members". - * For example, "roles/viewer", "roles/editor", or "roles/owner". - * @type string $member - * A single identity requesting access for a Cloud Platform resource, for - * example, "foo@google.com". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\IamBinding::initOnce(); - parent::__construct($data); - } - - /** - * The action that was performed on a Binding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.IamBinding.Action action = 1; - * @return int - */ - public function getAction() - { - return $this->action; - } - - /** - * The action that was performed on a Binding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.IamBinding.Action action = 1; - * @param int $var - * @return $this - */ - public function setAction($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\IamBinding\Action::class); - $this->action = $var; - - return $this; - } - - /** - * Role that is assigned to "members". - * For example, "roles/viewer", "roles/editor", or "roles/owner". - * - * Generated from protobuf field string role = 2; - * @return string - */ - public function getRole() - { - return $this->role; - } - - /** - * Role that is assigned to "members". - * For example, "roles/viewer", "roles/editor", or "roles/owner". - * - * Generated from protobuf field string role = 2; - * @param string $var - * @return $this - */ - public function setRole($var) - { - GPBUtil::checkString($var, True); - $this->role = $var; - - return $this; - } - - /** - * A single identity requesting access for a Cloud Platform resource, for - * example, "foo@google.com". - * - * Generated from protobuf field string member = 3; - * @return string - */ - public function getMember() - { - return $this->member; - } - - /** - * A single identity requesting access for a Cloud Platform resource, for - * example, "foo@google.com". - * - * Generated from protobuf field string member = 3; - * @param string $var - * @return $this - */ - public function setMember($var) - { - GPBUtil::checkString($var, True); - $this->member = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/IamBinding/Action.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/IamBinding/Action.php deleted file mode 100644 index a202e95ac477..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/IamBinding/Action.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.securitycenter.v2.IamBinding.Action - */ -class Action -{ - /** - * Unspecified. - * - * Generated from protobuf enum ACTION_UNSPECIFIED = 0; - */ - const ACTION_UNSPECIFIED = 0; - /** - * Addition of a Binding. - * - * Generated from protobuf enum ADD = 1; - */ - const ADD = 1; - /** - * Removal of a Binding. - * - * Generated from protobuf enum REMOVE = 2; - */ - const REMOVE = 2; - - private static $valueToName = [ - self::ACTION_UNSPECIFIED => 'ACTION_UNSPECIFIED', - self::ADD => 'ADD', - self::REMOVE => 'REMOVE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Action::class, \Google\Cloud\SecurityCenter\V2\IamBinding_Action::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator.php deleted file mode 100644 index cee7a882ad65..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator.php +++ /dev/null @@ -1,177 +0,0 @@ -google.cloud.securitycenter.v2.Indicator - */ -class Indicator extends \Google\Protobuf\Internal\Message -{ - /** - * The list of IP addresses that are associated with the finding. - * - * Generated from protobuf field repeated string ip_addresses = 1; - */ - private $ip_addresses; - /** - * List of domains associated to the Finding. - * - * Generated from protobuf field repeated string domains = 2; - */ - private $domains; - /** - * The list of matched signatures indicating that the given - * process is present in the environment. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Indicator.ProcessSignature signatures = 3; - */ - private $signatures; - /** - * The list of URIs associated to the Findings. - * - * Generated from protobuf field repeated string uris = 4; - */ - private $uris; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\RepeatedField $ip_addresses - * The list of IP addresses that are associated with the finding. - * @type array|\Google\Protobuf\Internal\RepeatedField $domains - * List of domains associated to the Finding. - * @type array<\Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature>|\Google\Protobuf\Internal\RepeatedField $signatures - * The list of matched signatures indicating that the given - * process is present in the environment. - * @type array|\Google\Protobuf\Internal\RepeatedField $uris - * The list of URIs associated to the Findings. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Indicator::initOnce(); - parent::__construct($data); - } - - /** - * The list of IP addresses that are associated with the finding. - * - * Generated from protobuf field repeated string ip_addresses = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getIpAddresses() - { - return $this->ip_addresses; - } - - /** - * The list of IP addresses that are associated with the finding. - * - * Generated from protobuf field repeated string ip_addresses = 1; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setIpAddresses($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->ip_addresses = $arr; - - return $this; - } - - /** - * List of domains associated to the Finding. - * - * Generated from protobuf field repeated string domains = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDomains() - { - return $this->domains; - } - - /** - * List of domains associated to the Finding. - * - * Generated from protobuf field repeated string domains = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDomains($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->domains = $arr; - - return $this; - } - - /** - * The list of matched signatures indicating that the given - * process is present in the environment. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Indicator.ProcessSignature signatures = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSignatures() - { - return $this->signatures; - } - - /** - * The list of matched signatures indicating that the given - * process is present in the environment. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Indicator.ProcessSignature signatures = 3; - * @param array<\Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSignatures($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature::class); - $this->signatures = $arr; - - return $this; - } - - /** - * The list of URIs associated to the Findings. - * - * Generated from protobuf field repeated string uris = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getUris() - { - return $this->uris; - } - - /** - * The list of URIs associated to the Findings. - * - * Generated from protobuf field repeated string uris = 4; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setUris($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->uris = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature.php deleted file mode 100644 index 8841ee7d687f..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature.php +++ /dev/null @@ -1,145 +0,0 @@ -google.cloud.securitycenter.v2.Indicator.ProcessSignature - */ -class ProcessSignature extends \Google\Protobuf\Internal\Message -{ - /** - * Describes the type of resource associated with the signature. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator.ProcessSignature.SignatureType signature_type = 8; - */ - protected $signature_type = 0; - protected $signature; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\MemoryHashSignature $memory_hash_signature - * Signature indicating that a binary family was matched. - * @type \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\YaraRuleSignature $yara_rule_signature - * Signature indicating that a YARA rule was matched. - * @type int $signature_type - * Describes the type of resource associated with the signature. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Indicator::initOnce(); - parent::__construct($data); - } - - /** - * Signature indicating that a binary family was matched. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator.ProcessSignature.MemoryHashSignature memory_hash_signature = 6; - * @return \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\MemoryHashSignature|null - */ - public function getMemoryHashSignature() - { - return $this->readOneof(6); - } - - public function hasMemoryHashSignature() - { - return $this->hasOneof(6); - } - - /** - * Signature indicating that a binary family was matched. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator.ProcessSignature.MemoryHashSignature memory_hash_signature = 6; - * @param \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\MemoryHashSignature $var - * @return $this - */ - public function setMemoryHashSignature($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\MemoryHashSignature::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * Signature indicating that a YARA rule was matched. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator.ProcessSignature.YaraRuleSignature yara_rule_signature = 7; - * @return \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\YaraRuleSignature|null - */ - public function getYaraRuleSignature() - { - return $this->readOneof(7); - } - - public function hasYaraRuleSignature() - { - return $this->hasOneof(7); - } - - /** - * Signature indicating that a YARA rule was matched. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator.ProcessSignature.YaraRuleSignature yara_rule_signature = 7; - * @param \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\YaraRuleSignature $var - * @return $this - */ - public function setYaraRuleSignature($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\YaraRuleSignature::class); - $this->writeOneof(7, $var); - - return $this; - } - - /** - * Describes the type of resource associated with the signature. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator.ProcessSignature.SignatureType signature_type = 8; - * @return int - */ - public function getSignatureType() - { - return $this->signature_type; - } - - /** - * Describes the type of resource associated with the signature. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Indicator.ProcessSignature.SignatureType signature_type = 8; - * @param int $var - * @return $this - */ - public function setSignatureType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\SignatureType::class); - $this->signature_type = $var; - - return $this; - } - - /** - * @return string - */ - public function getSignature() - { - return $this->whichOneof("signature"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ProcessSignature::class, \Google\Cloud\SecurityCenter\V2\Indicator_ProcessSignature::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/MemoryHashSignature.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/MemoryHashSignature.php deleted file mode 100644 index ca33f9a35908..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/MemoryHashSignature.php +++ /dev/null @@ -1,108 +0,0 @@ -google.cloud.securitycenter.v2.Indicator.ProcessSignature.MemoryHashSignature - */ -class MemoryHashSignature extends \Google\Protobuf\Internal\Message -{ - /** - * The binary family. - * - * Generated from protobuf field string binary_family = 1; - */ - protected $binary_family = ''; - /** - * The list of memory hash detections contributing to the binary family - * match. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Indicator.ProcessSignature.MemoryHashSignature.Detection detections = 4; - */ - private $detections; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $binary_family - * The binary family. - * @type array<\Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\MemoryHashSignature\Detection>|\Google\Protobuf\Internal\RepeatedField $detections - * The list of memory hash detections contributing to the binary family - * match. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Indicator::initOnce(); - parent::__construct($data); - } - - /** - * The binary family. - * - * Generated from protobuf field string binary_family = 1; - * @return string - */ - public function getBinaryFamily() - { - return $this->binary_family; - } - - /** - * The binary family. - * - * Generated from protobuf field string binary_family = 1; - * @param string $var - * @return $this - */ - public function setBinaryFamily($var) - { - GPBUtil::checkString($var, True); - $this->binary_family = $var; - - return $this; - } - - /** - * The list of memory hash detections contributing to the binary family - * match. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Indicator.ProcessSignature.MemoryHashSignature.Detection detections = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getDetections() - { - return $this->detections; - } - - /** - * The list of memory hash detections contributing to the binary family - * match. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Indicator.ProcessSignature.MemoryHashSignature.Detection detections = 4; - * @param array<\Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\MemoryHashSignature\Detection>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setDetections($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Indicator\ProcessSignature\MemoryHashSignature\Detection::class); - $this->detections = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(MemoryHashSignature::class, \Google\Cloud\SecurityCenter\V2\Indicator_ProcessSignature_MemoryHashSignature::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/MemoryHashSignature/Detection.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/MemoryHashSignature/Detection.php deleted file mode 100644 index a5a19cc0677f..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/MemoryHashSignature/Detection.php +++ /dev/null @@ -1,112 +0,0 @@ -google.cloud.securitycenter.v2.Indicator.ProcessSignature.MemoryHashSignature.Detection - */ -class Detection extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the binary associated with the memory hash - * signature detection. - * - * Generated from protobuf field string binary = 2; - */ - protected $binary = ''; - /** - * The percentage of memory page hashes in the signature - * that were matched. - * - * Generated from protobuf field double percent_pages_matched = 3; - */ - protected $percent_pages_matched = 0.0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $binary - * The name of the binary associated with the memory hash - * signature detection. - * @type float $percent_pages_matched - * The percentage of memory page hashes in the signature - * that were matched. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Indicator::initOnce(); - parent::__construct($data); - } - - /** - * The name of the binary associated with the memory hash - * signature detection. - * - * Generated from protobuf field string binary = 2; - * @return string - */ - public function getBinary() - { - return $this->binary; - } - - /** - * The name of the binary associated with the memory hash - * signature detection. - * - * Generated from protobuf field string binary = 2; - * @param string $var - * @return $this - */ - public function setBinary($var) - { - GPBUtil::checkString($var, True); - $this->binary = $var; - - return $this; - } - - /** - * The percentage of memory page hashes in the signature - * that were matched. - * - * Generated from protobuf field double percent_pages_matched = 3; - * @return float - */ - public function getPercentPagesMatched() - { - return $this->percent_pages_matched; - } - - /** - * The percentage of memory page hashes in the signature - * that were matched. - * - * Generated from protobuf field double percent_pages_matched = 3; - * @param float $var - * @return $this - */ - public function setPercentPagesMatched($var) - { - GPBUtil::checkDouble($var); - $this->percent_pages_matched = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Detection::class, \Google\Cloud\SecurityCenter\V2\Indicator_ProcessSignature_MemoryHashSignature_Detection::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/SignatureType.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/SignatureType.php deleted file mode 100644 index ff34fb5649f8..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/SignatureType.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.securitycenter.v2.Indicator.ProcessSignature.SignatureType - */ -class SignatureType -{ - /** - * The default signature type. - * - * Generated from protobuf enum SIGNATURE_TYPE_UNSPECIFIED = 0; - */ - const SIGNATURE_TYPE_UNSPECIFIED = 0; - /** - * Used for signatures concerning processes. - * - * Generated from protobuf enum SIGNATURE_TYPE_PROCESS = 1; - */ - const SIGNATURE_TYPE_PROCESS = 1; - /** - * Used for signatures concerning disks. - * - * Generated from protobuf enum SIGNATURE_TYPE_FILE = 2; - */ - const SIGNATURE_TYPE_FILE = 2; - - private static $valueToName = [ - self::SIGNATURE_TYPE_UNSPECIFIED => 'SIGNATURE_TYPE_UNSPECIFIED', - self::SIGNATURE_TYPE_PROCESS => 'SIGNATURE_TYPE_PROCESS', - self::SIGNATURE_TYPE_FILE => 'SIGNATURE_TYPE_FILE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SignatureType::class, \Google\Cloud\SecurityCenter\V2\Indicator_ProcessSignature_SignatureType::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/YaraRuleSignature.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/YaraRuleSignature.php deleted file mode 100644 index 61aa230b37b4..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Indicator/ProcessSignature/YaraRuleSignature.php +++ /dev/null @@ -1,70 +0,0 @@ -google.cloud.securitycenter.v2.Indicator.ProcessSignature.YaraRuleSignature - */ -class YaraRuleSignature extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the YARA rule. - * - * Generated from protobuf field string yara_rule = 5; - */ - protected $yara_rule = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $yara_rule - * The name of the YARA rule. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Indicator::initOnce(); - parent::__construct($data); - } - - /** - * The name of the YARA rule. - * - * Generated from protobuf field string yara_rule = 5; - * @return string - */ - public function getYaraRule() - { - return $this->yara_rule; - } - - /** - * The name of the YARA rule. - * - * Generated from protobuf field string yara_rule = 5; - * @param string $var - * @return $this - */ - public function setYaraRule($var) - { - GPBUtil::checkString($var, True); - $this->yara_rule = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(YaraRuleSignature::class, \Google\Cloud\SecurityCenter\V2\Indicator_ProcessSignature_YaraRuleSignature::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/KernelRootkit.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/KernelRootkit.php deleted file mode 100644 index 55a43f4ea22f..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/KernelRootkit.php +++ /dev/null @@ -1,367 +0,0 @@ -google.cloud.securitycenter.v2.KernelRootkit - */ -class KernelRootkit extends \Google\Protobuf\Internal\Message -{ - /** - * Rootkit name, when available. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * True if unexpected modifications of kernel code memory are present. - * - * Generated from protobuf field bool unexpected_code_modification = 2; - */ - protected $unexpected_code_modification = false; - /** - * True if unexpected modifications of kernel read-only data memory are - * present. - * - * Generated from protobuf field bool unexpected_read_only_data_modification = 3; - */ - protected $unexpected_read_only_data_modification = false; - /** - * True if `ftrace` points are present with callbacks pointing to regions - * that are not in the expected kernel or module code range. - * - * Generated from protobuf field bool unexpected_ftrace_handler = 4; - */ - protected $unexpected_ftrace_handler = false; - /** - * True if `kprobe` points are present with callbacks pointing to regions - * that are not in the expected kernel or module code range. - * - * Generated from protobuf field bool unexpected_kprobe_handler = 5; - */ - protected $unexpected_kprobe_handler = false; - /** - * True if kernel code pages that are not in the expected kernel or module - * code regions are present. - * - * Generated from protobuf field bool unexpected_kernel_code_pages = 6; - */ - protected $unexpected_kernel_code_pages = false; - /** - * True if system call handlers that are are not in the expected kernel or - * module code regions are present. - * - * Generated from protobuf field bool unexpected_system_call_handler = 7; - */ - protected $unexpected_system_call_handler = false; - /** - * True if interrupt handlers that are are not in the expected kernel or - * module code regions are present. - * - * Generated from protobuf field bool unexpected_interrupt_handler = 8; - */ - protected $unexpected_interrupt_handler = false; - /** - * True if unexpected processes in the scheduler run queue are present. Such - * processes are in the run queue, but not in the process task list. - * - * Generated from protobuf field bool unexpected_processes_in_runqueue = 9; - */ - protected $unexpected_processes_in_runqueue = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Rootkit name, when available. - * @type bool $unexpected_code_modification - * True if unexpected modifications of kernel code memory are present. - * @type bool $unexpected_read_only_data_modification - * True if unexpected modifications of kernel read-only data memory are - * present. - * @type bool $unexpected_ftrace_handler - * True if `ftrace` points are present with callbacks pointing to regions - * that are not in the expected kernel or module code range. - * @type bool $unexpected_kprobe_handler - * True if `kprobe` points are present with callbacks pointing to regions - * that are not in the expected kernel or module code range. - * @type bool $unexpected_kernel_code_pages - * True if kernel code pages that are not in the expected kernel or module - * code regions are present. - * @type bool $unexpected_system_call_handler - * True if system call handlers that are are not in the expected kernel or - * module code regions are present. - * @type bool $unexpected_interrupt_handler - * True if interrupt handlers that are are not in the expected kernel or - * module code regions are present. - * @type bool $unexpected_processes_in_runqueue - * True if unexpected processes in the scheduler run queue are present. Such - * processes are in the run queue, but not in the process task list. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\KernelRootkit::initOnce(); - parent::__construct($data); - } - - /** - * Rootkit name, when available. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Rootkit name, when available. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * True if unexpected modifications of kernel code memory are present. - * - * Generated from protobuf field bool unexpected_code_modification = 2; - * @return bool - */ - public function getUnexpectedCodeModification() - { - return $this->unexpected_code_modification; - } - - /** - * True if unexpected modifications of kernel code memory are present. - * - * Generated from protobuf field bool unexpected_code_modification = 2; - * @param bool $var - * @return $this - */ - public function setUnexpectedCodeModification($var) - { - GPBUtil::checkBool($var); - $this->unexpected_code_modification = $var; - - return $this; - } - - /** - * True if unexpected modifications of kernel read-only data memory are - * present. - * - * Generated from protobuf field bool unexpected_read_only_data_modification = 3; - * @return bool - */ - public function getUnexpectedReadOnlyDataModification() - { - return $this->unexpected_read_only_data_modification; - } - - /** - * True if unexpected modifications of kernel read-only data memory are - * present. - * - * Generated from protobuf field bool unexpected_read_only_data_modification = 3; - * @param bool $var - * @return $this - */ - public function setUnexpectedReadOnlyDataModification($var) - { - GPBUtil::checkBool($var); - $this->unexpected_read_only_data_modification = $var; - - return $this; - } - - /** - * True if `ftrace` points are present with callbacks pointing to regions - * that are not in the expected kernel or module code range. - * - * Generated from protobuf field bool unexpected_ftrace_handler = 4; - * @return bool - */ - public function getUnexpectedFtraceHandler() - { - return $this->unexpected_ftrace_handler; - } - - /** - * True if `ftrace` points are present with callbacks pointing to regions - * that are not in the expected kernel or module code range. - * - * Generated from protobuf field bool unexpected_ftrace_handler = 4; - * @param bool $var - * @return $this - */ - public function setUnexpectedFtraceHandler($var) - { - GPBUtil::checkBool($var); - $this->unexpected_ftrace_handler = $var; - - return $this; - } - - /** - * True if `kprobe` points are present with callbacks pointing to regions - * that are not in the expected kernel or module code range. - * - * Generated from protobuf field bool unexpected_kprobe_handler = 5; - * @return bool - */ - public function getUnexpectedKprobeHandler() - { - return $this->unexpected_kprobe_handler; - } - - /** - * True if `kprobe` points are present with callbacks pointing to regions - * that are not in the expected kernel or module code range. - * - * Generated from protobuf field bool unexpected_kprobe_handler = 5; - * @param bool $var - * @return $this - */ - public function setUnexpectedKprobeHandler($var) - { - GPBUtil::checkBool($var); - $this->unexpected_kprobe_handler = $var; - - return $this; - } - - /** - * True if kernel code pages that are not in the expected kernel or module - * code regions are present. - * - * Generated from protobuf field bool unexpected_kernel_code_pages = 6; - * @return bool - */ - public function getUnexpectedKernelCodePages() - { - return $this->unexpected_kernel_code_pages; - } - - /** - * True if kernel code pages that are not in the expected kernel or module - * code regions are present. - * - * Generated from protobuf field bool unexpected_kernel_code_pages = 6; - * @param bool $var - * @return $this - */ - public function setUnexpectedKernelCodePages($var) - { - GPBUtil::checkBool($var); - $this->unexpected_kernel_code_pages = $var; - - return $this; - } - - /** - * True if system call handlers that are are not in the expected kernel or - * module code regions are present. - * - * Generated from protobuf field bool unexpected_system_call_handler = 7; - * @return bool - */ - public function getUnexpectedSystemCallHandler() - { - return $this->unexpected_system_call_handler; - } - - /** - * True if system call handlers that are are not in the expected kernel or - * module code regions are present. - * - * Generated from protobuf field bool unexpected_system_call_handler = 7; - * @param bool $var - * @return $this - */ - public function setUnexpectedSystemCallHandler($var) - { - GPBUtil::checkBool($var); - $this->unexpected_system_call_handler = $var; - - return $this; - } - - /** - * True if interrupt handlers that are are not in the expected kernel or - * module code regions are present. - * - * Generated from protobuf field bool unexpected_interrupt_handler = 8; - * @return bool - */ - public function getUnexpectedInterruptHandler() - { - return $this->unexpected_interrupt_handler; - } - - /** - * True if interrupt handlers that are are not in the expected kernel or - * module code regions are present. - * - * Generated from protobuf field bool unexpected_interrupt_handler = 8; - * @param bool $var - * @return $this - */ - public function setUnexpectedInterruptHandler($var) - { - GPBUtil::checkBool($var); - $this->unexpected_interrupt_handler = $var; - - return $this; - } - - /** - * True if unexpected processes in the scheduler run queue are present. Such - * processes are in the run queue, but not in the process task list. - * - * Generated from protobuf field bool unexpected_processes_in_runqueue = 9; - * @return bool - */ - public function getUnexpectedProcessesInRunqueue() - { - return $this->unexpected_processes_in_runqueue; - } - - /** - * True if unexpected processes in the scheduler run queue are present. Such - * processes are in the run queue, but not in the process task list. - * - * Generated from protobuf field bool unexpected_processes_in_runqueue = 9; - * @param bool $var - * @return $this - */ - public function setUnexpectedProcessesInRunqueue($var) - { - GPBUtil::checkBool($var); - $this->unexpected_processes_in_runqueue = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes.php deleted file mode 100644 index 29312fe40a92..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes.php +++ /dev/null @@ -1,319 +0,0 @@ -google.cloud.securitycenter.v2.Kubernetes - */ -class Kubernetes extends \Google\Protobuf\Internal\Message -{ - /** - * Kubernetes - * [Pods](https://cloud.google.com/kubernetes-engine/docs/concepts/pod) - * associated with the finding. This field contains Pod records for each - * container that is owned by a Pod. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Pod pods = 1; - */ - private $pods; - /** - * Provides Kubernetes - * [node](https://cloud.google.com/kubernetes-engine/docs/concepts/cluster-architecture#nodes) - * information. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Node nodes = 2; - */ - private $nodes; - /** - * GKE [node - * pools](https://cloud.google.com/kubernetes-engine/docs/concepts/node-pools) - * associated with the finding. This field contains node pool information for - * each node, when it is available. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.NodePool node_pools = 3; - */ - private $node_pools; - /** - * Provides Kubernetes role information for findings that involve [Roles or - * ClusterRoles](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Role roles = 4; - */ - private $roles; - /** - * Provides Kubernetes role binding information for findings that involve - * [RoleBindings or - * ClusterRoleBindings](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Binding bindings = 5; - */ - private $bindings; - /** - * Provides information on any Kubernetes access reviews (privilege checks) - * relevant to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.AccessReview access_reviews = 6; - */ - private $access_reviews; - /** - * Kubernetes objects related to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Object objects = 7; - */ - private $objects; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Pod>|\Google\Protobuf\Internal\RepeatedField $pods - * Kubernetes - * [Pods](https://cloud.google.com/kubernetes-engine/docs/concepts/pod) - * associated with the finding. This field contains Pod records for each - * container that is owned by a Pod. - * @type array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Node>|\Google\Protobuf\Internal\RepeatedField $nodes - * Provides Kubernetes - * [node](https://cloud.google.com/kubernetes-engine/docs/concepts/cluster-architecture#nodes) - * information. - * @type array<\Google\Cloud\SecurityCenter\V2\Kubernetes\NodePool>|\Google\Protobuf\Internal\RepeatedField $node_pools - * GKE [node - * pools](https://cloud.google.com/kubernetes-engine/docs/concepts/node-pools) - * associated with the finding. This field contains node pool information for - * each node, when it is available. - * @type array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Role>|\Google\Protobuf\Internal\RepeatedField $roles - * Provides Kubernetes role information for findings that involve [Roles or - * ClusterRoles](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). - * @type array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Binding>|\Google\Protobuf\Internal\RepeatedField $bindings - * Provides Kubernetes role binding information for findings that involve - * [RoleBindings or - * ClusterRoleBindings](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). - * @type array<\Google\Cloud\SecurityCenter\V2\Kubernetes\AccessReview>|\Google\Protobuf\Internal\RepeatedField $access_reviews - * Provides information on any Kubernetes access reviews (privilege checks) - * relevant to the finding. - * @type array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Object>|\Google\Protobuf\Internal\RepeatedField $objects - * Kubernetes objects related to the finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Kubernetes::initOnce(); - parent::__construct($data); - } - - /** - * Kubernetes - * [Pods](https://cloud.google.com/kubernetes-engine/docs/concepts/pod) - * associated with the finding. This field contains Pod records for each - * container that is owned by a Pod. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Pod pods = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPods() - { - return $this->pods; - } - - /** - * Kubernetes - * [Pods](https://cloud.google.com/kubernetes-engine/docs/concepts/pod) - * associated with the finding. This field contains Pod records for each - * container that is owned by a Pod. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Pod pods = 1; - * @param array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Pod>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPods($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Kubernetes\Pod::class); - $this->pods = $arr; - - return $this; - } - - /** - * Provides Kubernetes - * [node](https://cloud.google.com/kubernetes-engine/docs/concepts/cluster-architecture#nodes) - * information. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Node nodes = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNodes() - { - return $this->nodes; - } - - /** - * Provides Kubernetes - * [node](https://cloud.google.com/kubernetes-engine/docs/concepts/cluster-architecture#nodes) - * information. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Node nodes = 2; - * @param array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Node>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNodes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Kubernetes\Node::class); - $this->nodes = $arr; - - return $this; - } - - /** - * GKE [node - * pools](https://cloud.google.com/kubernetes-engine/docs/concepts/node-pools) - * associated with the finding. This field contains node pool information for - * each node, when it is available. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.NodePool node_pools = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNodePools() - { - return $this->node_pools; - } - - /** - * GKE [node - * pools](https://cloud.google.com/kubernetes-engine/docs/concepts/node-pools) - * associated with the finding. This field contains node pool information for - * each node, when it is available. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.NodePool node_pools = 3; - * @param array<\Google\Cloud\SecurityCenter\V2\Kubernetes\NodePool>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNodePools($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Kubernetes\NodePool::class); - $this->node_pools = $arr; - - return $this; - } - - /** - * Provides Kubernetes role information for findings that involve [Roles or - * ClusterRoles](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Role roles = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRoles() - { - return $this->roles; - } - - /** - * Provides Kubernetes role information for findings that involve [Roles or - * ClusterRoles](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Role roles = 4; - * @param array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Role>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRoles($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Kubernetes\Role::class); - $this->roles = $arr; - - return $this; - } - - /** - * Provides Kubernetes role binding information for findings that involve - * [RoleBindings or - * ClusterRoleBindings](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Binding bindings = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getBindings() - { - return $this->bindings; - } - - /** - * Provides Kubernetes role binding information for findings that involve - * [RoleBindings or - * ClusterRoleBindings](https://cloud.google.com/kubernetes-engine/docs/how-to/role-based-access-control). - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Binding bindings = 5; - * @param array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Binding>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setBindings($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Kubernetes\Binding::class); - $this->bindings = $arr; - - return $this; - } - - /** - * Provides information on any Kubernetes access reviews (privilege checks) - * relevant to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.AccessReview access_reviews = 6; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAccessReviews() - { - return $this->access_reviews; - } - - /** - * Provides information on any Kubernetes access reviews (privilege checks) - * relevant to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.AccessReview access_reviews = 6; - * @param array<\Google\Cloud\SecurityCenter\V2\Kubernetes\AccessReview>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAccessReviews($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Kubernetes\AccessReview::class); - $this->access_reviews = $arr; - - return $this; - } - - /** - * Kubernetes objects related to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Object objects = 7; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getObjects() - { - return $this->objects; - } - - /** - * Kubernetes objects related to the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Object objects = 7; - * @param array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Object>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setObjects($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Kubernetes\Object::class); - $this->objects = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/AccessReview.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/AccessReview.php deleted file mode 100644 index 5619df16fb08..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/AccessReview.php +++ /dev/null @@ -1,289 +0,0 @@ -google.cloud.securitycenter.v2.Kubernetes.AccessReview - */ -class AccessReview extends \Google\Protobuf\Internal\Message -{ - /** - * The API group of the resource. "*" means all. - * - * Generated from protobuf field string group = 1; - */ - protected $group = ''; - /** - * Namespace of the action being requested. Currently, there is no - * distinction between no namespace and all namespaces. Both - * are represented by "" (empty). - * - * Generated from protobuf field string ns = 2; - */ - protected $ns = ''; - /** - * The name of the resource being requested. Empty means all. - * - * Generated from protobuf field string name = 3; - */ - protected $name = ''; - /** - * The optional resource type requested. "*" means all. - * - * Generated from protobuf field string resource = 4; - */ - protected $resource = ''; - /** - * The optional subresource type. - * - * Generated from protobuf field string subresource = 5; - */ - protected $subresource = ''; - /** - * A Kubernetes resource API verb, like get, list, watch, create, update, - * delete, proxy. "*" means all. - * - * Generated from protobuf field string verb = 6; - */ - protected $verb = ''; - /** - * The API version of the resource. "*" means all. - * - * Generated from protobuf field string version = 7; - */ - protected $version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $group - * The API group of the resource. "*" means all. - * @type string $ns - * Namespace of the action being requested. Currently, there is no - * distinction between no namespace and all namespaces. Both - * are represented by "" (empty). - * @type string $name - * The name of the resource being requested. Empty means all. - * @type string $resource - * The optional resource type requested. "*" means all. - * @type string $subresource - * The optional subresource type. - * @type string $verb - * A Kubernetes resource API verb, like get, list, watch, create, update, - * delete, proxy. "*" means all. - * @type string $version - * The API version of the resource. "*" means all. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Kubernetes::initOnce(); - parent::__construct($data); - } - - /** - * The API group of the resource. "*" means all. - * - * Generated from protobuf field string group = 1; - * @return string - */ - public function getGroup() - { - return $this->group; - } - - /** - * The API group of the resource. "*" means all. - * - * Generated from protobuf field string group = 1; - * @param string $var - * @return $this - */ - public function setGroup($var) - { - GPBUtil::checkString($var, True); - $this->group = $var; - - return $this; - } - - /** - * Namespace of the action being requested. Currently, there is no - * distinction between no namespace and all namespaces. Both - * are represented by "" (empty). - * - * Generated from protobuf field string ns = 2; - * @return string - */ - public function getNs() - { - return $this->ns; - } - - /** - * Namespace of the action being requested. Currently, there is no - * distinction between no namespace and all namespaces. Both - * are represented by "" (empty). - * - * Generated from protobuf field string ns = 2; - * @param string $var - * @return $this - */ - public function setNs($var) - { - GPBUtil::checkString($var, True); - $this->ns = $var; - - return $this; - } - - /** - * The name of the resource being requested. Empty means all. - * - * Generated from protobuf field string name = 3; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the resource being requested. Empty means all. - * - * Generated from protobuf field string name = 3; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The optional resource type requested. "*" means all. - * - * Generated from protobuf field string resource = 4; - * @return string - */ - public function getResource() - { - return $this->resource; - } - - /** - * The optional resource type requested. "*" means all. - * - * Generated from protobuf field string resource = 4; - * @param string $var - * @return $this - */ - public function setResource($var) - { - GPBUtil::checkString($var, True); - $this->resource = $var; - - return $this; - } - - /** - * The optional subresource type. - * - * Generated from protobuf field string subresource = 5; - * @return string - */ - public function getSubresource() - { - return $this->subresource; - } - - /** - * The optional subresource type. - * - * Generated from protobuf field string subresource = 5; - * @param string $var - * @return $this - */ - public function setSubresource($var) - { - GPBUtil::checkString($var, True); - $this->subresource = $var; - - return $this; - } - - /** - * A Kubernetes resource API verb, like get, list, watch, create, update, - * delete, proxy. "*" means all. - * - * Generated from protobuf field string verb = 6; - * @return string - */ - public function getVerb() - { - return $this->verb; - } - - /** - * A Kubernetes resource API verb, like get, list, watch, create, update, - * delete, proxy. "*" means all. - * - * Generated from protobuf field string verb = 6; - * @param string $var - * @return $this - */ - public function setVerb($var) - { - GPBUtil::checkString($var, True); - $this->verb = $var; - - return $this; - } - - /** - * The API version of the resource. "*" means all. - * - * Generated from protobuf field string version = 7; - * @return string - */ - public function getVersion() - { - return $this->version; - } - - /** - * The API version of the resource. "*" means all. - * - * Generated from protobuf field string version = 7; - * @param string $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkString($var, True); - $this->version = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AccessReview::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_AccessReview::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Binding.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Binding.php deleted file mode 100644 index c6ad46478d48..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Binding.php +++ /dev/null @@ -1,186 +0,0 @@ -google.cloud.securitycenter.v2.Kubernetes.Binding - */ -class Binding extends \Google\Protobuf\Internal\Message -{ - /** - * Namespace for the binding. - * - * Generated from protobuf field string ns = 1; - */ - protected $ns = ''; - /** - * Name for the binding. - * - * Generated from protobuf field string name = 2; - */ - protected $name = ''; - /** - * The Role or ClusterRole referenced by the binding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes.Role role = 3; - */ - protected $role = null; - /** - * Represents one or more subjects that are bound to the role. Not always - * available for PATCH requests. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Subject subjects = 4; - */ - private $subjects; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $ns - * Namespace for the binding. - * @type string $name - * Name for the binding. - * @type \Google\Cloud\SecurityCenter\V2\Kubernetes\Role $role - * The Role or ClusterRole referenced by the binding. - * @type array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Subject>|\Google\Protobuf\Internal\RepeatedField $subjects - * Represents one or more subjects that are bound to the role. Not always - * available for PATCH requests. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Kubernetes::initOnce(); - parent::__construct($data); - } - - /** - * Namespace for the binding. - * - * Generated from protobuf field string ns = 1; - * @return string - */ - public function getNs() - { - return $this->ns; - } - - /** - * Namespace for the binding. - * - * Generated from protobuf field string ns = 1; - * @param string $var - * @return $this - */ - public function setNs($var) - { - GPBUtil::checkString($var, True); - $this->ns = $var; - - return $this; - } - - /** - * Name for the binding. - * - * Generated from protobuf field string name = 2; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Name for the binding. - * - * Generated from protobuf field string name = 2; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The Role or ClusterRole referenced by the binding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes.Role role = 3; - * @return \Google\Cloud\SecurityCenter\V2\Kubernetes\Role|null - */ - public function getRole() - { - return $this->role; - } - - public function hasRole() - { - return isset($this->role); - } - - public function clearRole() - { - unset($this->role); - } - - /** - * The Role or ClusterRole referenced by the binding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes.Role role = 3; - * @param \Google\Cloud\SecurityCenter\V2\Kubernetes\Role $var - * @return $this - */ - public function setRole($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Kubernetes\Role::class); - $this->role = $var; - - return $this; - } - - /** - * Represents one or more subjects that are bound to the role. Not always - * available for PATCH requests. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Subject subjects = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSubjects() - { - return $this->subjects; - } - - /** - * Represents one or more subjects that are bound to the role. Not always - * available for PATCH requests. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Subject subjects = 4; - * @param array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Subject>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSubjects($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Kubernetes\Subject::class); - $this->subjects = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Binding::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_Binding::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Node.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Node.php deleted file mode 100644 index ec42e14203a0..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Node.php +++ /dev/null @@ -1,74 +0,0 @@ -google.cloud.securitycenter.v2.Kubernetes.Node - */ -class Node extends \Google\Protobuf\Internal\Message -{ - /** - * [Full resource name](https://google.aip.dev/122#full-resource-names) of - * the Compute Engine VM running the cluster node. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * [Full resource name](https://google.aip.dev/122#full-resource-names) of - * the Compute Engine VM running the cluster node. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Kubernetes::initOnce(); - parent::__construct($data); - } - - /** - * [Full resource name](https://google.aip.dev/122#full-resource-names) of - * the Compute Engine VM running the cluster node. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * [Full resource name](https://google.aip.dev/122#full-resource-names) of - * the Compute Engine VM running the cluster node. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Node::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_Node::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/NodePool.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/NodePool.php deleted file mode 100644 index fe5da418e6ce..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/NodePool.php +++ /dev/null @@ -1,104 +0,0 @@ -google.cloud.securitycenter.v2.Kubernetes.NodePool - */ -class NodePool extends \Google\Protobuf\Internal\Message -{ - /** - * Kubernetes node pool name. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Nodes associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Node nodes = 2; - */ - private $nodes; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Kubernetes node pool name. - * @type array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Node>|\Google\Protobuf\Internal\RepeatedField $nodes - * Nodes associated with the finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Kubernetes::initOnce(); - parent::__construct($data); - } - - /** - * Kubernetes node pool name. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Kubernetes node pool name. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Nodes associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Node nodes = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNodes() - { - return $this->nodes; - } - - /** - * Nodes associated with the finding. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Kubernetes.Node nodes = 2; - * @param array<\Google\Cloud\SecurityCenter\V2\Kubernetes\Node>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNodes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Kubernetes\Node::class); - $this->nodes = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(NodePool::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_NodePool::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Object.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Object.php deleted file mode 100644 index ad51d0f9697d..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Object.php +++ /dev/null @@ -1,220 +0,0 @@ -google.cloud.securitycenter.v2.Kubernetes.Object - */ -class Object extends \Google\Protobuf\Internal\Message -{ - /** - * Kubernetes object group, such as "policy.k8s.io/v1". - * - * Generated from protobuf field string group = 1; - */ - protected $group = ''; - /** - * Kubernetes object kind, such as "Namespace". - * - * Generated from protobuf field string kind = 2; - */ - protected $kind = ''; - /** - * Kubernetes object namespace. Must be a valid DNS label. Named - * "ns" to avoid collision with C++ namespace keyword. For details see - * https://kubernetes.io/docs/tasks/administer-cluster/namespaces/. - * - * Generated from protobuf field string ns = 3; - */ - protected $ns = ''; - /** - * Kubernetes object name. For details see - * https://kubernetes.io/docs/concepts/overview/working-with-objects/names/. - * - * Generated from protobuf field string name = 4; - */ - protected $name = ''; - /** - * Pod containers associated with this finding, if any. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Container containers = 5; - */ - private $containers; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $group - * Kubernetes object group, such as "policy.k8s.io/v1". - * @type string $kind - * Kubernetes object kind, such as "Namespace". - * @type string $ns - * Kubernetes object namespace. Must be a valid DNS label. Named - * "ns" to avoid collision with C++ namespace keyword. For details see - * https://kubernetes.io/docs/tasks/administer-cluster/namespaces/. - * @type string $name - * Kubernetes object name. For details see - * https://kubernetes.io/docs/concepts/overview/working-with-objects/names/. - * @type array<\Google\Cloud\SecurityCenter\V2\Container>|\Google\Protobuf\Internal\RepeatedField $containers - * Pod containers associated with this finding, if any. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Kubernetes::initOnce(); - parent::__construct($data); - } - - /** - * Kubernetes object group, such as "policy.k8s.io/v1". - * - * Generated from protobuf field string group = 1; - * @return string - */ - public function getGroup() - { - return $this->group; - } - - /** - * Kubernetes object group, such as "policy.k8s.io/v1". - * - * Generated from protobuf field string group = 1; - * @param string $var - * @return $this - */ - public function setGroup($var) - { - GPBUtil::checkString($var, True); - $this->group = $var; - - return $this; - } - - /** - * Kubernetes object kind, such as "Namespace". - * - * Generated from protobuf field string kind = 2; - * @return string - */ - public function getKind() - { - return $this->kind; - } - - /** - * Kubernetes object kind, such as "Namespace". - * - * Generated from protobuf field string kind = 2; - * @param string $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkString($var, True); - $this->kind = $var; - - return $this; - } - - /** - * Kubernetes object namespace. Must be a valid DNS label. Named - * "ns" to avoid collision with C++ namespace keyword. For details see - * https://kubernetes.io/docs/tasks/administer-cluster/namespaces/. - * - * Generated from protobuf field string ns = 3; - * @return string - */ - public function getNs() - { - return $this->ns; - } - - /** - * Kubernetes object namespace. Must be a valid DNS label. Named - * "ns" to avoid collision with C++ namespace keyword. For details see - * https://kubernetes.io/docs/tasks/administer-cluster/namespaces/. - * - * Generated from protobuf field string ns = 3; - * @param string $var - * @return $this - */ - public function setNs($var) - { - GPBUtil::checkString($var, True); - $this->ns = $var; - - return $this; - } - - /** - * Kubernetes object name. For details see - * https://kubernetes.io/docs/concepts/overview/working-with-objects/names/. - * - * Generated from protobuf field string name = 4; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Kubernetes object name. For details see - * https://kubernetes.io/docs/concepts/overview/working-with-objects/names/. - * - * Generated from protobuf field string name = 4; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Pod containers associated with this finding, if any. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Container containers = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getContainers() - { - return $this->containers; - } - - /** - * Pod containers associated with this finding, if any. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Container containers = 5; - * @param array<\Google\Cloud\SecurityCenter\V2\Container>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setContainers($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Container::class); - $this->containers = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Object::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_Object::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Pod.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Pod.php deleted file mode 100644 index cf46fb898afa..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Pod.php +++ /dev/null @@ -1,176 +0,0 @@ -google.cloud.securitycenter.v2.Kubernetes.Pod - */ -class Pod extends \Google\Protobuf\Internal\Message -{ - /** - * Kubernetes Pod namespace. - * - * Generated from protobuf field string ns = 1; - */ - protected $ns = ''; - /** - * Kubernetes Pod name. - * - * Generated from protobuf field string name = 2; - */ - protected $name = ''; - /** - * Pod labels. For Kubernetes containers, these are applied to the - * container. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Label labels = 3; - */ - private $labels; - /** - * Pod containers associated with this finding, if any. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Container containers = 4; - */ - private $containers; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $ns - * Kubernetes Pod namespace. - * @type string $name - * Kubernetes Pod name. - * @type array<\Google\Cloud\SecurityCenter\V2\Label>|\Google\Protobuf\Internal\RepeatedField $labels - * Pod labels. For Kubernetes containers, these are applied to the - * container. - * @type array<\Google\Cloud\SecurityCenter\V2\Container>|\Google\Protobuf\Internal\RepeatedField $containers - * Pod containers associated with this finding, if any. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Kubernetes::initOnce(); - parent::__construct($data); - } - - /** - * Kubernetes Pod namespace. - * - * Generated from protobuf field string ns = 1; - * @return string - */ - public function getNs() - { - return $this->ns; - } - - /** - * Kubernetes Pod namespace. - * - * Generated from protobuf field string ns = 1; - * @param string $var - * @return $this - */ - public function setNs($var) - { - GPBUtil::checkString($var, True); - $this->ns = $var; - - return $this; - } - - /** - * Kubernetes Pod name. - * - * Generated from protobuf field string name = 2; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Kubernetes Pod name. - * - * Generated from protobuf field string name = 2; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Pod labels. For Kubernetes containers, these are applied to the - * container. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Label labels = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Pod labels. For Kubernetes containers, these are applied to the - * container. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Label labels = 3; - * @param array<\Google\Cloud\SecurityCenter\V2\Label>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLabels($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Label::class); - $this->labels = $arr; - - return $this; - } - - /** - * Pod containers associated with this finding, if any. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Container containers = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getContainers() - { - return $this->containers; - } - - /** - * Pod containers associated with this finding, if any. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Container containers = 4; - * @param array<\Google\Cloud\SecurityCenter\V2\Container>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setContainers($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Container::class); - $this->containers = $arr; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Pod::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_Pod::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Role.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Role.php deleted file mode 100644 index 3df042edbea6..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Role.php +++ /dev/null @@ -1,138 +0,0 @@ -google.cloud.securitycenter.v2.Kubernetes.Role - */ -class Role extends \Google\Protobuf\Internal\Message -{ - /** - * Role type. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes.Role.Kind kind = 1; - */ - protected $kind = 0; - /** - * Role namespace. - * - * Generated from protobuf field string ns = 2; - */ - protected $ns = ''; - /** - * Role name. - * - * Generated from protobuf field string name = 3; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $kind - * Role type. - * @type string $ns - * Role namespace. - * @type string $name - * Role name. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Kubernetes::initOnce(); - parent::__construct($data); - } - - /** - * Role type. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes.Role.Kind kind = 1; - * @return int - */ - public function getKind() - { - return $this->kind; - } - - /** - * Role type. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes.Role.Kind kind = 1; - * @param int $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Kubernetes\Role\Kind::class); - $this->kind = $var; - - return $this; - } - - /** - * Role namespace. - * - * Generated from protobuf field string ns = 2; - * @return string - */ - public function getNs() - { - return $this->ns; - } - - /** - * Role namespace. - * - * Generated from protobuf field string ns = 2; - * @param string $var - * @return $this - */ - public function setNs($var) - { - GPBUtil::checkString($var, True); - $this->ns = $var; - - return $this; - } - - /** - * Role name. - * - * Generated from protobuf field string name = 3; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Role name. - * - * Generated from protobuf field string name = 3; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Role::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_Role::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Role/Kind.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Role/Kind.php deleted file mode 100644 index f714eb7e8d73..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Role/Kind.php +++ /dev/null @@ -1,64 +0,0 @@ -google.cloud.securitycenter.v2.Kubernetes.Role.Kind - */ -class Kind -{ - /** - * Role type is not specified. - * - * Generated from protobuf enum KIND_UNSPECIFIED = 0; - */ - const KIND_UNSPECIFIED = 0; - /** - * Kubernetes Role. - * - * Generated from protobuf enum ROLE = 1; - */ - const ROLE = 1; - /** - * Kubernetes ClusterRole. - * - * Generated from protobuf enum CLUSTER_ROLE = 2; - */ - const CLUSTER_ROLE = 2; - - private static $valueToName = [ - self::KIND_UNSPECIFIED => 'KIND_UNSPECIFIED', - self::ROLE => 'ROLE', - self::CLUSTER_ROLE => 'CLUSTER_ROLE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Kind::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_Role_Kind::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Subject.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Subject.php deleted file mode 100644 index 63e46fb3411d..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Subject.php +++ /dev/null @@ -1,138 +0,0 @@ -google.cloud.securitycenter.v2.Kubernetes.Subject - */ -class Subject extends \Google\Protobuf\Internal\Message -{ - /** - * Authentication type for the subject. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes.Subject.AuthType kind = 1; - */ - protected $kind = 0; - /** - * Namespace for the subject. - * - * Generated from protobuf field string ns = 2; - */ - protected $ns = ''; - /** - * Name for the subject. - * - * Generated from protobuf field string name = 3; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $kind - * Authentication type for the subject. - * @type string $ns - * Namespace for the subject. - * @type string $name - * Name for the subject. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Kubernetes::initOnce(); - parent::__construct($data); - } - - /** - * Authentication type for the subject. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes.Subject.AuthType kind = 1; - * @return int - */ - public function getKind() - { - return $this->kind; - } - - /** - * Authentication type for the subject. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Kubernetes.Subject.AuthType kind = 1; - * @param int $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Kubernetes\Subject\AuthType::class); - $this->kind = $var; - - return $this; - } - - /** - * Namespace for the subject. - * - * Generated from protobuf field string ns = 2; - * @return string - */ - public function getNs() - { - return $this->ns; - } - - /** - * Namespace for the subject. - * - * Generated from protobuf field string ns = 2; - * @param string $var - * @return $this - */ - public function setNs($var) - { - GPBUtil::checkString($var, True); - $this->ns = $var; - - return $this; - } - - /** - * Name for the subject. - * - * Generated from protobuf field string name = 3; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Name for the subject. - * - * Generated from protobuf field string name = 3; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Subject::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_Subject::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Subject/AuthType.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Subject/AuthType.php deleted file mode 100644 index c651f2876eb9..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Kubernetes/Subject/AuthType.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.securitycenter.v2.Kubernetes.Subject.AuthType - */ -class AuthType -{ - /** - * Authentication is not specified. - * - * Generated from protobuf enum AUTH_TYPE_UNSPECIFIED = 0; - */ - const AUTH_TYPE_UNSPECIFIED = 0; - /** - * User with valid certificate. - * - * Generated from protobuf enum USER = 1; - */ - const USER = 1; - /** - * Users managed by Kubernetes API with credentials stored as secrets. - * - * Generated from protobuf enum SERVICEACCOUNT = 2; - */ - const SERVICEACCOUNT = 2; - /** - * Collection of users. - * - * Generated from protobuf enum GROUP = 3; - */ - const GROUP = 3; - - private static $valueToName = [ - self::AUTH_TYPE_UNSPECIFIED => 'AUTH_TYPE_UNSPECIFIED', - self::USER => 'USER', - self::SERVICEACCOUNT => 'SERVICEACCOUNT', - self::GROUP => 'GROUP', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(AuthType::class, \Google\Cloud\SecurityCenter\V2\Kubernetes_Subject_AuthType::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Label.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Label.php deleted file mode 100644 index fcdf751ff4ef..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Label.php +++ /dev/null @@ -1,104 +0,0 @@ -google.cloud.securitycenter.v2.Label - */ -class Label extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the label. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Value that corresponds to the label's name. - * - * Generated from protobuf field string value = 2; - */ - protected $value = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Name of the label. - * @type string $value - * Value that corresponds to the label's name. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Label::initOnce(); - parent::__construct($data); - } - - /** - * Name of the label. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Name of the label. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Value that corresponds to the label's name. - * - * Generated from protobuf field string value = 2; - * @return string - */ - public function getValue() - { - return $this->value; - } - - /** - * Value that corresponds to the label's name. - * - * Generated from protobuf field string value = 2; - * @param string $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkString($var, True); - $this->value = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListAttackPathsRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListAttackPathsRequest.php deleted file mode 100644 index ffa62ff39865..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListAttackPathsRequest.php +++ /dev/null @@ -1,230 +0,0 @@ -google.cloud.securitycenter.v2.ListAttackPathsRequest - */ -class ListAttackPathsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of parent to list attack paths. - * Valid formats: - * "organizations/{organization}", - * "organizations/{organization}/simulations/{simulation}" - * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" - * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The filter expression that filters the attack path in the response. - * Supported fields: - * * `valued_resources` supports = - * - * Generated from protobuf field string filter = 2; - */ - protected $filter = ''; - /** - * The value returned by the last `ListAttackPathsResponse`; indicates - * that this is a continuation of a prior `ListAttackPaths` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 4; - */ - protected $page_size = 0; - - /** - * @param string $parent Required. Name of parent to list attack paths. - * - * Valid formats: - * "organizations/{organization}", - * "organizations/{organization}/simulations/{simulation}" - * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" - * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" - * Please see {@see SecurityCenterClient::organizationValuedResourceName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V2\ListAttackPathsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Name of parent to list attack paths. - * Valid formats: - * "organizations/{organization}", - * "organizations/{organization}/simulations/{simulation}" - * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" - * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" - * @type string $filter - * The filter expression that filters the attack path in the response. - * Supported fields: - * * `valued_resources` supports = - * @type string $page_token - * The value returned by the last `ListAttackPathsResponse`; indicates - * that this is a continuation of a prior `ListAttackPaths` call, and - * that the system should return the next page of data. - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of parent to list attack paths. - * Valid formats: - * "organizations/{organization}", - * "organizations/{organization}/simulations/{simulation}" - * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" - * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Name of parent to list attack paths. - * Valid formats: - * "organizations/{organization}", - * "organizations/{organization}/simulations/{simulation}" - * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" - * "organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The filter expression that filters the attack path in the response. - * Supported fields: - * * `valued_resources` supports = - * - * Generated from protobuf field string filter = 2; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * The filter expression that filters the attack path in the response. - * Supported fields: - * * `valued_resources` supports = - * - * Generated from protobuf field string filter = 2; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * The value returned by the last `ListAttackPathsResponse`; indicates - * that this is a continuation of a prior `ListAttackPaths` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListAttackPathsResponse`; indicates - * that this is a continuation of a prior `ListAttackPaths` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 4; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 4; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListAttackPathsResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListAttackPathsResponse.php deleted file mode 100644 index 6ea8a37d2c60..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListAttackPathsResponse.php +++ /dev/null @@ -1,106 +0,0 @@ -google.cloud.securitycenter.v2.ListAttackPathsResponse - */ -class ListAttackPathsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The attack paths that the attack path simulation identified. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath attack_paths = 1; - */ - private $attack_paths; - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V2\AttackPath>|\Google\Protobuf\Internal\RepeatedField $attack_paths - * The attack paths that the attack path simulation identified. - * @type string $next_page_token - * Token to retrieve the next page of results, or empty if there are no more - * results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * The attack paths that the attack path simulation identified. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath attack_paths = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAttackPaths() - { - return $this->attack_paths; - } - - /** - * The attack paths that the attack path simulation identified. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.AttackPath attack_paths = 1; - * @param array<\Google\Cloud\SecurityCenter\V2\AttackPath>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAttackPaths($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\AttackPath::class); - $this->attack_paths = $arr; - - return $this; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListBigQueryExportsRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListBigQueryExportsRequest.php deleted file mode 100644 index d6e1e47072cf..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListBigQueryExportsRequest.php +++ /dev/null @@ -1,189 +0,0 @@ -google.cloud.securitycenter.v2.ListBigQueryExportsRequest - */ -class ListBigQueryExportsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent, which owns the collection of BigQuery exports. Its - * format is "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListBigQueryExports` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListBigQueryExports` - * must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. The parent, which owns the collection of BigQuery exports. Its - * format is "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". Please see - * {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V2\ListBigQueryExportsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent, which owns the collection of BigQuery exports. Its - * format is "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * @type int $page_size - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * @type string $page_token - * A page token, received from a previous `ListBigQueryExports` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListBigQueryExports` - * must match the call that provided the page token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent, which owns the collection of BigQuery exports. Its - * format is "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent, which owns the collection of BigQuery exports. Its - * format is "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * A page token, received from a previous `ListBigQueryExports` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListBigQueryExports` - * must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A page token, received from a previous `ListBigQueryExports` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListBigQueryExports` - * must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListBigQueryExportsResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListBigQueryExportsResponse.php deleted file mode 100644 index a661ed3a90c3..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListBigQueryExportsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.securitycenter.v2.ListBigQueryExportsResponse - */ -class ListBigQueryExportsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The BigQuery exports from the specified parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.BigQueryExport big_query_exports = 1; - */ - private $big_query_exports; - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V2\BigQueryExport>|\Google\Protobuf\Internal\RepeatedField $big_query_exports - * The BigQuery exports from the specified parent. - * @type string $next_page_token - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * The BigQuery exports from the specified parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.BigQueryExport big_query_exports = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getBigQueryExports() - { - return $this->big_query_exports; - } - - /** - * The BigQuery exports from the specified parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.BigQueryExport big_query_exports = 1; - * @param array<\Google\Cloud\SecurityCenter\V2\BigQueryExport>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setBigQueryExports($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\BigQueryExport::class); - $this->big_query_exports = $arr; - - return $this; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsRequest.php deleted file mode 100644 index 159938828312..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsRequest.php +++ /dev/null @@ -1,572 +0,0 @@ -google.cloud.securitycenter.v2.ListFindingsRequest - */ -class ListFindingsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of the source the findings belong to. If no location is - * specified, the default is global. The following list shows some examples: - * + `organizations/[organization_id]/sources/[source_id]` - * + - * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` - * + `folders/[folder_id]/sources/[source_id]` - * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` - * + `projects/[project_id]/sources/[source_id]` - * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` - * To list across all sources provide a source_id of `-`. The following - * list shows some examples: - * + `organizations/{organization_id}/sources/-` - * + `organizations/{organization_id}/sources/-/locations/{location_id}` - * + `folders/{folder_id}/sources/-` - * + `folders/{folder_id}/sources/-locations/{location_id}` - * + `projects/{projects_id}/sources/-` - * + `projects/{projects_id}/sources/-/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * severity: `=`, `:` - * * security_marks.marks: `=`, `:` - * * resource: - * * resource.name: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.type: `=`, `:` - * * resource.folders.resource_folder: `=`, `:` - * * resource.display_name: `=`, `:` - * - * Generated from protobuf field string filter = 2; - */ - protected $filter = ''; - /** - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,parent". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,parent". Redundant space characters in the - * syntax are insignificant. "name desc,parent" and " - * name desc , parent " are equivalent. - * The following fields are supported: - * name - * parent - * state - * category - * resource_name - * event_time - * security_marks.marks - * - * Generated from protobuf field string order_by = 3; - */ - protected $order_by = ''; - /** - * A field mask to specify the Finding fields to be listed in the response. - * An empty field mask will list all fields. - * - * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; - */ - protected $field_mask = null; - /** - * The value returned by the last `ListFindingsResponse`; indicates - * that this is a continuation of a prior `ListFindings` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 8; - */ - protected $page_token = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 9; - */ - protected $page_size = 0; - - /** - * @param string $parent Required. Name of the source the findings belong to. If no location is - * specified, the default is global. The following list shows some examples: - * - * + `organizations/[organization_id]/sources/[source_id]` - * + - * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` - * + `folders/[folder_id]/sources/[source_id]` - * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` - * + `projects/[project_id]/sources/[source_id]` - * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` - * - * To list across all sources provide a source_id of `-`. The following - * list shows some examples: - * - * + `organizations/{organization_id}/sources/-` - * + `organizations/{organization_id}/sources/-/locations/{location_id}` - * + `folders/{folder_id}/sources/-` - * + `folders/{folder_id}/sources/-locations/{location_id}` - * + `projects/{projects_id}/sources/-` - * + `projects/{projects_id}/sources/-/locations/{location_id}` - * Please see {@see SecurityCenterClient::sourceName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V2\ListFindingsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Name of the source the findings belong to. If no location is - * specified, the default is global. The following list shows some examples: - * + `organizations/[organization_id]/sources/[source_id]` - * + - * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` - * + `folders/[folder_id]/sources/[source_id]` - * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` - * + `projects/[project_id]/sources/[source_id]` - * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` - * To list across all sources provide a source_id of `-`. The following - * list shows some examples: - * + `organizations/{organization_id}/sources/-` - * + `organizations/{organization_id}/sources/-/locations/{location_id}` - * + `folders/{folder_id}/sources/-` - * + `folders/{folder_id}/sources/-locations/{location_id}` - * + `projects/{projects_id}/sources/-` - * + `projects/{projects_id}/sources/-/locations/{location_id}` - * @type string $filter - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * severity: `=`, `:` - * * security_marks.marks: `=`, `:` - * * resource: - * * resource.name: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.type: `=`, `:` - * * resource.folders.resource_folder: `=`, `:` - * * resource.display_name: `=`, `:` - * @type string $order_by - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,parent". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,parent". Redundant space characters in the - * syntax are insignificant. "name desc,parent" and " - * name desc , parent " are equivalent. - * The following fields are supported: - * name - * parent - * state - * category - * resource_name - * event_time - * security_marks.marks - * @type \Google\Protobuf\FieldMask $field_mask - * A field mask to specify the Finding fields to be listed in the response. - * An empty field mask will list all fields. - * @type string $page_token - * The value returned by the last `ListFindingsResponse`; indicates - * that this is a continuation of a prior `ListFindings` call, and - * that the system should return the next page of data. - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of the source the findings belong to. If no location is - * specified, the default is global. The following list shows some examples: - * + `organizations/[organization_id]/sources/[source_id]` - * + - * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` - * + `folders/[folder_id]/sources/[source_id]` - * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` - * + `projects/[project_id]/sources/[source_id]` - * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` - * To list across all sources provide a source_id of `-`. The following - * list shows some examples: - * + `organizations/{organization_id}/sources/-` - * + `organizations/{organization_id}/sources/-/locations/{location_id}` - * + `folders/{folder_id}/sources/-` - * + `folders/{folder_id}/sources/-locations/{location_id}` - * + `projects/{projects_id}/sources/-` - * + `projects/{projects_id}/sources/-/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Name of the source the findings belong to. If no location is - * specified, the default is global. The following list shows some examples: - * + `organizations/[organization_id]/sources/[source_id]` - * + - * `organizations/[organization_id]/sources/[source_id]/locations/[location_id]` - * + `folders/[folder_id]/sources/[source_id]` - * + `folders/[folder_id]/sources/[source_id]/locations/[location_id]` - * + `projects/[project_id]/sources/[source_id]` - * + `projects/[project_id]/sources/[source_id]/locations/[location_id]` - * To list across all sources provide a source_id of `-`. The following - * list shows some examples: - * + `organizations/{organization_id}/sources/-` - * + `organizations/{organization_id}/sources/-/locations/{location_id}` - * + `folders/{folder_id}/sources/-` - * + `folders/{folder_id}/sources/-locations/{location_id}` - * + `projects/{projects_id}/sources/-` - * + `projects/{projects_id}/sources/-/locations/{location_id}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * severity: `=`, `:` - * * security_marks.marks: `=`, `:` - * * resource: - * * resource.name: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.type: `=`, `:` - * * resource.folders.resource_folder: `=`, `:` - * * resource.display_name: `=`, `:` - * - * Generated from protobuf field string filter = 2; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Expression that defines the filter to apply across findings. - * The expression is a list of one or more restrictions combined via logical - * operators `AND` and `OR`. - * Parentheses are supported, and `OR` has higher precedence than `AND`. - * Restrictions have the form ` ` and may have a `-` - * character in front of them to indicate negation. Examples include: - * * name - * * security_marks.marks.marka - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * The following field and operator combinations are supported: - * * name: `=` - * * parent: `=`, `:` - * * resource_name: `=`, `:` - * * state: `=`, `:` - * * category: `=`, `:` - * * external_uri: `=`, `:` - * * event_time: `=`, `>`, `<`, `>=`, `<=` - * Usage: This should be milliseconds since epoch or an RFC3339 string. - * Examples: - * `event_time = "2019-06-10T16:07:18-07:00"` - * `event_time = 1560208038000` - * * severity: `=`, `:` - * * security_marks.marks: `=`, `:` - * * resource: - * * resource.name: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.type: `=`, `:` - * * resource.folders.resource_folder: `=`, `:` - * * resource.display_name: `=`, `:` - * - * Generated from protobuf field string filter = 2; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,parent". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,parent". Redundant space characters in the - * syntax are insignificant. "name desc,parent" and " - * name desc , parent " are equivalent. - * The following fields are supported: - * name - * parent - * state - * category - * resource_name - * event_time - * security_marks.marks - * - * Generated from protobuf field string order_by = 3; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Expression that defines what fields and order to use for sorting. The - * string value should follow SQL syntax: comma separated list of fields. For - * example: "name,parent". The default sorting order - * is ascending. To specify descending order for a field, a suffix " desc" - * should be appended to the field name. For example: "name - * desc,parent". Redundant space characters in the - * syntax are insignificant. "name desc,parent" and " - * name desc , parent " are equivalent. - * The following fields are supported: - * name - * parent - * state - * category - * resource_name - * event_time - * security_marks.marks - * - * Generated from protobuf field string order_by = 3; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - - /** - * A field mask to specify the Finding fields to be listed in the response. - * An empty field mask will list all fields. - * - * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; - * @return \Google\Protobuf\FieldMask|null - */ - public function getFieldMask() - { - return $this->field_mask; - } - - public function hasFieldMask() - { - return isset($this->field_mask); - } - - public function clearFieldMask() - { - unset($this->field_mask); - } - - /** - * A field mask to specify the Finding fields to be listed in the response. - * An empty field mask will list all fields. - * - * Generated from protobuf field .google.protobuf.FieldMask field_mask = 7; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setFieldMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->field_mask = $var; - - return $this; - } - - /** - * The value returned by the last `ListFindingsResponse`; indicates - * that this is a continuation of a prior `ListFindings` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 8; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListFindingsResponse`; indicates - * that this is a continuation of a prior `ListFindings` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 8; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 9; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 9; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse.php deleted file mode 100644 index 6efe3b380fa9..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse.php +++ /dev/null @@ -1,139 +0,0 @@ -google.cloud.securitycenter.v2.ListFindingsResponse - */ -class ListFindingsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Findings matching the list request. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ListFindingsResponse.ListFindingsResult list_findings_results = 1; - */ - private $list_findings_results; - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - */ - protected $next_page_token = ''; - /** - * The total number of findings matching the query. - * - * Generated from protobuf field int32 total_size = 4; - */ - protected $total_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V2\ListFindingsResponse\ListFindingsResult>|\Google\Protobuf\Internal\RepeatedField $list_findings_results - * Findings matching the list request. - * @type string $next_page_token - * Token to retrieve the next page of results, or empty if there are no more - * results. - * @type int $total_size - * The total number of findings matching the query. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Findings matching the list request. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ListFindingsResponse.ListFindingsResult list_findings_results = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getListFindingsResults() - { - return $this->list_findings_results; - } - - /** - * Findings matching the list request. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ListFindingsResponse.ListFindingsResult list_findings_results = 1; - * @param array<\Google\Cloud\SecurityCenter\V2\ListFindingsResponse\ListFindingsResult>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setListFindingsResults($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ListFindingsResponse\ListFindingsResult::class); - $this->list_findings_results = $arr; - - return $this; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 3; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * The total number of findings matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @return int - */ - public function getTotalSize() - { - return $this->total_size; - } - - /** - * The total number of findings matching the query. - * - * Generated from protobuf field int32 total_size = 4; - * @param int $var - * @return $this - */ - public function setTotalSize($var) - { - GPBUtil::checkInt32($var); - $this->total_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse/ListFindingsResult.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse/ListFindingsResult.php deleted file mode 100644 index dbc0910fe001..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse/ListFindingsResult.php +++ /dev/null @@ -1,124 +0,0 @@ -google.cloud.securitycenter.v2.ListFindingsResponse.ListFindingsResult - */ -class ListFindingsResult extends \Google\Protobuf\Internal\Message -{ - /** - * Finding matching the search request. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 1; - */ - protected $finding = null; - /** - * Output only. Resource that is associated with this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ListFindingsResponse.ListFindingsResult.Resource resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $resource = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V2\Finding $finding - * Finding matching the search request. - * @type \Google\Cloud\SecurityCenter\V2\ListFindingsResponse\ListFindingsResult\Resource $resource - * Output only. Resource that is associated with this finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Finding matching the search request. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 1; - * @return \Google\Cloud\SecurityCenter\V2\Finding|null - */ - public function getFinding() - { - return $this->finding; - } - - public function hasFinding() - { - return isset($this->finding); - } - - public function clearFinding() - { - unset($this->finding); - } - - /** - * Finding matching the search request. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 1; - * @param \Google\Cloud\SecurityCenter\V2\Finding $var - * @return $this - */ - public function setFinding($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Finding::class); - $this->finding = $var; - - return $this; - } - - /** - * Output only. Resource that is associated with this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ListFindingsResponse.ListFindingsResult.Resource resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\SecurityCenter\V2\ListFindingsResponse\ListFindingsResult\Resource|null - */ - public function getResource() - { - return $this->resource; - } - - public function hasResource() - { - return isset($this->resource); - } - - public function clearResource() - { - unset($this->resource); - } - - /** - * Output only. Resource that is associated with this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ListFindingsResponse.ListFindingsResult.Resource resource = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\SecurityCenter\V2\ListFindingsResponse\ListFindingsResult\Resource $var - * @return $this - */ - public function setResource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ListFindingsResponse\ListFindingsResult\Resource::class); - $this->resource = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ListFindingsResult::class, \Google\Cloud\SecurityCenter\V2\ListFindingsResponse_ListFindingsResult::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse/ListFindingsResult/Resource.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse/ListFindingsResult/Resource.php deleted file mode 100644 index 7edd55ff73d7..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListFindingsResponse/ListFindingsResult/Resource.php +++ /dev/null @@ -1,467 +0,0 @@ -google.cloud.securitycenter.v2.ListFindingsResponse.ListFindingsResult.Resource - */ -class Resource extends \Google\Protobuf\Internal\Message -{ - /** - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The human readable name of the resource. - * - * Generated from protobuf field string display_name = 2; - */ - protected $display_name = ''; - /** - * The full resource type of the resource. - * - * Generated from protobuf field string type = 3; - */ - protected $type = ''; - /** - * Indicates which cloud provider the finding is from. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; - */ - protected $cloud_provider = 0; - /** - * The service or resource provider associated with the resource. - * - * Generated from protobuf field string service = 5; - */ - protected $service = ''; - /** - * The region or location of the service (if applicable). - * - * Generated from protobuf field string location = 6; - */ - protected $location = ''; - /** - * Provides the path to the resource within the resource hierarchy. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath resource_path = 10; - */ - protected $resource_path = null; - /** - * A string representation of the resource path. - * For Google Cloud, it has the format of - * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} - * where there can be any number of folders. - * For AWS, it has the format of - * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} - * where there can be any number of organizational units. - * For Azure, it has the format of - * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} - * where there can be any number of management groups. - * - * Generated from protobuf field string resource_path_string = 11; - */ - protected $resource_path_string = ''; - protected $cloud_provider_metadata; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * @type string $display_name - * The human readable name of the resource. - * @type string $type - * The full resource type of the resource. - * @type int $cloud_provider - * Indicates which cloud provider the finding is from. - * @type string $service - * The service or resource provider associated with the resource. - * @type string $location - * The region or location of the service (if applicable). - * @type \Google\Cloud\SecurityCenter\V2\GcpMetadata $gcp_metadata - * The GCP metadata associated with the finding. - * @type \Google\Cloud\SecurityCenter\V2\AwsMetadata $aws_metadata - * The AWS metadata associated with the finding. - * @type \Google\Cloud\SecurityCenter\V2\AzureMetadata $azure_metadata - * The Azure metadata associated with the finding. - * @type \Google\Cloud\SecurityCenter\V2\ResourcePath $resource_path - * Provides the path to the resource within the resource hierarchy. - * @type string $resource_path_string - * A string representation of the resource path. - * For Google Cloud, it has the format of - * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} - * where there can be any number of folders. - * For AWS, it has the format of - * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} - * where there can be any number of organizational units. - * For Azure, it has the format of - * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} - * where there can be any number of management groups. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The human readable name of the resource. - * - * Generated from protobuf field string display_name = 2; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * The human readable name of the resource. - * - * Generated from protobuf field string display_name = 2; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * The full resource type of the resource. - * - * Generated from protobuf field string type = 3; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * The full resource type of the resource. - * - * Generated from protobuf field string type = 3; - * @param string $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkString($var, True); - $this->type = $var; - - return $this; - } - - /** - * Indicates which cloud provider the finding is from. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; - * @return int - */ - public function getCloudProvider() - { - return $this->cloud_provider; - } - - /** - * Indicates which cloud provider the finding is from. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; - * @param int $var - * @return $this - */ - public function setCloudProvider($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\CloudProvider::class); - $this->cloud_provider = $var; - - return $this; - } - - /** - * The service or resource provider associated with the resource. - * - * Generated from protobuf field string service = 5; - * @return string - */ - public function getService() - { - return $this->service; - } - - /** - * The service or resource provider associated with the resource. - * - * Generated from protobuf field string service = 5; - * @param string $var - * @return $this - */ - public function setService($var) - { - GPBUtil::checkString($var, True); - $this->service = $var; - - return $this; - } - - /** - * The region or location of the service (if applicable). - * - * Generated from protobuf field string location = 6; - * @return string - */ - public function getLocation() - { - return $this->location; - } - - /** - * The region or location of the service (if applicable). - * - * Generated from protobuf field string location = 6; - * @param string $var - * @return $this - */ - public function setLocation($var) - { - GPBUtil::checkString($var, True); - $this->location = $var; - - return $this; - } - - /** - * The GCP metadata associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.GcpMetadata gcp_metadata = 7; - * @return \Google\Cloud\SecurityCenter\V2\GcpMetadata|null - */ - public function getGcpMetadata() - { - return $this->readOneof(7); - } - - public function hasGcpMetadata() - { - return $this->hasOneof(7); - } - - /** - * The GCP metadata associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.GcpMetadata gcp_metadata = 7; - * @param \Google\Cloud\SecurityCenter\V2\GcpMetadata $var - * @return $this - */ - public function setGcpMetadata($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\GcpMetadata::class); - $this->writeOneof(7, $var); - - return $this; - } - - /** - * The AWS metadata associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata aws_metadata = 8; - * @return \Google\Cloud\SecurityCenter\V2\AwsMetadata|null - */ - public function getAwsMetadata() - { - return $this->readOneof(8); - } - - public function hasAwsMetadata() - { - return $this->hasOneof(8); - } - - /** - * The AWS metadata associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata aws_metadata = 8; - * @param \Google\Cloud\SecurityCenter\V2\AwsMetadata $var - * @return $this - */ - public function setAwsMetadata($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\AwsMetadata::class); - $this->writeOneof(8, $var); - - return $this; - } - - /** - * The Azure metadata associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata azure_metadata = 9; - * @return \Google\Cloud\SecurityCenter\V2\AzureMetadata|null - */ - public function getAzureMetadata() - { - return $this->readOneof(9); - } - - public function hasAzureMetadata() - { - return $this->hasOneof(9); - } - - /** - * The Azure metadata associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata azure_metadata = 9; - * @param \Google\Cloud\SecurityCenter\V2\AzureMetadata $var - * @return $this - */ - public function setAzureMetadata($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\AzureMetadata::class); - $this->writeOneof(9, $var); - - return $this; - } - - /** - * Provides the path to the resource within the resource hierarchy. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath resource_path = 10; - * @return \Google\Cloud\SecurityCenter\V2\ResourcePath|null - */ - public function getResourcePath() - { - return $this->resource_path; - } - - public function hasResourcePath() - { - return isset($this->resource_path); - } - - public function clearResourcePath() - { - unset($this->resource_path); - } - - /** - * Provides the path to the resource within the resource hierarchy. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath resource_path = 10; - * @param \Google\Cloud\SecurityCenter\V2\ResourcePath $var - * @return $this - */ - public function setResourcePath($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ResourcePath::class); - $this->resource_path = $var; - - return $this; - } - - /** - * A string representation of the resource path. - * For Google Cloud, it has the format of - * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} - * where there can be any number of folders. - * For AWS, it has the format of - * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} - * where there can be any number of organizational units. - * For Azure, it has the format of - * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} - * where there can be any number of management groups. - * - * Generated from protobuf field string resource_path_string = 11; - * @return string - */ - public function getResourcePathString() - { - return $this->resource_path_string; - } - - /** - * A string representation of the resource path. - * For Google Cloud, it has the format of - * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} - * where there can be any number of folders. - * For AWS, it has the format of - * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} - * where there can be any number of organizational units. - * For Azure, it has the format of - * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} - * where there can be any number of management groups. - * - * Generated from protobuf field string resource_path_string = 11; - * @param string $var - * @return $this - */ - public function setResourcePathString($var) - { - GPBUtil::checkString($var, True); - $this->resource_path_string = $var; - - return $this; - } - - /** - * @return string - */ - public function getCloudProviderMetadata() - { - return $this->whichOneof("cloud_provider_metadata"); - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Resource::class, \Google\Cloud\SecurityCenter\V2\ListFindingsResponse_ListFindingsResult_Resource::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListMuteConfigsRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListMuteConfigsRequest.php deleted file mode 100644 index 25486891126a..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListMuteConfigsRequest.php +++ /dev/null @@ -1,200 +0,0 @@ -google.cloud.securitycenter.v2.ListMuteConfigsRequest - */ -class ListMuteConfigsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent, which owns the collection of mute configs. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]", - * "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", - * "projects/[project_id]/locations/[location_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListMuteConfigs` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListMuteConfigs` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. The parent, which owns the collection of mute configs. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]", - * "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", - * "projects/[project_id]/locations/[location_id]". Please see - * {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V2\ListMuteConfigsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent, which owns the collection of mute configs. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]", - * "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", - * "projects/[project_id]/locations/[location_id]". - * @type int $page_size - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * @type string $page_token - * A page token, received from a previous `ListMuteConfigs` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListMuteConfigs` must - * match the call that provided the page token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent, which owns the collection of mute configs. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]", - * "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", - * "projects/[project_id]/locations/[location_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent, which owns the collection of mute configs. Its format - * is "organizations/[organization_id]", "folders/[folder_id]", - * "projects/[project_id]", - * "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", - * "projects/[project_id]/locations/[location_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * A page token, received from a previous `ListMuteConfigs` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListMuteConfigs` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A page token, received from a previous `ListMuteConfigs` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListMuteConfigs` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListMuteConfigsResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListMuteConfigsResponse.php deleted file mode 100644 index 62a7df0534be..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListMuteConfigsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.securitycenter.v2.ListMuteConfigsResponse - */ -class ListMuteConfigsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The mute configs from the specified parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MuteConfig mute_configs = 1; - */ - private $mute_configs; - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V2\MuteConfig>|\Google\Protobuf\Internal\RepeatedField $mute_configs - * The mute configs from the specified parent. - * @type string $next_page_token - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * The mute configs from the specified parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MuteConfig mute_configs = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getMuteConfigs() - { - return $this->mute_configs; - } - - /** - * The mute configs from the specified parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MuteConfig mute_configs = 1; - * @param array<\Google\Cloud\SecurityCenter\V2\MuteConfig>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setMuteConfigs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\MuteConfig::class); - $this->mute_configs = $arr; - - return $this; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListNotificationConfigsRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListNotificationConfigsRequest.php deleted file mode 100644 index 616b9f14ce7e..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListNotificationConfigsRequest.php +++ /dev/null @@ -1,181 +0,0 @@ -google.cloud.securitycenter.v2.ListNotificationConfigsRequest - */ -class ListNotificationConfigsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the parent in which to list the notification - * configurations. Its format is - * "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The value returned by the last `ListNotificationConfigsResponse`; indicates - * that this is a continuation of a prior `ListNotificationConfigs` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 2; - */ - protected $page_token = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 3; - */ - protected $page_size = 0; - - /** - * @param string $parent Required. The name of the parent in which to list the notification - * configurations. Its format is - * "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". Please see - * {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V2\ListNotificationConfigsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The name of the parent in which to list the notification - * configurations. Its format is - * "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * @type string $page_token - * The value returned by the last `ListNotificationConfigsResponse`; indicates - * that this is a continuation of a prior `ListNotificationConfigs` call, and - * that the system should return the next page of data. - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the parent in which to list the notification - * configurations. Its format is - * "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The name of the parent in which to list the notification - * configurations. Its format is - * "organizations/[organization_id]/locations/[location_id]", - * "folders/[folder_id]/locations/[location_id]", or - * "projects/[project_id]/locations/[location_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The value returned by the last `ListNotificationConfigsResponse`; indicates - * that this is a continuation of a prior `ListNotificationConfigs` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 2; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListNotificationConfigsResponse`; indicates - * that this is a continuation of a prior `ListNotificationConfigs` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 2; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 3; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListNotificationConfigsResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListNotificationConfigsResponse.php deleted file mode 100644 index 83f774e2d736..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListNotificationConfigsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.securitycenter.v2.ListNotificationConfigsResponse - */ -class ListNotificationConfigsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Notification configs belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.NotificationConfig notification_configs = 1; - */ - private $notification_configs; - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V2\NotificationConfig>|\Google\Protobuf\Internal\RepeatedField $notification_configs - * Notification configs belonging to the requested parent. - * @type string $next_page_token - * Token to retrieve the next page of results, or empty if there are no more - * results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Notification configs belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.NotificationConfig notification_configs = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getNotificationConfigs() - { - return $this->notification_configs; - } - - /** - * Notification configs belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.NotificationConfig notification_configs = 1; - * @param array<\Google\Cloud\SecurityCenter\V2\NotificationConfig>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setNotificationConfigs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\NotificationConfig::class); - $this->notification_configs = $arr; - - return $this; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListResourceValueConfigsRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListResourceValueConfigsRequest.php deleted file mode 100644 index 3083c60fd32e..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListResourceValueConfigsRequest.php +++ /dev/null @@ -1,191 +0,0 @@ -google.cloud.securitycenter.v2.ListResourceValueConfigsRequest - */ -class ListResourceValueConfigsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parent, which owns the collection of resource value configs. - * Its format is - * "organizations/[organization_id]" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListResourceValueConfigs` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListResourceValueConfigs` must match the call that provided the - * page token. - * page_size can be specified, and the new page_size will be used. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. The parent, which owns the collection of resource value configs. - * Its format is - * "organizations/[organization_id]" - * Please see {@see SecurityCenterClient::organizationLocationName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V2\ListResourceValueConfigsRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The parent, which owns the collection of resource value configs. - * Its format is - * "organizations/[organization_id]" - * @type int $page_size - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * @type string $page_token - * A page token, received from a previous `ListResourceValueConfigs` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListResourceValueConfigs` must match the call that provided the - * page token. - * page_size can be specified, and the new page_size will be used. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parent, which owns the collection of resource value configs. - * Its format is - * "organizations/[organization_id]" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The parent, which owns the collection of resource value configs. - * Its format is - * "organizations/[organization_id]" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of configs to return. The service may return fewer than - * this value. - * If unspecified, at most 10 configs will be returned. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 2; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * A page token, received from a previous `ListResourceValueConfigs` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListResourceValueConfigs` must match the call that provided the - * page token. - * page_size can be specified, and the new page_size will be used. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A page token, received from a previous `ListResourceValueConfigs` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListResourceValueConfigs` must match the call that provided the - * page token. - * page_size can be specified, and the new page_size will be used. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListResourceValueConfigsResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListResourceValueConfigsResponse.php deleted file mode 100644 index 6c4bc793f92f..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListResourceValueConfigsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.securitycenter.v2.ListResourceValueConfigsResponse - */ -class ListResourceValueConfigsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The resource value configs from the specified parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_configs = 1; - */ - private $resource_value_configs; - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is empty, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V2\ResourceValueConfig>|\Google\Protobuf\Internal\RepeatedField $resource_value_configs - * The resource value configs from the specified parent. - * @type string $next_page_token - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is empty, there are no subsequent pages. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * The resource value configs from the specified parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_configs = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getResourceValueConfigs() - { - return $this->resource_value_configs; - } - - /** - * The resource value configs from the specified parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_configs = 1; - * @param array<\Google\Cloud\SecurityCenter\V2\ResourceValueConfig>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setResourceValueConfigs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ResourceValueConfig::class); - $this->resource_value_configs = $arr; - - return $this; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is empty, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * A token, which can be sent as `page_token` to retrieve the next page. - * If this field is empty, there are no subsequent pages. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListSourcesRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListSourcesRequest.php deleted file mode 100644 index 643ac6477dd6..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListSourcesRequest.php +++ /dev/null @@ -1,171 +0,0 @@ -google.cloud.securitycenter.v2.ListSourcesRequest - */ -class ListSourcesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the parent of sources to list. Its format should - * be "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The value returned by the last `ListSourcesResponse`; indicates - * that this is a continuation of a prior `ListSources` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 2; - */ - protected $page_token = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 7; - */ - protected $page_size = 0; - - /** - * @param string $parent Required. Resource name of the parent of sources to list. Its format should - * be "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". Please see - * {@see SecurityCenterClient::projectName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V2\ListSourcesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Resource name of the parent of sources to list. Its format should - * be "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * @type string $page_token - * The value returned by the last `ListSourcesResponse`; indicates - * that this is a continuation of a prior `ListSources` call, and - * that the system should return the next page of data. - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the parent of sources to list. Its format should - * be "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Resource name of the parent of sources to list. Its format should - * be "organizations/[organization_id]", "folders/[folder_id]", or - * "projects/[project_id]". - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The value returned by the last `ListSourcesResponse`; indicates - * that this is a continuation of a prior `ListSources` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 2; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListSourcesResponse`; indicates - * that this is a continuation of a prior `ListSources` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 2; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 7; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 7; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListSourcesResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListSourcesResponse.php deleted file mode 100644 index 6e2ebe4e3fbe..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListSourcesResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.securitycenter.v2.ListSourcesResponse - */ -class ListSourcesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Sources belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Source sources = 1; - */ - private $sources; - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V2\Source>|\Google\Protobuf\Internal\RepeatedField $sources - * Sources belonging to the requested parent. - * @type string $next_page_token - * Token to retrieve the next page of results, or empty if there are no more - * results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Sources belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Source sources = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getSources() - { - return $this->sources; - } - - /** - * Sources belonging to the requested parent. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.Source sources = 1; - * @param array<\Google\Cloud\SecurityCenter\V2\Source>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setSources($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\Source::class); - $this->sources = $arr; - - return $this; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListValuedResourcesRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListValuedResourcesRequest.php deleted file mode 100644 index 796336e2ecc8..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListValuedResourcesRequest.php +++ /dev/null @@ -1,298 +0,0 @@ -google.cloud.securitycenter.v2.ListValuedResourcesRequest - */ -class ListValuedResourcesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Name of parent to list exposed resources. - * Valid formats: - * "organizations/{organization}", - * "organizations/{organization}/simulations/{simulation}" - * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The filter expression that filters the valued resources in the response. - * Supported fields: - * * `resource_value` supports = - * * `resource_type` supports = - * - * Generated from protobuf field string filter = 2; - */ - protected $filter = ''; - /** - * The value returned by the last `ListValuedResourcesResponse`; indicates - * that this is a continuation of a prior `ListValuedResources` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 4; - */ - protected $page_size = 0; - /** - * Optional. The fields by which to order the valued resources response. - * Supported fields: - * * `exposed_score` - * * `resource_value` - * * `resource_type` - * Values should be a comma separated list of fields. For example: - * `exposed_score,resource_value`. - * The default sorting order is descending. To specify ascending or descending - * order for a field, append a " ASC" or a " DESC" suffix, respectively; for - * example: `exposed_score DESC`. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. Name of parent to list exposed resources. - * - * Valid formats: - * "organizations/{organization}", - * "organizations/{organization}/simulations/{simulation}" - * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" - * Please see {@see SecurityCenterClient::simulationName()} for help formatting this field. - * - * @return \Google\Cloud\SecurityCenter\V2\ListValuedResourcesRequest - * - * @experimental - */ - public static function build(string $parent): self - { - return (new self()) - ->setParent($parent); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Name of parent to list exposed resources. - * Valid formats: - * "organizations/{organization}", - * "organizations/{organization}/simulations/{simulation}" - * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" - * @type string $filter - * The filter expression that filters the valued resources in the response. - * Supported fields: - * * `resource_value` supports = - * * `resource_type` supports = - * @type string $page_token - * The value returned by the last `ListValuedResourcesResponse`; indicates - * that this is a continuation of a prior `ListValuedResources` call, and - * that the system should return the next page of data. - * @type int $page_size - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * @type string $order_by - * Optional. The fields by which to order the valued resources response. - * Supported fields: - * * `exposed_score` - * * `resource_value` - * * `resource_type` - * Values should be a comma separated list of fields. For example: - * `exposed_score,resource_value`. - * The default sorting order is descending. To specify ascending or descending - * order for a field, append a " ASC" or a " DESC" suffix, respectively; for - * example: `exposed_score DESC`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Name of parent to list exposed resources. - * Valid formats: - * "organizations/{organization}", - * "organizations/{organization}/simulations/{simulation}" - * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Name of parent to list exposed resources. - * Valid formats: - * "organizations/{organization}", - * "organizations/{organization}/simulations/{simulation}" - * "organizations/{organization}/simulations/{simulation}/attackExposureResults/{attack_exposure_result_v2}" - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * The filter expression that filters the valued resources in the response. - * Supported fields: - * * `resource_value` supports = - * * `resource_type` supports = - * - * Generated from protobuf field string filter = 2; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * The filter expression that filters the valued resources in the response. - * Supported fields: - * * `resource_value` supports = - * * `resource_type` supports = - * - * Generated from protobuf field string filter = 2; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * The value returned by the last `ListValuedResourcesResponse`; indicates - * that this is a continuation of a prior `ListValuedResources` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The value returned by the last `ListValuedResourcesResponse`; indicates - * that this is a continuation of a prior `ListValuedResources` call, and - * that the system should return the next page of data. - * - * Generated from protobuf field string page_token = 3; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 4; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of results to return in a single response. Default is - * 10, minimum is 1, maximum is 1000. - * - * Generated from protobuf field int32 page_size = 4; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Optional. The fields by which to order the valued resources response. - * Supported fields: - * * `exposed_score` - * * `resource_value` - * * `resource_type` - * Values should be a comma separated list of fields. For example: - * `exposed_score,resource_value`. - * The default sorting order is descending. To specify ascending or descending - * order for a field, append a " ASC" or a " DESC" suffix, respectively; for - * example: `exposed_score DESC`. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Optional. The fields by which to order the valued resources response. - * Supported fields: - * * `exposed_score` - * * `resource_value` - * * `resource_type` - * Values should be a comma separated list of fields. For example: - * `exposed_score,resource_value`. - * The default sorting order is descending. To specify ascending or descending - * order for a field, append a " ASC" or a " DESC" suffix, respectively; for - * example: `exposed_score DESC`. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setOrderBy($var) - { - GPBUtil::checkString($var, True); - $this->order_by = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListValuedResourcesResponse.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListValuedResourcesResponse.php deleted file mode 100644 index 304f314b179b..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ListValuedResourcesResponse.php +++ /dev/null @@ -1,139 +0,0 @@ -google.cloud.securitycenter.v2.ListValuedResourcesResponse - */ -class ListValuedResourcesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The valued resources that the attack path simulation identified. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ValuedResource valued_resources = 1; - */ - private $valued_resources; - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * The estimated total number of results matching the query. - * - * Generated from protobuf field int32 total_size = 3; - */ - protected $total_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array<\Google\Cloud\SecurityCenter\V2\ValuedResource>|\Google\Protobuf\Internal\RepeatedField $valued_resources - * The valued resources that the attack path simulation identified. - * @type string $next_page_token - * Token to retrieve the next page of results, or empty if there are no more - * results. - * @type int $total_size - * The estimated total number of results matching the query. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * The valued resources that the attack path simulation identified. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ValuedResource valued_resources = 1; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getValuedResources() - { - return $this->valued_resources; - } - - /** - * The valued resources that the attack path simulation identified. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ValuedResource valued_resources = 1; - * @param array<\Google\Cloud\SecurityCenter\V2\ValuedResource>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setValuedResources($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ValuedResource::class); - $this->valued_resources = $arr; - - return $this; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token to retrieve the next page of results, or empty if there are no more - * results. - * - * Generated from protobuf field string next_page_token = 2; - * @param string $var - * @return $this - */ - public function setNextPageToken($var) - { - GPBUtil::checkString($var, True); - $this->next_page_token = $var; - - return $this; - } - - /** - * The estimated total number of results matching the query. - * - * Generated from protobuf field int32 total_size = 3; - * @return int - */ - public function getTotalSize() - { - return $this->total_size; - } - - /** - * The estimated total number of results matching the query. - * - * Generated from protobuf field int32 total_size = 3; - * @param int $var - * @return $this - */ - public function setTotalSize($var) - { - GPBUtil::checkInt32($var); - $this->total_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/LoadBalancer.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/LoadBalancer.php deleted file mode 100644 index 7c260905a4f9..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/LoadBalancer.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.securitycenter.v2.LoadBalancer - */ -class LoadBalancer extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the load balancer associated with the finding. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of the load balancer associated with the finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\LoadBalancer::initOnce(); - parent::__construct($data); - } - - /** - * The name of the load balancer associated with the finding. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the load balancer associated with the finding. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/LogEntry.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/LogEntry.php deleted file mode 100644 index 78fde8306fed..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/LogEntry.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.securitycenter.v2.LogEntry - */ -class LogEntry extends \Google\Protobuf\Internal\Message -{ - protected $log_entry; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V2\CloudLoggingEntry $cloud_logging_entry - * An individual entry in a log stored in Cloud Logging. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\LogEntry::initOnce(); - parent::__construct($data); - } - - /** - * An individual entry in a log stored in Cloud Logging. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudLoggingEntry cloud_logging_entry = 1; - * @return \Google\Cloud\SecurityCenter\V2\CloudLoggingEntry|null - */ - public function getCloudLoggingEntry() - { - return $this->readOneof(1); - } - - public function hasCloudLoggingEntry() - { - return $this->hasOneof(1); - } - - /** - * An individual entry in a log stored in Cloud Logging. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudLoggingEntry cloud_logging_entry = 1; - * @param \Google\Cloud\SecurityCenter\V2\CloudLoggingEntry $var - * @return $this - */ - public function setCloudLoggingEntry($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\CloudLoggingEntry::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getLogEntry() - { - return $this->whichOneof("log_entry"); - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack.php deleted file mode 100644 index 500205976e94..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack.php +++ /dev/null @@ -1,228 +0,0 @@ -google.cloud.securitycenter.v2.MitreAttack - */ -class MitreAttack extends \Google\Protobuf\Internal\Message -{ - /** - * The MITRE ATT&CK tactic most closely represented by this finding, if any. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.MitreAttack.Tactic primary_tactic = 1; - */ - protected $primary_tactic = 0; - /** - * The MITRE ATT&CK technique most closely represented by this finding, if - * any. primary_techniques is a repeated field because there are multiple - * levels of MITRE ATT&CK techniques. If the technique most closely - * represented by this finding is a sub-technique (e.g. `SCANNING_IP_BLOCKS`), - * both the sub-technique and its parent technique(s) will be listed (e.g. - * `SCANNING_IP_BLOCKS`, `ACTIVE_SCANNING`). - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MitreAttack.Technique primary_techniques = 2; - */ - private $primary_techniques; - /** - * Additional MITRE ATT&CK tactics related to this finding, if any. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MitreAttack.Tactic additional_tactics = 3; - */ - private $additional_tactics; - /** - * Additional MITRE ATT&CK techniques related to this finding, if any, along - * with any of their respective parent techniques. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MitreAttack.Technique additional_techniques = 4; - */ - private $additional_techniques; - /** - * The MITRE ATT&CK version referenced by the above fields. E.g. "8". - * - * Generated from protobuf field string version = 5; - */ - protected $version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $primary_tactic - * The MITRE ATT&CK tactic most closely represented by this finding, if any. - * @type array|\Google\Protobuf\Internal\RepeatedField $primary_techniques - * The MITRE ATT&CK technique most closely represented by this finding, if - * any. primary_techniques is a repeated field because there are multiple - * levels of MITRE ATT&CK techniques. If the technique most closely - * represented by this finding is a sub-technique (e.g. `SCANNING_IP_BLOCKS`), - * both the sub-technique and its parent technique(s) will be listed (e.g. - * `SCANNING_IP_BLOCKS`, `ACTIVE_SCANNING`). - * @type array|\Google\Protobuf\Internal\RepeatedField $additional_tactics - * Additional MITRE ATT&CK tactics related to this finding, if any. - * @type array|\Google\Protobuf\Internal\RepeatedField $additional_techniques - * Additional MITRE ATT&CK techniques related to this finding, if any, along - * with any of their respective parent techniques. - * @type string $version - * The MITRE ATT&CK version referenced by the above fields. E.g. "8". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\MitreAttack::initOnce(); - parent::__construct($data); - } - - /** - * The MITRE ATT&CK tactic most closely represented by this finding, if any. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.MitreAttack.Tactic primary_tactic = 1; - * @return int - */ - public function getPrimaryTactic() - { - return $this->primary_tactic; - } - - /** - * The MITRE ATT&CK tactic most closely represented by this finding, if any. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.MitreAttack.Tactic primary_tactic = 1; - * @param int $var - * @return $this - */ - public function setPrimaryTactic($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\MitreAttack\Tactic::class); - $this->primary_tactic = $var; - - return $this; - } - - /** - * The MITRE ATT&CK technique most closely represented by this finding, if - * any. primary_techniques is a repeated field because there are multiple - * levels of MITRE ATT&CK techniques. If the technique most closely - * represented by this finding is a sub-technique (e.g. `SCANNING_IP_BLOCKS`), - * both the sub-technique and its parent technique(s) will be listed (e.g. - * `SCANNING_IP_BLOCKS`, `ACTIVE_SCANNING`). - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MitreAttack.Technique primary_techniques = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPrimaryTechniques() - { - return $this->primary_techniques; - } - - /** - * The MITRE ATT&CK technique most closely represented by this finding, if - * any. primary_techniques is a repeated field because there are multiple - * levels of MITRE ATT&CK techniques. If the technique most closely - * represented by this finding is a sub-technique (e.g. `SCANNING_IP_BLOCKS`), - * both the sub-technique and its parent technique(s) will be listed (e.g. - * `SCANNING_IP_BLOCKS`, `ACTIVE_SCANNING`). - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MitreAttack.Technique primary_techniques = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPrimaryTechniques($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\SecurityCenter\V2\MitreAttack\Technique::class); - $this->primary_techniques = $arr; - - return $this; - } - - /** - * Additional MITRE ATT&CK tactics related to this finding, if any. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MitreAttack.Tactic additional_tactics = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAdditionalTactics() - { - return $this->additional_tactics; - } - - /** - * Additional MITRE ATT&CK tactics related to this finding, if any. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MitreAttack.Tactic additional_tactics = 3; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAdditionalTactics($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\SecurityCenter\V2\MitreAttack\Tactic::class); - $this->additional_tactics = $arr; - - return $this; - } - - /** - * Additional MITRE ATT&CK techniques related to this finding, if any, along - * with any of their respective parent techniques. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MitreAttack.Technique additional_techniques = 4; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getAdditionalTechniques() - { - return $this->additional_techniques; - } - - /** - * Additional MITRE ATT&CK techniques related to this finding, if any, along - * with any of their respective parent techniques. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.MitreAttack.Technique additional_techniques = 4; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setAdditionalTechniques($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\SecurityCenter\V2\MitreAttack\Technique::class); - $this->additional_techniques = $arr; - - return $this; - } - - /** - * The MITRE ATT&CK version referenced by the above fields. E.g. "8". - * - * Generated from protobuf field string version = 5; - * @return string - */ - public function getVersion() - { - return $this->version; - } - - /** - * The MITRE ATT&CK version referenced by the above fields. E.g. "8". - * - * Generated from protobuf field string version = 5; - * @param string $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkString($var, True); - $this->version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack/Tactic.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack/Tactic.php deleted file mode 100644 index dbd3df8c5849..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack/Tactic.php +++ /dev/null @@ -1,149 +0,0 @@ -google.cloud.securitycenter.v2.MitreAttack.Tactic - */ -class Tactic -{ - /** - * Unspecified value. - * - * Generated from protobuf enum TACTIC_UNSPECIFIED = 0; - */ - const TACTIC_UNSPECIFIED = 0; - /** - * TA0043 - * - * Generated from protobuf enum RECONNAISSANCE = 1; - */ - const RECONNAISSANCE = 1; - /** - * TA0042 - * - * Generated from protobuf enum RESOURCE_DEVELOPMENT = 2; - */ - const RESOURCE_DEVELOPMENT = 2; - /** - * TA0001 - * - * Generated from protobuf enum INITIAL_ACCESS = 5; - */ - const INITIAL_ACCESS = 5; - /** - * TA0002 - * - * Generated from protobuf enum EXECUTION = 3; - */ - const EXECUTION = 3; - /** - * TA0003 - * - * Generated from protobuf enum PERSISTENCE = 6; - */ - const PERSISTENCE = 6; - /** - * TA0004 - * - * Generated from protobuf enum PRIVILEGE_ESCALATION = 8; - */ - const PRIVILEGE_ESCALATION = 8; - /** - * TA0005 - * - * Generated from protobuf enum DEFENSE_EVASION = 7; - */ - const DEFENSE_EVASION = 7; - /** - * TA0006 - * - * Generated from protobuf enum CREDENTIAL_ACCESS = 9; - */ - const CREDENTIAL_ACCESS = 9; - /** - * TA0007 - * - * Generated from protobuf enum DISCOVERY = 10; - */ - const DISCOVERY = 10; - /** - * TA0008 - * - * Generated from protobuf enum LATERAL_MOVEMENT = 11; - */ - const LATERAL_MOVEMENT = 11; - /** - * TA0009 - * - * Generated from protobuf enum COLLECTION = 12; - */ - const COLLECTION = 12; - /** - * TA0011 - * - * Generated from protobuf enum COMMAND_AND_CONTROL = 4; - */ - const COMMAND_AND_CONTROL = 4; - /** - * TA0010 - * - * Generated from protobuf enum EXFILTRATION = 13; - */ - const EXFILTRATION = 13; - /** - * TA0040 - * - * Generated from protobuf enum IMPACT = 14; - */ - const IMPACT = 14; - - private static $valueToName = [ - self::TACTIC_UNSPECIFIED => 'TACTIC_UNSPECIFIED', - self::RECONNAISSANCE => 'RECONNAISSANCE', - self::RESOURCE_DEVELOPMENT => 'RESOURCE_DEVELOPMENT', - self::INITIAL_ACCESS => 'INITIAL_ACCESS', - self::EXECUTION => 'EXECUTION', - self::PERSISTENCE => 'PERSISTENCE', - self::PRIVILEGE_ESCALATION => 'PRIVILEGE_ESCALATION', - self::DEFENSE_EVASION => 'DEFENSE_EVASION', - self::CREDENTIAL_ACCESS => 'CREDENTIAL_ACCESS', - self::DISCOVERY => 'DISCOVERY', - self::LATERAL_MOVEMENT => 'LATERAL_MOVEMENT', - self::COLLECTION => 'COLLECTION', - self::COMMAND_AND_CONTROL => 'COMMAND_AND_CONTROL', - self::EXFILTRATION => 'EXFILTRATION', - self::IMPACT => 'IMPACT', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Tactic::class, \Google\Cloud\SecurityCenter\V2\MitreAttack_Tactic::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack/Technique.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack/Technique.php deleted file mode 100644 index 158c67ead96a..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MitreAttack/Technique.php +++ /dev/null @@ -1,486 +0,0 @@ -google.cloud.securitycenter.v2.MitreAttack.Technique - */ -class Technique -{ - /** - * Unspecified value. - * - * Generated from protobuf enum TECHNIQUE_UNSPECIFIED = 0; - */ - const TECHNIQUE_UNSPECIFIED = 0; - /** - * T1036 - * - * Generated from protobuf enum MASQUERADING = 49; - */ - const MASQUERADING = 49; - /** - * T1036.005 - * - * Generated from protobuf enum MATCH_LEGITIMATE_NAME_OR_LOCATION = 50; - */ - const MATCH_LEGITIMATE_NAME_OR_LOCATION = 50; - /** - * T1037 - * - * Generated from protobuf enum BOOT_OR_LOGON_INITIALIZATION_SCRIPTS = 37; - */ - const BOOT_OR_LOGON_INITIALIZATION_SCRIPTS = 37; - /** - * T1037.005 - * - * Generated from protobuf enum STARTUP_ITEMS = 38; - */ - const STARTUP_ITEMS = 38; - /** - * T1046 - * - * Generated from protobuf enum NETWORK_SERVICE_DISCOVERY = 32; - */ - const NETWORK_SERVICE_DISCOVERY = 32; - /** - * T1057 - * - * Generated from protobuf enum PROCESS_DISCOVERY = 56; - */ - const PROCESS_DISCOVERY = 56; - /** - * T1059 - * - * Generated from protobuf enum COMMAND_AND_SCRIPTING_INTERPRETER = 6; - */ - const COMMAND_AND_SCRIPTING_INTERPRETER = 6; - /** - * T1059.004 - * - * Generated from protobuf enum UNIX_SHELL = 7; - */ - const UNIX_SHELL = 7; - /** - * T1059.006 - * - * Generated from protobuf enum PYTHON = 59; - */ - const PYTHON = 59; - /** - * T1069 - * - * Generated from protobuf enum PERMISSION_GROUPS_DISCOVERY = 18; - */ - const PERMISSION_GROUPS_DISCOVERY = 18; - /** - * T1069.003 - * - * Generated from protobuf enum CLOUD_GROUPS = 19; - */ - const CLOUD_GROUPS = 19; - /** - * T1071 - * - * Generated from protobuf enum APPLICATION_LAYER_PROTOCOL = 45; - */ - const APPLICATION_LAYER_PROTOCOL = 45; - /** - * T1071.004 - * - * Generated from protobuf enum DNS = 46; - */ - const DNS = 46; - /** - * T1072 - * - * Generated from protobuf enum SOFTWARE_DEPLOYMENT_TOOLS = 47; - */ - const SOFTWARE_DEPLOYMENT_TOOLS = 47; - /** - * T1078 - * - * Generated from protobuf enum VALID_ACCOUNTS = 14; - */ - const VALID_ACCOUNTS = 14; - /** - * T1078.001 - * - * Generated from protobuf enum DEFAULT_ACCOUNTS = 35; - */ - const DEFAULT_ACCOUNTS = 35; - /** - * T1078.003 - * - * Generated from protobuf enum LOCAL_ACCOUNTS = 15; - */ - const LOCAL_ACCOUNTS = 15; - /** - * T1078.004 - * - * Generated from protobuf enum CLOUD_ACCOUNTS = 16; - */ - const CLOUD_ACCOUNTS = 16; - /** - * T1090 - * - * Generated from protobuf enum PROXY = 9; - */ - const PROXY = 9; - /** - * T1090.002 - * - * Generated from protobuf enum EXTERNAL_PROXY = 10; - */ - const EXTERNAL_PROXY = 10; - /** - * T1090.003 - * - * Generated from protobuf enum MULTI_HOP_PROXY = 11; - */ - const MULTI_HOP_PROXY = 11; - /** - * T1098 - * - * Generated from protobuf enum ACCOUNT_MANIPULATION = 22; - */ - const ACCOUNT_MANIPULATION = 22; - /** - * T1098.001 - * - * Generated from protobuf enum ADDITIONAL_CLOUD_CREDENTIALS = 40; - */ - const ADDITIONAL_CLOUD_CREDENTIALS = 40; - /** - * T1098.004 - * - * Generated from protobuf enum SSH_AUTHORIZED_KEYS = 23; - */ - const SSH_AUTHORIZED_KEYS = 23; - /** - * T1098.006 - * - * Generated from protobuf enum ADDITIONAL_CONTAINER_CLUSTER_ROLES = 58; - */ - const ADDITIONAL_CONTAINER_CLUSTER_ROLES = 58; - /** - * T1105 - * - * Generated from protobuf enum INGRESS_TOOL_TRANSFER = 3; - */ - const INGRESS_TOOL_TRANSFER = 3; - /** - * T1106 - * - * Generated from protobuf enum NATIVE_API = 4; - */ - const NATIVE_API = 4; - /** - * T1110 - * - * Generated from protobuf enum BRUTE_FORCE = 44; - */ - const BRUTE_FORCE = 44; - /** - * T1129 - * - * Generated from protobuf enum SHARED_MODULES = 5; - */ - const SHARED_MODULES = 5; - /** - * T1134 - * - * Generated from protobuf enum ACCESS_TOKEN_MANIPULATION = 33; - */ - const ACCESS_TOKEN_MANIPULATION = 33; - /** - * T1134.001 - * - * Generated from protobuf enum TOKEN_IMPERSONATION_OR_THEFT = 39; - */ - const TOKEN_IMPERSONATION_OR_THEFT = 39; - /** - * T1190 - * - * Generated from protobuf enum EXPLOIT_PUBLIC_FACING_APPLICATION = 27; - */ - const EXPLOIT_PUBLIC_FACING_APPLICATION = 27; - /** - * T1484 - * - * Generated from protobuf enum DOMAIN_POLICY_MODIFICATION = 30; - */ - const DOMAIN_POLICY_MODIFICATION = 30; - /** - * T1485 - * - * Generated from protobuf enum DATA_DESTRUCTION = 29; - */ - const DATA_DESTRUCTION = 29; - /** - * T1489 - * - * Generated from protobuf enum SERVICE_STOP = 52; - */ - const SERVICE_STOP = 52; - /** - * T1490 - * - * Generated from protobuf enum INHIBIT_SYSTEM_RECOVERY = 36; - */ - const INHIBIT_SYSTEM_RECOVERY = 36; - /** - * T1496 - * - * Generated from protobuf enum RESOURCE_HIJACKING = 8; - */ - const RESOURCE_HIJACKING = 8; - /** - * T1498 - * - * Generated from protobuf enum NETWORK_DENIAL_OF_SERVICE = 17; - */ - const NETWORK_DENIAL_OF_SERVICE = 17; - /** - * T1526 - * - * Generated from protobuf enum CLOUD_SERVICE_DISCOVERY = 48; - */ - const CLOUD_SERVICE_DISCOVERY = 48; - /** - * T1528 - * - * Generated from protobuf enum STEAL_APPLICATION_ACCESS_TOKEN = 42; - */ - const STEAL_APPLICATION_ACCESS_TOKEN = 42; - /** - * T1531 - * - * Generated from protobuf enum ACCOUNT_ACCESS_REMOVAL = 51; - */ - const ACCOUNT_ACCESS_REMOVAL = 51; - /** - * T1539 - * - * Generated from protobuf enum STEAL_WEB_SESSION_COOKIE = 25; - */ - const STEAL_WEB_SESSION_COOKIE = 25; - /** - * T1543 - * - * Generated from protobuf enum CREATE_OR_MODIFY_SYSTEM_PROCESS = 24; - */ - const CREATE_OR_MODIFY_SYSTEM_PROCESS = 24; - /** - * T1548 - * - * Generated from protobuf enum ABUSE_ELEVATION_CONTROL_MECHANISM = 34; - */ - const ABUSE_ELEVATION_CONTROL_MECHANISM = 34; - /** - * T1552 - * - * Generated from protobuf enum UNSECURED_CREDENTIALS = 13; - */ - const UNSECURED_CREDENTIALS = 13; - /** - * T1556 - * - * Generated from protobuf enum MODIFY_AUTHENTICATION_PROCESS = 28; - */ - const MODIFY_AUTHENTICATION_PROCESS = 28; - /** - * T1562 - * - * Generated from protobuf enum IMPAIR_DEFENSES = 31; - */ - const IMPAIR_DEFENSES = 31; - /** - * T1562.001 - * - * Generated from protobuf enum DISABLE_OR_MODIFY_TOOLS = 55; - */ - const DISABLE_OR_MODIFY_TOOLS = 55; - /** - * T1567 - * - * Generated from protobuf enum EXFILTRATION_OVER_WEB_SERVICE = 20; - */ - const EXFILTRATION_OVER_WEB_SERVICE = 20; - /** - * T1567.002 - * - * Generated from protobuf enum EXFILTRATION_TO_CLOUD_STORAGE = 21; - */ - const EXFILTRATION_TO_CLOUD_STORAGE = 21; - /** - * T1568 - * - * Generated from protobuf enum DYNAMIC_RESOLUTION = 12; - */ - const DYNAMIC_RESOLUTION = 12; - /** - * T1570 - * - * Generated from protobuf enum LATERAL_TOOL_TRANSFER = 41; - */ - const LATERAL_TOOL_TRANSFER = 41; - /** - * T1578 - * - * Generated from protobuf enum MODIFY_CLOUD_COMPUTE_INFRASTRUCTURE = 26; - */ - const MODIFY_CLOUD_COMPUTE_INFRASTRUCTURE = 26; - /** - * T1578.001 - * - * Generated from protobuf enum CREATE_SNAPSHOT = 54; - */ - const CREATE_SNAPSHOT = 54; - /** - * T1580 - * - * Generated from protobuf enum CLOUD_INFRASTRUCTURE_DISCOVERY = 53; - */ - const CLOUD_INFRASTRUCTURE_DISCOVERY = 53; - /** - * T1588 - * - * Generated from protobuf enum OBTAIN_CAPABILITIES = 43; - */ - const OBTAIN_CAPABILITIES = 43; - /** - * T1595 - * - * Generated from protobuf enum ACTIVE_SCANNING = 1; - */ - const ACTIVE_SCANNING = 1; - /** - * T1595.001 - * - * Generated from protobuf enum SCANNING_IP_BLOCKS = 2; - */ - const SCANNING_IP_BLOCKS = 2; - /** - * T1613 - * - * Generated from protobuf enum CONTAINER_ADMINISTRATION_COMMAND = 60; - */ - const CONTAINER_ADMINISTRATION_COMMAND = 60; - /** - * T1611 - * - * Generated from protobuf enum ESCAPE_TO_HOST = 61; - */ - const ESCAPE_TO_HOST = 61; - /** - * T1613 - * - * Generated from protobuf enum CONTAINER_AND_RESOURCE_DISCOVERY = 57; - */ - const CONTAINER_AND_RESOURCE_DISCOVERY = 57; - /** - * T1649 - * - * Generated from protobuf enum STEAL_OR_FORGE_AUTHENTICATION_CERTIFICATES = 62; - */ - const STEAL_OR_FORGE_AUTHENTICATION_CERTIFICATES = 62; - - private static $valueToName = [ - self::TECHNIQUE_UNSPECIFIED => 'TECHNIQUE_UNSPECIFIED', - self::MASQUERADING => 'MASQUERADING', - self::MATCH_LEGITIMATE_NAME_OR_LOCATION => 'MATCH_LEGITIMATE_NAME_OR_LOCATION', - self::BOOT_OR_LOGON_INITIALIZATION_SCRIPTS => 'BOOT_OR_LOGON_INITIALIZATION_SCRIPTS', - self::STARTUP_ITEMS => 'STARTUP_ITEMS', - self::NETWORK_SERVICE_DISCOVERY => 'NETWORK_SERVICE_DISCOVERY', - self::PROCESS_DISCOVERY => 'PROCESS_DISCOVERY', - self::COMMAND_AND_SCRIPTING_INTERPRETER => 'COMMAND_AND_SCRIPTING_INTERPRETER', - self::UNIX_SHELL => 'UNIX_SHELL', - self::PYTHON => 'PYTHON', - self::PERMISSION_GROUPS_DISCOVERY => 'PERMISSION_GROUPS_DISCOVERY', - self::CLOUD_GROUPS => 'CLOUD_GROUPS', - self::APPLICATION_LAYER_PROTOCOL => 'APPLICATION_LAYER_PROTOCOL', - self::DNS => 'DNS', - self::SOFTWARE_DEPLOYMENT_TOOLS => 'SOFTWARE_DEPLOYMENT_TOOLS', - self::VALID_ACCOUNTS => 'VALID_ACCOUNTS', - self::DEFAULT_ACCOUNTS => 'DEFAULT_ACCOUNTS', - self::LOCAL_ACCOUNTS => 'LOCAL_ACCOUNTS', - self::CLOUD_ACCOUNTS => 'CLOUD_ACCOUNTS', - self::PROXY => 'PROXY', - self::EXTERNAL_PROXY => 'EXTERNAL_PROXY', - self::MULTI_HOP_PROXY => 'MULTI_HOP_PROXY', - self::ACCOUNT_MANIPULATION => 'ACCOUNT_MANIPULATION', - self::ADDITIONAL_CLOUD_CREDENTIALS => 'ADDITIONAL_CLOUD_CREDENTIALS', - self::SSH_AUTHORIZED_KEYS => 'SSH_AUTHORIZED_KEYS', - self::ADDITIONAL_CONTAINER_CLUSTER_ROLES => 'ADDITIONAL_CONTAINER_CLUSTER_ROLES', - self::INGRESS_TOOL_TRANSFER => 'INGRESS_TOOL_TRANSFER', - self::NATIVE_API => 'NATIVE_API', - self::BRUTE_FORCE => 'BRUTE_FORCE', - self::SHARED_MODULES => 'SHARED_MODULES', - self::ACCESS_TOKEN_MANIPULATION => 'ACCESS_TOKEN_MANIPULATION', - self::TOKEN_IMPERSONATION_OR_THEFT => 'TOKEN_IMPERSONATION_OR_THEFT', - self::EXPLOIT_PUBLIC_FACING_APPLICATION => 'EXPLOIT_PUBLIC_FACING_APPLICATION', - self::DOMAIN_POLICY_MODIFICATION => 'DOMAIN_POLICY_MODIFICATION', - self::DATA_DESTRUCTION => 'DATA_DESTRUCTION', - self::SERVICE_STOP => 'SERVICE_STOP', - self::INHIBIT_SYSTEM_RECOVERY => 'INHIBIT_SYSTEM_RECOVERY', - self::RESOURCE_HIJACKING => 'RESOURCE_HIJACKING', - self::NETWORK_DENIAL_OF_SERVICE => 'NETWORK_DENIAL_OF_SERVICE', - self::CLOUD_SERVICE_DISCOVERY => 'CLOUD_SERVICE_DISCOVERY', - self::STEAL_APPLICATION_ACCESS_TOKEN => 'STEAL_APPLICATION_ACCESS_TOKEN', - self::ACCOUNT_ACCESS_REMOVAL => 'ACCOUNT_ACCESS_REMOVAL', - self::STEAL_WEB_SESSION_COOKIE => 'STEAL_WEB_SESSION_COOKIE', - self::CREATE_OR_MODIFY_SYSTEM_PROCESS => 'CREATE_OR_MODIFY_SYSTEM_PROCESS', - self::ABUSE_ELEVATION_CONTROL_MECHANISM => 'ABUSE_ELEVATION_CONTROL_MECHANISM', - self::UNSECURED_CREDENTIALS => 'UNSECURED_CREDENTIALS', - self::MODIFY_AUTHENTICATION_PROCESS => 'MODIFY_AUTHENTICATION_PROCESS', - self::IMPAIR_DEFENSES => 'IMPAIR_DEFENSES', - self::DISABLE_OR_MODIFY_TOOLS => 'DISABLE_OR_MODIFY_TOOLS', - self::EXFILTRATION_OVER_WEB_SERVICE => 'EXFILTRATION_OVER_WEB_SERVICE', - self::EXFILTRATION_TO_CLOUD_STORAGE => 'EXFILTRATION_TO_CLOUD_STORAGE', - self::DYNAMIC_RESOLUTION => 'DYNAMIC_RESOLUTION', - self::LATERAL_TOOL_TRANSFER => 'LATERAL_TOOL_TRANSFER', - self::MODIFY_CLOUD_COMPUTE_INFRASTRUCTURE => 'MODIFY_CLOUD_COMPUTE_INFRASTRUCTURE', - self::CREATE_SNAPSHOT => 'CREATE_SNAPSHOT', - self::CLOUD_INFRASTRUCTURE_DISCOVERY => 'CLOUD_INFRASTRUCTURE_DISCOVERY', - self::OBTAIN_CAPABILITIES => 'OBTAIN_CAPABILITIES', - self::ACTIVE_SCANNING => 'ACTIVE_SCANNING', - self::SCANNING_IP_BLOCKS => 'SCANNING_IP_BLOCKS', - self::CONTAINER_ADMINISTRATION_COMMAND => 'CONTAINER_ADMINISTRATION_COMMAND', - self::ESCAPE_TO_HOST => 'ESCAPE_TO_HOST', - self::CONTAINER_AND_RESOURCE_DISCOVERY => 'CONTAINER_AND_RESOURCE_DISCOVERY', - self::STEAL_OR_FORGE_AUTHENTICATION_CERTIFICATES => 'STEAL_OR_FORGE_AUTHENTICATION_CERTIFICATES', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(Technique::class, \Google\Cloud\SecurityCenter\V2\MitreAttack_Technique::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MuteConfig.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MuteConfig.php deleted file mode 100644 index 2d22fc8b58d6..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MuteConfig.php +++ /dev/null @@ -1,420 +0,0 @@ -google.cloud.securitycenter.v2.MuteConfig - */ -class MuteConfig extends \Google\Protobuf\Internal\Message -{ - /** - * This field will be ignored if provided on config creation. The following - * list shows some examples of the format: - * + `organizations/{organization}/muteConfigs/{mute_config}` - * + - * `organizations/{organization}locations/{location}//muteConfigs/{mute_config}` - * + `folders/{folder}/muteConfigs/{mute_config}` - * + `folders/{folder}/locations/{location}/muteConfigs/{mute_config}` - * + `projects/{project}/muteConfigs/{mute_config}` - * + `projects/{project}/locations/{location}/muteConfigs/{mute_config}` - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * A description of the mute config. - * - * Generated from protobuf field string description = 2; - */ - protected $description = ''; - /** - * Required. An expression that defines the filter to apply across - * create/update events of findings. While creating a filter string, be - * mindful of the scope in which the mute configuration is being created. - * E.g., If a filter contains project = X but is created under the project = Y - * scope, it might not match any findings. - * The following field and operator combinations are supported: - * * severity: `=`, `:` - * * category: `=`, `:` - * * resource.name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.folders.resource_folder: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.type: `=`, `:` - * * finding_class: `=`, `:` - * * indicator.ip_addresses: `=`, `:` - * * indicator.domains: `=`, `:` - * - * Generated from protobuf field string filter = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $filter = ''; - /** - * Output only. The time at which the mute config was created. - * This field is set by the server and will be ignored if provided on config - * creation. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The most recent time at which the mute config was updated. - * This field is set by the server and will be ignored if provided on config - * creation or update. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. Email address of the user who last edited the mute config. - * This field is set by the server and will be ignored if provided on config - * creation or update. - * - * Generated from protobuf field string most_recent_editor = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $most_recent_editor = ''; - /** - * Required. The type of the mute config, which determines what type of mute - * state the config affects. Immutable after creation. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.MuteConfig.MuteConfigType type = 8 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $type = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * This field will be ignored if provided on config creation. The following - * list shows some examples of the format: - * + `organizations/{organization}/muteConfigs/{mute_config}` - * + - * `organizations/{organization}locations/{location}//muteConfigs/{mute_config}` - * + `folders/{folder}/muteConfigs/{mute_config}` - * + `folders/{folder}/locations/{location}/muteConfigs/{mute_config}` - * + `projects/{project}/muteConfigs/{mute_config}` - * + `projects/{project}/locations/{location}/muteConfigs/{mute_config}` - * @type string $description - * A description of the mute config. - * @type string $filter - * Required. An expression that defines the filter to apply across - * create/update events of findings. While creating a filter string, be - * mindful of the scope in which the mute configuration is being created. - * E.g., If a filter contains project = X but is created under the project = Y - * scope, it might not match any findings. - * The following field and operator combinations are supported: - * * severity: `=`, `:` - * * category: `=`, `:` - * * resource.name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.folders.resource_folder: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.type: `=`, `:` - * * finding_class: `=`, `:` - * * indicator.ip_addresses: `=`, `:` - * * indicator.domains: `=`, `:` - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time at which the mute config was created. - * This field is set by the server and will be ignored if provided on config - * creation. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The most recent time at which the mute config was updated. - * This field is set by the server and will be ignored if provided on config - * creation or update. - * @type string $most_recent_editor - * Output only. Email address of the user who last edited the mute config. - * This field is set by the server and will be ignored if provided on config - * creation or update. - * @type int $type - * Required. The type of the mute config, which determines what type of mute - * state the config affects. Immutable after creation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\MuteConfig::initOnce(); - parent::__construct($data); - } - - /** - * This field will be ignored if provided on config creation. The following - * list shows some examples of the format: - * + `organizations/{organization}/muteConfigs/{mute_config}` - * + - * `organizations/{organization}locations/{location}//muteConfigs/{mute_config}` - * + `folders/{folder}/muteConfigs/{mute_config}` - * + `folders/{folder}/locations/{location}/muteConfigs/{mute_config}` - * + `projects/{project}/muteConfigs/{mute_config}` - * + `projects/{project}/locations/{location}/muteConfigs/{mute_config}` - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * This field will be ignored if provided on config creation. The following - * list shows some examples of the format: - * + `organizations/{organization}/muteConfigs/{mute_config}` - * + - * `organizations/{organization}locations/{location}//muteConfigs/{mute_config}` - * + `folders/{folder}/muteConfigs/{mute_config}` - * + `folders/{folder}/locations/{location}/muteConfigs/{mute_config}` - * + `projects/{project}/muteConfigs/{mute_config}` - * + `projects/{project}/locations/{location}/muteConfigs/{mute_config}` - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * A description of the mute config. - * - * Generated from protobuf field string description = 2; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * A description of the mute config. - * - * Generated from protobuf field string description = 2; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Required. An expression that defines the filter to apply across - * create/update events of findings. While creating a filter string, be - * mindful of the scope in which the mute configuration is being created. - * E.g., If a filter contains project = X but is created under the project = Y - * scope, it might not match any findings. - * The following field and operator combinations are supported: - * * severity: `=`, `:` - * * category: `=`, `:` - * * resource.name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.folders.resource_folder: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.type: `=`, `:` - * * finding_class: `=`, `:` - * * indicator.ip_addresses: `=`, `:` - * * indicator.domains: `=`, `:` - * - * Generated from protobuf field string filter = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Required. An expression that defines the filter to apply across - * create/update events of findings. While creating a filter string, be - * mindful of the scope in which the mute configuration is being created. - * E.g., If a filter contains project = X but is created under the project = Y - * scope, it might not match any findings. - * The following field and operator combinations are supported: - * * severity: `=`, `:` - * * category: `=`, `:` - * * resource.name: `=`, `:` - * * resource.project_name: `=`, `:` - * * resource.project_display_name: `=`, `:` - * * resource.folders.resource_folder: `=`, `:` - * * resource.parent_name: `=`, `:` - * * resource.parent_display_name: `=`, `:` - * * resource.type: `=`, `:` - * * finding_class: `=`, `:` - * * indicator.ip_addresses: `=`, `:` - * * indicator.domains: `=`, `:` - * - * Generated from protobuf field string filter = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Output only. The time at which the mute config was created. - * This field is set by the server and will be ignored if provided on config - * creation. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. The time at which the mute config was created. - * This field is set by the server and will be ignored if provided on config - * creation. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. The most recent time at which the mute config was updated. - * This field is set by the server and will be ignored if provided on config - * creation or update. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. The most recent time at which the mute config was updated. - * This field is set by the server and will be ignored if provided on config - * creation or update. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Output only. Email address of the user who last edited the mute config. - * This field is set by the server and will be ignored if provided on config - * creation or update. - * - * Generated from protobuf field string most_recent_editor = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getMostRecentEditor() - { - return $this->most_recent_editor; - } - - /** - * Output only. Email address of the user who last edited the mute config. - * This field is set by the server and will be ignored if provided on config - * creation or update. - * - * Generated from protobuf field string most_recent_editor = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setMostRecentEditor($var) - { - GPBUtil::checkString($var, True); - $this->most_recent_editor = $var; - - return $this; - } - - /** - * Required. The type of the mute config, which determines what type of mute - * state the config affects. Immutable after creation. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.MuteConfig.MuteConfigType type = 8 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Required. The type of the mute config, which determines what type of mute - * state the config affects. Immutable after creation. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.MuteConfig.MuteConfigType type = 8 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\MuteConfig\MuteConfigType::class); - $this->type = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MuteConfig/MuteConfigType.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MuteConfig/MuteConfigType.php deleted file mode 100644 index c78c97ba5b5c..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/MuteConfig/MuteConfigType.php +++ /dev/null @@ -1,63 +0,0 @@ -google.cloud.securitycenter.v2.MuteConfig.MuteConfigType - */ -class MuteConfigType -{ - /** - * Unused. - * - * Generated from protobuf enum MUTE_CONFIG_TYPE_UNSPECIFIED = 0; - */ - const MUTE_CONFIG_TYPE_UNSPECIFIED = 0; - /** - * A static mute config, which sets the static mute state of future matching - * findings to muted. Once the static mute state has been set, finding or - * config modifications will not affect the state. - * - * Generated from protobuf enum STATIC = 1; - */ - const PBSTATIC = 1; - - private static $valueToName = [ - self::MUTE_CONFIG_TYPE_UNSPECIFIED => 'MUTE_CONFIG_TYPE_UNSPECIFIED', - self::PBSTATIC => 'STATIC', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - $pbconst = __CLASS__. '::PB' . strtoupper($name); - if (!defined($pbconst)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($pbconst); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(MuteConfigType::class, \Google\Cloud\SecurityCenter\V2\MuteConfig_MuteConfigType::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationConfig.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationConfig.php deleted file mode 100644 index 762556b94f42..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationConfig.php +++ /dev/null @@ -1,253 +0,0 @@ -google.cloud.securitycenter.v2.NotificationConfig - */ -class NotificationConfig extends \Google\Protobuf\Internal\Message -{ - /** - * The relative resource name of this notification config. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * The following list shows some examples: - * + - * `organizations/{organization_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` - * + - * `folders/{folder_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` - * + - * `projects/{project_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The description of the notification config (max of 1024 characters). - * - * Generated from protobuf field string description = 2; - */ - protected $description = ''; - /** - * The Pub/Sub topic to send notifications to. Its format is - * "projects/[project_id]/topics/[topic]". - * - * Generated from protobuf field string pubsub_topic = 3 [(.google.api.resource_reference) = { - */ - protected $pubsub_topic = ''; - /** - * Output only. The service account that needs "pubsub.topics.publish" - * permission to publish to the Pub/Sub topic. - * - * Generated from protobuf field string service_account = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $service_account = ''; - protected $notify_config; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The relative resource name of this notification config. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * The following list shows some examples: - * + - * `organizations/{organization_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` - * + - * `folders/{folder_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` - * + - * `projects/{project_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` - * @type string $description - * The description of the notification config (max of 1024 characters). - * @type string $pubsub_topic - * The Pub/Sub topic to send notifications to. Its format is - * "projects/[project_id]/topics/[topic]". - * @type string $service_account - * Output only. The service account that needs "pubsub.topics.publish" - * permission to publish to the Pub/Sub topic. - * @type \Google\Cloud\SecurityCenter\V2\NotificationConfig\StreamingConfig $streaming_config - * The config for triggering streaming-based notifications. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\NotificationConfig::initOnce(); - parent::__construct($data); - } - - /** - * The relative resource name of this notification config. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * The following list shows some examples: - * + - * `organizations/{organization_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` - * + - * `folders/{folder_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` - * + - * `projects/{project_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The relative resource name of this notification config. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * The following list shows some examples: - * + - * `organizations/{organization_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` - * + - * `folders/{folder_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` - * + - * `projects/{project_id}/locations/{location_id}/notificationConfigs/notify_public_bucket` - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The description of the notification config (max of 1024 characters). - * - * Generated from protobuf field string description = 2; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * The description of the notification config (max of 1024 characters). - * - * Generated from protobuf field string description = 2; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * The Pub/Sub topic to send notifications to. Its format is - * "projects/[project_id]/topics/[topic]". - * - * Generated from protobuf field string pubsub_topic = 3 [(.google.api.resource_reference) = { - * @return string - */ - public function getPubsubTopic() - { - return $this->pubsub_topic; - } - - /** - * The Pub/Sub topic to send notifications to. Its format is - * "projects/[project_id]/topics/[topic]". - * - * Generated from protobuf field string pubsub_topic = 3 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setPubsubTopic($var) - { - GPBUtil::checkString($var, True); - $this->pubsub_topic = $var; - - return $this; - } - - /** - * Output only. The service account that needs "pubsub.topics.publish" - * permission to publish to the Pub/Sub topic. - * - * Generated from protobuf field string service_account = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getServiceAccount() - { - return $this->service_account; - } - - /** - * Output only. The service account that needs "pubsub.topics.publish" - * permission to publish to the Pub/Sub topic. - * - * Generated from protobuf field string service_account = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setServiceAccount($var) - { - GPBUtil::checkString($var, True); - $this->service_account = $var; - - return $this; - } - - /** - * The config for triggering streaming-based notifications. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.NotificationConfig.StreamingConfig streaming_config = 5; - * @return \Google\Cloud\SecurityCenter\V2\NotificationConfig\StreamingConfig|null - */ - public function getStreamingConfig() - { - return $this->readOneof(5); - } - - public function hasStreamingConfig() - { - return $this->hasOneof(5); - } - - /** - * The config for triggering streaming-based notifications. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.NotificationConfig.StreamingConfig streaming_config = 5; - * @param \Google\Cloud\SecurityCenter\V2\NotificationConfig\StreamingConfig $var - * @return $this - */ - public function setStreamingConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\NotificationConfig\StreamingConfig::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * @return string - */ - public function getNotifyConfig() - { - return $this->whichOneof("notify_config"); - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationConfig/StreamingConfig.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationConfig/StreamingConfig.php deleted file mode 100644 index d6fbef5cd427..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationConfig/StreamingConfig.php +++ /dev/null @@ -1,131 +0,0 @@ -google.cloud.securitycenter.v2.NotificationConfig.StreamingConfig - */ -class StreamingConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Expression that defines the filter to apply across create/update events - * of assets or findings as specified by the event type. The expression is a - * list of zero or more restrictions combined via logical operators `AND` - * and `OR`. Parentheses are supported, and `OR` has higher precedence than - * `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 1; - */ - protected $filter = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $filter - * Expression that defines the filter to apply across create/update events - * of assets or findings as specified by the event type. The expression is a - * list of zero or more restrictions combined via logical operators `AND` - * and `OR`. Parentheses are supported, and `OR` has higher precedence than - * `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\NotificationConfig::initOnce(); - parent::__construct($data); - } - - /** - * Expression that defines the filter to apply across create/update events - * of assets or findings as specified by the event type. The expression is a - * list of zero or more restrictions combined via logical operators `AND` - * and `OR`. Parentheses are supported, and `OR` has higher precedence than - * `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 1; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Expression that defines the filter to apply across create/update events - * of assets or findings as specified by the event type. The expression is a - * list of zero or more restrictions combined via logical operators `AND` - * and `OR`. Parentheses are supported, and `OR` has higher precedence than - * `AND`. - * Restrictions have the form ` ` and may have a - * `-` character in front of them to indicate negation. The fields map to - * those defined in the corresponding resource. - * The supported operators are: - * * `=` for all value types. - * * `>`, `<`, `>=`, `<=` for integer values. - * * `:`, meaning substring matching, for strings. - * The supported value types are: - * * string literals in quotes. - * * integer literals without quotes. - * * boolean literals `true` and `false` without quotes. - * - * Generated from protobuf field string filter = 1; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(StreamingConfig::class, \Google\Cloud\SecurityCenter\V2\NotificationConfig_StreamingConfig::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationMessage.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationMessage.php deleted file mode 100644 index fc90b3d93ba7..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/NotificationMessage.php +++ /dev/null @@ -1,156 +0,0 @@ -google.cloud.securitycenter.v2.NotificationMessage - */ -class NotificationMessage extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the notification config that generated current notification. - * - * Generated from protobuf field string notification_config_name = 1; - */ - protected $notification_config_name = ''; - /** - * The Cloud resource tied to this notification's Finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Resource resource = 3; - */ - protected $resource = null; - protected $event; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $notification_config_name - * Name of the notification config that generated current notification. - * @type \Google\Cloud\SecurityCenter\V2\Finding $finding - * If it's a Finding based notification config, this field will be - * populated. - * @type \Google\Cloud\SecurityCenter\V2\Resource $resource - * The Cloud resource tied to this notification's Finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\NotificationMessage::initOnce(); - parent::__construct($data); - } - - /** - * Name of the notification config that generated current notification. - * - * Generated from protobuf field string notification_config_name = 1; - * @return string - */ - public function getNotificationConfigName() - { - return $this->notification_config_name; - } - - /** - * Name of the notification config that generated current notification. - * - * Generated from protobuf field string notification_config_name = 1; - * @param string $var - * @return $this - */ - public function setNotificationConfigName($var) - { - GPBUtil::checkString($var, True); - $this->notification_config_name = $var; - - return $this; - } - - /** - * If it's a Finding based notification config, this field will be - * populated. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 2; - * @return \Google\Cloud\SecurityCenter\V2\Finding|null - */ - public function getFinding() - { - return $this->readOneof(2); - } - - public function hasFinding() - { - return $this->hasOneof(2); - } - - /** - * If it's a Finding based notification config, this field will be - * populated. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 2; - * @param \Google\Cloud\SecurityCenter\V2\Finding $var - * @return $this - */ - public function setFinding($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Finding::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The Cloud resource tied to this notification's Finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Resource resource = 3; - * @return \Google\Cloud\SecurityCenter\V2\Resource|null - */ - public function getResource() - { - return $this->resource; - } - - public function hasResource() - { - return isset($this->resource); - } - - public function clearResource() - { - unset($this->resource); - } - - /** - * The Cloud resource tied to this notification's Finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Resource resource = 3; - * @param \Google\Cloud\SecurityCenter\V2\Resource $var - * @return $this - */ - public function setResource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Resource::class); - $this->resource = $var; - - return $this; - } - - /** - * @return string - */ - public function getEvent() - { - return $this->whichOneof("event"); - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/OrgPolicy.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/OrgPolicy.php deleted file mode 100644 index a23d78837a19..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/OrgPolicy.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.securitycenter.v2.OrgPolicy - */ -class OrgPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * The resource name of the org policy. - * Example: - * "organizations/{organization_id}/policies/{constraint_name}" - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The resource name of the org policy. - * Example: - * "organizations/{organization_id}/policies/{constraint_name}" - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\OrgPolicy::initOnce(); - parent::__construct($data); - } - - /** - * The resource name of the org policy. - * Example: - * "organizations/{organization_id}/policies/{constraint_name}" - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The resource name of the org policy. - * Example: - * "organizations/{organization_id}/policies/{constraint_name}" - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Package.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Package.php deleted file mode 100644 index 3837e34efec1..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Package.php +++ /dev/null @@ -1,169 +0,0 @@ -google.cloud.securitycenter.v2.Package - */ -class Package extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the package where the vulnerability was detected. - * - * Generated from protobuf field string package_name = 1; - */ - protected $package_name = ''; - /** - * The CPE URI where the vulnerability was detected. - * - * Generated from protobuf field string cpe_uri = 2; - */ - protected $cpe_uri = ''; - /** - * Type of package, for example, os, maven, or go. - * - * Generated from protobuf field string package_type = 3; - */ - protected $package_type = ''; - /** - * The version of the package. - * - * Generated from protobuf field string package_version = 4; - */ - protected $package_version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $package_name - * The name of the package where the vulnerability was detected. - * @type string $cpe_uri - * The CPE URI where the vulnerability was detected. - * @type string $package_type - * Type of package, for example, os, maven, or go. - * @type string $package_version - * The version of the package. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Vulnerability::initOnce(); - parent::__construct($data); - } - - /** - * The name of the package where the vulnerability was detected. - * - * Generated from protobuf field string package_name = 1; - * @return string - */ - public function getPackageName() - { - return $this->package_name; - } - - /** - * The name of the package where the vulnerability was detected. - * - * Generated from protobuf field string package_name = 1; - * @param string $var - * @return $this - */ - public function setPackageName($var) - { - GPBUtil::checkString($var, True); - $this->package_name = $var; - - return $this; - } - - /** - * The CPE URI where the vulnerability was detected. - * - * Generated from protobuf field string cpe_uri = 2; - * @return string - */ - public function getCpeUri() - { - return $this->cpe_uri; - } - - /** - * The CPE URI where the vulnerability was detected. - * - * Generated from protobuf field string cpe_uri = 2; - * @param string $var - * @return $this - */ - public function setCpeUri($var) - { - GPBUtil::checkString($var, True); - $this->cpe_uri = $var; - - return $this; - } - - /** - * Type of package, for example, os, maven, or go. - * - * Generated from protobuf field string package_type = 3; - * @return string - */ - public function getPackageType() - { - return $this->package_type; - } - - /** - * Type of package, for example, os, maven, or go. - * - * Generated from protobuf field string package_type = 3; - * @param string $var - * @return $this - */ - public function setPackageType($var) - { - GPBUtil::checkString($var, True); - $this->package_type = $var; - - return $this; - } - - /** - * The version of the package. - * - * Generated from protobuf field string package_version = 4; - * @return string - */ - public function getPackageVersion() - { - return $this->package_version; - } - - /** - * The version of the package. - * - * Generated from protobuf field string package_version = 4; - * @param string $var - * @return $this - */ - public function setPackageVersion($var) - { - GPBUtil::checkString($var, True); - $this->package_version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Process.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Process.php deleted file mode 100644 index e66d564c995f..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Process.php +++ /dev/null @@ -1,409 +0,0 @@ -google.cloud.securitycenter.v2.Process - */ -class Process extends \Google\Protobuf\Internal\Message -{ - /** - * The process name, as displayed in utilities like `top` and `ps`. This name - * can be accessed through `/proc/[pid]/comm` and changed with - * `prctl(PR_SET_NAME)`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * File information for the process executable. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.File binary = 2; - */ - protected $binary = null; - /** - * File information for libraries loaded by the process. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.File libraries = 3; - */ - private $libraries; - /** - * When the process represents the invocation of a script, `binary` provides - * information about the interpreter, while `script` provides information - * about the script file provided to the interpreter. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.File script = 4; - */ - protected $script = null; - /** - * Process arguments as JSON encoded strings. - * - * Generated from protobuf field repeated string args = 5; - */ - private $args; - /** - * True if `args` is incomplete. - * - * Generated from protobuf field bool arguments_truncated = 6; - */ - protected $arguments_truncated = false; - /** - * Process environment variables. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.EnvironmentVariable env_variables = 7; - */ - private $env_variables; - /** - * True if `env_variables` is incomplete. - * - * Generated from protobuf field bool env_variables_truncated = 8; - */ - protected $env_variables_truncated = false; - /** - * The process ID. - * - * Generated from protobuf field int64 pid = 9; - */ - protected $pid = 0; - /** - * The parent process ID. - * - * Generated from protobuf field int64 parent_pid = 10; - */ - protected $parent_pid = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The process name, as displayed in utilities like `top` and `ps`. This name - * can be accessed through `/proc/[pid]/comm` and changed with - * `prctl(PR_SET_NAME)`. - * @type \Google\Cloud\SecurityCenter\V2\File $binary - * File information for the process executable. - * @type array<\Google\Cloud\SecurityCenter\V2\File>|\Google\Protobuf\Internal\RepeatedField $libraries - * File information for libraries loaded by the process. - * @type \Google\Cloud\SecurityCenter\V2\File $script - * When the process represents the invocation of a script, `binary` provides - * information about the interpreter, while `script` provides information - * about the script file provided to the interpreter. - * @type array|\Google\Protobuf\Internal\RepeatedField $args - * Process arguments as JSON encoded strings. - * @type bool $arguments_truncated - * True if `args` is incomplete. - * @type array<\Google\Cloud\SecurityCenter\V2\EnvironmentVariable>|\Google\Protobuf\Internal\RepeatedField $env_variables - * Process environment variables. - * @type bool $env_variables_truncated - * True if `env_variables` is incomplete. - * @type int|string $pid - * The process ID. - * @type int|string $parent_pid - * The parent process ID. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Process::initOnce(); - parent::__construct($data); - } - - /** - * The process name, as displayed in utilities like `top` and `ps`. This name - * can be accessed through `/proc/[pid]/comm` and changed with - * `prctl(PR_SET_NAME)`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The process name, as displayed in utilities like `top` and `ps`. This name - * can be accessed through `/proc/[pid]/comm` and changed with - * `prctl(PR_SET_NAME)`. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * File information for the process executable. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.File binary = 2; - * @return \Google\Cloud\SecurityCenter\V2\File|null - */ - public function getBinary() - { - return $this->binary; - } - - public function hasBinary() - { - return isset($this->binary); - } - - public function clearBinary() - { - unset($this->binary); - } - - /** - * File information for the process executable. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.File binary = 2; - * @param \Google\Cloud\SecurityCenter\V2\File $var - * @return $this - */ - public function setBinary($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\File::class); - $this->binary = $var; - - return $this; - } - - /** - * File information for libraries loaded by the process. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.File libraries = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getLibraries() - { - return $this->libraries; - } - - /** - * File information for libraries loaded by the process. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.File libraries = 3; - * @param array<\Google\Cloud\SecurityCenter\V2\File>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setLibraries($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\File::class); - $this->libraries = $arr; - - return $this; - } - - /** - * When the process represents the invocation of a script, `binary` provides - * information about the interpreter, while `script` provides information - * about the script file provided to the interpreter. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.File script = 4; - * @return \Google\Cloud\SecurityCenter\V2\File|null - */ - public function getScript() - { - return $this->script; - } - - public function hasScript() - { - return isset($this->script); - } - - public function clearScript() - { - unset($this->script); - } - - /** - * When the process represents the invocation of a script, `binary` provides - * information about the interpreter, while `script` provides information - * about the script file provided to the interpreter. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.File script = 4; - * @param \Google\Cloud\SecurityCenter\V2\File $var - * @return $this - */ - public function setScript($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\File::class); - $this->script = $var; - - return $this; - } - - /** - * Process arguments as JSON encoded strings. - * - * Generated from protobuf field repeated string args = 5; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getArgs() - { - return $this->args; - } - - /** - * Process arguments as JSON encoded strings. - * - * Generated from protobuf field repeated string args = 5; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setArgs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->args = $arr; - - return $this; - } - - /** - * True if `args` is incomplete. - * - * Generated from protobuf field bool arguments_truncated = 6; - * @return bool - */ - public function getArgumentsTruncated() - { - return $this->arguments_truncated; - } - - /** - * True if `args` is incomplete. - * - * Generated from protobuf field bool arguments_truncated = 6; - * @param bool $var - * @return $this - */ - public function setArgumentsTruncated($var) - { - GPBUtil::checkBool($var); - $this->arguments_truncated = $var; - - return $this; - } - - /** - * Process environment variables. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.EnvironmentVariable env_variables = 7; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getEnvVariables() - { - return $this->env_variables; - } - - /** - * Process environment variables. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.EnvironmentVariable env_variables = 7; - * @param array<\Google\Cloud\SecurityCenter\V2\EnvironmentVariable>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setEnvVariables($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\EnvironmentVariable::class); - $this->env_variables = $arr; - - return $this; - } - - /** - * True if `env_variables` is incomplete. - * - * Generated from protobuf field bool env_variables_truncated = 8; - * @return bool - */ - public function getEnvVariablesTruncated() - { - return $this->env_variables_truncated; - } - - /** - * True if `env_variables` is incomplete. - * - * Generated from protobuf field bool env_variables_truncated = 8; - * @param bool $var - * @return $this - */ - public function setEnvVariablesTruncated($var) - { - GPBUtil::checkBool($var); - $this->env_variables_truncated = $var; - - return $this; - } - - /** - * The process ID. - * - * Generated from protobuf field int64 pid = 9; - * @return int|string - */ - public function getPid() - { - return $this->pid; - } - - /** - * The process ID. - * - * Generated from protobuf field int64 pid = 9; - * @param int|string $var - * @return $this - */ - public function setPid($var) - { - GPBUtil::checkInt64($var); - $this->pid = $var; - - return $this; - } - - /** - * The parent process ID. - * - * Generated from protobuf field int64 parent_pid = 10; - * @return int|string - */ - public function getParentPid() - { - return $this->parent_pid; - } - - /** - * The parent process ID. - * - * Generated from protobuf field int64 parent_pid = 10; - * @param int|string $var - * @return $this - */ - public function setParentPid($var) - { - GPBUtil::checkInt64($var); - $this->parent_pid = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Reference.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Reference.php deleted file mode 100644 index 5c8b35a270b9..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Reference.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.securitycenter.v2.Reference - */ -class Reference extends \Google\Protobuf\Internal\Message -{ - /** - * Source of the reference e.g. NVD - * - * Generated from protobuf field string source = 1; - */ - protected $source = ''; - /** - * Uri for the mentioned source e.g. - * https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527. - * - * Generated from protobuf field string uri = 2; - */ - protected $uri = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $source - * Source of the reference e.g. NVD - * @type string $uri - * Uri for the mentioned source e.g. - * https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Vulnerability::initOnce(); - parent::__construct($data); - } - - /** - * Source of the reference e.g. NVD - * - * Generated from protobuf field string source = 1; - * @return string - */ - public function getSource() - { - return $this->source; - } - - /** - * Source of the reference e.g. NVD - * - * Generated from protobuf field string source = 1; - * @param string $var - * @return $this - */ - public function setSource($var) - { - GPBUtil::checkString($var, True); - $this->source = $var; - - return $this; - } - - /** - * Uri for the mentioned source e.g. - * https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527. - * - * Generated from protobuf field string uri = 2; - * @return string - */ - public function getUri() - { - return $this->uri; - } - - /** - * Uri for the mentioned source e.g. - * https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2021-34527. - * - * Generated from protobuf field string uri = 2; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->uri = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Resource.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Resource.php deleted file mode 100644 index 644e65332382..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Resource.php +++ /dev/null @@ -1,463 +0,0 @@ -google.cloud.securitycenter.v2.Resource - */ -class Resource extends \Google\Protobuf\Internal\Message -{ - /** - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The human readable name of the resource. - * - * Generated from protobuf field string display_name = 2; - */ - protected $display_name = ''; - /** - * The full resource type of the resource. - * - * Generated from protobuf field string type = 3; - */ - protected $type = ''; - /** - * Indicates which cloud provider the finding is from. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; - */ - protected $cloud_provider = 0; - /** - * The service or resource provider associated with the resource. - * - * Generated from protobuf field string service = 5; - */ - protected $service = ''; - /** - * The region or location of the service (if applicable). - * - * Generated from protobuf field string location = 6; - */ - protected $location = ''; - /** - * Provides the path to the resource within the resource hierarchy. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath resource_path = 10; - */ - protected $resource_path = null; - /** - * A string representation of the resource path. - * For Google Cloud, it has the format of - * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} - * where there can be any number of folders. - * For AWS, it has the format of - * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} - * where there can be any number of organizational units. - * For Azure, it has the format of - * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} - * where there can be any number of management groups. - * - * Generated from protobuf field string resource_path_string = 11; - */ - protected $resource_path_string = ''; - protected $cloud_provider_metadata; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * @type string $display_name - * The human readable name of the resource. - * @type string $type - * The full resource type of the resource. - * @type int $cloud_provider - * Indicates which cloud provider the finding is from. - * @type string $service - * The service or resource provider associated with the resource. - * @type string $location - * The region or location of the service (if applicable). - * @type \Google\Cloud\SecurityCenter\V2\GcpMetadata $gcp_metadata - * The GCP metadata associated with the finding. - * @type \Google\Cloud\SecurityCenter\V2\AwsMetadata $aws_metadata - * The AWS metadata associated with the finding. - * @type \Google\Cloud\SecurityCenter\V2\AzureMetadata $azure_metadata - * The Azure metadata associated with the finding. - * @type \Google\Cloud\SecurityCenter\V2\ResourcePath $resource_path - * Provides the path to the resource within the resource hierarchy. - * @type string $resource_path_string - * A string representation of the resource path. - * For Google Cloud, it has the format of - * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} - * where there can be any number of folders. - * For AWS, it has the format of - * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} - * where there can be any number of organizational units. - * For Azure, it has the format of - * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} - * where there can be any number of management groups. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Resource::initOnce(); - parent::__construct($data); - } - - /** - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The full resource name of the resource. See: - * https://cloud.google.com/apis/design/resource_names#full_resource_name - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The human readable name of the resource. - * - * Generated from protobuf field string display_name = 2; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * The human readable name of the resource. - * - * Generated from protobuf field string display_name = 2; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * The full resource type of the resource. - * - * Generated from protobuf field string type = 3; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * The full resource type of the resource. - * - * Generated from protobuf field string type = 3; - * @param string $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkString($var, True); - $this->type = $var; - - return $this; - } - - /** - * Indicates which cloud provider the finding is from. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; - * @return int - */ - public function getCloudProvider() - { - return $this->cloud_provider; - } - - /** - * Indicates which cloud provider the finding is from. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; - * @param int $var - * @return $this - */ - public function setCloudProvider($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\CloudProvider::class); - $this->cloud_provider = $var; - - return $this; - } - - /** - * The service or resource provider associated with the resource. - * - * Generated from protobuf field string service = 5; - * @return string - */ - public function getService() - { - return $this->service; - } - - /** - * The service or resource provider associated with the resource. - * - * Generated from protobuf field string service = 5; - * @param string $var - * @return $this - */ - public function setService($var) - { - GPBUtil::checkString($var, True); - $this->service = $var; - - return $this; - } - - /** - * The region or location of the service (if applicable). - * - * Generated from protobuf field string location = 6; - * @return string - */ - public function getLocation() - { - return $this->location; - } - - /** - * The region or location of the service (if applicable). - * - * Generated from protobuf field string location = 6; - * @param string $var - * @return $this - */ - public function setLocation($var) - { - GPBUtil::checkString($var, True); - $this->location = $var; - - return $this; - } - - /** - * The GCP metadata associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.GcpMetadata gcp_metadata = 7; - * @return \Google\Cloud\SecurityCenter\V2\GcpMetadata|null - */ - public function getGcpMetadata() - { - return $this->readOneof(7); - } - - public function hasGcpMetadata() - { - return $this->hasOneof(7); - } - - /** - * The GCP metadata associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.GcpMetadata gcp_metadata = 7; - * @param \Google\Cloud\SecurityCenter\V2\GcpMetadata $var - * @return $this - */ - public function setGcpMetadata($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\GcpMetadata::class); - $this->writeOneof(7, $var); - - return $this; - } - - /** - * The AWS metadata associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata aws_metadata = 8; - * @return \Google\Cloud\SecurityCenter\V2\AwsMetadata|null - */ - public function getAwsMetadata() - { - return $this->readOneof(8); - } - - public function hasAwsMetadata() - { - return $this->hasOneof(8); - } - - /** - * The AWS metadata associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.AwsMetadata aws_metadata = 8; - * @param \Google\Cloud\SecurityCenter\V2\AwsMetadata $var - * @return $this - */ - public function setAwsMetadata($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\AwsMetadata::class); - $this->writeOneof(8, $var); - - return $this; - } - - /** - * The Azure metadata associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata azure_metadata = 9; - * @return \Google\Cloud\SecurityCenter\V2\AzureMetadata|null - */ - public function getAzureMetadata() - { - return $this->readOneof(9); - } - - public function hasAzureMetadata() - { - return $this->hasOneof(9); - } - - /** - * The Azure metadata associated with the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.AzureMetadata azure_metadata = 9; - * @param \Google\Cloud\SecurityCenter\V2\AzureMetadata $var - * @return $this - */ - public function setAzureMetadata($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\AzureMetadata::class); - $this->writeOneof(9, $var); - - return $this; - } - - /** - * Provides the path to the resource within the resource hierarchy. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath resource_path = 10; - * @return \Google\Cloud\SecurityCenter\V2\ResourcePath|null - */ - public function getResourcePath() - { - return $this->resource_path; - } - - public function hasResourcePath() - { - return isset($this->resource_path); - } - - public function clearResourcePath() - { - unset($this->resource_path); - } - - /** - * Provides the path to the resource within the resource hierarchy. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourcePath resource_path = 10; - * @param \Google\Cloud\SecurityCenter\V2\ResourcePath $var - * @return $this - */ - public function setResourcePath($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ResourcePath::class); - $this->resource_path = $var; - - return $this; - } - - /** - * A string representation of the resource path. - * For Google Cloud, it has the format of - * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} - * where there can be any number of folders. - * For AWS, it has the format of - * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} - * where there can be any number of organizational units. - * For Azure, it has the format of - * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} - * where there can be any number of management groups. - * - * Generated from protobuf field string resource_path_string = 11; - * @return string - */ - public function getResourcePathString() - { - return $this->resource_path_string; - } - - /** - * A string representation of the resource path. - * For Google Cloud, it has the format of - * organizations/{organization_id}/folders/{folder_id}/folders/{folder_id}/projects/{project_id} - * where there can be any number of folders. - * For AWS, it has the format of - * org/{organization_id}/ou/{organizational_unit_id}/ou/{organizational_unit_id}/account/{account_id} - * where there can be any number of organizational units. - * For Azure, it has the format of - * mg/{management_group_id}/mg/{management_group_id}/subscription/{subscription_id}/rg/{resource_group_name} - * where there can be any number of management groups. - * - * Generated from protobuf field string resource_path_string = 11; - * @param string $var - * @return $this - */ - public function setResourcePathString($var) - { - GPBUtil::checkString($var, True); - $this->resource_path_string = $var; - - return $this; - } - - /** - * @return string - */ - public function getCloudProviderMetadata() - { - return $this->whichOneof("cloud_provider_metadata"); - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValue.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValue.php deleted file mode 100644 index 0952e0b3d347..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValue.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.securitycenter.v2.ResourceValue - */ -class ResourceValue -{ - /** - * Unspecific value - * - * Generated from protobuf enum RESOURCE_VALUE_UNSPECIFIED = 0; - */ - const RESOURCE_VALUE_UNSPECIFIED = 0; - /** - * High resource value - * - * Generated from protobuf enum HIGH = 1; - */ - const HIGH = 1; - /** - * Medium resource value - * - * Generated from protobuf enum MEDIUM = 2; - */ - const MEDIUM = 2; - /** - * Low resource value - * - * Generated from protobuf enum LOW = 3; - */ - const LOW = 3; - /** - * No resource value, e.g. ignore these resources - * - * Generated from protobuf enum NONE = 4; - */ - const NONE = 4; - - private static $valueToName = [ - self::RESOURCE_VALUE_UNSPECIFIED => 'RESOURCE_VALUE_UNSPECIFIED', - self::HIGH => 'HIGH', - self::MEDIUM => 'MEDIUM', - self::LOW => 'LOW', - self::NONE => 'NONE', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfig.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfig.php deleted file mode 100644 index 390eee2b4943..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfig.php +++ /dev/null @@ -1,506 +0,0 @@ -google.cloud.securitycenter.v2.ResourceValueConfig - */ -class ResourceValueConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Name for the resource value configuration - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Resource value level this expression represents - * Only required when there is no SDP mapping in the request - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValue resource_value = 2; - */ - protected $resource_value = 0; - /** - * Required. Tag values combined with AND to check against. - * Values in the form "tagValues/123" - * Example: [ "tagValues/123", "tagValues/456", "tagValues/789" ] - * https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing - * - * Generated from protobuf field repeated string tag_values = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - private $tag_values; - /** - * Apply resource_value only to resources that match resource_type. - * resource_type will be checked with AND of other resources. - * For example, "storage.googleapis.com/Bucket" with resource_value "HIGH" - * will apply "HIGH" value only to "storage.googleapis.com/Bucket" resources. - * - * Generated from protobuf field string resource_type = 4; - */ - protected $resource_type = ''; - /** - * Project or folder to scope this configuration to. - * For example, "project/456" would apply this configuration only to resources - * in "project/456" scope will be checked with AND of other - * resources. - * - * Generated from protobuf field string scope = 5; - */ - protected $scope = ''; - /** - * List of resource labels to search for, evaluated with AND. - * For example, "resource_labels_selector": {"key": "value", "env": "prod"} - * will match resources with labels "key": "value" AND "env": - * "prod" - * https://cloud.google.com/resource-manager/docs/creating-managing-labels - * - * Generated from protobuf field map resource_labels_selector = 6; - */ - private $resource_labels_selector; - /** - * Description of the resource value configuration. - * - * Generated from protobuf field string description = 7; - */ - protected $description = ''; - /** - * Output only. Timestamp this resource value configuration was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Timestamp this resource value configuration was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Cloud provider this configuration applies to - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 10; - */ - protected $cloud_provider = 0; - /** - * A mapping of the sensitivity on Sensitive Data Protection finding to - * resource values. This mapping can only be used in combination with a - * resource_type that is related to BigQuery, e.g. - * "bigquery.googleapis.com/Dataset". - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValueConfig.SensitiveDataProtectionMapping sensitive_data_protection_mapping = 11; - */ - protected $sensitive_data_protection_mapping = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Name for the resource value configuration - * @type int $resource_value - * Resource value level this expression represents - * Only required when there is no SDP mapping in the request - * @type array|\Google\Protobuf\Internal\RepeatedField $tag_values - * Required. Tag values combined with AND to check against. - * Values in the form "tagValues/123" - * Example: [ "tagValues/123", "tagValues/456", "tagValues/789" ] - * https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing - * @type string $resource_type - * Apply resource_value only to resources that match resource_type. - * resource_type will be checked with AND of other resources. - * For example, "storage.googleapis.com/Bucket" with resource_value "HIGH" - * will apply "HIGH" value only to "storage.googleapis.com/Bucket" resources. - * @type string $scope - * Project or folder to scope this configuration to. - * For example, "project/456" would apply this configuration only to resources - * in "project/456" scope will be checked with AND of other - * resources. - * @type array|\Google\Protobuf\Internal\MapField $resource_labels_selector - * List of resource labels to search for, evaluated with AND. - * For example, "resource_labels_selector": {"key": "value", "env": "prod"} - * will match resources with labels "key": "value" AND "env": - * "prod" - * https://cloud.google.com/resource-manager/docs/creating-managing-labels - * @type string $description - * Description of the resource value configuration. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Timestamp this resource value configuration was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Timestamp this resource value configuration was last updated. - * @type int $cloud_provider - * Cloud provider this configuration applies to - * @type \Google\Cloud\SecurityCenter\V2\ResourceValueConfig\SensitiveDataProtectionMapping $sensitive_data_protection_mapping - * A mapping of the sensitivity on Sensitive Data Protection finding to - * resource values. This mapping can only be used in combination with a - * resource_type that is related to BigQuery, e.g. - * "bigquery.googleapis.com/Dataset". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\ResourceValueConfig::initOnce(); - parent::__construct($data); - } - - /** - * Name for the resource value configuration - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Name for the resource value configuration - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Resource value level this expression represents - * Only required when there is no SDP mapping in the request - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValue resource_value = 2; - * @return int - */ - public function getResourceValue() - { - return $this->resource_value; - } - - /** - * Resource value level this expression represents - * Only required when there is no SDP mapping in the request - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValue resource_value = 2; - * @param int $var - * @return $this - */ - public function setResourceValue($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\ResourceValue::class); - $this->resource_value = $var; - - return $this; - } - - /** - * Required. Tag values combined with AND to check against. - * Values in the form "tagValues/123" - * Example: [ "tagValues/123", "tagValues/456", "tagValues/789" ] - * https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing - * - * Generated from protobuf field repeated string tag_values = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getTagValues() - { - return $this->tag_values; - } - - /** - * Required. Tag values combined with AND to check against. - * Values in the form "tagValues/123" - * Example: [ "tagValues/123", "tagValues/456", "tagValues/789" ] - * https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing - * - * Generated from protobuf field repeated string tag_values = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setTagValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->tag_values = $arr; - - return $this; - } - - /** - * Apply resource_value only to resources that match resource_type. - * resource_type will be checked with AND of other resources. - * For example, "storage.googleapis.com/Bucket" with resource_value "HIGH" - * will apply "HIGH" value only to "storage.googleapis.com/Bucket" resources. - * - * Generated from protobuf field string resource_type = 4; - * @return string - */ - public function getResourceType() - { - return $this->resource_type; - } - - /** - * Apply resource_value only to resources that match resource_type. - * resource_type will be checked with AND of other resources. - * For example, "storage.googleapis.com/Bucket" with resource_value "HIGH" - * will apply "HIGH" value only to "storage.googleapis.com/Bucket" resources. - * - * Generated from protobuf field string resource_type = 4; - * @param string $var - * @return $this - */ - public function setResourceType($var) - { - GPBUtil::checkString($var, True); - $this->resource_type = $var; - - return $this; - } - - /** - * Project or folder to scope this configuration to. - * For example, "project/456" would apply this configuration only to resources - * in "project/456" scope will be checked with AND of other - * resources. - * - * Generated from protobuf field string scope = 5; - * @return string - */ - public function getScope() - { - return $this->scope; - } - - /** - * Project or folder to scope this configuration to. - * For example, "project/456" would apply this configuration only to resources - * in "project/456" scope will be checked with AND of other - * resources. - * - * Generated from protobuf field string scope = 5; - * @param string $var - * @return $this - */ - public function setScope($var) - { - GPBUtil::checkString($var, True); - $this->scope = $var; - - return $this; - } - - /** - * List of resource labels to search for, evaluated with AND. - * For example, "resource_labels_selector": {"key": "value", "env": "prod"} - * will match resources with labels "key": "value" AND "env": - * "prod" - * https://cloud.google.com/resource-manager/docs/creating-managing-labels - * - * Generated from protobuf field map resource_labels_selector = 6; - * @return \Google\Protobuf\Internal\MapField - */ - public function getResourceLabelsSelector() - { - return $this->resource_labels_selector; - } - - /** - * List of resource labels to search for, evaluated with AND. - * For example, "resource_labels_selector": {"key": "value", "env": "prod"} - * will match resources with labels "key": "value" AND "env": - * "prod" - * https://cloud.google.com/resource-manager/docs/creating-managing-labels - * - * Generated from protobuf field map resource_labels_selector = 6; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setResourceLabelsSelector($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->resource_labels_selector = $arr; - - return $this; - } - - /** - * Description of the resource value configuration. - * - * Generated from protobuf field string description = 7; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Description of the resource value configuration. - * - * Generated from protobuf field string description = 7; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Output only. Timestamp this resource value configuration was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. Timestamp this resource value configuration was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Output only. Timestamp this resource value configuration was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getUpdateTime() - { - return $this->update_time; - } - - public function hasUpdateTime() - { - return isset($this->update_time); - } - - public function clearUpdateTime() - { - unset($this->update_time); - } - - /** - * Output only. Timestamp this resource value configuration was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setUpdateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->update_time = $var; - - return $this; - } - - /** - * Cloud provider this configuration applies to - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 10; - * @return int - */ - public function getCloudProvider() - { - return $this->cloud_provider; - } - - /** - * Cloud provider this configuration applies to - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 10; - * @param int $var - * @return $this - */ - public function setCloudProvider($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\CloudProvider::class); - $this->cloud_provider = $var; - - return $this; - } - - /** - * A mapping of the sensitivity on Sensitive Data Protection finding to - * resource values. This mapping can only be used in combination with a - * resource_type that is related to BigQuery, e.g. - * "bigquery.googleapis.com/Dataset". - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValueConfig.SensitiveDataProtectionMapping sensitive_data_protection_mapping = 11; - * @return \Google\Cloud\SecurityCenter\V2\ResourceValueConfig\SensitiveDataProtectionMapping|null - */ - public function getSensitiveDataProtectionMapping() - { - return $this->sensitive_data_protection_mapping; - } - - public function hasSensitiveDataProtectionMapping() - { - return isset($this->sensitive_data_protection_mapping); - } - - public function clearSensitiveDataProtectionMapping() - { - unset($this->sensitive_data_protection_mapping); - } - - /** - * A mapping of the sensitivity on Sensitive Data Protection finding to - * resource values. This mapping can only be used in combination with a - * resource_type that is related to BigQuery, e.g. - * "bigquery.googleapis.com/Dataset". - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValueConfig.SensitiveDataProtectionMapping sensitive_data_protection_mapping = 11; - * @param \Google\Cloud\SecurityCenter\V2\ResourceValueConfig\SensitiveDataProtectionMapping $var - * @return $this - */ - public function setSensitiveDataProtectionMapping($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ResourceValueConfig\SensitiveDataProtectionMapping::class); - $this->sensitive_data_protection_mapping = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfig/SensitiveDataProtectionMapping.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfig/SensitiveDataProtectionMapping.php deleted file mode 100644 index 6107bec83cff..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfig/SensitiveDataProtectionMapping.php +++ /dev/null @@ -1,114 +0,0 @@ -google.cloud.securitycenter.v2.ResourceValueConfig.SensitiveDataProtectionMapping - */ -class SensitiveDataProtectionMapping extends \Google\Protobuf\Internal\Message -{ - /** - * Resource value mapping for high-sensitivity Sensitive Data Protection - * findings - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValue high_sensitivity_mapping = 1; - */ - protected $high_sensitivity_mapping = 0; - /** - * Resource value mapping for medium-sensitivity Sensitive Data Protection - * findings - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValue medium_sensitivity_mapping = 2; - */ - protected $medium_sensitivity_mapping = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $high_sensitivity_mapping - * Resource value mapping for high-sensitivity Sensitive Data Protection - * findings - * @type int $medium_sensitivity_mapping - * Resource value mapping for medium-sensitivity Sensitive Data Protection - * findings - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\ResourceValueConfig::initOnce(); - parent::__construct($data); - } - - /** - * Resource value mapping for high-sensitivity Sensitive Data Protection - * findings - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValue high_sensitivity_mapping = 1; - * @return int - */ - public function getHighSensitivityMapping() - { - return $this->high_sensitivity_mapping; - } - - /** - * Resource value mapping for high-sensitivity Sensitive Data Protection - * findings - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValue high_sensitivity_mapping = 1; - * @param int $var - * @return $this - */ - public function setHighSensitivityMapping($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\ResourceValue::class); - $this->high_sensitivity_mapping = $var; - - return $this; - } - - /** - * Resource value mapping for medium-sensitivity Sensitive Data Protection - * findings - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValue medium_sensitivity_mapping = 2; - * @return int - */ - public function getMediumSensitivityMapping() - { - return $this->medium_sensitivity_mapping; - } - - /** - * Resource value mapping for medium-sensitivity Sensitive Data Protection - * findings - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValue medium_sensitivity_mapping = 2; - * @param int $var - * @return $this - */ - public function setMediumSensitivityMapping($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\ResourceValue::class); - $this->medium_sensitivity_mapping = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(SensitiveDataProtectionMapping::class, \Google\Cloud\SecurityCenter\V2\ResourceValueConfig_SensitiveDataProtectionMapping::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfigMetadata.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfigMetadata.php deleted file mode 100644 index 2691859ffff0..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ResourceValueConfigMetadata.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.securitycenter.v2.ResourceValueConfigMetadata - */ -class ResourceValueConfigMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Resource value config name - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Resource value config name - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\ValuedResource::initOnce(); - parent::__construct($data); - } - - /** - * Resource value config name - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Resource value config name - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityBulletin.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityBulletin.php deleted file mode 100644 index 8909dfe27dd2..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityBulletin.php +++ /dev/null @@ -1,149 +0,0 @@ -google.cloud.securitycenter.v2.SecurityBulletin - */ -class SecurityBulletin extends \Google\Protobuf\Internal\Message -{ - /** - * ID of the bulletin corresponding to the vulnerability. - * - * Generated from protobuf field string bulletin_id = 1; - */ - protected $bulletin_id = ''; - /** - * Submission time of this Security Bulletin. - * - * Generated from protobuf field .google.protobuf.Timestamp submission_time = 2; - */ - protected $submission_time = null; - /** - * This represents a version that the cluster receiving this notification - * should be upgraded to, based on its current version. For example, 1.15.0 - * - * Generated from protobuf field string suggested_upgrade_version = 3; - */ - protected $suggested_upgrade_version = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $bulletin_id - * ID of the bulletin corresponding to the vulnerability. - * @type \Google\Protobuf\Timestamp $submission_time - * Submission time of this Security Bulletin. - * @type string $suggested_upgrade_version - * This represents a version that the cluster receiving this notification - * should be upgraded to, based on its current version. For example, 1.15.0 - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Vulnerability::initOnce(); - parent::__construct($data); - } - - /** - * ID of the bulletin corresponding to the vulnerability. - * - * Generated from protobuf field string bulletin_id = 1; - * @return string - */ - public function getBulletinId() - { - return $this->bulletin_id; - } - - /** - * ID of the bulletin corresponding to the vulnerability. - * - * Generated from protobuf field string bulletin_id = 1; - * @param string $var - * @return $this - */ - public function setBulletinId($var) - { - GPBUtil::checkString($var, True); - $this->bulletin_id = $var; - - return $this; - } - - /** - * Submission time of this Security Bulletin. - * - * Generated from protobuf field .google.protobuf.Timestamp submission_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getSubmissionTime() - { - return $this->submission_time; - } - - public function hasSubmissionTime() - { - return isset($this->submission_time); - } - - public function clearSubmissionTime() - { - unset($this->submission_time); - } - - /** - * Submission time of this Security Bulletin. - * - * Generated from protobuf field .google.protobuf.Timestamp submission_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setSubmissionTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->submission_time = $var; - - return $this; - } - - /** - * This represents a version that the cluster receiving this notification - * should be upgraded to, based on its current version. For example, 1.15.0 - * - * Generated from protobuf field string suggested_upgrade_version = 3; - * @return string - */ - public function getSuggestedUpgradeVersion() - { - return $this->suggested_upgrade_version; - } - - /** - * This represents a version that the cluster receiving this notification - * should be upgraded to, based on its current version. For example, 1.15.0 - * - * Generated from protobuf field string suggested_upgrade_version = 3; - * @param string $var - * @return $this - */ - public function setSuggestedUpgradeVersion($var) - { - GPBUtil::checkString($var, True); - $this->suggested_upgrade_version = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityMarks.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityMarks.php deleted file mode 100644 index 599094423a8e..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityMarks.php +++ /dev/null @@ -1,250 +0,0 @@ -google.cloud.securitycenter.v2.SecurityMarks - */ -class SecurityMarks extends \Google\Protobuf\Internal\Message -{ - /** - * The relative resource name of the SecurityMarks. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * The following list shows some examples: - * + `organizations/{organization_id}/assets/{asset_id}/securityMarks` - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Mutable user specified security marks belonging to the parent resource. - * Constraints are as follows: - * * Keys and values are treated as case insensitive - * * Keys must be between 1 - 256 characters (inclusive) - * * Keys must be letters, numbers, underscores, or dashes - * * Values have leading and trailing whitespace trimmed, remaining - * characters must be between 1 - 4096 characters (inclusive) - * - * Generated from protobuf field map marks = 2; - */ - private $marks; - /** - * The canonical name of the marks. The following list shows some examples: - * + `organizations/{organization_id}/assets/{asset_id}/securityMarks` - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` - * + `folders/{folder_id}/assets/{asset_id}/securityMarks` - * + - * `folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` - * + `projects/{project_number}/assets/{asset_id}/securityMarks` - * + - * `projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks` - * + - * `projects/{project_number}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` - * - * Generated from protobuf field string canonical_name = 3; - */ - protected $canonical_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The relative resource name of the SecurityMarks. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * The following list shows some examples: - * + `organizations/{organization_id}/assets/{asset_id}/securityMarks` - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` - * @type array|\Google\Protobuf\Internal\MapField $marks - * Mutable user specified security marks belonging to the parent resource. - * Constraints are as follows: - * * Keys and values are treated as case insensitive - * * Keys must be between 1 - 256 characters (inclusive) - * * Keys must be letters, numbers, underscores, or dashes - * * Values have leading and trailing whitespace trimmed, remaining - * characters must be between 1 - 4096 characters (inclusive) - * @type string $canonical_name - * The canonical name of the marks. The following list shows some examples: - * + `organizations/{organization_id}/assets/{asset_id}/securityMarks` - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` - * + `folders/{folder_id}/assets/{asset_id}/securityMarks` - * + - * `folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` - * + `projects/{project_number}/assets/{asset_id}/securityMarks` - * + - * `projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks` - * + - * `projects/{project_number}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecurityMarks::initOnce(); - parent::__construct($data); - } - - /** - * The relative resource name of the SecurityMarks. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * The following list shows some examples: - * + `organizations/{organization_id}/assets/{asset_id}/securityMarks` - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The relative resource name of the SecurityMarks. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * The following list shows some examples: - * + `organizations/{organization_id}/assets/{asset_id}/securityMarks` - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Mutable user specified security marks belonging to the parent resource. - * Constraints are as follows: - * * Keys and values are treated as case insensitive - * * Keys must be between 1 - 256 characters (inclusive) - * * Keys must be letters, numbers, underscores, or dashes - * * Values have leading and trailing whitespace trimmed, remaining - * characters must be between 1 - 4096 characters (inclusive) - * - * Generated from protobuf field map marks = 2; - * @return \Google\Protobuf\Internal\MapField - */ - public function getMarks() - { - return $this->marks; - } - - /** - * Mutable user specified security marks belonging to the parent resource. - * Constraints are as follows: - * * Keys and values are treated as case insensitive - * * Keys must be between 1 - 256 characters (inclusive) - * * Keys must be letters, numbers, underscores, or dashes - * * Values have leading and trailing whitespace trimmed, remaining - * characters must be between 1 - 4096 characters (inclusive) - * - * Generated from protobuf field map marks = 2; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setMarks($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->marks = $arr; - - return $this; - } - - /** - * The canonical name of the marks. The following list shows some examples: - * + `organizations/{organization_id}/assets/{asset_id}/securityMarks` - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` - * + `folders/{folder_id}/assets/{asset_id}/securityMarks` - * + - * `folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` - * + `projects/{project_number}/assets/{asset_id}/securityMarks` - * + - * `projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks` - * + - * `projects/{project_number}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` - * - * Generated from protobuf field string canonical_name = 3; - * @return string - */ - public function getCanonicalName() - { - return $this->canonical_name; - } - - /** - * The canonical name of the marks. The following list shows some examples: - * + `organizations/{organization_id}/assets/{asset_id}/securityMarks` - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}/securityMarks` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` - * + `folders/{folder_id}/assets/{asset_id}/securityMarks` - * + - * `folders/{folder_id}/sources/{source_id}/findings/{finding_id}/securityMarks` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` - * + `projects/{project_number}/assets/{asset_id}/securityMarks` - * + - * `projects/{project_number}/sources/{source_id}/findings/{finding_id}/securityMarks` - * + - * `projects/{project_number}/sources/{source_id}/locations/{location}/findings/{finding_id}/securityMarks` - * - * Generated from protobuf field string canonical_name = 3; - * @param string $var - * @return $this - */ - public function setCanonicalName($var) - { - GPBUtil::checkString($var, True); - $this->canonical_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPosture.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPosture.php deleted file mode 100644 index 04ba9a8280f7..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPosture.php +++ /dev/null @@ -1,325 +0,0 @@ -google.cloud.securitycenter.v2.SecurityPosture - */ -class SecurityPosture extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the posture, for example, `CIS-Posture`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The version of the posture, for example, `c7cfa2a8`. - * - * Generated from protobuf field string revision_id = 2; - */ - protected $revision_id = ''; - /** - * The project, folder, or organization on which the posture is deployed, - * for example, `projects/{project_number}`. - * - * Generated from protobuf field string posture_deployment_resource = 3; - */ - protected $posture_deployment_resource = ''; - /** - * The name of the posture deployment, for example, - * `organizations/{org_id}/posturedeployments/{posture_deployment_id}`. - * - * Generated from protobuf field string posture_deployment = 4; - */ - protected $posture_deployment = ''; - /** - * The name of the updated policy, for example, - * `projects/{project_id}/policies/{constraint_name}`. - * - * Generated from protobuf field string changed_policy = 5; - */ - protected $changed_policy = ''; - /** - * The name of the updated policy set, for example, `cis-policyset`. - * - * Generated from protobuf field string policy_set = 6; - */ - protected $policy_set = ''; - /** - * The ID of the updated policy, for example, `compute-policy-1`. - * - * Generated from protobuf field string policy = 7; - */ - protected $policy = ''; - /** - * The details about a change in an updated policy that violates the deployed - * posture. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.SecurityPosture.PolicyDriftDetails policy_drift_details = 8; - */ - private $policy_drift_details; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Name of the posture, for example, `CIS-Posture`. - * @type string $revision_id - * The version of the posture, for example, `c7cfa2a8`. - * @type string $posture_deployment_resource - * The project, folder, or organization on which the posture is deployed, - * for example, `projects/{project_number}`. - * @type string $posture_deployment - * The name of the posture deployment, for example, - * `organizations/{org_id}/posturedeployments/{posture_deployment_id}`. - * @type string $changed_policy - * The name of the updated policy, for example, - * `projects/{project_id}/policies/{constraint_name}`. - * @type string $policy_set - * The name of the updated policy set, for example, `cis-policyset`. - * @type string $policy - * The ID of the updated policy, for example, `compute-policy-1`. - * @type array<\Google\Cloud\SecurityCenter\V2\SecurityPosture\PolicyDriftDetails>|\Google\Protobuf\Internal\RepeatedField $policy_drift_details - * The details about a change in an updated policy that violates the deployed - * posture. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecurityPosture::initOnce(); - parent::__construct($data); - } - - /** - * Name of the posture, for example, `CIS-Posture`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Name of the posture, for example, `CIS-Posture`. - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The version of the posture, for example, `c7cfa2a8`. - * - * Generated from protobuf field string revision_id = 2; - * @return string - */ - public function getRevisionId() - { - return $this->revision_id; - } - - /** - * The version of the posture, for example, `c7cfa2a8`. - * - * Generated from protobuf field string revision_id = 2; - * @param string $var - * @return $this - */ - public function setRevisionId($var) - { - GPBUtil::checkString($var, True); - $this->revision_id = $var; - - return $this; - } - - /** - * The project, folder, or organization on which the posture is deployed, - * for example, `projects/{project_number}`. - * - * Generated from protobuf field string posture_deployment_resource = 3; - * @return string - */ - public function getPostureDeploymentResource() - { - return $this->posture_deployment_resource; - } - - /** - * The project, folder, or organization on which the posture is deployed, - * for example, `projects/{project_number}`. - * - * Generated from protobuf field string posture_deployment_resource = 3; - * @param string $var - * @return $this - */ - public function setPostureDeploymentResource($var) - { - GPBUtil::checkString($var, True); - $this->posture_deployment_resource = $var; - - return $this; - } - - /** - * The name of the posture deployment, for example, - * `organizations/{org_id}/posturedeployments/{posture_deployment_id}`. - * - * Generated from protobuf field string posture_deployment = 4; - * @return string - */ - public function getPostureDeployment() - { - return $this->posture_deployment; - } - - /** - * The name of the posture deployment, for example, - * `organizations/{org_id}/posturedeployments/{posture_deployment_id}`. - * - * Generated from protobuf field string posture_deployment = 4; - * @param string $var - * @return $this - */ - public function setPostureDeployment($var) - { - GPBUtil::checkString($var, True); - $this->posture_deployment = $var; - - return $this; - } - - /** - * The name of the updated policy, for example, - * `projects/{project_id}/policies/{constraint_name}`. - * - * Generated from protobuf field string changed_policy = 5; - * @return string - */ - public function getChangedPolicy() - { - return $this->changed_policy; - } - - /** - * The name of the updated policy, for example, - * `projects/{project_id}/policies/{constraint_name}`. - * - * Generated from protobuf field string changed_policy = 5; - * @param string $var - * @return $this - */ - public function setChangedPolicy($var) - { - GPBUtil::checkString($var, True); - $this->changed_policy = $var; - - return $this; - } - - /** - * The name of the updated policy set, for example, `cis-policyset`. - * - * Generated from protobuf field string policy_set = 6; - * @return string - */ - public function getPolicySet() - { - return $this->policy_set; - } - - /** - * The name of the updated policy set, for example, `cis-policyset`. - * - * Generated from protobuf field string policy_set = 6; - * @param string $var - * @return $this - */ - public function setPolicySet($var) - { - GPBUtil::checkString($var, True); - $this->policy_set = $var; - - return $this; - } - - /** - * The ID of the updated policy, for example, `compute-policy-1`. - * - * Generated from protobuf field string policy = 7; - * @return string - */ - public function getPolicy() - { - return $this->policy; - } - - /** - * The ID of the updated policy, for example, `compute-policy-1`. - * - * Generated from protobuf field string policy = 7; - * @param string $var - * @return $this - */ - public function setPolicy($var) - { - GPBUtil::checkString($var, True); - $this->policy = $var; - - return $this; - } - - /** - * The details about a change in an updated policy that violates the deployed - * posture. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.SecurityPosture.PolicyDriftDetails policy_drift_details = 8; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getPolicyDriftDetails() - { - return $this->policy_drift_details; - } - - /** - * The details about a change in an updated policy that violates the deployed - * posture. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.SecurityPosture.PolicyDriftDetails policy_drift_details = 8; - * @param array<\Google\Cloud\SecurityCenter\V2\SecurityPosture\PolicyDriftDetails>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setPolicyDriftDetails($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\SecurityPosture\PolicyDriftDetails::class); - $this->policy_drift_details = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPosture/PolicyDriftDetails.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPosture/PolicyDriftDetails.php deleted file mode 100644 index 68b239c357d5..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SecurityPosture/PolicyDriftDetails.php +++ /dev/null @@ -1,151 +0,0 @@ -google.cloud.securitycenter.v2.SecurityPosture.PolicyDriftDetails - */ -class PolicyDriftDetails extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the updated field, for example - * constraint.implementation.policy_rules[0].enforce - * - * Generated from protobuf field string field = 1; - */ - protected $field = ''; - /** - * The value of this field that was configured in a posture, for example, - * `true` or `allowed_values={"projects/29831892"}`. - * - * Generated from protobuf field string expected_value = 2; - */ - protected $expected_value = ''; - /** - * The detected value that violates the deployed posture, for example, - * `false` or `allowed_values={"projects/22831892"}`. - * - * Generated from protobuf field string detected_value = 3; - */ - protected $detected_value = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $field - * The name of the updated field, for example - * constraint.implementation.policy_rules[0].enforce - * @type string $expected_value - * The value of this field that was configured in a posture, for example, - * `true` or `allowed_values={"projects/29831892"}`. - * @type string $detected_value - * The detected value that violates the deployed posture, for example, - * `false` or `allowed_values={"projects/22831892"}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecurityPosture::initOnce(); - parent::__construct($data); - } - - /** - * The name of the updated field, for example - * constraint.implementation.policy_rules[0].enforce - * - * Generated from protobuf field string field = 1; - * @return string - */ - public function getField() - { - return $this->field; - } - - /** - * The name of the updated field, for example - * constraint.implementation.policy_rules[0].enforce - * - * Generated from protobuf field string field = 1; - * @param string $var - * @return $this - */ - public function setField($var) - { - GPBUtil::checkString($var, True); - $this->field = $var; - - return $this; - } - - /** - * The value of this field that was configured in a posture, for example, - * `true` or `allowed_values={"projects/29831892"}`. - * - * Generated from protobuf field string expected_value = 2; - * @return string - */ - public function getExpectedValue() - { - return $this->expected_value; - } - - /** - * The value of this field that was configured in a posture, for example, - * `true` or `allowed_values={"projects/29831892"}`. - * - * Generated from protobuf field string expected_value = 2; - * @param string $var - * @return $this - */ - public function setExpectedValue($var) - { - GPBUtil::checkString($var, True); - $this->expected_value = $var; - - return $this; - } - - /** - * The detected value that violates the deployed posture, for example, - * `false` or `allowed_values={"projects/22831892"}`. - * - * Generated from protobuf field string detected_value = 3; - * @return string - */ - public function getDetectedValue() - { - return $this->detected_value; - } - - /** - * The detected value that violates the deployed posture, for example, - * `false` or `allowed_values={"projects/22831892"}`. - * - * Generated from protobuf field string detected_value = 3; - * @param string $var - * @return $this - */ - public function setDetectedValue($var) - { - GPBUtil::checkString($var, True); - $this->detected_value = $var; - - return $this; - } - -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(PolicyDriftDetails::class, \Google\Cloud\SecurityCenter\V2\SecurityPosture_PolicyDriftDetails::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ServiceAccountDelegationInfo.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ServiceAccountDelegationInfo.php deleted file mode 100644 index 4145baf6ef0b..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ServiceAccountDelegationInfo.php +++ /dev/null @@ -1,125 +0,0 @@ -google.cloud.securitycenter.v2.ServiceAccountDelegationInfo - */ -class ServiceAccountDelegationInfo extends \Google\Protobuf\Internal\Message -{ - /** - * The email address of a Google account. - * - * Generated from protobuf field string principal_email = 1; - */ - protected $principal_email = ''; - /** - * A string representing the principal_subject associated with the identity. - * As compared to `principal_email`, supports principals that aren't - * associated with email addresses, such as third party principals. For most - * identities, the format will be `principal://iam.googleapis.com/{identity - * pool name}/subjects/{subject}` except for some GKE identities - * (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy - * format `serviceAccount:{identity pool name}[{subject}]` - * - * Generated from protobuf field string principal_subject = 2; - */ - protected $principal_subject = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $principal_email - * The email address of a Google account. - * @type string $principal_subject - * A string representing the principal_subject associated with the identity. - * As compared to `principal_email`, supports principals that aren't - * associated with email addresses, such as third party principals. For most - * identities, the format will be `principal://iam.googleapis.com/{identity - * pool name}/subjects/{subject}` except for some GKE identities - * (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy - * format `serviceAccount:{identity pool name}[{subject}]` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Access::initOnce(); - parent::__construct($data); - } - - /** - * The email address of a Google account. - * - * Generated from protobuf field string principal_email = 1; - * @return string - */ - public function getPrincipalEmail() - { - return $this->principal_email; - } - - /** - * The email address of a Google account. - * - * Generated from protobuf field string principal_email = 1; - * @param string $var - * @return $this - */ - public function setPrincipalEmail($var) - { - GPBUtil::checkString($var, True); - $this->principal_email = $var; - - return $this; - } - - /** - * A string representing the principal_subject associated with the identity. - * As compared to `principal_email`, supports principals that aren't - * associated with email addresses, such as third party principals. For most - * identities, the format will be `principal://iam.googleapis.com/{identity - * pool name}/subjects/{subject}` except for some GKE identities - * (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy - * format `serviceAccount:{identity pool name}[{subject}]` - * - * Generated from protobuf field string principal_subject = 2; - * @return string - */ - public function getPrincipalSubject() - { - return $this->principal_subject; - } - - /** - * A string representing the principal_subject associated with the identity. - * As compared to `principal_email`, supports principals that aren't - * associated with email addresses, such as third party principals. For most - * identities, the format will be `principal://iam.googleapis.com/{identity - * pool name}/subjects/{subject}` except for some GKE identities - * (GKE_WORKLOAD, FREEFORM, GKE_HUB_WORKLOAD) that are still in the legacy - * format `serviceAccount:{identity pool name}[{subject}]` - * - * Generated from protobuf field string principal_subject = 2; - * @param string $var - * @return $this - */ - public function setPrincipalSubject($var) - { - GPBUtil::checkString($var, True); - $this->principal_subject = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SetFindingStateRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SetFindingStateRequest.php deleted file mode 100644 index dd5c233881f4..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SetFindingStateRequest.php +++ /dev/null @@ -1,184 +0,0 @@ -google.cloud.securitycenter.v2.SetFindingStateRequest - */ -class SetFindingStateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. If no location is specified, finding is assumed to be in - * global. The following list shows some examples: - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` - * + - * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. The desired State of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.State state = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $state = 0; - - /** - * @param string $name Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. If no location is specified, finding is assumed to be in - * global. The following list shows some examples: - * - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` - * + - * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * Please see {@see SecurityCenterClient::findingName()} for help formatting this field. - * @param int $state Required. The desired State of the finding. - * For allowed values, use constants defined on {@see \Google\Cloud\SecurityCenter\V2\Finding\State} - * - * @return \Google\Cloud\SecurityCenter\V2\SetFindingStateRequest - * - * @experimental - */ - public static function build(string $name, int $state): self - { - return (new self()) - ->setName($name) - ->setState($state); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. If no location is specified, finding is assumed to be in - * global. The following list shows some examples: - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` - * + - * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * @type int $state - * Required. The desired State of the finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. If no location is specified, finding is assumed to be in - * global. The following list shows some examples: - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` - * + - * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. If no location is specified, finding is assumed to be in - * global. The following list shows some examples: - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` - * + - * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. The desired State of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.State state = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Required. The desired State of the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.State state = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Finding\State::class); - $this->state = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SetMuteRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SetMuteRequest.php deleted file mode 100644 index e8be7ff3aa7d..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/SetMuteRequest.php +++ /dev/null @@ -1,184 +0,0 @@ -google.cloud.securitycenter.v2.SetMuteRequest - */ -class SetMuteRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. If no location is specified, finding is assumed to be in - * global. The following list shows some examples: - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` - * + - * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. The desired state of the Mute. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.Mute mute = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $mute = 0; - - /** - * @param string $name Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. If no location is specified, finding is assumed to be in - * global. The following list shows some examples: - * - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` - * + - * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * Please see {@see SecurityCenterClient::findingName()} for help formatting this field. - * @param int $mute Required. The desired state of the Mute. - * For allowed values, use constants defined on {@see \Google\Cloud\SecurityCenter\V2\Finding\Mute} - * - * @return \Google\Cloud\SecurityCenter\V2\SetMuteRequest - * - * @experimental - */ - public static function build(string $name, int $mute): self - { - return (new self()) - ->setName($name) - ->setMute($mute); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. If no location is specified, finding is assumed to be in - * global. The following list shows some examples: - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` - * + - * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * @type int $mute - * Required. The desired state of the Mute. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. If no location is specified, finding is assumed to be in - * global. The following list shows some examples: - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` - * + - * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. The [relative resource - * name](https://cloud.google.com/apis/design/resource_names#relative_resource_name) - * of the finding. If no location is specified, finding is assumed to be in - * global. The following list shows some examples: - * + - * `organizations/{organization_id}/sources/{source_id}/findings/{finding_id}` - * + - * `organizations/{organization_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `folders/{folder_id}/sources/{source_id}/findings/{finding_id}` - * + - * `folders/{folder_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * + `projects/{project_id}/sources/{source_id}/findings/{finding_id}` - * + - * `projects/{project_id}/sources/{source_id}/locations/{location_id}/findings/{finding_id}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. The desired state of the Mute. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.Mute mute = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getMute() - { - return $this->mute; - } - - /** - * Required. The desired state of the Mute. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding.Mute mute = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setMute($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\Finding\Mute::class); - $this->mute = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Simulation.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Simulation.php deleted file mode 100644 index f94b7f0cface..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Simulation.php +++ /dev/null @@ -1,187 +0,0 @@ -google.cloud.securitycenter.v2.Simulation - */ -class Simulation extends \Google\Protobuf\Internal\Message -{ - /** - * Full resource name of the Simulation: - * organizations/123/simulations/456 - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Output only. Time simulation was created - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Resource value configurations' metadata used in this simulation. Maximum of - * 100. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfigMetadata resource_value_configs_metadata = 3; - */ - private $resource_value_configs_metadata; - /** - * Indicates which cloud provider was used in this simulation. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; - */ - protected $cloud_provider = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Full resource name of the Simulation: - * organizations/123/simulations/456 - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Time simulation was created - * @type array<\Google\Cloud\SecurityCenter\V2\ResourceValueConfigMetadata>|\Google\Protobuf\Internal\RepeatedField $resource_value_configs_metadata - * Resource value configurations' metadata used in this simulation. Maximum of - * 100. - * @type int $cloud_provider - * Indicates which cloud provider was used in this simulation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Simulation::initOnce(); - parent::__construct($data); - } - - /** - * Full resource name of the Simulation: - * organizations/123/simulations/456 - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Full resource name of the Simulation: - * organizations/123/simulations/456 - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. Time simulation was created - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getCreateTime() - { - return $this->create_time; - } - - public function hasCreateTime() - { - return isset($this->create_time); - } - - public function clearCreateTime() - { - unset($this->create_time); - } - - /** - * Output only. Time simulation was created - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setCreateTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->create_time = $var; - - return $this; - } - - /** - * Resource value configurations' metadata used in this simulation. Maximum of - * 100. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfigMetadata resource_value_configs_metadata = 3; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getResourceValueConfigsMetadata() - { - return $this->resource_value_configs_metadata; - } - - /** - * Resource value configurations' metadata used in this simulation. Maximum of - * 100. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfigMetadata resource_value_configs_metadata = 3; - * @param array<\Google\Cloud\SecurityCenter\V2\ResourceValueConfigMetadata>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setResourceValueConfigsMetadata($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ResourceValueConfigMetadata::class); - $this->resource_value_configs_metadata = $arr; - - return $this; - } - - /** - * Indicates which cloud provider was used in this simulation. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; - * @return int - */ - public function getCloudProvider() - { - return $this->cloud_provider; - } - - /** - * Indicates which cloud provider was used in this simulation. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.CloudProvider cloud_provider = 4; - * @param int $var - * @return $this - */ - public function setCloudProvider($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\CloudProvider::class); - $this->cloud_provider = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Source.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Source.php deleted file mode 100644 index e129fd42ce1d..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Source.php +++ /dev/null @@ -1,244 +0,0 @@ -google.cloud.securitycenter.v2.Source - */ -class Source extends \Google\Protobuf\Internal\Message -{ - /** - * The relative resource name of this source. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}" - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The source's display name. - * A source's display name must be unique amongst its siblings, for example, - * two sources with the same parent can't share the same display name. - * The display name must have a length between 1 and 64 characters - * (inclusive). - * - * Generated from protobuf field string display_name = 2; - */ - protected $display_name = ''; - /** - * The description of the source (max of 1024 characters). - * Example: - * "Web Security Scanner is a web security scanner for common - * vulnerabilities in App Engine applications. It can automatically - * scan and detect four common vulnerabilities, including cross-site-scripting - * (XSS), Flash injection, mixed content (HTTP in HTTPS), and - * outdated or insecure libraries." - * - * Generated from protobuf field string description = 3; - */ - protected $description = ''; - /** - * The canonical name of the finding source. It's either - * "organizations/{organization_id}/sources/{source_id}", - * "folders/{folder_id}/sources/{source_id}", or - * "projects/{project_number}/sources/{source_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * - * Generated from protobuf field string canonical_name = 4; - */ - protected $canonical_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The relative resource name of this source. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}" - * @type string $display_name - * The source's display name. - * A source's display name must be unique amongst its siblings, for example, - * two sources with the same parent can't share the same display name. - * The display name must have a length between 1 and 64 characters - * (inclusive). - * @type string $description - * The description of the source (max of 1024 characters). - * Example: - * "Web Security Scanner is a web security scanner for common - * vulnerabilities in App Engine applications. It can automatically - * scan and detect four common vulnerabilities, including cross-site-scripting - * (XSS), Flash injection, mixed content (HTTP in HTTPS), and - * outdated or insecure libraries." - * @type string $canonical_name - * The canonical name of the finding source. It's either - * "organizations/{organization_id}/sources/{source_id}", - * "folders/{folder_id}/sources/{source_id}", or - * "projects/{project_number}/sources/{source_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Source::initOnce(); - parent::__construct($data); - } - - /** - * The relative resource name of this source. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}" - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The relative resource name of this source. See: - * https://cloud.google.com/apis/design/resource_names#relative_resource_name - * Example: - * "organizations/{organization_id}/sources/{source_id}" - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The source's display name. - * A source's display name must be unique amongst its siblings, for example, - * two sources with the same parent can't share the same display name. - * The display name must have a length between 1 and 64 characters - * (inclusive). - * - * Generated from protobuf field string display_name = 2; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * The source's display name. - * A source's display name must be unique amongst its siblings, for example, - * two sources with the same parent can't share the same display name. - * The display name must have a length between 1 and 64 characters - * (inclusive). - * - * Generated from protobuf field string display_name = 2; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * The description of the source (max of 1024 characters). - * Example: - * "Web Security Scanner is a web security scanner for common - * vulnerabilities in App Engine applications. It can automatically - * scan and detect four common vulnerabilities, including cross-site-scripting - * (XSS), Flash injection, mixed content (HTTP in HTTPS), and - * outdated or insecure libraries." - * - * Generated from protobuf field string description = 3; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * The description of the source (max of 1024 characters). - * Example: - * "Web Security Scanner is a web security scanner for common - * vulnerabilities in App Engine applications. It can automatically - * scan and detect four common vulnerabilities, including cross-site-scripting - * (XSS), Flash injection, mixed content (HTTP in HTTPS), and - * outdated or insecure libraries." - * - * Generated from protobuf field string description = 3; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * The canonical name of the finding source. It's either - * "organizations/{organization_id}/sources/{source_id}", - * "folders/{folder_id}/sources/{source_id}", or - * "projects/{project_number}/sources/{source_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * - * Generated from protobuf field string canonical_name = 4; - * @return string - */ - public function getCanonicalName() - { - return $this->canonical_name; - } - - /** - * The canonical name of the finding source. It's either - * "organizations/{organization_id}/sources/{source_id}", - * "folders/{folder_id}/sources/{source_id}", or - * "projects/{project_number}/sources/{source_id}", - * depending on the closest CRM ancestor of the resource associated with the - * finding. - * - * Generated from protobuf field string canonical_name = 4; - * @param string $var - * @return $this - */ - public function setCanonicalName($var) - { - GPBUtil::checkString($var, True); - $this->canonical_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ToxicCombination.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ToxicCombination.php deleted file mode 100644 index 28c16fe8e41e..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ToxicCombination.php +++ /dev/null @@ -1,124 +0,0 @@ -google.cloud.securitycenter.v2.ToxicCombination - */ -class ToxicCombination extends \Google\Protobuf\Internal\Message -{ - /** - * The - * [Attack exposure - * score](https://cloud.google.com/security-command-center/docs/attack-exposure-learn#attack_exposure_scores) - * of this toxic combination. The score is a measure of how much this toxic - * combination exposes one or more high-value resources to potential attack. - * - * Generated from protobuf field double attack_exposure_score = 1; - */ - protected $attack_exposure_score = 0.0; - /** - * List of resource names of findings associated with this toxic combination. - * For example, `organizations/123/sources/456/findings/789`. - * - * Generated from protobuf field repeated string related_findings = 2; - */ - private $related_findings; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type float $attack_exposure_score - * The - * [Attack exposure - * score](https://cloud.google.com/security-command-center/docs/attack-exposure-learn#attack_exposure_scores) - * of this toxic combination. The score is a measure of how much this toxic - * combination exposes one or more high-value resources to potential attack. - * @type array|\Google\Protobuf\Internal\RepeatedField $related_findings - * List of resource names of findings associated with this toxic combination. - * For example, `organizations/123/sources/456/findings/789`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\ToxicCombination::initOnce(); - parent::__construct($data); - } - - /** - * The - * [Attack exposure - * score](https://cloud.google.com/security-command-center/docs/attack-exposure-learn#attack_exposure_scores) - * of this toxic combination. The score is a measure of how much this toxic - * combination exposes one or more high-value resources to potential attack. - * - * Generated from protobuf field double attack_exposure_score = 1; - * @return float - */ - public function getAttackExposureScore() - { - return $this->attack_exposure_score; - } - - /** - * The - * [Attack exposure - * score](https://cloud.google.com/security-command-center/docs/attack-exposure-learn#attack_exposure_scores) - * of this toxic combination. The score is a measure of how much this toxic - * combination exposes one or more high-value resources to potential attack. - * - * Generated from protobuf field double attack_exposure_score = 1; - * @param float $var - * @return $this - */ - public function setAttackExposureScore($var) - { - GPBUtil::checkDouble($var); - $this->attack_exposure_score = $var; - - return $this; - } - - /** - * List of resource names of findings associated with this toxic combination. - * For example, `organizations/123/sources/456/findings/789`. - * - * Generated from protobuf field repeated string related_findings = 2; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getRelatedFindings() - { - return $this->related_findings; - } - - /** - * List of resource names of findings associated with this toxic combination. - * For example, `organizations/123/sources/456/findings/789`. - * - * Generated from protobuf field repeated string related_findings = 2; - * @param array|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setRelatedFindings($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->related_findings = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateBigQueryExportRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateBigQueryExportRequest.php deleted file mode 100644 index 7d92466628b3..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateBigQueryExportRequest.php +++ /dev/null @@ -1,141 +0,0 @@ -google.cloud.securitycenter.v2.UpdateBigQueryExportRequest - */ -class UpdateBigQueryExportRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The BigQuery export being updated. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.BigQueryExport big_query_export = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $big_query_export = null; - /** - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\SecurityCenter\V2\BigQueryExport $bigQueryExport Required. The BigQuery export being updated. - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. - * If empty all mutable fields will be updated. - * - * @return \Google\Cloud\SecurityCenter\V2\UpdateBigQueryExportRequest - * - * @experimental - */ - public static function build(\Google\Cloud\SecurityCenter\V2\BigQueryExport $bigQueryExport, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setBigQueryExport($bigQueryExport) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V2\BigQueryExport $big_query_export - * Required. The BigQuery export being updated. - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The BigQuery export being updated. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.BigQueryExport big_query_export = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V2\BigQueryExport|null - */ - public function getBigQueryExport() - { - return $this->big_query_export; - } - - public function hasBigQueryExport() - { - return isset($this->big_query_export); - } - - public function clearBigQueryExport() - { - unset($this->big_query_export); - } - - /** - * Required. The BigQuery export being updated. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.BigQueryExport big_query_export = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V2\BigQueryExport $var - * @return $this - */ - public function setBigQueryExport($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\BigQueryExport::class); - $this->big_query_export = $var; - - return $this; - } - - /** - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateExternalSystemRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateExternalSystemRequest.php deleted file mode 100644 index ad459bb1e223..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateExternalSystemRequest.php +++ /dev/null @@ -1,142 +0,0 @@ -google.cloud.securitycenter.v2.UpdateExternalSystemRequest - */ -class UpdateExternalSystemRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The external system resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ExternalSystem external_system = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $external_system = null; - /** - * The FieldMask to use when updating the external system resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\SecurityCenter\V2\ExternalSystem $externalSystem Required. The external system resource to update. - * @param \Google\Protobuf\FieldMask $updateMask The FieldMask to use when updating the external system resource. - * - * If empty all mutable fields will be updated. - * - * @return \Google\Cloud\SecurityCenter\V2\UpdateExternalSystemRequest - * - * @experimental - */ - public static function build(\Google\Cloud\SecurityCenter\V2\ExternalSystem $externalSystem, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setExternalSystem($externalSystem) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V2\ExternalSystem $external_system - * Required. The external system resource to update. - * @type \Google\Protobuf\FieldMask $update_mask - * The FieldMask to use when updating the external system resource. - * If empty all mutable fields will be updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The external system resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ExternalSystem external_system = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V2\ExternalSystem|null - */ - public function getExternalSystem() - { - return $this->external_system; - } - - public function hasExternalSystem() - { - return isset($this->external_system); - } - - public function clearExternalSystem() - { - unset($this->external_system); - } - - /** - * Required. The external system resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ExternalSystem external_system = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V2\ExternalSystem $var - * @return $this - */ - public function setExternalSystem($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ExternalSystem::class); - $this->external_system = $var; - - return $this; - } - - /** - * The FieldMask to use when updating the external system resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The FieldMask to use when updating the external system resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateFindingRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateFindingRequest.php deleted file mode 100644 index 7f09a9ce90f0..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateFindingRequest.php +++ /dev/null @@ -1,183 +0,0 @@ -google.cloud.securitycenter.v2.UpdateFindingRequest - */ -class UpdateFindingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The finding resource to update or create if it does not already - * exist. parent, security_marks, and update_time will be ignored. - * In the case of creation, the finding id portion of the name must be - * alphanumeric and less than or equal to 32 characters and greater than 0 - * characters in length. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $finding = null; - /** - * The FieldMask to use when updating the finding resource. This field should - * not be specified when creating a finding. - * When updating a finding, an empty mask is treated as updating all mutable - * fields and replacing source_properties. Individual source_properties can - * be added/updated by using "source_properties." in the field - * mask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\SecurityCenter\V2\Finding $finding Required. The finding resource to update or create if it does not already - * exist. parent, security_marks, and update_time will be ignored. - * - * In the case of creation, the finding id portion of the name must be - * alphanumeric and less than or equal to 32 characters and greater than 0 - * characters in length. - * @param \Google\Protobuf\FieldMask $updateMask The FieldMask to use when updating the finding resource. This field should - * not be specified when creating a finding. - * - * When updating a finding, an empty mask is treated as updating all mutable - * fields and replacing source_properties. Individual source_properties can - * be added/updated by using "source_properties." in the field - * mask. - * - * @return \Google\Cloud\SecurityCenter\V2\UpdateFindingRequest - * - * @experimental - */ - public static function build(\Google\Cloud\SecurityCenter\V2\Finding $finding, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setFinding($finding) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V2\Finding $finding - * Required. The finding resource to update or create if it does not already - * exist. parent, security_marks, and update_time will be ignored. - * In the case of creation, the finding id portion of the name must be - * alphanumeric and less than or equal to 32 characters and greater than 0 - * characters in length. - * @type \Google\Protobuf\FieldMask $update_mask - * The FieldMask to use when updating the finding resource. This field should - * not be specified when creating a finding. - * When updating a finding, an empty mask is treated as updating all mutable - * fields and replacing source_properties. Individual source_properties can - * be added/updated by using "source_properties." in the field - * mask. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The finding resource to update or create if it does not already - * exist. parent, security_marks, and update_time will be ignored. - * In the case of creation, the finding id portion of the name must be - * alphanumeric and less than or equal to 32 characters and greater than 0 - * characters in length. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V2\Finding|null - */ - public function getFinding() - { - return $this->finding; - } - - public function hasFinding() - { - return isset($this->finding); - } - - public function clearFinding() - { - unset($this->finding); - } - - /** - * Required. The finding resource to update or create if it does not already - * exist. parent, security_marks, and update_time will be ignored. - * In the case of creation, the finding id portion of the name must be - * alphanumeric and less than or equal to 32 characters and greater than 0 - * characters in length. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Finding finding = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V2\Finding $var - * @return $this - */ - public function setFinding($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Finding::class); - $this->finding = $var; - - return $this; - } - - /** - * The FieldMask to use when updating the finding resource. This field should - * not be specified when creating a finding. - * When updating a finding, an empty mask is treated as updating all mutable - * fields and replacing source_properties. Individual source_properties can - * be added/updated by using "source_properties." in the field - * mask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The FieldMask to use when updating the finding resource. This field should - * not be specified when creating a finding. - * When updating a finding, an empty mask is treated as updating all mutable - * fields and replacing source_properties. Individual source_properties can - * be added/updated by using "source_properties." in the field - * mask. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateMuteConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateMuteConfigRequest.php deleted file mode 100644 index a8d7e9e90164..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateMuteConfigRequest.php +++ /dev/null @@ -1,141 +0,0 @@ -google.cloud.securitycenter.v2.UpdateMuteConfigRequest - */ -class UpdateMuteConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The mute config being updated. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.MuteConfig mute_config = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $mute_config = null; - /** - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\SecurityCenter\V2\MuteConfig $muteConfig Required. The mute config being updated. - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. - * If empty all mutable fields will be updated. - * - * @return \Google\Cloud\SecurityCenter\V2\UpdateMuteConfigRequest - * - * @experimental - */ - public static function build(\Google\Cloud\SecurityCenter\V2\MuteConfig $muteConfig, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setMuteConfig($muteConfig) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V2\MuteConfig $mute_config - * Required. The mute config being updated. - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The mute config being updated. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.MuteConfig mute_config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V2\MuteConfig|null - */ - public function getMuteConfig() - { - return $this->mute_config; - } - - public function hasMuteConfig() - { - return isset($this->mute_config); - } - - public function clearMuteConfig() - { - unset($this->mute_config); - } - - /** - * Required. The mute config being updated. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.MuteConfig mute_config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V2\MuteConfig $var - * @return $this - */ - public function setMuteConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\MuteConfig::class); - $this->mute_config = $var; - - return $this; - } - - /** - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateNotificationConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateNotificationConfigRequest.php deleted file mode 100644 index f64cf1a15c06..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateNotificationConfigRequest.php +++ /dev/null @@ -1,142 +0,0 @@ -google.cloud.securitycenter.v2.UpdateNotificationConfigRequest - */ -class UpdateNotificationConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The notification config to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.NotificationConfig notification_config = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $notification_config = null; - /** - * The FieldMask to use when updating the notification config. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\SecurityCenter\V2\NotificationConfig $notificationConfig Required. The notification config to update. - * @param \Google\Protobuf\FieldMask $updateMask The FieldMask to use when updating the notification config. - * - * If empty all mutable fields will be updated. - * - * @return \Google\Cloud\SecurityCenter\V2\UpdateNotificationConfigRequest - * - * @experimental - */ - public static function build(\Google\Cloud\SecurityCenter\V2\NotificationConfig $notificationConfig, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setNotificationConfig($notificationConfig) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V2\NotificationConfig $notification_config - * Required. The notification config to update. - * @type \Google\Protobuf\FieldMask $update_mask - * The FieldMask to use when updating the notification config. - * If empty all mutable fields will be updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The notification config to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.NotificationConfig notification_config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V2\NotificationConfig|null - */ - public function getNotificationConfig() - { - return $this->notification_config; - } - - public function hasNotificationConfig() - { - return isset($this->notification_config); - } - - public function clearNotificationConfig() - { - unset($this->notification_config); - } - - /** - * Required. The notification config to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.NotificationConfig notification_config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V2\NotificationConfig $var - * @return $this - */ - public function setNotificationConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\NotificationConfig::class); - $this->notification_config = $var; - - return $this; - } - - /** - * The FieldMask to use when updating the notification config. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The FieldMask to use when updating the notification config. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateResourceValueConfigRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateResourceValueConfigRequest.php deleted file mode 100644 index 95920b7f008d..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateResourceValueConfigRequest.php +++ /dev/null @@ -1,157 +0,0 @@ -google.cloud.securitycenter.v2.UpdateResourceValueConfigRequest - */ -class UpdateResourceValueConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource value config being updated. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_config = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $resource_value_config = null; - /** - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * To update nested fields, include the top level field in the mask - * For example, to update gcp_metadata.resource_type, include the - * "gcp_metadata" field mask - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\SecurityCenter\V2\ResourceValueConfig $resourceValueConfig Required. The resource value config being updated. - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. - * If empty all mutable fields will be updated. - * - * To update nested fields, include the top level field in the mask - * For example, to update gcp_metadata.resource_type, include the - * "gcp_metadata" field mask - * - * @return \Google\Cloud\SecurityCenter\V2\UpdateResourceValueConfigRequest - * - * @experimental - */ - public static function build(\Google\Cloud\SecurityCenter\V2\ResourceValueConfig $resourceValueConfig, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setResourceValueConfig($resourceValueConfig) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V2\ResourceValueConfig $resource_value_config - * Required. The resource value config being updated. - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * To update nested fields, include the top level field in the mask - * For example, to update gcp_metadata.resource_type, include the - * "gcp_metadata" field mask - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource value config being updated. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V2\ResourceValueConfig|null - */ - public function getResourceValueConfig() - { - return $this->resource_value_config; - } - - public function hasResourceValueConfig() - { - return isset($this->resource_value_config); - } - - public function clearResourceValueConfig() - { - unset($this->resource_value_config); - } - - /** - * Required. The resource value config being updated. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ResourceValueConfig resource_value_config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V2\ResourceValueConfig $var - * @return $this - */ - public function setResourceValueConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\ResourceValueConfig::class); - $this->resource_value_config = $var; - - return $this; - } - - /** - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * To update nested fields, include the top level field in the mask - * For example, to update gcp_metadata.resource_type, include the - * "gcp_metadata" field mask - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The list of fields to be updated. - * If empty all mutable fields will be updated. - * To update nested fields, include the top level field in the mask - * For example, to update gcp_metadata.resource_type, include the - * "gcp_metadata" field mask - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateSecurityMarksRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateSecurityMarksRequest.php deleted file mode 100644 index 14b3382b251b..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateSecurityMarksRequest.php +++ /dev/null @@ -1,152 +0,0 @@ -google.cloud.securitycenter.v2.UpdateSecurityMarksRequest - */ -class UpdateSecurityMarksRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The security marks resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityMarks security_marks = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $security_marks = null; - /** - * The FieldMask to use when updating the security marks resource. - * The field mask must not contain duplicate fields. - * If empty or set to "marks", all marks will be replaced. Individual - * marks can be updated using "marks.". - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\SecurityCenter\V2\SecurityMarks $securityMarks Required. The security marks resource to update. - * @param \Google\Protobuf\FieldMask $updateMask The FieldMask to use when updating the security marks resource. - * - * The field mask must not contain duplicate fields. - * If empty or set to "marks", all marks will be replaced. Individual - * marks can be updated using "marks.". - * - * @return \Google\Cloud\SecurityCenter\V2\UpdateSecurityMarksRequest - * - * @experimental - */ - public static function build(\Google\Cloud\SecurityCenter\V2\SecurityMarks $securityMarks, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setSecurityMarks($securityMarks) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V2\SecurityMarks $security_marks - * Required. The security marks resource to update. - * @type \Google\Protobuf\FieldMask $update_mask - * The FieldMask to use when updating the security marks resource. - * The field mask must not contain duplicate fields. - * If empty or set to "marks", all marks will be replaced. Individual - * marks can be updated using "marks.". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The security marks resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityMarks security_marks = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V2\SecurityMarks|null - */ - public function getSecurityMarks() - { - return $this->security_marks; - } - - public function hasSecurityMarks() - { - return isset($this->security_marks); - } - - public function clearSecurityMarks() - { - unset($this->security_marks); - } - - /** - * Required. The security marks resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityMarks security_marks = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V2\SecurityMarks $var - * @return $this - */ - public function setSecurityMarks($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\SecurityMarks::class); - $this->security_marks = $var; - - return $this; - } - - /** - * The FieldMask to use when updating the security marks resource. - * The field mask must not contain duplicate fields. - * If empty or set to "marks", all marks will be replaced. Individual - * marks can be updated using "marks.". - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The FieldMask to use when updating the security marks resource. - * The field mask must not contain duplicate fields. - * If empty or set to "marks", all marks will be replaced. Individual - * marks can be updated using "marks.". - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateSourceRequest.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateSourceRequest.php deleted file mode 100644 index f4802b6d3c2c..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/UpdateSourceRequest.php +++ /dev/null @@ -1,142 +0,0 @@ -google.cloud.securitycenter.v2.UpdateSourceRequest - */ -class UpdateSourceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The source resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Source source = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $source = null; - /** - * The FieldMask to use when updating the source resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\SecurityCenter\V2\Source $source Required. The source resource to update. - * @param \Google\Protobuf\FieldMask $updateMask The FieldMask to use when updating the source resource. - * - * If empty all mutable fields will be updated. - * - * @return \Google\Cloud\SecurityCenter\V2\UpdateSourceRequest - * - * @experimental - */ - public static function build(\Google\Cloud\SecurityCenter\V2\Source $source, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setSource($source) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V2\Source $source - * Required. The source resource to update. - * @type \Google\Protobuf\FieldMask $update_mask - * The FieldMask to use when updating the source resource. - * If empty all mutable fields will be updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\SecuritycenterService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The source resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Source source = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\SecurityCenter\V2\Source|null - */ - public function getSource() - { - return $this->source; - } - - public function hasSource() - { - return isset($this->source); - } - - public function clearSource() - { - unset($this->source); - } - - /** - * Required. The source resource to update. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Source source = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\SecurityCenter\V2\Source $var - * @return $this - */ - public function setSource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Source::class); - $this->source = $var; - - return $this; - } - - /** - * The FieldMask to use when updating the source resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @return \Google\Protobuf\FieldMask|null - */ - public function getUpdateMask() - { - return $this->update_mask; - } - - public function hasUpdateMask() - { - return isset($this->update_mask); - } - - public function clearUpdateMask() - { - unset($this->update_mask); - } - - /** - * The FieldMask to use when updating the source resource. - * If empty all mutable fields will be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ValuedResource.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ValuedResource.php deleted file mode 100644 index 41aede0ba23d..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ValuedResource.php +++ /dev/null @@ -1,307 +0,0 @@ -google.cloud.securitycenter.v2.ValuedResource - */ -class ValuedResource extends \Google\Protobuf\Internal\Message -{ - /** - * Valued resource name, for example, - * e.g.: - * `organizations/123/simulations/456/valuedResources/789` - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * The - * [full resource - * name](https://cloud.google.com/apis/design/resource_names#full_resource_name) - * of the valued resource. - * - * Generated from protobuf field string resource = 2; - */ - protected $resource = ''; - /** - * The [resource - * type](https://cloud.google.com/asset-inventory/docs/supported-asset-types) - * of the valued resource. - * - * Generated from protobuf field string resource_type = 3; - */ - protected $resource_type = ''; - /** - * Human-readable name of the valued resource. - * - * Generated from protobuf field string display_name = 4; - */ - protected $display_name = ''; - /** - * How valuable this resource is. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ValuedResource.ResourceValue resource_value = 5; - */ - protected $resource_value = 0; - /** - * Exposed score for this valued resource. A value of 0 means no exposure was - * detected exposure. - * - * Generated from protobuf field double exposed_score = 6; - */ - protected $exposed_score = 0.0; - /** - * List of resource value configurations' metadata used to determine the value - * of this resource. Maximum of 100. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfigMetadata resource_value_configs_used = 7; - */ - private $resource_value_configs_used; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Valued resource name, for example, - * e.g.: - * `organizations/123/simulations/456/valuedResources/789` - * @type string $resource - * The - * [full resource - * name](https://cloud.google.com/apis/design/resource_names#full_resource_name) - * of the valued resource. - * @type string $resource_type - * The [resource - * type](https://cloud.google.com/asset-inventory/docs/supported-asset-types) - * of the valued resource. - * @type string $display_name - * Human-readable name of the valued resource. - * @type int $resource_value - * How valuable this resource is. - * @type float $exposed_score - * Exposed score for this valued resource. A value of 0 means no exposure was - * detected exposure. - * @type array<\Google\Cloud\SecurityCenter\V2\ResourceValueConfigMetadata>|\Google\Protobuf\Internal\RepeatedField $resource_value_configs_used - * List of resource value configurations' metadata used to determine the value - * of this resource. Maximum of 100. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\ValuedResource::initOnce(); - parent::__construct($data); - } - - /** - * Valued resource name, for example, - * e.g.: - * `organizations/123/simulations/456/valuedResources/789` - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Valued resource name, for example, - * e.g.: - * `organizations/123/simulations/456/valuedResources/789` - * - * Generated from protobuf field string name = 1; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * The - * [full resource - * name](https://cloud.google.com/apis/design/resource_names#full_resource_name) - * of the valued resource. - * - * Generated from protobuf field string resource = 2; - * @return string - */ - public function getResource() - { - return $this->resource; - } - - /** - * The - * [full resource - * name](https://cloud.google.com/apis/design/resource_names#full_resource_name) - * of the valued resource. - * - * Generated from protobuf field string resource = 2; - * @param string $var - * @return $this - */ - public function setResource($var) - { - GPBUtil::checkString($var, True); - $this->resource = $var; - - return $this; - } - - /** - * The [resource - * type](https://cloud.google.com/asset-inventory/docs/supported-asset-types) - * of the valued resource. - * - * Generated from protobuf field string resource_type = 3; - * @return string - */ - public function getResourceType() - { - return $this->resource_type; - } - - /** - * The [resource - * type](https://cloud.google.com/asset-inventory/docs/supported-asset-types) - * of the valued resource. - * - * Generated from protobuf field string resource_type = 3; - * @param string $var - * @return $this - */ - public function setResourceType($var) - { - GPBUtil::checkString($var, True); - $this->resource_type = $var; - - return $this; - } - - /** - * Human-readable name of the valued resource. - * - * Generated from protobuf field string display_name = 4; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Human-readable name of the valued resource. - * - * Generated from protobuf field string display_name = 4; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * How valuable this resource is. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ValuedResource.ResourceValue resource_value = 5; - * @return int - */ - public function getResourceValue() - { - return $this->resource_value; - } - - /** - * How valuable this resource is. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.ValuedResource.ResourceValue resource_value = 5; - * @param int $var - * @return $this - */ - public function setResourceValue($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\SecurityCenter\V2\ValuedResource\ResourceValue::class); - $this->resource_value = $var; - - return $this; - } - - /** - * Exposed score for this valued resource. A value of 0 means no exposure was - * detected exposure. - * - * Generated from protobuf field double exposed_score = 6; - * @return float - */ - public function getExposedScore() - { - return $this->exposed_score; - } - - /** - * Exposed score for this valued resource. A value of 0 means no exposure was - * detected exposure. - * - * Generated from protobuf field double exposed_score = 6; - * @param float $var - * @return $this - */ - public function setExposedScore($var) - { - GPBUtil::checkDouble($var); - $this->exposed_score = $var; - - return $this; - } - - /** - * List of resource value configurations' metadata used to determine the value - * of this resource. Maximum of 100. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfigMetadata resource_value_configs_used = 7; - * @return \Google\Protobuf\Internal\RepeatedField - */ - public function getResourceValueConfigsUsed() - { - return $this->resource_value_configs_used; - } - - /** - * List of resource value configurations' metadata used to determine the value - * of this resource. Maximum of 100. - * - * Generated from protobuf field repeated .google.cloud.securitycenter.v2.ResourceValueConfigMetadata resource_value_configs_used = 7; - * @param array<\Google\Cloud\SecurityCenter\V2\ResourceValueConfigMetadata>|\Google\Protobuf\Internal\RepeatedField $var - * @return $this - */ - public function setResourceValueConfigsUsed($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\SecurityCenter\V2\ResourceValueConfigMetadata::class); - $this->resource_value_configs_used = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ValuedResource/ResourceValue.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ValuedResource/ResourceValue.php deleted file mode 100644 index d6b2831a2751..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/ValuedResource/ResourceValue.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.securitycenter.v2.ValuedResource.ResourceValue - */ -class ResourceValue -{ - /** - * The resource value isn't specified. - * - * Generated from protobuf enum RESOURCE_VALUE_UNSPECIFIED = 0; - */ - const RESOURCE_VALUE_UNSPECIFIED = 0; - /** - * This is a low-value resource. - * - * Generated from protobuf enum RESOURCE_VALUE_LOW = 1; - */ - const RESOURCE_VALUE_LOW = 1; - /** - * This is a medium-value resource. - * - * Generated from protobuf enum RESOURCE_VALUE_MEDIUM = 2; - */ - const RESOURCE_VALUE_MEDIUM = 2; - /** - * This is a high-value resource. - * - * Generated from protobuf enum RESOURCE_VALUE_HIGH = 3; - */ - const RESOURCE_VALUE_HIGH = 3; - - private static $valueToName = [ - self::RESOURCE_VALUE_UNSPECIFIED => 'RESOURCE_VALUE_UNSPECIFIED', - self::RESOURCE_VALUE_LOW => 'RESOURCE_VALUE_LOW', - self::RESOURCE_VALUE_MEDIUM => 'RESOURCE_VALUE_MEDIUM', - self::RESOURCE_VALUE_HIGH => 'RESOURCE_VALUE_HIGH', - ]; - - public static function name($value) - { - if (!isset(self::$valueToName[$value])) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no name defined for value %s', __CLASS__, $value)); - } - return self::$valueToName[$value]; - } - - - public static function value($name) - { - $const = __CLASS__ . '::' . strtoupper($name); - if (!defined($const)) { - throw new UnexpectedValueException(sprintf( - 'Enum %s has no value defined for name %s', __CLASS__, $name)); - } - return constant($const); - } -} - -// Adding a class alias for backwards compatibility with the previous class name. -class_alias(ResourceValue::class, \Google\Cloud\SecurityCenter\V2\ValuedResource_ResourceValue::class); - diff --git a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Vulnerability.php b/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Vulnerability.php deleted file mode 100644 index 780743966879..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/proto/src/Google/Cloud/SecurityCenter/V2/Vulnerability.php +++ /dev/null @@ -1,213 +0,0 @@ -google.cloud.securitycenter.v2.Vulnerability - */ -class Vulnerability extends \Google\Protobuf\Internal\Message -{ - /** - * CVE stands for Common Vulnerabilities and Exposures - * (https://cve.mitre.org/about/) - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cve cve = 1; - */ - protected $cve = null; - /** - * The offending package is relevant to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Package offending_package = 2; - */ - protected $offending_package = null; - /** - * The fixed package is relevant to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Package fixed_package = 3; - */ - protected $fixed_package = null; - /** - * The security bulletin is relevant to this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityBulletin security_bulletin = 4; - */ - protected $security_bulletin = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\SecurityCenter\V2\Cve $cve - * CVE stands for Common Vulnerabilities and Exposures - * (https://cve.mitre.org/about/) - * @type \Google\Cloud\SecurityCenter\V2\Package $offending_package - * The offending package is relevant to the finding. - * @type \Google\Cloud\SecurityCenter\V2\Package $fixed_package - * The fixed package is relevant to the finding. - * @type \Google\Cloud\SecurityCenter\V2\SecurityBulletin $security_bulletin - * The security bulletin is relevant to this finding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Securitycenter\V2\Vulnerability::initOnce(); - parent::__construct($data); - } - - /** - * CVE stands for Common Vulnerabilities and Exposures - * (https://cve.mitre.org/about/) - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cve cve = 1; - * @return \Google\Cloud\SecurityCenter\V2\Cve|null - */ - public function getCve() - { - return $this->cve; - } - - public function hasCve() - { - return isset($this->cve); - } - - public function clearCve() - { - unset($this->cve); - } - - /** - * CVE stands for Common Vulnerabilities and Exposures - * (https://cve.mitre.org/about/) - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Cve cve = 1; - * @param \Google\Cloud\SecurityCenter\V2\Cve $var - * @return $this - */ - public function setCve($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Cve::class); - $this->cve = $var; - - return $this; - } - - /** - * The offending package is relevant to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Package offending_package = 2; - * @return \Google\Cloud\SecurityCenter\V2\Package|null - */ - public function getOffendingPackage() - { - return $this->offending_package; - } - - public function hasOffendingPackage() - { - return isset($this->offending_package); - } - - public function clearOffendingPackage() - { - unset($this->offending_package); - } - - /** - * The offending package is relevant to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Package offending_package = 2; - * @param \Google\Cloud\SecurityCenter\V2\Package $var - * @return $this - */ - public function setOffendingPackage($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Package::class); - $this->offending_package = $var; - - return $this; - } - - /** - * The fixed package is relevant to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Package fixed_package = 3; - * @return \Google\Cloud\SecurityCenter\V2\Package|null - */ - public function getFixedPackage() - { - return $this->fixed_package; - } - - public function hasFixedPackage() - { - return isset($this->fixed_package); - } - - public function clearFixedPackage() - { - unset($this->fixed_package); - } - - /** - * The fixed package is relevant to the finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.Package fixed_package = 3; - * @param \Google\Cloud\SecurityCenter\V2\Package $var - * @return $this - */ - public function setFixedPackage($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\Package::class); - $this->fixed_package = $var; - - return $this; - } - - /** - * The security bulletin is relevant to this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityBulletin security_bulletin = 4; - * @return \Google\Cloud\SecurityCenter\V2\SecurityBulletin|null - */ - public function getSecurityBulletin() - { - return $this->security_bulletin; - } - - public function hasSecurityBulletin() - { - return isset($this->security_bulletin); - } - - public function clearSecurityBulletin() - { - unset($this->security_bulletin); - } - - /** - * The security bulletin is relevant to this finding. - * - * Generated from protobuf field .google.cloud.securitycenter.v2.SecurityBulletin security_bulletin = 4; - * @param \Google\Cloud\SecurityCenter\V2\SecurityBulletin $var - * @return $this - */ - public function setSecurityBulletin($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\SecurityCenter\V2\SecurityBulletin::class); - $this->security_bulletin = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/batch_create_resource_value_configs.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/batch_create_resource_value_configs.php deleted file mode 100644 index f2258fa62849..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/batch_create_resource_value_configs.php +++ /dev/null @@ -1,102 +0,0 @@ -AND to check against. - * Values in the form "tagValues/123" - * Example: [ "tagValues/123", "tagValues/456", "tagValues/789" ] - * https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing - */ -function batch_create_resource_value_configs_sample( - string $formattedParent, - string $formattedRequestsParent, - string $requestsResourceValueConfigTagValuesElement -): void { - // Create a client. - $securityCenterClient = new SecurityCenterClient(); - - // Prepare the request message. - $requestsResourceValueConfigTagValues = [$requestsResourceValueConfigTagValuesElement,]; - $requestsResourceValueConfig = (new ResourceValueConfig()) - ->setTagValues($requestsResourceValueConfigTagValues); - $createResourceValueConfigRequest = (new CreateResourceValueConfigRequest()) - ->setParent($formattedRequestsParent) - ->setResourceValueConfig($requestsResourceValueConfig); - $requests = [$createResourceValueConfigRequest,]; - $request = (new BatchCreateResourceValueConfigsRequest()) - ->setParent($formattedParent) - ->setRequests($requests); - - // Call the API and handle any network failures. - try { - /** @var BatchCreateResourceValueConfigsResponse $response */ - $response = $securityCenterClient->batchCreateResourceValueConfigs($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $formattedRequestsParent = SecurityCenterClient::organizationLocationName( - '[ORGANIZATION]', - '[LOCATION]' - ); - $requestsResourceValueConfigTagValuesElement = '[TAG_VALUES]'; - - batch_create_resource_value_configs_sample( - $formattedParent, - $formattedRequestsParent, - $requestsResourceValueConfigTagValuesElement - ); -} -// [END securitycenter_v2_generated_SecurityCenter_BatchCreateResourceValueConfigs_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/bulk_mute_findings.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/bulk_mute_findings.php deleted file mode 100644 index 0300825d282f..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/bulk_mute_findings.php +++ /dev/null @@ -1,94 +0,0 @@ -setParent($parent); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $securityCenterClient->bulkMuteFindings($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var BulkMuteFindingsResponse $result */ - $result = $response->getResult(); - printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString()); - } else { - /** @var Status $error */ - $error = $response->getError(); - printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $parent = '[PARENT]'; - - bulk_mute_findings_sample($parent); -} -// [END securitycenter_v2_generated_SecurityCenter_BulkMuteFindings_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_big_query_export.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_big_query_export.php deleted file mode 100644 index deac9b2687cd..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_big_query_export.php +++ /dev/null @@ -1,82 +0,0 @@ -setParent($formattedParent) - ->setBigQueryExport($bigQueryExport) - ->setBigQueryExportId($bigQueryExportId); - - // Call the API and handle any network failures. - try { - /** @var BigQueryExport $response */ - $response = $securityCenterClient->createBigQueryExport($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $bigQueryExportId = '[BIG_QUERY_EXPORT_ID]'; - - create_big_query_export_sample($formattedParent, $bigQueryExportId); -} -// [END securitycenter_v2_generated_SecurityCenter_CreateBigQueryExport_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_finding.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_finding.php deleted file mode 100644 index bbc174b8fc52..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_finding.php +++ /dev/null @@ -1,84 +0,0 @@ -setParent($formattedParent) - ->setFindingId($findingId) - ->setFinding($finding); - - // Call the API and handle any network failures. - try { - /** @var Finding $response */ - $response = $securityCenterClient->createFinding($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); - $findingId = '[FINDING_ID]'; - - create_finding_sample($formattedParent, $findingId); -} -// [END securitycenter_v2_generated_SecurityCenter_CreateFinding_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_mute_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_mute_config.php deleted file mode 100644 index 397847206476..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_mute_config.php +++ /dev/null @@ -1,113 +0,0 @@ -setFilter($muteConfigFilter) - ->setType($muteConfigType); - $request = (new CreateMuteConfigRequest()) - ->setParent($formattedParent) - ->setMuteConfig($muteConfig) - ->setMuteConfigId($muteConfigId); - - // Call the API and handle any network failures. - try { - /** @var MuteConfig $response */ - $response = $securityCenterClient->createMuteConfig($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $muteConfigFilter = '[FILTER]'; - $muteConfigType = MuteConfigType::MUTE_CONFIG_TYPE_UNSPECIFIED; - $muteConfigId = '[MUTE_CONFIG_ID]'; - - create_mute_config_sample($formattedParent, $muteConfigFilter, $muteConfigType, $muteConfigId); -} -// [END securitycenter_v2_generated_SecurityCenter_CreateMuteConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_notification_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_notification_config.php deleted file mode 100644 index 773db97e5540..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_notification_config.php +++ /dev/null @@ -1,82 +0,0 @@ -setParent($formattedParent) - ->setConfigId($configId) - ->setNotificationConfig($notificationConfig); - - // Call the API and handle any network failures. - try { - /** @var NotificationConfig $response */ - $response = $securityCenterClient->createNotificationConfig($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $configId = '[CONFIG_ID]'; - - create_notification_config_sample($formattedParent, $configId); -} -// [END securitycenter_v2_generated_SecurityCenter_CreateNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_source.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_source.php deleted file mode 100644 index 5bf33ef01ff3..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/create_source.php +++ /dev/null @@ -1,74 +0,0 @@ -setParent($formattedParent) - ->setSource($source); - - // Call the API and handle any network failures. - try { - /** @var Source $response */ - $response = $securityCenterClient->createSource($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::organizationName('[ORGANIZATION]'); - - create_source_sample($formattedParent); -} -// [END securitycenter_v2_generated_SecurityCenter_CreateSource_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_big_query_export.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_big_query_export.php deleted file mode 100644 index d7c566a4f58d..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_big_query_export.php +++ /dev/null @@ -1,79 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $securityCenterClient->deleteBigQueryExport($request); - printf('Call completed successfully.' . PHP_EOL); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::bigQueryExportName( - '[ORGANIZATION]', - '[LOCATION]', - '[EXPORT]' - ); - - delete_big_query_export_sample($formattedName); -} -// [END securitycenter_v2_generated_SecurityCenter_DeleteBigQueryExport_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_mute_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_mute_config.php deleted file mode 100644 index fce07f47bcbd..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_mute_config.php +++ /dev/null @@ -1,79 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $securityCenterClient->deleteMuteConfig($request); - printf('Call completed successfully.' . PHP_EOL); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); - - delete_mute_config_sample($formattedName); -} -// [END securitycenter_v2_generated_SecurityCenter_DeleteMuteConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_notification_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_notification_config.php deleted file mode 100644 index 6a96dd10f38f..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_notification_config.php +++ /dev/null @@ -1,81 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $securityCenterClient->deleteNotificationConfig($request); - printf('Call completed successfully.' . PHP_EOL); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::notificationConfigName( - '[ORGANIZATION]', - '[LOCATION]', - '[NOTIFICATION_CONFIG]' - ); - - delete_notification_config_sample($formattedName); -} -// [END securitycenter_v2_generated_SecurityCenter_DeleteNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_resource_value_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_resource_value_config.php deleted file mode 100644 index 28fbd37e6393..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/delete_resource_value_config.php +++ /dev/null @@ -1,72 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $securityCenterClient->deleteResourceValueConfig($request); - printf('Call completed successfully.' . PHP_EOL); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::resourceValueConfigName( - '[ORGANIZATION]', - '[RESOURCE_VALUE_CONFIG]' - ); - - delete_resource_value_config_sample($formattedName); -} -// [END securitycenter_v2_generated_SecurityCenter_DeleteResourceValueConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_big_query_export.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_big_query_export.php deleted file mode 100644 index 220e37216f30..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_big_query_export.php +++ /dev/null @@ -1,81 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var BigQueryExport $response */ - $response = $securityCenterClient->getBigQueryExport($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::bigQueryExportName( - '[ORGANIZATION]', - '[LOCATION]', - '[EXPORT]' - ); - - get_big_query_export_sample($formattedName); -} -// [END securitycenter_v2_generated_SecurityCenter_GetBigQueryExport_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_iam_policy.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_iam_policy.php deleted file mode 100644 index bc5da467b950..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_iam_policy.php +++ /dev/null @@ -1,71 +0,0 @@ -setResource($resource); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $securityCenterClient->getIamPolicy($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $resource = '[RESOURCE]'; - - get_iam_policy_sample($resource); -} -// [END securitycenter_v2_generated_SecurityCenter_GetIamPolicy_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_mute_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_mute_config.php deleted file mode 100644 index c8770040f68e..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_mute_config.php +++ /dev/null @@ -1,81 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var MuteConfig $response */ - $response = $securityCenterClient->getMuteConfig($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); - - get_mute_config_sample($formattedName); -} -// [END securitycenter_v2_generated_SecurityCenter_GetMuteConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_notification_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_notification_config.php deleted file mode 100644 index 975ee2350a5e..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_notification_config.php +++ /dev/null @@ -1,83 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var NotificationConfig $response */ - $response = $securityCenterClient->getNotificationConfig($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::notificationConfigName( - '[ORGANIZATION]', - '[LOCATION]', - '[NOTIFICATION_CONFIG]' - ); - - get_notification_config_sample($formattedName); -} -// [END securitycenter_v2_generated_SecurityCenter_GetNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_resource_value_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_resource_value_config.php deleted file mode 100644 index 0412e23f52a6..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_resource_value_config.php +++ /dev/null @@ -1,75 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var ResourceValueConfig $response */ - $response = $securityCenterClient->getResourceValueConfig($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::resourceValueConfigName( - '[ORGANIZATION]', - '[RESOURCE_VALUE_CONFIG]' - ); - - get_resource_value_config_sample($formattedName); -} -// [END securitycenter_v2_generated_SecurityCenter_GetResourceValueConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_simulation.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_simulation.php deleted file mode 100644 index 323b8e239677..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_simulation.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Simulation $response */ - $response = $securityCenterClient->getSimulation($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::simulationName('[ORGANIZATION]', '[SIMULATION]'); - - get_simulation_sample($formattedName); -} -// [END securitycenter_v2_generated_SecurityCenter_GetSimulation_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_source.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_source.php deleted file mode 100644 index d9edaa9e9ff7..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_source.php +++ /dev/null @@ -1,72 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Source $response */ - $response = $securityCenterClient->getSource($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); - - get_source_sample($formattedName); -} -// [END securitycenter_v2_generated_SecurityCenter_GetSource_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_valued_resource.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_valued_resource.php deleted file mode 100644 index 56b54dd0da66..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/get_valued_resource.php +++ /dev/null @@ -1,78 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var ValuedResource $response */ - $response = $securityCenterClient->getValuedResource($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::valuedResourceName( - '[ORGANIZATION]', - '[SIMULATION]', - '[VALUED_RESOURCE]' - ); - - get_valued_resource_sample($formattedName); -} -// [END securitycenter_v2_generated_SecurityCenter_GetValuedResource_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/group_findings.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/group_findings.php deleted file mode 100644 index 17c770cff8f4..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/group_findings.php +++ /dev/null @@ -1,114 +0,0 @@ -setParent($formattedParent) - ->setGroupBy($groupBy); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->groupFindings($request); - - /** @var GroupResult $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); - $groupBy = '[GROUP_BY]'; - - group_findings_sample($formattedParent, $groupBy); -} -// [END securitycenter_v2_generated_SecurityCenter_GroupFindings_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_attack_paths.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_attack_paths.php deleted file mode 100644 index c73ae4482d56..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_attack_paths.php +++ /dev/null @@ -1,88 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->listAttackPaths($request); - - /** @var AttackPath $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::organizationValuedResourceName( - '[ORGANIZATION]', - '[LOCATION]', - '[SIMULATION]', - '[VALUED_RESOURCE]' - ); - - list_attack_paths_sample($formattedParent); -} -// [END securitycenter_v2_generated_SecurityCenter_ListAttackPaths_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_big_query_exports.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_big_query_exports.php deleted file mode 100644 index 98209ecb6106..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_big_query_exports.php +++ /dev/null @@ -1,83 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->listBigQueryExports($request); - - /** @var BigQueryExport $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - - list_big_query_exports_sample($formattedParent); -} -// [END securitycenter_v2_generated_SecurityCenter_ListBigQueryExports_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_findings.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_findings.php deleted file mode 100644 index f1a611b5f476..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_findings.php +++ /dev/null @@ -1,103 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->listFindings($request); - - /** @var ListFindingsResult $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::sourceName('[ORGANIZATION]', '[SOURCE]'); - - list_findings_sample($formattedParent); -} -// [END securitycenter_v2_generated_SecurityCenter_ListFindings_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_mute_configs.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_mute_configs.php deleted file mode 100644 index c9f315f496ee..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_mute_configs.php +++ /dev/null @@ -1,82 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->listMuteConfigs($request); - - /** @var MuteConfig $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - - list_mute_configs_sample($formattedParent); -} -// [END securitycenter_v2_generated_SecurityCenter_ListMuteConfigs_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_notification_configs.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_notification_configs.php deleted file mode 100644 index 185c3518d48f..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_notification_configs.php +++ /dev/null @@ -1,80 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->listNotificationConfigs($request); - - /** @var NotificationConfig $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - - list_notification_configs_sample($formattedParent); -} -// [END securitycenter_v2_generated_SecurityCenter_ListNotificationConfigs_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_resource_value_configs.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_resource_value_configs.php deleted file mode 100644 index 63ea9e8e6697..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_resource_value_configs.php +++ /dev/null @@ -1,78 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->listResourceValueConfigs($request); - - /** @var ResourceValueConfig $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - - list_resource_value_configs_sample($formattedParent); -} -// [END securitycenter_v2_generated_SecurityCenter_ListResourceValueConfigs_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_sources.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_sources.php deleted file mode 100644 index 47b9882c05dd..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_sources.php +++ /dev/null @@ -1,78 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->listSources($request); - - /** @var Source $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::projectName('[PROJECT]'); - - list_sources_sample($formattedParent); -} -// [END securitycenter_v2_generated_SecurityCenter_ListSources_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_valued_resources.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_valued_resources.php deleted file mode 100644 index b3732d2b7a53..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/list_valued_resources.php +++ /dev/null @@ -1,81 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $securityCenterClient->listValuedResources($request); - - /** @var ValuedResource $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedParent = SecurityCenterClient::simulationName('[ORGANIZATION]', '[SIMULATION]'); - - list_valued_resources_sample($formattedParent); -} -// [END securitycenter_v2_generated_SecurityCenter_ListValuedResources_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_finding_state.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_finding_state.php deleted file mode 100644 index 51e2901ef3cc..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_finding_state.php +++ /dev/null @@ -1,90 +0,0 @@ -setName($formattedName) - ->setState($state); - - // Call the API and handle any network failures. - try { - /** @var Finding $response */ - $response = $securityCenterClient->setFindingState($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - $state = State::STATE_UNSPECIFIED; - - set_finding_state_sample($formattedName, $state); -} -// [END securitycenter_v2_generated_SecurityCenter_SetFindingState_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_iam_policy.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_iam_policy.php deleted file mode 100644 index 994eae7c0930..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_iam_policy.php +++ /dev/null @@ -1,73 +0,0 @@ -setResource($resource) - ->setPolicy($policy); - - // Call the API and handle any network failures. - try { - /** @var Policy $response */ - $response = $securityCenterClient->setIamPolicy($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $resource = '[RESOURCE]'; - - set_iam_policy_sample($resource); -} -// [END securitycenter_v2_generated_SecurityCenter_SetIamPolicy_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_mute.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_mute.php deleted file mode 100644 index 46e7f2382bdc..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/set_mute.php +++ /dev/null @@ -1,90 +0,0 @@ -setName($formattedName) - ->setMute($mute); - - // Call the API and handle any network failures. - try { - /** @var Finding $response */ - $response = $securityCenterClient->setMute($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $formattedName = SecurityCenterClient::findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - $mute = Mute::MUTE_UNSPECIFIED; - - set_mute_sample($formattedName, $mute); -} -// [END securitycenter_v2_generated_SecurityCenter_SetMute_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/test_iam_permissions.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/test_iam_permissions.php deleted file mode 100644 index 8b4e4297173e..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/test_iam_permissions.php +++ /dev/null @@ -1,78 +0,0 @@ -setResource($resource) - ->setPermissions($permissions); - - // Call the API and handle any network failures. - try { - /** @var TestIamPermissionsResponse $response */ - $response = $securityCenterClient->testIamPermissions($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $resource = '[RESOURCE]'; - $permissionsElement = '[PERMISSIONS]'; - - test_iam_permissions_sample($resource, $permissionsElement); -} -// [END securitycenter_v2_generated_SecurityCenter_TestIamPermissions_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_big_query_export.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_big_query_export.php deleted file mode 100644 index 3701cd360e27..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_big_query_export.php +++ /dev/null @@ -1,59 +0,0 @@ -setBigQueryExport($bigQueryExport); - - // Call the API and handle any network failures. - try { - /** @var BigQueryExport $response */ - $response = $securityCenterClient->updateBigQueryExport($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END securitycenter_v2_generated_SecurityCenter_UpdateBigQueryExport_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_external_system.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_external_system.php deleted file mode 100644 index 3036bdbefd69..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_external_system.php +++ /dev/null @@ -1,60 +0,0 @@ -setExternalSystem($externalSystem); - - // Call the API and handle any network failures. - try { - /** @var ExternalSystem $response */ - $response = $securityCenterClient->updateExternalSystem($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END securitycenter_v2_generated_SecurityCenter_UpdateExternalSystem_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_finding.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_finding.php deleted file mode 100644 index 06fd8eb4aac9..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_finding.php +++ /dev/null @@ -1,61 +0,0 @@ -setFinding($finding); - - // Call the API and handle any network failures. - try { - /** @var Finding $response */ - $response = $securityCenterClient->updateFinding($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END securitycenter_v2_generated_SecurityCenter_UpdateFinding_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_mute_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_mute_config.php deleted file mode 100644 index 88891aa5a60a..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_mute_config.php +++ /dev/null @@ -1,97 +0,0 @@ -setFilter($muteConfigFilter) - ->setType($muteConfigType); - $request = (new UpdateMuteConfigRequest()) - ->setMuteConfig($muteConfig); - - // Call the API and handle any network failures. - try { - /** @var MuteConfig $response */ - $response = $securityCenterClient->updateMuteConfig($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $muteConfigFilter = '[FILTER]'; - $muteConfigType = MuteConfigType::MUTE_CONFIG_TYPE_UNSPECIFIED; - - update_mute_config_sample($muteConfigFilter, $muteConfigType); -} -// [END securitycenter_v2_generated_SecurityCenter_UpdateMuteConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_notification_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_notification_config.php deleted file mode 100644 index 1bed33b59408..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_notification_config.php +++ /dev/null @@ -1,60 +0,0 @@ -setNotificationConfig($notificationConfig); - - // Call the API and handle any network failures. - try { - /** @var NotificationConfig $response */ - $response = $securityCenterClient->updateNotificationConfig($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END securitycenter_v2_generated_SecurityCenter_UpdateNotificationConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_resource_value_config.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_resource_value_config.php deleted file mode 100644 index 88655d00e356..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_resource_value_config.php +++ /dev/null @@ -1,76 +0,0 @@ -AND to check against. - * Values in the form "tagValues/123" - * Example: [ "tagValues/123", "tagValues/456", "tagValues/789" ] - * https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing - */ -function update_resource_value_config_sample(string $resourceValueConfigTagValuesElement): void -{ - // Create a client. - $securityCenterClient = new SecurityCenterClient(); - - // Prepare the request message. - $resourceValueConfigTagValues = [$resourceValueConfigTagValuesElement,]; - $resourceValueConfig = (new ResourceValueConfig()) - ->setTagValues($resourceValueConfigTagValues); - $request = (new UpdateResourceValueConfigRequest()) - ->setResourceValueConfig($resourceValueConfig); - - // Call the API and handle any network failures. - try { - /** @var ResourceValueConfig $response */ - $response = $securityCenterClient->updateResourceValueConfig($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $resourceValueConfigTagValuesElement = '[TAG_VALUES]'; - - update_resource_value_config_sample($resourceValueConfigTagValuesElement); -} -// [END securitycenter_v2_generated_SecurityCenter_UpdateResourceValueConfig_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_security_marks.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_security_marks.php deleted file mode 100644 index faac811ad4a6..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_security_marks.php +++ /dev/null @@ -1,61 +0,0 @@ -setSecurityMarks($securityMarks); - - // Call the API and handle any network failures. - try { - /** @var SecurityMarks $response */ - $response = $securityCenterClient->updateSecurityMarks($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END securitycenter_v2_generated_SecurityCenter_UpdateSecurityMarks_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_source.php b/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_source.php deleted file mode 100644 index 0cd0c337c75a..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/samples/V2/SecurityCenterClient/update_source.php +++ /dev/null @@ -1,59 +0,0 @@ -setSource($source); - - // Call the API and handle any network failures. - try { - /** @var Source $response */ - $response = $securityCenterClient->updateSource($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END securitycenter_v2_generated_SecurityCenter_UpdateSource_sync] diff --git a/owl-bot-staging/SecurityCenter/v2/src/V2/Client/SecurityCenterClient.php b/owl-bot-staging/SecurityCenter/v2/src/V2/Client/SecurityCenterClient.php deleted file mode 100644 index 07df517a9ec6..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/src/V2/Client/SecurityCenterClient.php +++ /dev/null @@ -1,2791 +0,0 @@ - self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/security_center_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/security_center_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/security_center_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/security_center_rest_client_config.php', - ], - ], - ]; - } - - /** - * Return an OperationsClient object with the same endpoint as $this. - * - * @return OperationsClient - */ - public function getOperationsClient() - { - return $this->operationsClient; - } - - /** - * Resume an existing long running operation that was previously started by a long - * running API method. If $methodName is not provided, or does not match a long - * running API method, then the operation can still be resumed, but the - * OperationResponse object will not deserialize the final response. - * - * @param string $operationName The name of the long running operation - * @param string $methodName The name of the method used to start the operation - * - * @return OperationResponse - */ - public function resumeOperation($operationName, $methodName = null) - { - $options = isset($this->descriptors[$methodName]['longRunning']) ? $this->descriptors[$methodName]['longRunning'] : []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Create the default operation client for the service. - * - * @param array $options ClientOptions for the client. - * - * @return OperationsClient - */ - private function createOperationsClient(array $options) - { - // Unset client-specific configuration options - unset($options['serviceName'], $options['clientConfig'], $options['descriptorsConfigPath']); - - if (isset($options['operationsClient'])) { - return $options['operationsClient']; - } - - return new OperationsClient($options); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * big_query_export resource. - * - * @param string $organization - * @param string $location - * @param string $export - * - * @return string The formatted big_query_export resource. - */ - public static function bigQueryExportName(string $organization, string $location, string $export): string - { - return self::getPathTemplate('bigQueryExport')->render([ - 'organization' => $organization, - 'location' => $location, - 'export' => $export, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a dlp_job - * resource. - * - * @param string $project - * @param string $dlpJob - * - * @return string The formatted dlp_job resource. - */ - public static function dlpJobName(string $project, string $dlpJob): string - { - return self::getPathTemplate('dlpJob')->render([ - 'project' => $project, - 'dlp_job' => $dlpJob, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * external_system resource. - * - * @param string $organization - * @param string $source - * @param string $finding - * @param string $externalsystem - * - * @return string The formatted external_system resource. - */ - public static function externalSystemName(string $organization, string $source, string $finding, string $externalsystem): string - { - return self::getPathTemplate('externalSystem')->render([ - 'organization' => $organization, - 'source' => $source, - 'finding' => $finding, - 'externalsystem' => $externalsystem, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a finding - * resource. - * - * @param string $organization - * @param string $source - * @param string $finding - * - * @return string The formatted finding resource. - */ - public static function findingName(string $organization, string $source, string $finding): string - { - return self::getPathTemplate('finding')->render([ - 'organization' => $organization, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a folder - * resource. - * - * @param string $folder - * - * @return string The formatted folder resource. - */ - public static function folderName(string $folder): string - { - return self::getPathTemplate('folder')->render([ - 'folder' => $folder, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_asset_securityMarks resource. - * - * @param string $folder - * @param string $asset - * - * @return string The formatted folder_asset_securityMarks resource. - */ - public static function folderAssetSecurityMarksName(string $folder, string $asset): string - { - return self::getPathTemplate('folderAssetSecurityMarks')->render([ - 'folder' => $folder, - 'asset' => $asset, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_constraint_name resource. - * - * @param string $folder - * @param string $constraintName - * - * @return string The formatted folder_constraint_name resource. - */ - public static function folderConstraintNameName(string $folder, string $constraintName): string - { - return self::getPathTemplate('folderConstraintName')->render([ - 'folder' => $folder, - 'constraint_name' => $constraintName, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_location resource. - * - * @param string $folder - * @param string $location - * - * @return string The formatted folder_location resource. - */ - public static function folderLocationName(string $folder, string $location): string - { - return self::getPathTemplate('folderLocation')->render([ - 'folder' => $folder, - 'location' => $location, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_location_export resource. - * - * @param string $folder - * @param string $location - * @param string $export - * - * @return string The formatted folder_location_export resource. - */ - public static function folderLocationExportName(string $folder, string $location, string $export): string - { - return self::getPathTemplate('folderLocationExport')->render([ - 'folder' => $folder, - 'location' => $location, - 'export' => $export, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_location_mute_config resource. - * - * @param string $folder - * @param string $location - * @param string $muteConfig - * - * @return string The formatted folder_location_mute_config resource. - */ - public static function folderLocationMuteConfigName(string $folder, string $location, string $muteConfig): string - { - return self::getPathTemplate('folderLocationMuteConfig')->render([ - 'folder' => $folder, - 'location' => $location, - 'mute_config' => $muteConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_location_notification_config resource. - * - * @param string $folder - * @param string $location - * @param string $notificationConfig - * - * @return string The formatted folder_location_notification_config resource. - */ - public static function folderLocationNotificationConfigName(string $folder, string $location, string $notificationConfig): string - { - return self::getPathTemplate('folderLocationNotificationConfig')->render([ - 'folder' => $folder, - 'location' => $location, - 'notification_config' => $notificationConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_mute_config resource. - * - * @param string $folder - * @param string $muteConfig - * - * @return string The formatted folder_mute_config resource. - */ - public static function folderMuteConfigName(string $folder, string $muteConfig): string - { - return self::getPathTemplate('folderMuteConfig')->render([ - 'folder' => $folder, - 'mute_config' => $muteConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_source resource. - * - * @param string $folder - * @param string $source - * - * @return string The formatted folder_source resource. - */ - public static function folderSourceName(string $folder, string $source): string - { - return self::getPathTemplate('folderSource')->render([ - 'folder' => $folder, - 'source' => $source, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_source_finding resource. - * - * @param string $folder - * @param string $source - * @param string $finding - * - * @return string The formatted folder_source_finding resource. - */ - public static function folderSourceFindingName(string $folder, string $source, string $finding): string - { - return self::getPathTemplate('folderSourceFinding')->render([ - 'folder' => $folder, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_source_finding_externalsystem resource. - * - * @param string $folder - * @param string $source - * @param string $finding - * @param string $externalsystem - * - * @return string The formatted folder_source_finding_externalsystem resource. - */ - public static function folderSourceFindingExternalsystemName(string $folder, string $source, string $finding, string $externalsystem): string - { - return self::getPathTemplate('folderSourceFindingExternalsystem')->render([ - 'folder' => $folder, - 'source' => $source, - 'finding' => $finding, - 'externalsystem' => $externalsystem, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_source_finding_securityMarks resource. - * - * @param string $folder - * @param string $source - * @param string $finding - * - * @return string The formatted folder_source_finding_securityMarks resource. - */ - public static function folderSourceFindingSecurityMarksName(string $folder, string $source, string $finding): string - { - return self::getPathTemplate('folderSourceFindingSecurityMarks')->render([ - 'folder' => $folder, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_source_location_finding resource. - * - * @param string $folder - * @param string $source - * @param string $location - * @param string $finding - * - * @return string The formatted folder_source_location_finding resource. - */ - public static function folderSourceLocationFindingName(string $folder, string $source, string $location, string $finding): string - { - return self::getPathTemplate('folderSourceLocationFinding')->render([ - 'folder' => $folder, - 'source' => $source, - 'location' => $location, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_source_location_finding_externalsystem resource. - * - * @param string $folder - * @param string $source - * @param string $location - * @param string $finding - * @param string $externalsystem - * - * @return string The formatted folder_source_location_finding_externalsystem resource. - */ - public static function folderSourceLocationFindingExternalsystemName(string $folder, string $source, string $location, string $finding, string $externalsystem): string - { - return self::getPathTemplate('folderSourceLocationFindingExternalsystem')->render([ - 'folder' => $folder, - 'source' => $source, - 'location' => $location, - 'finding' => $finding, - 'externalsystem' => $externalsystem, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * folder_source_location_finding_securityMarks resource. - * - * @param string $folder - * @param string $source - * @param string $location - * @param string $finding - * - * @return string The formatted folder_source_location_finding_securityMarks resource. - */ - public static function folderSourceLocationFindingSecurityMarksName(string $folder, string $source, string $location, string $finding): string - { - return self::getPathTemplate('folderSourceLocationFindingSecurityMarks')->render([ - 'folder' => $folder, - 'source' => $source, - 'location' => $location, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a location - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted location resource. - */ - public static function locationName(string $project, string $location): string - { - return self::getPathTemplate('location')->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a mute_config - * resource. - * - * @param string $organization - * @param string $muteConfig - * - * @return string The formatted mute_config resource. - */ - public static function muteConfigName(string $organization, string $muteConfig): string - { - return self::getPathTemplate('muteConfig')->render([ - 'organization' => $organization, - 'mute_config' => $muteConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * notification_config resource. - * - * @param string $organization - * @param string $location - * @param string $notificationConfig - * - * @return string The formatted notification_config resource. - */ - public static function notificationConfigName(string $organization, string $location, string $notificationConfig): string - { - return self::getPathTemplate('notificationConfig')->render([ - 'organization' => $organization, - 'location' => $location, - 'notification_config' => $notificationConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a organization - * resource. - * - * @param string $organization - * - * @return string The formatted organization resource. - */ - public static function organizationName(string $organization): string - { - return self::getPathTemplate('organization')->render([ - 'organization' => $organization, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_asset_securityMarks resource. - * - * @param string $organization - * @param string $asset - * - * @return string The formatted organization_asset_securityMarks resource. - */ - public static function organizationAssetSecurityMarksName(string $organization, string $asset): string - { - return self::getPathTemplate('organizationAssetSecurityMarks')->render([ - 'organization' => $organization, - 'asset' => $asset, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_constraint_name resource. - * - * @param string $organization - * @param string $constraintName - * - * @return string The formatted organization_constraint_name resource. - */ - public static function organizationConstraintNameName(string $organization, string $constraintName): string - { - return self::getPathTemplate('organizationConstraintName')->render([ - 'organization' => $organization, - 'constraint_name' => $constraintName, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location resource. - * - * @param string $organization - * @param string $location - * - * @return string The formatted organization_location resource. - */ - public static function organizationLocationName(string $organization, string $location): string - { - return self::getPathTemplate('organizationLocation')->render([ - 'organization' => $organization, - 'location' => $location, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location_export resource. - * - * @param string $organization - * @param string $location - * @param string $export - * - * @return string The formatted organization_location_export resource. - */ - public static function organizationLocationExportName(string $organization, string $location, string $export): string - { - return self::getPathTemplate('organizationLocationExport')->render([ - 'organization' => $organization, - 'location' => $location, - 'export' => $export, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location_mute_config resource. - * - * @param string $organization - * @param string $location - * @param string $muteConfig - * - * @return string The formatted organization_location_mute_config resource. - */ - public static function organizationLocationMuteConfigName(string $organization, string $location, string $muteConfig): string - { - return self::getPathTemplate('organizationLocationMuteConfig')->render([ - 'organization' => $organization, - 'location' => $location, - 'mute_config' => $muteConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location_notification_config resource. - * - * @param string $organization - * @param string $location - * @param string $notificationConfig - * - * @return string The formatted organization_location_notification_config resource. - */ - public static function organizationLocationNotificationConfigName(string $organization, string $location, string $notificationConfig): string - { - return self::getPathTemplate('organizationLocationNotificationConfig')->render([ - 'organization' => $organization, - 'location' => $location, - 'notification_config' => $notificationConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location_resource_value_config resource. - * - * @param string $organization - * @param string $location - * @param string $resourceValueConfig - * - * @return string The formatted organization_location_resource_value_config resource. - */ - public static function organizationLocationResourceValueConfigName(string $organization, string $location, string $resourceValueConfig): string - { - return self::getPathTemplate('organizationLocationResourceValueConfig')->render([ - 'organization' => $organization, - 'location' => $location, - 'resource_value_config' => $resourceValueConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location_simluation resource. - * - * @param string $organization - * @param string $location - * @param string $simluation - * - * @return string The formatted organization_location_simluation resource. - */ - public static function organizationLocationSimluationName(string $organization, string $location, string $simluation): string - { - return self::getPathTemplate('organizationLocationSimluation')->render([ - 'organization' => $organization, - 'location' => $location, - 'simluation' => $simluation, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_location_simluation_valued_resource resource. - * - * @param string $organization - * @param string $location - * @param string $simluation - * @param string $valuedResource - * - * @return string The formatted organization_location_simluation_valued_resource resource. - */ - public static function organizationLocationSimluationValuedResourceName(string $organization, string $location, string $simluation, string $valuedResource): string - { - return self::getPathTemplate('organizationLocationSimluationValuedResource')->render([ - 'organization' => $organization, - 'location' => $location, - 'simluation' => $simluation, - 'valued_resource' => $valuedResource, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_mute_config resource. - * - * @param string $organization - * @param string $muteConfig - * - * @return string The formatted organization_mute_config resource. - */ - public static function organizationMuteConfigName(string $organization, string $muteConfig): string - { - return self::getPathTemplate('organizationMuteConfig')->render([ - 'organization' => $organization, - 'mute_config' => $muteConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_resource_value_config resource. - * - * @param string $organization - * @param string $resourceValueConfig - * - * @return string The formatted organization_resource_value_config resource. - */ - public static function organizationResourceValueConfigName(string $organization, string $resourceValueConfig): string - { - return self::getPathTemplate('organizationResourceValueConfig')->render([ - 'organization' => $organization, - 'resource_value_config' => $resourceValueConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_simulation resource. - * - * @param string $organization - * @param string $simulation - * - * @return string The formatted organization_simulation resource. - */ - public static function organizationSimulationName(string $organization, string $simulation): string - { - return self::getPathTemplate('organizationSimulation')->render([ - 'organization' => $organization, - 'simulation' => $simulation, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_simulation_valued_resource resource. - * - * @param string $organization - * @param string $simulation - * @param string $valuedResource - * - * @return string The formatted organization_simulation_valued_resource resource. - */ - public static function organizationSimulationValuedResourceName(string $organization, string $simulation, string $valuedResource): string - { - return self::getPathTemplate('organizationSimulationValuedResource')->render([ - 'organization' => $organization, - 'simulation' => $simulation, - 'valued_resource' => $valuedResource, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_source resource. - * - * @param string $organization - * @param string $source - * - * @return string The formatted organization_source resource. - */ - public static function organizationSourceName(string $organization, string $source): string - { - return self::getPathTemplate('organizationSource')->render([ - 'organization' => $organization, - 'source' => $source, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_source_finding resource. - * - * @param string $organization - * @param string $source - * @param string $finding - * - * @return string The formatted organization_source_finding resource. - */ - public static function organizationSourceFindingName(string $organization, string $source, string $finding): string - { - return self::getPathTemplate('organizationSourceFinding')->render([ - 'organization' => $organization, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_source_finding_externalsystem resource. - * - * @param string $organization - * @param string $source - * @param string $finding - * @param string $externalsystem - * - * @return string The formatted organization_source_finding_externalsystem resource. - */ - public static function organizationSourceFindingExternalsystemName(string $organization, string $source, string $finding, string $externalsystem): string - { - return self::getPathTemplate('organizationSourceFindingExternalsystem')->render([ - 'organization' => $organization, - 'source' => $source, - 'finding' => $finding, - 'externalsystem' => $externalsystem, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_source_finding_securityMarks resource. - * - * @param string $organization - * @param string $source - * @param string $finding - * - * @return string The formatted organization_source_finding_securityMarks resource. - */ - public static function organizationSourceFindingSecurityMarksName(string $organization, string $source, string $finding): string - { - return self::getPathTemplate('organizationSourceFindingSecurityMarks')->render([ - 'organization' => $organization, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_source_location_finding resource. - * - * @param string $organization - * @param string $source - * @param string $location - * @param string $finding - * - * @return string The formatted organization_source_location_finding resource. - */ - public static function organizationSourceLocationFindingName(string $organization, string $source, string $location, string $finding): string - { - return self::getPathTemplate('organizationSourceLocationFinding')->render([ - 'organization' => $organization, - 'source' => $source, - 'location' => $location, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_source_location_finding_externalsystem resource. - * - * @param string $organization - * @param string $source - * @param string $location - * @param string $finding - * @param string $externalsystem - * - * @return string The formatted organization_source_location_finding_externalsystem resource. - */ - public static function organizationSourceLocationFindingExternalsystemName(string $organization, string $source, string $location, string $finding, string $externalsystem): string - { - return self::getPathTemplate('organizationSourceLocationFindingExternalsystem')->render([ - 'organization' => $organization, - 'source' => $source, - 'location' => $location, - 'finding' => $finding, - 'externalsystem' => $externalsystem, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_source_location_finding_securityMarks resource. - * - * @param string $organization - * @param string $source - * @param string $location - * @param string $finding - * - * @return string The formatted organization_source_location_finding_securityMarks resource. - */ - public static function organizationSourceLocationFindingSecurityMarksName(string $organization, string $source, string $location, string $finding): string - { - return self::getPathTemplate('organizationSourceLocationFindingSecurityMarks')->render([ - 'organization' => $organization, - 'source' => $source, - 'location' => $location, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * organization_valued_resource resource. - * - * @param string $organization - * @param string $location - * @param string $simulation - * @param string $valuedResource - * - * @return string The formatted organization_valued_resource resource. - */ - public static function organizationValuedResourceName(string $organization, string $location, string $simulation, string $valuedResource): string - { - return self::getPathTemplate('organizationValuedResource')->render([ - 'organization' => $organization, - 'location' => $location, - 'simulation' => $simulation, - 'valued_resource' => $valuedResource, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a policy - * resource. - * - * @param string $organization - * @param string $constraintName - * - * @return string The formatted policy resource. - */ - public static function policyName(string $organization, string $constraintName): string - { - return self::getPathTemplate('policy')->render([ - 'organization' => $organization, - 'constraint_name' => $constraintName, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a project - * resource. - * - * @param string $project - * - * @return string The formatted project resource. - */ - public static function projectName(string $project): string - { - return self::getPathTemplate('project')->render([ - 'project' => $project, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_asset_securityMarks resource. - * - * @param string $project - * @param string $asset - * - * @return string The formatted project_asset_securityMarks resource. - */ - public static function projectAssetSecurityMarksName(string $project, string $asset): string - { - return self::getPathTemplate('projectAssetSecurityMarks')->render([ - 'project' => $project, - 'asset' => $asset, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_constraint_name resource. - * - * @param string $project - * @param string $constraintName - * - * @return string The formatted project_constraint_name resource. - */ - public static function projectConstraintNameName(string $project, string $constraintName): string - { - return self::getPathTemplate('projectConstraintName')->render([ - 'project' => $project, - 'constraint_name' => $constraintName, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_dlp_job resource. - * - * @param string $project - * @param string $dlpJob - * - * @return string The formatted project_dlp_job resource. - */ - public static function projectDlpJobName(string $project, string $dlpJob): string - { - return self::getPathTemplate('projectDlpJob')->render([ - 'project' => $project, - 'dlp_job' => $dlpJob, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_dlp_job resource. - * - * @param string $project - * @param string $location - * @param string $dlpJob - * - * @return string The formatted project_location_dlp_job resource. - */ - public static function projectLocationDlpJobName(string $project, string $location, string $dlpJob): string - { - return self::getPathTemplate('projectLocationDlpJob')->render([ - 'project' => $project, - 'location' => $location, - 'dlp_job' => $dlpJob, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_export resource. - * - * @param string $project - * @param string $location - * @param string $export - * - * @return string The formatted project_location_export resource. - */ - public static function projectLocationExportName(string $project, string $location, string $export): string - { - return self::getPathTemplate('projectLocationExport')->render([ - 'project' => $project, - 'location' => $location, - 'export' => $export, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_mute_config resource. - * - * @param string $project - * @param string $location - * @param string $muteConfig - * - * @return string The formatted project_location_mute_config resource. - */ - public static function projectLocationMuteConfigName(string $project, string $location, string $muteConfig): string - { - return self::getPathTemplate('projectLocationMuteConfig')->render([ - 'project' => $project, - 'location' => $location, - 'mute_config' => $muteConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_notification_config resource. - * - * @param string $project - * @param string $location - * @param string $notificationConfig - * - * @return string The formatted project_location_notification_config resource. - */ - public static function projectLocationNotificationConfigName(string $project, string $location, string $notificationConfig): string - { - return self::getPathTemplate('projectLocationNotificationConfig')->render([ - 'project' => $project, - 'location' => $location, - 'notification_config' => $notificationConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_location_table_profile resource. - * - * @param string $project - * @param string $location - * @param string $tableProfile - * - * @return string The formatted project_location_table_profile resource. - */ - public static function projectLocationTableProfileName(string $project, string $location, string $tableProfile): string - { - return self::getPathTemplate('projectLocationTableProfile')->render([ - 'project' => $project, - 'location' => $location, - 'table_profile' => $tableProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_mute_config resource. - * - * @param string $project - * @param string $muteConfig - * - * @return string The formatted project_mute_config resource. - */ - public static function projectMuteConfigName(string $project, string $muteConfig): string - { - return self::getPathTemplate('projectMuteConfig')->render([ - 'project' => $project, - 'mute_config' => $muteConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_source resource. - * - * @param string $project - * @param string $source - * - * @return string The formatted project_source resource. - */ - public static function projectSourceName(string $project, string $source): string - { - return self::getPathTemplate('projectSource')->render([ - 'project' => $project, - 'source' => $source, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_source_finding resource. - * - * @param string $project - * @param string $source - * @param string $finding - * - * @return string The formatted project_source_finding resource. - */ - public static function projectSourceFindingName(string $project, string $source, string $finding): string - { - return self::getPathTemplate('projectSourceFinding')->render([ - 'project' => $project, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_source_finding_externalsystem resource. - * - * @param string $project - * @param string $source - * @param string $finding - * @param string $externalsystem - * - * @return string The formatted project_source_finding_externalsystem resource. - */ - public static function projectSourceFindingExternalsystemName(string $project, string $source, string $finding, string $externalsystem): string - { - return self::getPathTemplate('projectSourceFindingExternalsystem')->render([ - 'project' => $project, - 'source' => $source, - 'finding' => $finding, - 'externalsystem' => $externalsystem, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_source_finding_securityMarks resource. - * - * @param string $project - * @param string $source - * @param string $finding - * - * @return string The formatted project_source_finding_securityMarks resource. - */ - public static function projectSourceFindingSecurityMarksName(string $project, string $source, string $finding): string - { - return self::getPathTemplate('projectSourceFindingSecurityMarks')->render([ - 'project' => $project, - 'source' => $source, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_source_location_finding resource. - * - * @param string $project - * @param string $source - * @param string $location - * @param string $finding - * - * @return string The formatted project_source_location_finding resource. - */ - public static function projectSourceLocationFindingName(string $project, string $source, string $location, string $finding): string - { - return self::getPathTemplate('projectSourceLocationFinding')->render([ - 'project' => $project, - 'source' => $source, - 'location' => $location, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_source_location_finding_externalsystem resource. - * - * @param string $project - * @param string $source - * @param string $location - * @param string $finding - * @param string $externalsystem - * - * @return string The formatted project_source_location_finding_externalsystem resource. - */ - public static function projectSourceLocationFindingExternalsystemName(string $project, string $source, string $location, string $finding, string $externalsystem): string - { - return self::getPathTemplate('projectSourceLocationFindingExternalsystem')->render([ - 'project' => $project, - 'source' => $source, - 'location' => $location, - 'finding' => $finding, - 'externalsystem' => $externalsystem, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_source_location_finding_securityMarks resource. - * - * @param string $project - * @param string $source - * @param string $location - * @param string $finding - * - * @return string The formatted project_source_location_finding_securityMarks resource. - */ - public static function projectSourceLocationFindingSecurityMarksName(string $project, string $source, string $location, string $finding): string - { - return self::getPathTemplate('projectSourceLocationFindingSecurityMarks')->render([ - 'project' => $project, - 'source' => $source, - 'location' => $location, - 'finding' => $finding, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * project_table_profile resource. - * - * @param string $project - * @param string $tableProfile - * - * @return string The formatted project_table_profile resource. - */ - public static function projectTableProfileName(string $project, string $tableProfile): string - { - return self::getPathTemplate('projectTableProfile')->render([ - 'project' => $project, - 'table_profile' => $tableProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * resource_value_config resource. - * - * @param string $organization - * @param string $resourceValueConfig - * - * @return string The formatted resource_value_config resource. - */ - public static function resourceValueConfigName(string $organization, string $resourceValueConfig): string - { - return self::getPathTemplate('resourceValueConfig')->render([ - 'organization' => $organization, - 'resource_value_config' => $resourceValueConfig, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * security_marks resource. - * - * @param string $organization - * @param string $asset - * - * @return string The formatted security_marks resource. - */ - public static function securityMarksName(string $organization, string $asset): string - { - return self::getPathTemplate('securityMarks')->render([ - 'organization' => $organization, - 'asset' => $asset, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a simulation - * resource. - * - * @param string $organization - * @param string $simulation - * - * @return string The formatted simulation resource. - */ - public static function simulationName(string $organization, string $simulation): string - { - return self::getPathTemplate('simulation')->render([ - 'organization' => $organization, - 'simulation' => $simulation, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a source - * resource. - * - * @param string $organization - * @param string $source - * - * @return string The formatted source resource. - */ - public static function sourceName(string $organization, string $source): string - { - return self::getPathTemplate('source')->render([ - 'organization' => $organization, - 'source' => $source, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * table_data_profile resource. - * - * @param string $project - * @param string $tableProfile - * - * @return string The formatted table_data_profile resource. - */ - public static function tableDataProfileName(string $project, string $tableProfile): string - { - return self::getPathTemplate('tableDataProfile')->render([ - 'project' => $project, - 'table_profile' => $tableProfile, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a topic - * resource. - * - * @param string $project - * @param string $topic - * - * @return string The formatted topic resource. - */ - public static function topicName(string $project, string $topic): string - { - return self::getPathTemplate('topic')->render([ - 'project' => $project, - 'topic' => $topic, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * valued_resource resource. - * - * @param string $organization - * @param string $simulation - * @param string $valuedResource - * - * @return string The formatted valued_resource resource. - */ - public static function valuedResourceName(string $organization, string $simulation, string $valuedResource): string - { - return self::getPathTemplate('valuedResource')->render([ - 'organization' => $organization, - 'simulation' => $simulation, - 'valued_resource' => $valuedResource, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - bigQueryExport: organizations/{organization}/locations/{location}/bigQueryExports/{export} - * - dlpJob: projects/{project}/dlpJobs/{dlp_job} - * - externalSystem: organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} - * - finding: organizations/{organization}/sources/{source}/findings/{finding} - * - folder: folders/{folder} - * - folderAssetSecurityMarks: folders/{folder}/assets/{asset}/securityMarks - * - folderConstraintName: folders/{folder}/policies/{constraint_name} - * - folderLocation: folders/{folder}/locations/{location} - * - folderLocationExport: folders/{folder}/locations/{location}/bigQueryExports/{export} - * - folderLocationMuteConfig: folders/{folder}/locations/{location}/muteConfigs/{mute_config} - * - folderLocationNotificationConfig: folders/{folder}/locations/{location}/notificationConfigs/{notification_config} - * - folderMuteConfig: folders/{folder}/muteConfigs/{mute_config} - * - folderSource: folders/{folder}/sources/{source} - * - folderSourceFinding: folders/{folder}/sources/{source}/findings/{finding} - * - folderSourceFindingExternalsystem: folders/{folder}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} - * - folderSourceFindingSecurityMarks: folders/{folder}/sources/{source}/findings/{finding}/securityMarks - * - folderSourceLocationFinding: folders/{folder}/sources/{source}/locations/{location}/findings/{finding} - * - folderSourceLocationFindingExternalsystem: folders/{folder}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem} - * - folderSourceLocationFindingSecurityMarks: folders/{folder}/sources/{source}/locations/{location}/findings/{finding}/securityMarks - * - location: projects/{project}/locations/{location} - * - muteConfig: organizations/{organization}/muteConfigs/{mute_config} - * - notificationConfig: organizations/{organization}/locations/{location}/notificationConfigs/{notification_config} - * - organization: organizations/{organization} - * - organizationAssetSecurityMarks: organizations/{organization}/assets/{asset}/securityMarks - * - organizationConstraintName: organizations/{organization}/policies/{constraint_name} - * - organizationLocation: organizations/{organization}/locations/{location} - * - organizationLocationExport: organizations/{organization}/locations/{location}/bigQueryExports/{export} - * - organizationLocationMuteConfig: organizations/{organization}/locations/{location}/muteConfigs/{mute_config} - * - organizationLocationNotificationConfig: organizations/{organization}/locations/{location}/notificationConfigs/{notification_config} - * - organizationLocationResourceValueConfig: organizations/{organization}/locations/{location}/resourceValueConfigs/{resource_value_config} - * - organizationLocationSimluation: organizations/{organization}/locations/{location}/simulations/{simluation} - * - organizationLocationSimluationValuedResource: organizations/{organization}/locations/{location}/simulations/{simluation}/valuedResources/{valued_resource} - * - organizationMuteConfig: organizations/{organization}/muteConfigs/{mute_config} - * - organizationResourceValueConfig: organizations/{organization}/resourceValueConfigs/{resource_value_config} - * - organizationSimulation: organizations/{organization}/simulations/{simulation} - * - organizationSimulationValuedResource: organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource} - * - organizationSource: organizations/{organization}/sources/{source} - * - organizationSourceFinding: organizations/{organization}/sources/{source}/findings/{finding} - * - organizationSourceFindingExternalsystem: organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} - * - organizationSourceFindingSecurityMarks: organizations/{organization}/sources/{source}/findings/{finding}/securityMarks - * - organizationSourceLocationFinding: organizations/{organization}/sources/{source}/locations/{location}/findings/{finding} - * - organizationSourceLocationFindingExternalsystem: organizations/{organization}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem} - * - organizationSourceLocationFindingSecurityMarks: organizations/{organization}/sources/{source}/locations/{location}/findings/{finding}/securityMarks - * - organizationValuedResource: organizations/{organization}/locations/{location}/simulations/{simulation}/valuedResources/{valued_resource} - * - policy: organizations/{organization}/policies/{constraint_name} - * - project: projects/{project} - * - projectAssetSecurityMarks: projects/{project}/assets/{asset}/securityMarks - * - projectConstraintName: projects/{project}/policies/{constraint_name} - * - projectDlpJob: projects/{project}/dlpJobs/{dlp_job} - * - projectLocationDlpJob: projects/{project}/locations/{location}/dlpJobs/{dlp_job} - * - projectLocationExport: projects/{project}/locations/{location}/bigQueryExports/{export} - * - projectLocationMuteConfig: projects/{project}/locations/{location}/muteConfigs/{mute_config} - * - projectLocationNotificationConfig: projects/{project}/locations/{location}/notificationConfigs/{notification_config} - * - projectLocationTableProfile: projects/{project}/locations/{location}/tableProfiles/{table_profile} - * - projectMuteConfig: projects/{project}/muteConfigs/{mute_config} - * - projectSource: projects/{project}/sources/{source} - * - projectSourceFinding: projects/{project}/sources/{source}/findings/{finding} - * - projectSourceFindingExternalsystem: projects/{project}/sources/{source}/findings/{finding}/externalSystems/{externalsystem} - * - projectSourceFindingSecurityMarks: projects/{project}/sources/{source}/findings/{finding}/securityMarks - * - projectSourceLocationFinding: projects/{project}/sources/{source}/locations/{location}/findings/{finding} - * - projectSourceLocationFindingExternalsystem: projects/{project}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem} - * - projectSourceLocationFindingSecurityMarks: projects/{project}/sources/{source}/locations/{location}/findings/{finding}/securityMarks - * - projectTableProfile: projects/{project}/tableProfiles/{table_profile} - * - resourceValueConfig: organizations/{organization}/resourceValueConfigs/{resource_value_config} - * - securityMarks: organizations/{organization}/assets/{asset}/securityMarks - * - simulation: organizations/{organization}/simulations/{simulation} - * - source: organizations/{organization}/sources/{source} - * - tableDataProfile: projects/{project}/tableProfiles/{table_profile} - * - topic: projects/{project}/topics/{topic} - * - valuedResource: organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource} - * - * The optional $template argument can be supplied to specify a particular pattern, - * and must match one of the templates listed above. If no $template argument is - * provided, or if the $template argument does not match one of the templates - * listed, then parseName will check each of the supported templates, and return - * the first match. - * - * @param string $formattedName The formatted name string - * @param string $template Optional name of template to match - * - * @return array An associative array from name component IDs to component values. - * - * @throws ValidationException If $formattedName could not be matched. - */ - public static function parseName(string $formattedName, string $template = null): array - { - return self::parseFormattedName($formattedName, $template); - } - - /** - * Constructor. - * - * @param array $options { - * Optional. Options for configuring the service API wrapper. - * - * @type string $apiEndpoint - * The address of the API remote host. May optionally include the port, formatted - * as ":". Default 'securitycenter.googleapis.com:443'. - * @type string|array|FetchAuthTokenInterface|CredentialsWrapper $credentials - * The credentials to be used by the client to authorize API calls. This option - * accepts either a path to a credentials file, or a decoded credentials file as a - * PHP array. - * *Advanced usage*: In addition, this option can also accept a pre-constructed - * {@see \Google\Auth\FetchAuthTokenInterface} object or - * {@see \Google\ApiCore\CredentialsWrapper} object. Note that when one of these - * objects are provided, any settings in $credentialsConfig will be ignored. - * @type array $credentialsConfig - * Options used to configure credentials, including auth token caching, for the - * client. For a full list of supporting configuration options, see - * {@see \Google\ApiCore\CredentialsWrapper::build()} . - * @type bool $disableRetries - * Determines whether or not retries defined by the client configuration should be - * disabled. Defaults to `false`. - * @type string|array $clientConfig - * Client method configuration, including retry settings. This option can be either - * a path to a JSON file, or a PHP array containing the decoded JSON data. By - * default this settings points to the default client config file, which is - * provided in the resources folder. - * @type string|TransportInterface $transport - * The transport used for executing network requests. May be either the string - * `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. - * *Advanced usage*: Additionally, it is possible to pass in an already - * instantiated {@see \Google\ApiCore\Transport\TransportInterface} object. Note - * that when this object is provided, any settings in $transportConfig, and any - * $apiEndpoint setting, will be ignored. - * @type array $transportConfig - * Configuration options that will be used to construct the transport. Options for - * each supported transport type should be passed in a key for that transport. For - * example: - * $transportConfig = [ - * 'grpc' => [...], - * 'rest' => [...], - * ]; - * See the {@see \Google\ApiCore\Transport\GrpcTransport::build()} and - * {@see \Google\ApiCore\Transport\RestTransport::build()} methods for the - * supported options. - * @type callable $clientCertSource - * A callable which returns the client cert as a string. This can be used to - * provide a certificate and private key to the transport layer for mTLS. - * } - * - * @throws ValidationException - */ - public function __construct(array $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** Handles execution of the async variants for each documented method. */ - public function __call($method, $args) - { - if (substr($method, -5) !== 'Async') { - trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); - } - - array_unshift($args, substr($method, 0, -5)); - return call_user_func_array([$this, 'startAsyncCall'], $args); - } - - /** - * Creates a ResourceValueConfig for an organization. Maps user's tags to - * difference resource values for use by the attack path simulation. - * - * The async variant is - * {@see SecurityCenterClient::batchCreateResourceValueConfigsAsync()} . - * - * @example samples/V2/SecurityCenterClient/batch_create_resource_value_configs.php - * - * @param BatchCreateResourceValueConfigsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return BatchCreateResourceValueConfigsResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function batchCreateResourceValueConfigs(BatchCreateResourceValueConfigsRequest $request, array $callOptions = []): BatchCreateResourceValueConfigsResponse - { - return $this->startApiCall('BatchCreateResourceValueConfigs', $request, $callOptions)->wait(); - } - - /** - * Kicks off an LRO to bulk mute findings for a parent based on a filter. If - * no location is specified, findings are muted in global. The parent - * can be either an organization, folder, or project. The findings matched by - * the filter will be muted after the LRO is done. - * - * The async variant is {@see SecurityCenterClient::bulkMuteFindingsAsync()} . - * - * @example samples/V2/SecurityCenterClient/bulk_mute_findings.php - * - * @param BulkMuteFindingsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function bulkMuteFindings(BulkMuteFindingsRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('BulkMuteFindings', $request, $callOptions)->wait(); - } - - /** - * Creates a BigQuery export. - * - * The async variant is {@see SecurityCenterClient::createBigQueryExportAsync()} . - * - * @example samples/V2/SecurityCenterClient/create_big_query_export.php - * - * @param CreateBigQueryExportRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return BigQueryExport - * - * @throws ApiException Thrown if the API call fails. - */ - public function createBigQueryExport(CreateBigQueryExportRequest $request, array $callOptions = []): BigQueryExport - { - return $this->startApiCall('CreateBigQueryExport', $request, $callOptions)->wait(); - } - - /** - * Creates a finding in a location. The corresponding source must exist for - * finding creation to succeed. - * - * The async variant is {@see SecurityCenterClient::createFindingAsync()} . - * - * @example samples/V2/SecurityCenterClient/create_finding.php - * - * @param CreateFindingRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Finding - * - * @throws ApiException Thrown if the API call fails. - */ - public function createFinding(CreateFindingRequest $request, array $callOptions = []): Finding - { - return $this->startApiCall('CreateFinding', $request, $callOptions)->wait(); - } - - /** - * Creates a mute config. - * - * The async variant is {@see SecurityCenterClient::createMuteConfigAsync()} . - * - * @example samples/V2/SecurityCenterClient/create_mute_config.php - * - * @param CreateMuteConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return MuteConfig - * - * @throws ApiException Thrown if the API call fails. - */ - public function createMuteConfig(CreateMuteConfigRequest $request, array $callOptions = []): MuteConfig - { - return $this->startApiCall('CreateMuteConfig', $request, $callOptions)->wait(); - } - - /** - * Creates a notification config. - * - * The async variant is - * {@see SecurityCenterClient::createNotificationConfigAsync()} . - * - * @example samples/V2/SecurityCenterClient/create_notification_config.php - * - * @param CreateNotificationConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return NotificationConfig - * - * @throws ApiException Thrown if the API call fails. - */ - public function createNotificationConfig(CreateNotificationConfigRequest $request, array $callOptions = []): NotificationConfig - { - return $this->startApiCall('CreateNotificationConfig', $request, $callOptions)->wait(); - } - - /** - * Creates a source. - * - * The async variant is {@see SecurityCenterClient::createSourceAsync()} . - * - * @example samples/V2/SecurityCenterClient/create_source.php - * - * @param CreateSourceRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Source - * - * @throws ApiException Thrown if the API call fails. - */ - public function createSource(CreateSourceRequest $request, array $callOptions = []): Source - { - return $this->startApiCall('CreateSource', $request, $callOptions)->wait(); - } - - /** - * Deletes an existing BigQuery export. - * - * The async variant is {@see SecurityCenterClient::deleteBigQueryExportAsync()} . - * - * @example samples/V2/SecurityCenterClient/delete_big_query_export.php - * - * @param DeleteBigQueryExportRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteBigQueryExport(DeleteBigQueryExportRequest $request, array $callOptions = []): void - { - $this->startApiCall('DeleteBigQueryExport', $request, $callOptions)->wait(); - } - - /** - * Deletes an existing mute config. If no location is specified, default is - * global. - * - * The async variant is {@see SecurityCenterClient::deleteMuteConfigAsync()} . - * - * @example samples/V2/SecurityCenterClient/delete_mute_config.php - * - * @param DeleteMuteConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteMuteConfig(DeleteMuteConfigRequest $request, array $callOptions = []): void - { - $this->startApiCall('DeleteMuteConfig', $request, $callOptions)->wait(); - } - - /** - * Deletes a notification config. - * - * The async variant is - * {@see SecurityCenterClient::deleteNotificationConfigAsync()} . - * - * @example samples/V2/SecurityCenterClient/delete_notification_config.php - * - * @param DeleteNotificationConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteNotificationConfig(DeleteNotificationConfigRequest $request, array $callOptions = []): void - { - $this->startApiCall('DeleteNotificationConfig', $request, $callOptions)->wait(); - } - - /** - * Deletes a ResourceValueConfig. - * - * The async variant is - * {@see SecurityCenterClient::deleteResourceValueConfigAsync()} . - * - * @example samples/V2/SecurityCenterClient/delete_resource_value_config.php - * - * @param DeleteResourceValueConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteResourceValueConfig(DeleteResourceValueConfigRequest $request, array $callOptions = []): void - { - $this->startApiCall('DeleteResourceValueConfig', $request, $callOptions)->wait(); - } - - /** - * Gets a BigQuery export. - * - * The async variant is {@see SecurityCenterClient::getBigQueryExportAsync()} . - * - * @example samples/V2/SecurityCenterClient/get_big_query_export.php - * - * @param GetBigQueryExportRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return BigQueryExport - * - * @throws ApiException Thrown if the API call fails. - */ - public function getBigQueryExport(GetBigQueryExportRequest $request, array $callOptions = []): BigQueryExport - { - return $this->startApiCall('GetBigQueryExport', $request, $callOptions)->wait(); - } - - /** - * Gets the access control policy on the specified Source. - * - * The async variant is {@see SecurityCenterClient::getIamPolicyAsync()} . - * - * @example samples/V2/SecurityCenterClient/get_iam_policy.php - * - * @param GetIamPolicyRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Policy - * - * @throws ApiException Thrown if the API call fails. - */ - public function getIamPolicy(GetIamPolicyRequest $request, array $callOptions = []): Policy - { - return $this->startApiCall('GetIamPolicy', $request, $callOptions)->wait(); - } - - /** - * Gets a mute config. If no location is specified, default is - * global. - * - * The async variant is {@see SecurityCenterClient::getMuteConfigAsync()} . - * - * @example samples/V2/SecurityCenterClient/get_mute_config.php - * - * @param GetMuteConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return MuteConfig - * - * @throws ApiException Thrown if the API call fails. - */ - public function getMuteConfig(GetMuteConfigRequest $request, array $callOptions = []): MuteConfig - { - return $this->startApiCall('GetMuteConfig', $request, $callOptions)->wait(); - } - - /** - * Gets a notification config. - * - * The async variant is {@see SecurityCenterClient::getNotificationConfigAsync()} . - * - * @example samples/V2/SecurityCenterClient/get_notification_config.php - * - * @param GetNotificationConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return NotificationConfig - * - * @throws ApiException Thrown if the API call fails. - */ - public function getNotificationConfig(GetNotificationConfigRequest $request, array $callOptions = []): NotificationConfig - { - return $this->startApiCall('GetNotificationConfig', $request, $callOptions)->wait(); - } - - /** - * Gets a ResourceValueConfig. - * - * The async variant is {@see SecurityCenterClient::getResourceValueConfigAsync()} - * . - * - * @example samples/V2/SecurityCenterClient/get_resource_value_config.php - * - * @param GetResourceValueConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return ResourceValueConfig - * - * @throws ApiException Thrown if the API call fails. - */ - public function getResourceValueConfig(GetResourceValueConfigRequest $request, array $callOptions = []): ResourceValueConfig - { - return $this->startApiCall('GetResourceValueConfig', $request, $callOptions)->wait(); - } - - /** - * Get the simulation by name or the latest simulation for the given - * organization. - * - * The async variant is {@see SecurityCenterClient::getSimulationAsync()} . - * - * @example samples/V2/SecurityCenterClient/get_simulation.php - * - * @param GetSimulationRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Simulation - * - * @throws ApiException Thrown if the API call fails. - */ - public function getSimulation(GetSimulationRequest $request, array $callOptions = []): Simulation - { - return $this->startApiCall('GetSimulation', $request, $callOptions)->wait(); - } - - /** - * Gets a source. - * - * The async variant is {@see SecurityCenterClient::getSourceAsync()} . - * - * @example samples/V2/SecurityCenterClient/get_source.php - * - * @param GetSourceRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Source - * - * @throws ApiException Thrown if the API call fails. - */ - public function getSource(GetSourceRequest $request, array $callOptions = []): Source - { - return $this->startApiCall('GetSource', $request, $callOptions)->wait(); - } - - /** - * Get the valued resource by name - * - * The async variant is {@see SecurityCenterClient::getValuedResourceAsync()} . - * - * @example samples/V2/SecurityCenterClient/get_valued_resource.php - * - * @param GetValuedResourceRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return ValuedResource - * - * @throws ApiException Thrown if the API call fails. - */ - public function getValuedResource(GetValuedResourceRequest $request, array $callOptions = []): ValuedResource - { - return $this->startApiCall('GetValuedResource', $request, $callOptions)->wait(); - } - - /** - * Filters an organization or source's findings and groups them by their - * specified properties in a location. If no location is specified, findings - * are assumed to be in global - * - * To group across all sources provide a `-` as the source id. - * The following list shows some examples: - * - * + `/v2/organizations/{organization_id}/sources/-/findings` - * + - * `/v2/organizations/{organization_id}/sources/-/locations/{location_id}/findings` - * + `/v2/folders/{folder_id}/sources/-/findings` - * + `/v2/folders/{folder_id}/sources/-/locations/{location_id}/findings` - * + `/v2/projects/{project_id}/sources/-/findings` - * + `/v2/projects/{project_id}/sources/-/locations/{location_id}/findings` - * - * The async variant is {@see SecurityCenterClient::groupFindingsAsync()} . - * - * @example samples/V2/SecurityCenterClient/group_findings.php - * - * @param GroupFindingsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function groupFindings(GroupFindingsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('GroupFindings', $request, $callOptions); - } - - /** - * Lists the attack paths for a set of simulation results or valued resources - * and filter. - * - * The async variant is {@see SecurityCenterClient::listAttackPathsAsync()} . - * - * @example samples/V2/SecurityCenterClient/list_attack_paths.php - * - * @param ListAttackPathsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listAttackPaths(ListAttackPathsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListAttackPaths', $request, $callOptions); - } - - /** - * Lists BigQuery exports. Note that when requesting BigQuery exports at a - * given level all exports under that level are also returned e.g. if - * requesting BigQuery exports under a folder, then all BigQuery exports - * immediately under the folder plus the ones created under the projects - * within the folder are returned. - * - * The async variant is {@see SecurityCenterClient::listBigQueryExportsAsync()} . - * - * @example samples/V2/SecurityCenterClient/list_big_query_exports.php - * - * @param ListBigQueryExportsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listBigQueryExports(ListBigQueryExportsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListBigQueryExports', $request, $callOptions); - } - - /** - * Lists an organization or source's findings. - * - * To list across all sources for a given location provide a `-` as the source - * id. If no location is specified, finding are assumed to be in global. - * The following list shows some examples: - * - * + `/v2/organizations/{organization_id}/sources/-/findings` - * + - * `/v2/organizations/{organization_id}/sources/-/locations/{location_id}/findings` - * - * The async variant is {@see SecurityCenterClient::listFindingsAsync()} . - * - * @example samples/V2/SecurityCenterClient/list_findings.php - * - * @param ListFindingsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listFindings(ListFindingsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListFindings', $request, $callOptions); - } - - /** - * Lists mute configs. If no location is specified, default is - * global. - * - * The async variant is {@see SecurityCenterClient::listMuteConfigsAsync()} . - * - * @example samples/V2/SecurityCenterClient/list_mute_configs.php - * - * @param ListMuteConfigsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listMuteConfigs(ListMuteConfigsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListMuteConfigs', $request, $callOptions); - } - - /** - * Lists notification configs. - * - * The async variant is {@see SecurityCenterClient::listNotificationConfigsAsync()} - * . - * - * @example samples/V2/SecurityCenterClient/list_notification_configs.php - * - * @param ListNotificationConfigsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listNotificationConfigs(ListNotificationConfigsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListNotificationConfigs', $request, $callOptions); - } - - /** - * Lists all ResourceValueConfigs. - * - * The async variant is - * {@see SecurityCenterClient::listResourceValueConfigsAsync()} . - * - * @example samples/V2/SecurityCenterClient/list_resource_value_configs.php - * - * @param ListResourceValueConfigsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listResourceValueConfigs(ListResourceValueConfigsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListResourceValueConfigs', $request, $callOptions); - } - - /** - * Lists all sources belonging to an organization. - * - * The async variant is {@see SecurityCenterClient::listSourcesAsync()} . - * - * @example samples/V2/SecurityCenterClient/list_sources.php - * - * @param ListSourcesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listSources(ListSourcesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListSources', $request, $callOptions); - } - - /** - * Lists the valued resources for a set of simulation results and filter. - * - * The async variant is {@see SecurityCenterClient::listValuedResourcesAsync()} . - * - * @example samples/V2/SecurityCenterClient/list_valued_resources.php - * - * @param ListValuedResourcesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listValuedResources(ListValuedResourcesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListValuedResources', $request, $callOptions); - } - - /** - * Updates the state of a finding. If no location is specified, finding is - * assumed to be in global - * - * The async variant is {@see SecurityCenterClient::setFindingStateAsync()} . - * - * @example samples/V2/SecurityCenterClient/set_finding_state.php - * - * @param SetFindingStateRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Finding - * - * @throws ApiException Thrown if the API call fails. - */ - public function setFindingState(SetFindingStateRequest $request, array $callOptions = []): Finding - { - return $this->startApiCall('SetFindingState', $request, $callOptions)->wait(); - } - - /** - * Sets the access control policy on the specified Source. - * - * The async variant is {@see SecurityCenterClient::setIamPolicyAsync()} . - * - * @example samples/V2/SecurityCenterClient/set_iam_policy.php - * - * @param SetIamPolicyRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Policy - * - * @throws ApiException Thrown if the API call fails. - */ - public function setIamPolicy(SetIamPolicyRequest $request, array $callOptions = []): Policy - { - return $this->startApiCall('SetIamPolicy', $request, $callOptions)->wait(); - } - - /** - * Updates the mute state of a finding. If no location is specified, finding - * is assumed to be in global - * - * The async variant is {@see SecurityCenterClient::setMuteAsync()} . - * - * @example samples/V2/SecurityCenterClient/set_mute.php - * - * @param SetMuteRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Finding - * - * @throws ApiException Thrown if the API call fails. - */ - public function setMute(SetMuteRequest $request, array $callOptions = []): Finding - { - return $this->startApiCall('SetMute', $request, $callOptions)->wait(); - } - - /** - * Returns the permissions that a caller has on the specified source. - * - * The async variant is {@see SecurityCenterClient::testIamPermissionsAsync()} . - * - * @example samples/V2/SecurityCenterClient/test_iam_permissions.php - * - * @param TestIamPermissionsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return TestIamPermissionsResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function testIamPermissions(TestIamPermissionsRequest $request, array $callOptions = []): TestIamPermissionsResponse - { - return $this->startApiCall('TestIamPermissions', $request, $callOptions)->wait(); - } - - /** - * Updates a BigQuery export. - * - * The async variant is {@see SecurityCenterClient::updateBigQueryExportAsync()} . - * - * @example samples/V2/SecurityCenterClient/update_big_query_export.php - * - * @param UpdateBigQueryExportRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return BigQueryExport - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateBigQueryExport(UpdateBigQueryExportRequest $request, array $callOptions = []): BigQueryExport - { - return $this->startApiCall('UpdateBigQueryExport', $request, $callOptions)->wait(); - } - - /** - * Updates external system. This is for a given finding. If no location is - * specified, finding is assumed to be in global - * - * The async variant is {@see SecurityCenterClient::updateExternalSystemAsync()} . - * - * @example samples/V2/SecurityCenterClient/update_external_system.php - * - * @param UpdateExternalSystemRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return ExternalSystem - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateExternalSystem(UpdateExternalSystemRequest $request, array $callOptions = []): ExternalSystem - { - return $this->startApiCall('UpdateExternalSystem', $request, $callOptions)->wait(); - } - - /** - * Creates or updates a finding. If no location is specified, finding is - * assumed to be in global. The corresponding source must exist for a finding - * creation to succeed. - * - * The async variant is {@see SecurityCenterClient::updateFindingAsync()} . - * - * @example samples/V2/SecurityCenterClient/update_finding.php - * - * @param UpdateFindingRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Finding - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateFinding(UpdateFindingRequest $request, array $callOptions = []): Finding - { - return $this->startApiCall('UpdateFinding', $request, $callOptions)->wait(); - } - - /** - * Updates a mute config. If no location is specified, default is - * global. - * - * The async variant is {@see SecurityCenterClient::updateMuteConfigAsync()} . - * - * @example samples/V2/SecurityCenterClient/update_mute_config.php - * - * @param UpdateMuteConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return MuteConfig - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateMuteConfig(UpdateMuteConfigRequest $request, array $callOptions = []): MuteConfig - { - return $this->startApiCall('UpdateMuteConfig', $request, $callOptions)->wait(); - } - - /** - * Updates a notification config. The following update - * fields are allowed: description, pubsub_topic, streaming_config.filter - * - * The async variant is - * {@see SecurityCenterClient::updateNotificationConfigAsync()} . - * - * @example samples/V2/SecurityCenterClient/update_notification_config.php - * - * @param UpdateNotificationConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return NotificationConfig - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateNotificationConfig(UpdateNotificationConfigRequest $request, array $callOptions = []): NotificationConfig - { - return $this->startApiCall('UpdateNotificationConfig', $request, $callOptions)->wait(); - } - - /** - * Updates an existing ResourceValueConfigs with new rules. - * - * The async variant is - * {@see SecurityCenterClient::updateResourceValueConfigAsync()} . - * - * @example samples/V2/SecurityCenterClient/update_resource_value_config.php - * - * @param UpdateResourceValueConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return ResourceValueConfig - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateResourceValueConfig(UpdateResourceValueConfigRequest $request, array $callOptions = []): ResourceValueConfig - { - return $this->startApiCall('UpdateResourceValueConfig', $request, $callOptions)->wait(); - } - - /** - * Updates security marks. For Finding Security marks, if no location is - * specified, finding is assumed to be in global. Assets Security Marks can - * only be accessed through global endpoint. - * - * The async variant is {@see SecurityCenterClient::updateSecurityMarksAsync()} . - * - * @example samples/V2/SecurityCenterClient/update_security_marks.php - * - * @param UpdateSecurityMarksRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return SecurityMarks - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateSecurityMarks(UpdateSecurityMarksRequest $request, array $callOptions = []): SecurityMarks - { - return $this->startApiCall('UpdateSecurityMarks', $request, $callOptions)->wait(); - } - - /** - * Updates a source. - * - * The async variant is {@see SecurityCenterClient::updateSourceAsync()} . - * - * @example samples/V2/SecurityCenterClient/update_source.php - * - * @param UpdateSourceRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * Optional. - * - * @type RetrySettings|array $retrySettings - * Retry settings to use for this call. Can be a {@see RetrySettings} object, or an - * associative array of retry settings parameters. See the documentation on - * {@see RetrySettings} for example usage. - * } - * - * @return Source - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateSource(UpdateSourceRequest $request, array $callOptions = []): Source - { - return $this->startApiCall('UpdateSource', $request, $callOptions)->wait(); - } -} diff --git a/owl-bot-staging/SecurityCenter/v2/src/V2/gapic_metadata.json b/owl-bot-staging/SecurityCenter/v2/src/V2/gapic_metadata.json deleted file mode 100644 index 375a86c17fe7..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/src/V2/gapic_metadata.json +++ /dev/null @@ -1,218 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.securitycenter.v2", - "libraryPackage": "Google\\Cloud\\SecurityCenter\\V2", - "services": { - "SecurityCenter": { - "clients": { - "grpc": { - "libraryClient": "SecurityCenterGapicClient", - "rpcs": { - "BatchCreateResourceValueConfigs": { - "methods": [ - "batchCreateResourceValueConfigs" - ] - }, - "BulkMuteFindings": { - "methods": [ - "bulkMuteFindings" - ] - }, - "CreateBigQueryExport": { - "methods": [ - "createBigQueryExport" - ] - }, - "CreateFinding": { - "methods": [ - "createFinding" - ] - }, - "CreateMuteConfig": { - "methods": [ - "createMuteConfig" - ] - }, - "CreateNotificationConfig": { - "methods": [ - "createNotificationConfig" - ] - }, - "CreateSource": { - "methods": [ - "createSource" - ] - }, - "DeleteBigQueryExport": { - "methods": [ - "deleteBigQueryExport" - ] - }, - "DeleteMuteConfig": { - "methods": [ - "deleteMuteConfig" - ] - }, - "DeleteNotificationConfig": { - "methods": [ - "deleteNotificationConfig" - ] - }, - "DeleteResourceValueConfig": { - "methods": [ - "deleteResourceValueConfig" - ] - }, - "GetBigQueryExport": { - "methods": [ - "getBigQueryExport" - ] - }, - "GetIamPolicy": { - "methods": [ - "getIamPolicy" - ] - }, - "GetMuteConfig": { - "methods": [ - "getMuteConfig" - ] - }, - "GetNotificationConfig": { - "methods": [ - "getNotificationConfig" - ] - }, - "GetResourceValueConfig": { - "methods": [ - "getResourceValueConfig" - ] - }, - "GetSimulation": { - "methods": [ - "getSimulation" - ] - }, - "GetSource": { - "methods": [ - "getSource" - ] - }, - "GetValuedResource": { - "methods": [ - "getValuedResource" - ] - }, - "GroupFindings": { - "methods": [ - "groupFindings" - ] - }, - "ListAttackPaths": { - "methods": [ - "listAttackPaths" - ] - }, - "ListBigQueryExports": { - "methods": [ - "listBigQueryExports" - ] - }, - "ListFindings": { - "methods": [ - "listFindings" - ] - }, - "ListMuteConfigs": { - "methods": [ - "listMuteConfigs" - ] - }, - "ListNotificationConfigs": { - "methods": [ - "listNotificationConfigs" - ] - }, - "ListResourceValueConfigs": { - "methods": [ - "listResourceValueConfigs" - ] - }, - "ListSources": { - "methods": [ - "listSources" - ] - }, - "ListValuedResources": { - "methods": [ - "listValuedResources" - ] - }, - "SetFindingState": { - "methods": [ - "setFindingState" - ] - }, - "SetIamPolicy": { - "methods": [ - "setIamPolicy" - ] - }, - "SetMute": { - "methods": [ - "setMute" - ] - }, - "TestIamPermissions": { - "methods": [ - "testIamPermissions" - ] - }, - "UpdateBigQueryExport": { - "methods": [ - "updateBigQueryExport" - ] - }, - "UpdateExternalSystem": { - "methods": [ - "updateExternalSystem" - ] - }, - "UpdateFinding": { - "methods": [ - "updateFinding" - ] - }, - "UpdateMuteConfig": { - "methods": [ - "updateMuteConfig" - ] - }, - "UpdateNotificationConfig": { - "methods": [ - "updateNotificationConfig" - ] - }, - "UpdateResourceValueConfig": { - "methods": [ - "updateResourceValueConfig" - ] - }, - "UpdateSecurityMarks": { - "methods": [ - "updateSecurityMarks" - ] - }, - "UpdateSource": { - "methods": [ - "updateSource" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_client_config.json b/owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_client_config.json deleted file mode 100644 index 93f35a4efd54..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_client_config.json +++ /dev/null @@ -1,226 +0,0 @@ -{ - "interfaces": { - "google.cloud.securitycenter.v2.SecurityCenter": { - "retry_codes": { - "idempotent": [ - "DEADLINE_EXCEEDED", - "UNAVAILABLE" - ], - "non_idempotent": [] - }, - "retry_params": { - "default": { - "initial_retry_delay_millis": 100, - "retry_delay_multiplier": 1.3, - "max_retry_delay_millis": 60000, - "initial_rpc_timeout_millis": 20000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 20000, - "total_timeout_millis": 600000 - } - }, - "methods": { - "BatchCreateResourceValueConfigs": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "BulkMuteFindings": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "CreateBigQueryExport": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "CreateFinding": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "CreateMuteConfig": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "CreateNotificationConfig": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "CreateSource": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "DeleteBigQueryExport": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "DeleteMuteConfig": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "DeleteNotificationConfig": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "DeleteResourceValueConfig": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "GetBigQueryExport": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "GetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "GetMuteConfig": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "GetNotificationConfig": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "GetResourceValueConfig": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "GetSimulation": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "GetSource": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "GetValuedResource": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "GroupFindings": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "ListAttackPaths": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "ListBigQueryExports": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "ListFindings": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "ListMuteConfigs": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "ListNotificationConfigs": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "ListResourceValueConfigs": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "ListSources": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "ListValuedResources": { - "timeout_millis": 60000, - "retry_codes_name": "idempotent", - "retry_params_name": "default" - }, - "SetFindingState": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "SetIamPolicy": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "SetMute": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "TestIamPermissions": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "UpdateBigQueryExport": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "UpdateExternalSystem": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "UpdateFinding": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "UpdateMuteConfig": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "UpdateNotificationConfig": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "UpdateResourceValueConfig": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "UpdateSecurityMarks": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - }, - "UpdateSource": { - "timeout_millis": 60000, - "retry_codes_name": "non_idempotent", - "retry_params_name": "default" - } - } - } - } -} diff --git a/owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_descriptor_config.php b/owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_descriptor_config.php deleted file mode 100644 index c8e952422ea3..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_descriptor_config.php +++ /dev/null @@ -1,672 +0,0 @@ - [ - 'google.cloud.securitycenter.v2.SecurityCenter' => [ - 'BulkMuteFindings' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\SecurityCenter\V2\BulkMuteFindingsResponse', - 'metadataReturnType' => '\Google\Protobuf\GPBEmpty', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'BatchCreateResourceValueConfigs' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\BatchCreateResourceValueConfigsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateBigQueryExport' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\BigQueryExport', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateFinding' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\Finding', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateMuteConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\MuteConfig', - 'headerParams' => [ - [ - 'keyName' => 'location', - 'fieldAccessors' => [ - 'getParent', - ], - 'matchers' => [], - ], - ], - ], - 'CreateNotificationConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\NotificationConfig', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateSource' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\Source', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteBigQueryExport' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteMuteConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'location', - 'fieldAccessors' => [ - 'getName', - ], - 'matchers' => [], - ], - ], - ], - 'DeleteNotificationConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteResourceValueConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetBigQueryExport' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\BigQueryExport', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - ], - 'GetMuteConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\MuteConfig', - 'headerParams' => [ - [ - 'keyName' => 'location', - 'fieldAccessors' => [ - 'getName', - ], - 'matchers' => [], - ], - ], - ], - 'GetNotificationConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\NotificationConfig', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetResourceValueConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\ResourceValueConfig', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetSimulation' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\Simulation', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetSource' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\Source', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetValuedResource' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\ValuedResource', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GroupFindings' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getGroupByResults', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\GroupFindingsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListAttackPaths' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getAttackPaths', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\ListAttackPathsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListBigQueryExports' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getBigQueryExports', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\ListBigQueryExportsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListFindings' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getListFindingsResults', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\ListFindingsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListMuteConfigs' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getMuteConfigs', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\ListMuteConfigsResponse', - 'headerParams' => [ - [ - 'keyName' => 'location', - 'fieldAccessors' => [ - 'getParent', - ], - 'matchers' => [], - ], - ], - ], - 'ListNotificationConfigs' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getNotificationConfigs', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\ListNotificationConfigsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListResourceValueConfigs' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getResourceValueConfigs', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\ListResourceValueConfigsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListSources' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getSources', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\ListSourcesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListValuedResources' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getValuedResources', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\ListValuedResourcesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'SetFindingState' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\Finding', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\Policy', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - ], - 'SetMute' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\Finding', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Iam\V1\TestIamPermissionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'resource', - 'fieldAccessors' => [ - 'getResource', - ], - ], - ], - ], - 'UpdateBigQueryExport' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\BigQueryExport', - 'headerParams' => [ - [ - 'keyName' => 'big_query_export.name', - 'fieldAccessors' => [ - 'getBigQueryExport', - 'getName', - ], - ], - ], - ], - 'UpdateExternalSystem' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\ExternalSystem', - 'headerParams' => [ - [ - 'keyName' => 'external_system.name', - 'fieldAccessors' => [ - 'getExternalSystem', - 'getName', - ], - ], - ], - ], - 'UpdateFinding' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\Finding', - 'headerParams' => [ - [ - 'keyName' => 'finding.name', - 'fieldAccessors' => [ - 'getFinding', - 'getName', - ], - ], - ], - ], - 'UpdateMuteConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\MuteConfig', - 'headerParams' => [ - [ - 'keyName' => 'location', - 'fieldAccessors' => [ - 'getMuteConfig', - 'getName', - ], - 'matchers' => [], - ], - ], - ], - 'UpdateNotificationConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\NotificationConfig', - 'headerParams' => [ - [ - 'keyName' => 'notification_config.name', - 'fieldAccessors' => [ - 'getNotificationConfig', - 'getName', - ], - ], - ], - ], - 'UpdateResourceValueConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\ResourceValueConfig', - 'headerParams' => [ - [ - 'keyName' => 'resource_value_config.name', - 'fieldAccessors' => [ - 'getResourceValueConfig', - 'getName', - ], - ], - ], - ], - 'UpdateSecurityMarks' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\SecurityMarks', - 'headerParams' => [ - [ - 'keyName' => 'security_marks.name', - 'fieldAccessors' => [ - 'getSecurityMarks', - 'getName', - ], - ], - ], - ], - 'UpdateSource' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\SecurityCenter\V2\Source', - 'headerParams' => [ - [ - 'keyName' => 'source.name', - 'fieldAccessors' => [ - 'getSource', - 'getName', - ], - ], - ], - ], - 'templateMap' => [ - 'bigQueryExport' => 'organizations/{organization}/locations/{location}/bigQueryExports/{export}', - 'dlpJob' => 'projects/{project}/dlpJobs/{dlp_job}', - 'externalSystem' => 'organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}', - 'finding' => 'organizations/{organization}/sources/{source}/findings/{finding}', - 'folder' => 'folders/{folder}', - 'folderAssetSecurityMarks' => 'folders/{folder}/assets/{asset}/securityMarks', - 'folderConstraintName' => 'folders/{folder}/policies/{constraint_name}', - 'folderLocation' => 'folders/{folder}/locations/{location}', - 'folderLocationExport' => 'folders/{folder}/locations/{location}/bigQueryExports/{export}', - 'folderLocationMuteConfig' => 'folders/{folder}/locations/{location}/muteConfigs/{mute_config}', - 'folderLocationNotificationConfig' => 'folders/{folder}/locations/{location}/notificationConfigs/{notification_config}', - 'folderMuteConfig' => 'folders/{folder}/muteConfigs/{mute_config}', - 'folderSource' => 'folders/{folder}/sources/{source}', - 'folderSourceFinding' => 'folders/{folder}/sources/{source}/findings/{finding}', - 'folderSourceFindingExternalsystem' => 'folders/{folder}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}', - 'folderSourceFindingSecurityMarks' => 'folders/{folder}/sources/{source}/findings/{finding}/securityMarks', - 'folderSourceLocationFinding' => 'folders/{folder}/sources/{source}/locations/{location}/findings/{finding}', - 'folderSourceLocationFindingExternalsystem' => 'folders/{folder}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem}', - 'folderSourceLocationFindingSecurityMarks' => 'folders/{folder}/sources/{source}/locations/{location}/findings/{finding}/securityMarks', - 'location' => 'projects/{project}/locations/{location}', - 'muteConfig' => 'organizations/{organization}/muteConfigs/{mute_config}', - 'notificationConfig' => 'organizations/{organization}/locations/{location}/notificationConfigs/{notification_config}', - 'organization' => 'organizations/{organization}', - 'organizationAssetSecurityMarks' => 'organizations/{organization}/assets/{asset}/securityMarks', - 'organizationConstraintName' => 'organizations/{organization}/policies/{constraint_name}', - 'organizationLocation' => 'organizations/{organization}/locations/{location}', - 'organizationLocationExport' => 'organizations/{organization}/locations/{location}/bigQueryExports/{export}', - 'organizationLocationMuteConfig' => 'organizations/{organization}/locations/{location}/muteConfigs/{mute_config}', - 'organizationLocationNotificationConfig' => 'organizations/{organization}/locations/{location}/notificationConfigs/{notification_config}', - 'organizationLocationResourceValueConfig' => 'organizations/{organization}/locations/{location}/resourceValueConfigs/{resource_value_config}', - 'organizationLocationSimluation' => 'organizations/{organization}/locations/{location}/simulations/{simluation}', - 'organizationLocationSimluationValuedResource' => 'organizations/{organization}/locations/{location}/simulations/{simluation}/valuedResources/{valued_resource}', - 'organizationMuteConfig' => 'organizations/{organization}/muteConfigs/{mute_config}', - 'organizationResourceValueConfig' => 'organizations/{organization}/resourceValueConfigs/{resource_value_config}', - 'organizationSimulation' => 'organizations/{organization}/simulations/{simulation}', - 'organizationSimulationValuedResource' => 'organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}', - 'organizationSource' => 'organizations/{organization}/sources/{source}', - 'organizationSourceFinding' => 'organizations/{organization}/sources/{source}/findings/{finding}', - 'organizationSourceFindingExternalsystem' => 'organizations/{organization}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}', - 'organizationSourceFindingSecurityMarks' => 'organizations/{organization}/sources/{source}/findings/{finding}/securityMarks', - 'organizationSourceLocationFinding' => 'organizations/{organization}/sources/{source}/locations/{location}/findings/{finding}', - 'organizationSourceLocationFindingExternalsystem' => 'organizations/{organization}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem}', - 'organizationSourceLocationFindingSecurityMarks' => 'organizations/{organization}/sources/{source}/locations/{location}/findings/{finding}/securityMarks', - 'organizationValuedResource' => 'organizations/{organization}/locations/{location}/simulations/{simulation}/valuedResources/{valued_resource}', - 'policy' => 'organizations/{organization}/policies/{constraint_name}', - 'project' => 'projects/{project}', - 'projectAssetSecurityMarks' => 'projects/{project}/assets/{asset}/securityMarks', - 'projectConstraintName' => 'projects/{project}/policies/{constraint_name}', - 'projectDlpJob' => 'projects/{project}/dlpJobs/{dlp_job}', - 'projectLocationDlpJob' => 'projects/{project}/locations/{location}/dlpJobs/{dlp_job}', - 'projectLocationExport' => 'projects/{project}/locations/{location}/bigQueryExports/{export}', - 'projectLocationMuteConfig' => 'projects/{project}/locations/{location}/muteConfigs/{mute_config}', - 'projectLocationNotificationConfig' => 'projects/{project}/locations/{location}/notificationConfigs/{notification_config}', - 'projectLocationTableProfile' => 'projects/{project}/locations/{location}/tableProfiles/{table_profile}', - 'projectMuteConfig' => 'projects/{project}/muteConfigs/{mute_config}', - 'projectSource' => 'projects/{project}/sources/{source}', - 'projectSourceFinding' => 'projects/{project}/sources/{source}/findings/{finding}', - 'projectSourceFindingExternalsystem' => 'projects/{project}/sources/{source}/findings/{finding}/externalSystems/{externalsystem}', - 'projectSourceFindingSecurityMarks' => 'projects/{project}/sources/{source}/findings/{finding}/securityMarks', - 'projectSourceLocationFinding' => 'projects/{project}/sources/{source}/locations/{location}/findings/{finding}', - 'projectSourceLocationFindingExternalsystem' => 'projects/{project}/sources/{source}/locations/{location}/findings/{finding}/externalSystems/{externalsystem}', - 'projectSourceLocationFindingSecurityMarks' => 'projects/{project}/sources/{source}/locations/{location}/findings/{finding}/securityMarks', - 'projectTableProfile' => 'projects/{project}/tableProfiles/{table_profile}', - 'resourceValueConfig' => 'organizations/{organization}/resourceValueConfigs/{resource_value_config}', - 'securityMarks' => 'organizations/{organization}/assets/{asset}/securityMarks', - 'simulation' => 'organizations/{organization}/simulations/{simulation}', - 'source' => 'organizations/{organization}/sources/{source}', - 'tableDataProfile' => 'projects/{project}/tableProfiles/{table_profile}', - 'topic' => 'projects/{project}/topics/{topic}', - 'valuedResource' => 'organizations/{organization}/simulations/{simulation}/valuedResources/{valued_resource}', - ], - ], - ], -]; diff --git a/owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_rest_client_config.php b/owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_rest_client_config.php deleted file mode 100644 index ae5110e7ac2d..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/src/V2/resources/security_center_rest_client_config.php +++ /dev/null @@ -1,1125 +0,0 @@ - [ - 'google.cloud.securitycenter.v2.SecurityCenter' => [ - 'BatchCreateResourceValueConfigs' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*}/resourceValueConfigs:batchCreate', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/resourceValueConfigs:batchCreate', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'BulkMuteFindings' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*}/findings:bulkMute', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/findings:bulkMute', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=folders/*}/findings:bulkMute', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=folders/*/locations/*}/findings:bulkMute', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*}/findings:bulkMute', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/findings:bulkMute', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreateBigQueryExport' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/bigQueryExports', - 'body' => 'big_query_export', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=folders/*/locations/*}/bigQueryExports', - 'body' => 'big_query_export', - 'queryParams' => [ - 'big_query_export_id', - ], - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/bigQueryExports', - 'body' => 'big_query_export', - 'queryParams' => [ - 'big_query_export_id', - ], - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'big_query_export_id', - ], - ], - 'CreateFinding' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*/sources/*/locations/*}/findings', - 'body' => 'finding', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*/sources/*}/findings', - 'body' => 'finding', - 'queryParams' => [ - 'finding_id', - ], - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'finding_id', - ], - ], - 'CreateMuteConfig' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/muteConfigs', - 'body' => 'mute_config', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=folders/*/locations/*}/muteConfigs', - 'body' => 'mute_config', - 'queryParams' => [ - 'mute_config_id', - ], - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/muteConfigs', - 'body' => 'mute_config', - 'queryParams' => [ - 'mute_config_id', - ], - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*}/muteConfigs', - 'body' => 'mute_config', - 'queryParams' => [ - 'mute_config_id', - ], - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=folders/*}/muteConfigs', - 'body' => 'mute_config', - 'queryParams' => [ - 'mute_config_id', - ], - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*}/muteConfigs', - 'body' => 'mute_config', - 'queryParams' => [ - 'mute_config_id', - ], - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'mute_config_id', - ], - ], - 'CreateNotificationConfig' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/notificationConfigs', - 'body' => 'notification_config', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=folders/*/locations/*}/notificationConfigs', - 'body' => 'notification_config', - 'queryParams' => [ - 'config_id', - ], - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/notificationConfigs', - 'body' => 'notification_config', - 'queryParams' => [ - 'config_id', - ], - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'config_id', - ], - ], - 'CreateSource' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*}/sources', - 'body' => 'source', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteBigQueryExport' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/bigQueryExports/*}', - 'additionalBindings' => [ - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=folders/*/locations/*/bigQueryExports/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/bigQueryExports/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteMuteConfig' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=organizations/*/muteConfigs/*}', - 'additionalBindings' => [ - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/muteConfigs/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=folders/*/muteConfigs/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=folders/*/locations/*/muteConfigs/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/muteConfigs/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/muteConfigs/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteNotificationConfig' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/notificationConfigs/*}', - 'additionalBindings' => [ - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=folders/*/locations/*/notificationConfigs/*}', - ], - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/notificationConfigs/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteResourceValueConfig' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=organizations/*/resourceValueConfigs/*}', - 'additionalBindings' => [ - [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/resourceValueConfigs/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetBigQueryExport' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/bigQueryExports/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=folders/*/locations/*/bigQueryExports/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/bigQueryExports/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{resource=organizations/*/sources/*}:getIamPolicy', - 'body' => '*', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'GetMuteConfig' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/muteConfigs/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/muteConfigs/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=folders/*/muteConfigs/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=folders/*/locations/*/muteConfigs/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/muteConfigs/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/muteConfigs/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetNotificationConfig' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/notificationConfigs/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=folders/*/locations/*/notificationConfigs/*}', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/notificationConfigs/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetResourceValueConfig' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/resourceValueConfigs/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/resourceValueConfigs/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetSimulation' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/simulations/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/simulations/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetSource' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/sources/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetValuedResource' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/simulations/*/valuedResources/*}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/locations/*/simulations/*/valuedResources/*}', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GroupFindings' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*/sources/*}/findings:group', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=organizations/*/sources/*/locations/*}/findings:group', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=folders/*/sources/*}/findings:group', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=folders/*/sources/*/locations/*}/findings:group', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/sources/*}/findings:group', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/sources/*/locations/*}/findings:group', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListAttackPaths' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/simulations/*}/attackPaths', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/simulations/*/valuedResources/*}/attackPaths', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*/simulations/*/valuedResources/*}/attackPaths', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/simulations/*/attackExposureResults/*}/attackPaths', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*/simulations/*/attackExposureResults/*}/attackPaths', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListBigQueryExports' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/bigQueryExports', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=folders/*/locations/*}/bigQueryExports', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/bigQueryExports', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListFindings' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/sources/*}/findings', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/sources/*/locations/*}/findings', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=folders/*/sources/*}/findings', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=folders/*/sources/*/locations/*}/findings', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/sources/*}/findings', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/sources/*/locations/*}/findings', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListMuteConfigs' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*}/muteConfigs', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/muteConfigs', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=folders/*}/muteConfigs', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=folders/*/locations/*}/muteConfigs', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*}/muteConfigs', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/muteConfigs', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListNotificationConfigs' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/notificationConfigs', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=folders/*/locations/*}/notificationConfigs', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/notificationConfigs', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListResourceValueConfigs' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*}/resourceValueConfigs', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/locations/*}/resourceValueConfigs', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListSources' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*}/sources', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=folders/*}/sources', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*}/sources', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListValuedResources' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/simulations/*}/valuedResources', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=organizations/*/simulations/*/attackExposureResults/*}/valuedResources', - ], - ], - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'SetFindingState' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=organizations/*/sources/*/findings/*}:setState', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=organizations/*/sources/*/locations/*/findings/*}:setState', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=folders/*/sources/*/findings/*}:setState', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=folders/*/sources/*/locations/*/findings/*}:setState', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/sources/*/findings/*}:setState', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/sources/*/locations/*/findings/*}:setState', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{resource=organizations/*/sources/*}:setIamPolicy', - 'body' => '*', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'SetMute' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=organizations/*/sources/*/findings/*}:setMute', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=organizations/*/sources/*/locations/*/findings/*}:setMute', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=folders/*/sources/*/findings/*}:setMute', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=folders/*/sources/*/locations/*/findings/*}:setMute', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/sources/*/findings/*}:setMute', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/sources/*/locations/*/findings/*}:setMute', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{resource=organizations/*/sources/*}:testIamPermissions', - 'body' => '*', - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'UpdateBigQueryExport' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{big_query_export.name=organizations/*/locations/*/bigQueryExports/*}', - 'body' => 'big_query_export', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{big_query_export.name=folders/*/locations/*/bigQueryExports/*}', - 'body' => 'big_query_export', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{big_query_export.name=projects/*/locations/*/bigQueryExports/*}', - 'body' => 'big_query_export', - ], - ], - 'placeholders' => [ - 'big_query_export.name' => [ - 'getters' => [ - 'getBigQueryExport', - 'getName', - ], - ], - ], - ], - 'UpdateExternalSystem' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{external_system.name=organizations/*/sources/*/findings/*/externalSystems/*}', - 'body' => 'external_system', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{external_system.name=organizations/*/sources/*/locations/*/findings/*/externalSystems/*}', - 'body' => 'external_system', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{external_system.name=folders/*/sources/*/findings/*/externalSystems/*}', - 'body' => 'external_system', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{external_system.name=folders/*/sources/*/locations/*/findings/*/externalSystems/*}', - 'body' => 'external_system', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{external_system.name=projects/*/sources/*/findings/*/externalSystems/*}', - 'body' => 'external_system', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{external_system.name=projects/*/sources/*/locations/*/findings/*/externalSystems/*}', - 'body' => 'external_system', - ], - ], - 'placeholders' => [ - 'external_system.name' => [ - 'getters' => [ - 'getExternalSystem', - 'getName', - ], - ], - ], - ], - 'UpdateFinding' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{finding.name=organizations/*/sources/*/findings/*}', - 'body' => 'finding', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{finding.name=organizations/*/sources/*/locations/*/findings/*}', - 'body' => 'finding', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{finding.name=folders/*/sources/*/findings/*}', - 'body' => 'finding', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{finding.name=folders/*/sources/*/locations/*/findings/*}', - 'body' => 'finding', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{finding.name=projects/*/sources/*/findings/*}', - 'body' => 'finding', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{finding.name=projects/*/sources/*/locations/*/findings/*}', - 'body' => 'finding', - ], - ], - 'placeholders' => [ - 'finding.name' => [ - 'getters' => [ - 'getFinding', - 'getName', - ], - ], - ], - ], - 'UpdateMuteConfig' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{mute_config.name=organizations/*/muteConfigs/*}', - 'body' => 'mute_config', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{mute_config.name=organizations/*/locations/*/muteConfigs/*}', - 'body' => 'mute_config', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{mute_config.name=folders/*/muteConfigs/*}', - 'body' => 'mute_config', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{mute_config.name=folders/*/locations/*/muteConfigs/*}', - 'body' => 'mute_config', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{mute_config.name=projects/*/muteConfigs/*}', - 'body' => 'mute_config', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{mute_config.name=projects/*/locations/*/muteConfigs/*}', - 'body' => 'mute_config', - ], - ], - 'placeholders' => [ - 'mute_config.name' => [ - 'getters' => [ - 'getMuteConfig', - 'getName', - ], - ], - ], - ], - 'UpdateNotificationConfig' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{notification_config.name=organizations/*/locations/*/notificationConfigs/*}', - 'body' => 'notification_config', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{notification_config.name=folders/*/locations/*/notificationConfigs/*}', - 'body' => 'notification_config', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{notification_config.name=projects/*/locations/*/notificationConfigs/*}', - 'body' => 'notification_config', - ], - ], - 'placeholders' => [ - 'notification_config.name' => [ - 'getters' => [ - 'getNotificationConfig', - 'getName', - ], - ], - ], - ], - 'UpdateResourceValueConfig' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{resource_value_config.name=organizations/*/resourceValueConfigs/*}', - 'body' => 'resource_value_config', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{resource_value_config.name=organizations/*/locations/*/resourceValueConfigs/*}', - 'body' => 'resource_value_config', - ], - ], - 'placeholders' => [ - 'resource_value_config.name' => [ - 'getters' => [ - 'getResourceValueConfig', - 'getName', - ], - ], - ], - ], - 'UpdateSecurityMarks' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{security_marks.name=organizations/*/sources/*/findings/*/securityMarks}', - 'body' => 'security_marks', - 'additionalBindings' => [ - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{security_marks.name=organizations/*/assets/*/securityMarks}', - 'body' => 'security_marks', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{security_marks.name=organizations/*/sources/*/locations/*/findings/*/securityMarks}', - 'body' => 'security_marks', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{security_marks.name=folders/*/sources/*/findings/*/securityMarks}', - 'body' => 'security_marks', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{security_marks.name=folders/*/assets/*/securityMarks}', - 'body' => 'security_marks', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{security_marks.name=folders/*/sources/*/locations/*/findings/*/securityMarks}', - 'body' => 'security_marks', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{security_marks.name=projects/*/sources/*/findings/*/securityMarks}', - 'body' => 'security_marks', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{security_marks.name=projects/*/assets/*/securityMarks}', - 'body' => 'security_marks', - ], - [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{security_marks.name=projects/*/sources/*/locations/*/findings/*/securityMarks}', - 'body' => 'security_marks', - ], - ], - 'placeholders' => [ - 'security_marks.name' => [ - 'getters' => [ - 'getSecurityMarks', - 'getName', - ], - ], - ], - ], - 'UpdateSource' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{source.name=organizations/*/sources/*}', - 'body' => 'source', - 'placeholders' => [ - 'source.name' => [ - 'getters' => [ - 'getSource', - 'getName', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - 'CancelOperation' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=organizations/*/operations/*}:cancel', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteOperation' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=organizations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOperation' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListOperations' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=organizations/*/operations}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/SecurityCenter/v2/tests/Unit/V2/Client/SecurityCenterClientTest.php b/owl-bot-staging/SecurityCenter/v2/tests/Unit/V2/Client/SecurityCenterClientTest.php deleted file mode 100644 index b3717581d42b..000000000000 --- a/owl-bot-staging/SecurityCenter/v2/tests/Unit/V2/Client/SecurityCenterClientTest.php +++ /dev/null @@ -1,3152 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return SecurityCenterClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new SecurityCenterClient($options); - } - - /** @test */ - public function batchCreateResourceValueConfigsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new BatchCreateResourceValueConfigsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $requests = []; - $request = (new BatchCreateResourceValueConfigsRequest()) - ->setParent($formattedParent) - ->setRequests($requests); - $response = $gapicClient->batchCreateResourceValueConfigs($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/BatchCreateResourceValueConfigs', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getRequests(); - $this->assertProtobufEquals($requests, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function batchCreateResourceValueConfigsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $requests = []; - $request = (new BatchCreateResourceValueConfigsRequest()) - ->setParent($formattedParent) - ->setRequests($requests); - try { - $gapicClient->batchCreateResourceValueConfigs($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function bulkMuteFindingsTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/bulkMuteFindingsTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new BulkMuteFindingsResponse(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/bulkMuteFindingsTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $parent = 'parent-995424086'; - $request = (new BulkMuteFindingsRequest()) - ->setParent($parent); - $response = $gapicClient->bulkMuteFindings($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $apiRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($apiRequests)); - $operationsRequestsEmpty = $operationsTransport->popReceivedCalls(); - $this->assertSame(0, count($operationsRequestsEmpty)); - $actualApiFuncCall = $apiRequests[0]->getFuncCall(); - $actualApiRequestObject = $apiRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/BulkMuteFindings', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($parent, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/bulkMuteFindingsTest'); - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - $this->assertTrue($response->isDone()); - $this->assertEquals($expectedResponse, $response->getResult()); - $apiRequestsEmpty = $transport->popReceivedCalls(); - $this->assertSame(0, count($apiRequestsEmpty)); - $operationsRequests = $operationsTransport->popReceivedCalls(); - $this->assertSame(1, count($operationsRequests)); - $actualOperationsFuncCall = $operationsRequests[0]->getFuncCall(); - $actualOperationsRequestObject = $operationsRequests[0]->getRequestObject(); - $this->assertSame('/google.longrunning.Operations/GetOperation', $actualOperationsFuncCall); - $this->assertEquals($expectedOperationsRequestObject, $actualOperationsRequestObject); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function bulkMuteFindingsExceptionTest() - { - $operationsTransport = $this->createTransport(); - $operationsClient = new OperationsClient([ - 'apiEndpoint' => '', - 'transport' => $operationsTransport, - 'credentials' => $this->createCredentials(), - ]); - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - 'operationsClient' => $operationsClient, - ]); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - // Mock response - $incompleteOperation = new Operation(); - $incompleteOperation->setName('operations/bulkMuteFindingsTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $operationsTransport->addResponse(null, $status); - // Mock request - $parent = 'parent-995424086'; - $request = (new BulkMuteFindingsRequest()) - ->setParent($parent); - $response = $gapicClient->bulkMuteFindings($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/bulkMuteFindingsTest'); - try { - $response->pollUntilComplete([ - 'initialPollDelayMillis' => 1, - ]); - // If the pollUntilComplete() method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stubs are exhausted - $transport->popReceivedCalls(); - $operationsTransport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - $this->assertTrue($operationsTransport->isExhausted()); - } - - /** @test */ - public function createBigQueryExportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $description = 'description-1724546052'; - $filter = 'filter-1274492040'; - $dataset = 'dataset1443214456'; - $mostRecentEditor = 'mostRecentEditor-657770475'; - $principal = 'principal-1812041682'; - $expectedResponse = new BigQueryExport(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setFilter($filter); - $expectedResponse->setDataset($dataset); - $expectedResponse->setMostRecentEditor($mostRecentEditor); - $expectedResponse->setPrincipal($principal); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $bigQueryExport = new BigQueryExport(); - $bigQueryExportId = 'bigQueryExportId269737360'; - $request = (new CreateBigQueryExportRequest()) - ->setParent($formattedParent) - ->setBigQueryExport($bigQueryExport) - ->setBigQueryExportId($bigQueryExportId); - $response = $gapicClient->createBigQueryExport($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/CreateBigQueryExport', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getBigQueryExport(); - $this->assertProtobufEquals($bigQueryExport, $actualValue); - $actualValue = $actualRequestObject->getBigQueryExportId(); - $this->assertProtobufEquals($bigQueryExportId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createBigQueryExportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $bigQueryExport = new BigQueryExport(); - $bigQueryExportId = 'bigQueryExportId269737360'; - $request = (new CreateBigQueryExportRequest()) - ->setParent($formattedParent) - ->setBigQueryExport($bigQueryExport) - ->setBigQueryExportId($bigQueryExportId); - try { - $gapicClient->createBigQueryExport($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createFindingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $canonicalName = 'canonicalName1385400054'; - $parent2 = 'parent21175163357'; - $resourceName = 'resourceName979421212'; - $category = 'category50511102'; - $externalUri = 'externalUri-1385596168'; - $muteInitiator = 'muteInitiator7603081'; - $parentDisplayName = 'parentDisplayName934119773'; - $description = 'description-1724546052'; - $nextSteps = 'nextSteps-921338149'; - $moduleName = 'moduleName-1195003778'; - $expectedResponse = new Finding(); - $expectedResponse->setName($name); - $expectedResponse->setCanonicalName($canonicalName); - $expectedResponse->setParent($parent2); - $expectedResponse->setResourceName($resourceName); - $expectedResponse->setCategory($category); - $expectedResponse->setExternalUri($externalUri); - $expectedResponse->setMuteInitiator($muteInitiator); - $expectedResponse->setParentDisplayName($parentDisplayName); - $expectedResponse->setDescription($description); - $expectedResponse->setNextSteps($nextSteps); - $expectedResponse->setModuleName($moduleName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $findingId = 'findingId728776081'; - $finding = new Finding(); - $request = (new CreateFindingRequest()) - ->setParent($formattedParent) - ->setFindingId($findingId) - ->setFinding($finding); - $response = $gapicClient->createFinding($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/CreateFinding', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getFindingId(); - $this->assertProtobufEquals($findingId, $actualValue); - $actualValue = $actualRequestObject->getFinding(); - $this->assertProtobufEquals($finding, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createFindingExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $findingId = 'findingId728776081'; - $finding = new Finding(); - $request = (new CreateFindingRequest()) - ->setParent($formattedParent) - ->setFindingId($findingId) - ->setFinding($finding); - try { - $gapicClient->createFinding($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createMuteConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $description = 'description-1724546052'; - $filter = 'filter-1274492040'; - $mostRecentEditor = 'mostRecentEditor-657770475'; - $expectedResponse = new MuteConfig(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setFilter($filter); - $expectedResponse->setMostRecentEditor($mostRecentEditor); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $muteConfig = new MuteConfig(); - $muteConfigFilter = 'muteConfigFilter-1921414637'; - $muteConfig->setFilter($muteConfigFilter); - $muteConfigType = MuteConfigType::MUTE_CONFIG_TYPE_UNSPECIFIED; - $muteConfig->setType($muteConfigType); - $muteConfigId = 'muteConfigId-547860334'; - $request = (new CreateMuteConfigRequest()) - ->setParent($formattedParent) - ->setMuteConfig($muteConfig) - ->setMuteConfigId($muteConfigId); - $response = $gapicClient->createMuteConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/CreateMuteConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getMuteConfig(); - $this->assertProtobufEquals($muteConfig, $actualValue); - $actualValue = $actualRequestObject->getMuteConfigId(); - $this->assertProtobufEquals($muteConfigId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createMuteConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $muteConfig = new MuteConfig(); - $muteConfigFilter = 'muteConfigFilter-1921414637'; - $muteConfig->setFilter($muteConfigFilter); - $muteConfigType = MuteConfigType::MUTE_CONFIG_TYPE_UNSPECIFIED; - $muteConfig->setType($muteConfigType); - $muteConfigId = 'muteConfigId-547860334'; - $request = (new CreateMuteConfigRequest()) - ->setParent($formattedParent) - ->setMuteConfig($muteConfig) - ->setMuteConfigId($muteConfigId); - try { - $gapicClient->createMuteConfig($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createNotificationConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $description = 'description-1724546052'; - $pubsubTopic = 'pubsubTopic-338126829'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new NotificationConfig(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setPubsubTopic($pubsubTopic); - $expectedResponse->setServiceAccount($serviceAccount); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $configId = 'configId-804450504'; - $notificationConfig = new NotificationConfig(); - $request = (new CreateNotificationConfigRequest()) - ->setParent($formattedParent) - ->setConfigId($configId) - ->setNotificationConfig($notificationConfig); - $response = $gapicClient->createNotificationConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/CreateNotificationConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getConfigId(); - $this->assertProtobufEquals($configId, $actualValue); - $actualValue = $actualRequestObject->getNotificationConfig(); - $this->assertProtobufEquals($notificationConfig, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createNotificationConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $configId = 'configId-804450504'; - $notificationConfig = new NotificationConfig(); - $request = (new CreateNotificationConfigRequest()) - ->setParent($formattedParent) - ->setConfigId($configId) - ->setNotificationConfig($notificationConfig); - try { - $gapicClient->createNotificationConfig($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createSourceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $canonicalName = 'canonicalName1385400054'; - $expectedResponse = new Source(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setCanonicalName($canonicalName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); - $source = new Source(); - $request = (new CreateSourceRequest()) - ->setParent($formattedParent) - ->setSource($source); - $response = $gapicClient->createSource($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/CreateSource', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getSource(); - $this->assertProtobufEquals($source, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createSourceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->organizationName('[ORGANIZATION]'); - $source = new Source(); - $request = (new CreateSourceRequest()) - ->setParent($formattedParent) - ->setSource($source); - try { - $gapicClient->createSource($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteBigQueryExportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[LOCATION]', '[EXPORT]'); - $request = (new DeleteBigQueryExportRequest()) - ->setName($formattedName); - $gapicClient->deleteBigQueryExport($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/DeleteBigQueryExport', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteBigQueryExportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[LOCATION]', '[EXPORT]'); - $request = (new DeleteBigQueryExportRequest()) - ->setName($formattedName); - try { - $gapicClient->deleteBigQueryExport($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteMuteConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); - $request = (new DeleteMuteConfigRequest()) - ->setName($formattedName); - $gapicClient->deleteMuteConfig($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/DeleteMuteConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteMuteConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); - $request = (new DeleteMuteConfigRequest()) - ->setName($formattedName); - try { - $gapicClient->deleteMuteConfig($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteNotificationConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[LOCATION]', '[NOTIFICATION_CONFIG]'); - $request = (new DeleteNotificationConfigRequest()) - ->setName($formattedName); - $gapicClient->deleteNotificationConfig($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/DeleteNotificationConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteNotificationConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[LOCATION]', '[NOTIFICATION_CONFIG]'); - $request = (new DeleteNotificationConfigRequest()) - ->setName($formattedName); - try { - $gapicClient->deleteNotificationConfig($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteResourceValueConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->resourceValueConfigName('[ORGANIZATION]', '[RESOURCE_VALUE_CONFIG]'); - $request = (new DeleteResourceValueConfigRequest()) - ->setName($formattedName); - $gapicClient->deleteResourceValueConfig($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/DeleteResourceValueConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteResourceValueConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->resourceValueConfigName('[ORGANIZATION]', '[RESOURCE_VALUE_CONFIG]'); - $request = (new DeleteResourceValueConfigRequest()) - ->setName($formattedName); - try { - $gapicClient->deleteResourceValueConfig($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getBigQueryExportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $filter = 'filter-1274492040'; - $dataset = 'dataset1443214456'; - $mostRecentEditor = 'mostRecentEditor-657770475'; - $principal = 'principal-1812041682'; - $expectedResponse = new BigQueryExport(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setFilter($filter); - $expectedResponse->setDataset($dataset); - $expectedResponse->setMostRecentEditor($mostRecentEditor); - $expectedResponse->setPrincipal($principal); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[LOCATION]', '[EXPORT]'); - $request = (new GetBigQueryExportRequest()) - ->setName($formattedName); - $response = $gapicClient->getBigQueryExport($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/GetBigQueryExport', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getBigQueryExportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->bigQueryExportName('[ORGANIZATION]', '[LOCATION]', '[EXPORT]'); - $request = (new GetBigQueryExportRequest()) - ->setName($formattedName); - try { - $gapicClient->getBigQueryExport($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $request = (new GetIamPolicyRequest()) - ->setResource($resource); - $response = $gapicClient->getIamPolicy($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/GetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $request = (new GetIamPolicyRequest()) - ->setResource($resource); - try { - $gapicClient->getIamPolicy($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getMuteConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $filter = 'filter-1274492040'; - $mostRecentEditor = 'mostRecentEditor-657770475'; - $expectedResponse = new MuteConfig(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setFilter($filter); - $expectedResponse->setMostRecentEditor($mostRecentEditor); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); - $request = (new GetMuteConfigRequest()) - ->setName($formattedName); - $response = $gapicClient->getMuteConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/GetMuteConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getMuteConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->muteConfigName('[ORGANIZATION]', '[MUTE_CONFIG]'); - $request = (new GetMuteConfigRequest()) - ->setName($formattedName); - try { - $gapicClient->getMuteConfig($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getNotificationConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $pubsubTopic = 'pubsubTopic-338126829'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new NotificationConfig(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setPubsubTopic($pubsubTopic); - $expectedResponse->setServiceAccount($serviceAccount); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[LOCATION]', '[NOTIFICATION_CONFIG]'); - $request = (new GetNotificationConfigRequest()) - ->setName($formattedName); - $response = $gapicClient->getNotificationConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/GetNotificationConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getNotificationConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->notificationConfigName('[ORGANIZATION]', '[LOCATION]', '[NOTIFICATION_CONFIG]'); - $request = (new GetNotificationConfigRequest()) - ->setName($formattedName); - try { - $gapicClient->getNotificationConfig($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getResourceValueConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $resourceType = 'resourceType979623115'; - $scope = 'scope109264468'; - $description = 'description-1724546052'; - $expectedResponse = new ResourceValueConfig(); - $expectedResponse->setName($name2); - $expectedResponse->setResourceType($resourceType); - $expectedResponse->setScope($scope); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->resourceValueConfigName('[ORGANIZATION]', '[RESOURCE_VALUE_CONFIG]'); - $request = (new GetResourceValueConfigRequest()) - ->setName($formattedName); - $response = $gapicClient->getResourceValueConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/GetResourceValueConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getResourceValueConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->resourceValueConfigName('[ORGANIZATION]', '[RESOURCE_VALUE_CONFIG]'); - $request = (new GetResourceValueConfigRequest()) - ->setName($formattedName); - try { - $gapicClient->getResourceValueConfig($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getSimulationTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $expectedResponse = new Simulation(); - $expectedResponse->setName($name2); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->simulationName('[ORGANIZATION]', '[SIMULATION]'); - $request = (new GetSimulationRequest()) - ->setName($formattedName); - $response = $gapicClient->getSimulation($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/GetSimulation', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getSimulationExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->simulationName('[ORGANIZATION]', '[SIMULATION]'); - $request = (new GetSimulationRequest()) - ->setName($formattedName); - try { - $gapicClient->getSimulation($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getSourceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $canonicalName = 'canonicalName1385400054'; - $expectedResponse = new Source(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setCanonicalName($canonicalName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $request = (new GetSourceRequest()) - ->setName($formattedName); - $response = $gapicClient->getSource($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/GetSource', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getSourceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $request = (new GetSourceRequest()) - ->setName($formattedName); - try { - $gapicClient->getSource($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getValuedResourceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $resource = 'resource-341064690'; - $resourceType = 'resourceType979623115'; - $displayName = 'displayName1615086568'; - $exposedScore = -1.37568698E8; - $expectedResponse = new ValuedResource(); - $expectedResponse->setName($name2); - $expectedResponse->setResource($resource); - $expectedResponse->setResourceType($resourceType); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setExposedScore($exposedScore); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->valuedResourceName('[ORGANIZATION]', '[SIMULATION]', '[VALUED_RESOURCE]'); - $request = (new GetValuedResourceRequest()) - ->setName($formattedName); - $response = $gapicClient->getValuedResource($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/GetValuedResource', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getValuedResourceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->valuedResourceName('[ORGANIZATION]', '[SIMULATION]', '[VALUED_RESOURCE]'); - $request = (new GetValuedResourceRequest()) - ->setName($formattedName); - try { - $gapicClient->getValuedResource($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function groupFindingsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $totalSize = 705419236; - $groupByResultsElement = new GroupResult(); - $groupByResults = [ - $groupByResultsElement, - ]; - $expectedResponse = new GroupFindingsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTotalSize($totalSize); - $expectedResponse->setGroupByResults($groupByResults); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $groupBy = 'groupBy506361367'; - $request = (new GroupFindingsRequest()) - ->setParent($formattedParent) - ->setGroupBy($groupBy); - $response = $gapicClient->groupFindings($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getGroupByResults()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/GroupFindings', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getGroupBy(); - $this->assertProtobufEquals($groupBy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function groupFindingsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $groupBy = 'groupBy506361367'; - $request = (new GroupFindingsRequest()) - ->setParent($formattedParent) - ->setGroupBy($groupBy); - try { - $gapicClient->groupFindings($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAttackPathsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $attackPathsElement = new AttackPath(); - $attackPaths = [ - $attackPathsElement, - ]; - $expectedResponse = new ListAttackPathsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setAttackPaths($attackPaths); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationValuedResourceName('[ORGANIZATION]', '[LOCATION]', '[SIMULATION]', '[VALUED_RESOURCE]'); - $request = (new ListAttackPathsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listAttackPaths($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getAttackPaths()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/ListAttackPaths', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listAttackPathsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->organizationValuedResourceName('[ORGANIZATION]', '[LOCATION]', '[SIMULATION]', '[VALUED_RESOURCE]'); - $request = (new ListAttackPathsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listAttackPaths($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listBigQueryExportsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $bigQueryExportsElement = new BigQueryExport(); - $bigQueryExports = [ - $bigQueryExportsElement, - ]; - $expectedResponse = new ListBigQueryExportsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setBigQueryExports($bigQueryExports); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListBigQueryExportsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listBigQueryExports($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getBigQueryExports()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/ListBigQueryExports', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listBigQueryExportsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListBigQueryExportsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listBigQueryExports($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listFindingsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $totalSize = 705419236; - $listFindingsResultsElement = new ListFindingsResult(); - $listFindingsResults = [ - $listFindingsResultsElement, - ]; - $expectedResponse = new ListFindingsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTotalSize($totalSize); - $expectedResponse->setListFindingsResults($listFindingsResults); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $request = (new ListFindingsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listFindings($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getListFindingsResults()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/ListFindings', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listFindingsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->sourceName('[ORGANIZATION]', '[SOURCE]'); - $request = (new ListFindingsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listFindings($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listMuteConfigsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $muteConfigsElement = new MuteConfig(); - $muteConfigs = [ - $muteConfigsElement, - ]; - $expectedResponse = new ListMuteConfigsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setMuteConfigs($muteConfigs); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListMuteConfigsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listMuteConfigs($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getMuteConfigs()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/ListMuteConfigs', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listMuteConfigsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListMuteConfigsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listMuteConfigs($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNotificationConfigsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $notificationConfigsElement = new NotificationConfig(); - $notificationConfigs = [ - $notificationConfigsElement, - ]; - $expectedResponse = new ListNotificationConfigsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setNotificationConfigs($notificationConfigs); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListNotificationConfigsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listNotificationConfigs($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getNotificationConfigs()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/ListNotificationConfigs', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNotificationConfigsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListNotificationConfigsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listNotificationConfigs($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listResourceValueConfigsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $resourceValueConfigsElement = new ResourceValueConfig(); - $resourceValueConfigs = [ - $resourceValueConfigsElement, - ]; - $expectedResponse = new ListResourceValueConfigsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setResourceValueConfigs($resourceValueConfigs); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListResourceValueConfigsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listResourceValueConfigs($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getResourceValueConfigs()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/ListResourceValueConfigs', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listResourceValueConfigsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $request = (new ListResourceValueConfigsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listResourceValueConfigs($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listSourcesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $sourcesElement = new Source(); - $sources = [ - $sourcesElement, - ]; - $expectedResponse = new ListSourcesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setSources($sources); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $request = (new ListSourcesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listSources($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getSources()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/ListSources', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listSourcesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->projectName('[PROJECT]'); - $request = (new ListSourcesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listSources($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listValuedResourcesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $totalSize = 705419236; - $valuedResourcesElement = new ValuedResource(); - $valuedResources = [ - $valuedResourcesElement, - ]; - $expectedResponse = new ListValuedResourcesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setTotalSize($totalSize); - $expectedResponse->setValuedResources($valuedResources); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->simulationName('[ORGANIZATION]', '[SIMULATION]'); - $request = (new ListValuedResourcesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listValuedResources($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getValuedResources()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/ListValuedResources', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listValuedResourcesExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedParent = $gapicClient->simulationName('[ORGANIZATION]', '[SIMULATION]'); - $request = (new ListValuedResourcesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listValuedResources($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setFindingStateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $canonicalName = 'canonicalName1385400054'; - $parent = 'parent-995424086'; - $resourceName = 'resourceName979421212'; - $category = 'category50511102'; - $externalUri = 'externalUri-1385596168'; - $muteInitiator = 'muteInitiator7603081'; - $parentDisplayName = 'parentDisplayName934119773'; - $description = 'description-1724546052'; - $nextSteps = 'nextSteps-921338149'; - $moduleName = 'moduleName-1195003778'; - $expectedResponse = new Finding(); - $expectedResponse->setName($name2); - $expectedResponse->setCanonicalName($canonicalName); - $expectedResponse->setParent($parent); - $expectedResponse->setResourceName($resourceName); - $expectedResponse->setCategory($category); - $expectedResponse->setExternalUri($externalUri); - $expectedResponse->setMuteInitiator($muteInitiator); - $expectedResponse->setParentDisplayName($parentDisplayName); - $expectedResponse->setDescription($description); - $expectedResponse->setNextSteps($nextSteps); - $expectedResponse->setModuleName($moduleName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - $state = State::STATE_UNSPECIFIED; - $request = (new SetFindingStateRequest()) - ->setName($formattedName) - ->setState($state); - $response = $gapicClient->setFindingState($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/SetFindingState', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualRequestObject->getState(); - $this->assertProtobufEquals($state, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setFindingStateExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - $state = State::STATE_UNSPECIFIED; - $request = (new SetFindingStateRequest()) - ->setName($formattedName) - ->setState($state); - try { - $gapicClient->setFindingState($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $version = 351608024; - $etag = '21'; - $expectedResponse = new Policy(); - $expectedResponse->setVersion($version); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $request = (new SetIamPolicyRequest()) - ->setResource($resource) - ->setPolicy($policy); - $response = $gapicClient->setIamPolicy($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/SetIamPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPolicy(); - $this->assertProtobufEquals($policy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setIamPolicyExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $policy = new Policy(); - $request = (new SetIamPolicyRequest()) - ->setResource($resource) - ->setPolicy($policy); - try { - $gapicClient->setIamPolicy($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setMuteTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $canonicalName = 'canonicalName1385400054'; - $parent = 'parent-995424086'; - $resourceName = 'resourceName979421212'; - $category = 'category50511102'; - $externalUri = 'externalUri-1385596168'; - $muteInitiator = 'muteInitiator7603081'; - $parentDisplayName = 'parentDisplayName934119773'; - $description = 'description-1724546052'; - $nextSteps = 'nextSteps-921338149'; - $moduleName = 'moduleName-1195003778'; - $expectedResponse = new Finding(); - $expectedResponse->setName($name2); - $expectedResponse->setCanonicalName($canonicalName); - $expectedResponse->setParent($parent); - $expectedResponse->setResourceName($resourceName); - $expectedResponse->setCategory($category); - $expectedResponse->setExternalUri($externalUri); - $expectedResponse->setMuteInitiator($muteInitiator); - $expectedResponse->setParentDisplayName($parentDisplayName); - $expectedResponse->setDescription($description); - $expectedResponse->setNextSteps($nextSteps); - $expectedResponse->setModuleName($moduleName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - $mute = Mute::MUTE_UNSPECIFIED; - $request = (new SetMuteRequest()) - ->setName($formattedName) - ->setMute($mute); - $response = $gapicClient->setMute($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/SetMute', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualRequestObject->getMute(); - $this->assertProtobufEquals($mute, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function setMuteExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $formattedName = $gapicClient->findingName('[ORGANIZATION]', '[SOURCE]', '[FINDING]'); - $mute = Mute::MUTE_UNSPECIFIED; - $request = (new SetMuteRequest()) - ->setName($formattedName) - ->setMute($mute); - try { - $gapicClient->setMute($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new TestIamPermissionsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $request = (new TestIamPermissionsRequest()) - ->setResource($resource) - ->setPermissions($permissions); - $response = $gapicClient->testIamPermissions($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/TestIamPermissions', $actualFuncCall); - $actualValue = $actualRequestObject->getResource(); - $this->assertProtobufEquals($resource, $actualValue); - $actualValue = $actualRequestObject->getPermissions(); - $this->assertProtobufEquals($permissions, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function testIamPermissionsExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resource = 'resource-341064690'; - $permissions = []; - $request = (new TestIamPermissionsRequest()) - ->setResource($resource) - ->setPermissions($permissions); - try { - $gapicClient->testIamPermissions($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateBigQueryExportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $description = 'description-1724546052'; - $filter = 'filter-1274492040'; - $dataset = 'dataset1443214456'; - $mostRecentEditor = 'mostRecentEditor-657770475'; - $principal = 'principal-1812041682'; - $expectedResponse = new BigQueryExport(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setFilter($filter); - $expectedResponse->setDataset($dataset); - $expectedResponse->setMostRecentEditor($mostRecentEditor); - $expectedResponse->setPrincipal($principal); - $transport->addResponse($expectedResponse); - // Mock request - $bigQueryExport = new BigQueryExport(); - $request = (new UpdateBigQueryExportRequest()) - ->setBigQueryExport($bigQueryExport); - $response = $gapicClient->updateBigQueryExport($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/UpdateBigQueryExport', $actualFuncCall); - $actualValue = $actualRequestObject->getBigQueryExport(); - $this->assertProtobufEquals($bigQueryExport, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateBigQueryExportExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $bigQueryExport = new BigQueryExport(); - $request = (new UpdateBigQueryExportRequest()) - ->setBigQueryExport($bigQueryExport); - try { - $gapicClient->updateBigQueryExport($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateExternalSystemTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $externalUid = 'externalUid-1385596452'; - $status = 'status-892481550'; - $caseUri = 'caseUri21649373'; - $casePriority = 'casePriority715048403'; - $expectedResponse = new ExternalSystem(); - $expectedResponse->setName($name); - $expectedResponse->setExternalUid($externalUid); - $expectedResponse->setStatus($status); - $expectedResponse->setCaseUri($caseUri); - $expectedResponse->setCasePriority($casePriority); - $transport->addResponse($expectedResponse); - // Mock request - $externalSystem = new ExternalSystem(); - $request = (new UpdateExternalSystemRequest()) - ->setExternalSystem($externalSystem); - $response = $gapicClient->updateExternalSystem($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/UpdateExternalSystem', $actualFuncCall); - $actualValue = $actualRequestObject->getExternalSystem(); - $this->assertProtobufEquals($externalSystem, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateExternalSystemExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $externalSystem = new ExternalSystem(); - $request = (new UpdateExternalSystemRequest()) - ->setExternalSystem($externalSystem); - try { - $gapicClient->updateExternalSystem($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateFindingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $canonicalName = 'canonicalName1385400054'; - $parent = 'parent-995424086'; - $resourceName = 'resourceName979421212'; - $category = 'category50511102'; - $externalUri = 'externalUri-1385596168'; - $muteInitiator = 'muteInitiator7603081'; - $parentDisplayName = 'parentDisplayName934119773'; - $description = 'description-1724546052'; - $nextSteps = 'nextSteps-921338149'; - $moduleName = 'moduleName-1195003778'; - $expectedResponse = new Finding(); - $expectedResponse->setName($name); - $expectedResponse->setCanonicalName($canonicalName); - $expectedResponse->setParent($parent); - $expectedResponse->setResourceName($resourceName); - $expectedResponse->setCategory($category); - $expectedResponse->setExternalUri($externalUri); - $expectedResponse->setMuteInitiator($muteInitiator); - $expectedResponse->setParentDisplayName($parentDisplayName); - $expectedResponse->setDescription($description); - $expectedResponse->setNextSteps($nextSteps); - $expectedResponse->setModuleName($moduleName); - $transport->addResponse($expectedResponse); - // Mock request - $finding = new Finding(); - $request = (new UpdateFindingRequest()) - ->setFinding($finding); - $response = $gapicClient->updateFinding($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/UpdateFinding', $actualFuncCall); - $actualValue = $actualRequestObject->getFinding(); - $this->assertProtobufEquals($finding, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateFindingExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $finding = new Finding(); - $request = (new UpdateFindingRequest()) - ->setFinding($finding); - try { - $gapicClient->updateFinding($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateMuteConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $description = 'description-1724546052'; - $filter = 'filter-1274492040'; - $mostRecentEditor = 'mostRecentEditor-657770475'; - $expectedResponse = new MuteConfig(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setFilter($filter); - $expectedResponse->setMostRecentEditor($mostRecentEditor); - $transport->addResponse($expectedResponse); - // Mock request - $muteConfig = new MuteConfig(); - $muteConfigFilter = 'muteConfigFilter-1921414637'; - $muteConfig->setFilter($muteConfigFilter); - $muteConfigType = MuteConfigType::MUTE_CONFIG_TYPE_UNSPECIFIED; - $muteConfig->setType($muteConfigType); - $request = (new UpdateMuteConfigRequest()) - ->setMuteConfig($muteConfig); - $response = $gapicClient->updateMuteConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/UpdateMuteConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getMuteConfig(); - $this->assertProtobufEquals($muteConfig, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateMuteConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $muteConfig = new MuteConfig(); - $muteConfigFilter = 'muteConfigFilter-1921414637'; - $muteConfig->setFilter($muteConfigFilter); - $muteConfigType = MuteConfigType::MUTE_CONFIG_TYPE_UNSPECIFIED; - $muteConfig->setType($muteConfigType); - $request = (new UpdateMuteConfigRequest()) - ->setMuteConfig($muteConfig); - try { - $gapicClient->updateMuteConfig($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateNotificationConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $description = 'description-1724546052'; - $pubsubTopic = 'pubsubTopic-338126829'; - $serviceAccount = 'serviceAccount-1948028253'; - $expectedResponse = new NotificationConfig(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setPubsubTopic($pubsubTopic); - $expectedResponse->setServiceAccount($serviceAccount); - $transport->addResponse($expectedResponse); - // Mock request - $notificationConfig = new NotificationConfig(); - $request = (new UpdateNotificationConfigRequest()) - ->setNotificationConfig($notificationConfig); - $response = $gapicClient->updateNotificationConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/UpdateNotificationConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getNotificationConfig(); - $this->assertProtobufEquals($notificationConfig, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateNotificationConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $notificationConfig = new NotificationConfig(); - $request = (new UpdateNotificationConfigRequest()) - ->setNotificationConfig($notificationConfig); - try { - $gapicClient->updateNotificationConfig($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateResourceValueConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $resourceType = 'resourceType979623115'; - $scope = 'scope109264468'; - $description = 'description-1724546052'; - $expectedResponse = new ResourceValueConfig(); - $expectedResponse->setName($name); - $expectedResponse->setResourceType($resourceType); - $expectedResponse->setScope($scope); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $resourceValueConfig = new ResourceValueConfig(); - $resourceValueConfigTagValues = []; - $resourceValueConfig->setTagValues($resourceValueConfigTagValues); - $request = (new UpdateResourceValueConfigRequest()) - ->setResourceValueConfig($resourceValueConfig); - $response = $gapicClient->updateResourceValueConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/UpdateResourceValueConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getResourceValueConfig(); - $this->assertProtobufEquals($resourceValueConfig, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateResourceValueConfigExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $resourceValueConfig = new ResourceValueConfig(); - $resourceValueConfigTagValues = []; - $resourceValueConfig->setTagValues($resourceValueConfigTagValues); - $request = (new UpdateResourceValueConfigRequest()) - ->setResourceValueConfig($resourceValueConfig); - try { - $gapicClient->updateResourceValueConfig($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSecurityMarksTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $canonicalName = 'canonicalName1385400054'; - $expectedResponse = new SecurityMarks(); - $expectedResponse->setName($name); - $expectedResponse->setCanonicalName($canonicalName); - $transport->addResponse($expectedResponse); - // Mock request - $securityMarks = new SecurityMarks(); - $request = (new UpdateSecurityMarksRequest()) - ->setSecurityMarks($securityMarks); - $response = $gapicClient->updateSecurityMarks($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/UpdateSecurityMarks', $actualFuncCall); - $actualValue = $actualRequestObject->getSecurityMarks(); - $this->assertProtobufEquals($securityMarks, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSecurityMarksExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $securityMarks = new SecurityMarks(); - $request = (new UpdateSecurityMarksRequest()) - ->setSecurityMarks($securityMarks); - try { - $gapicClient->updateSecurityMarks($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSourceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $canonicalName = 'canonicalName1385400054'; - $expectedResponse = new Source(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setCanonicalName($canonicalName); - $transport->addResponse($expectedResponse); - // Mock request - $source = new Source(); - $request = (new UpdateSourceRequest()) - ->setSource($source); - $response = $gapicClient->updateSource($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/UpdateSource', $actualFuncCall); - $actualValue = $actualRequestObject->getSource(); - $this->assertProtobufEquals($source, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateSourceExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - $status = new stdClass(); - $status->code = Code::DATA_LOSS; - $status->details = 'internal error'; - $expectedExceptionMessage = json_encode([ - 'message' => 'internal error', - 'code' => Code::DATA_LOSS, - 'status' => 'DATA_LOSS', - 'details' => [], - ], JSON_PRETTY_PRINT); - $transport->addResponse(null, $status); - // Mock request - $source = new Source(); - $request = (new UpdateSourceRequest()) - ->setSource($source); - try { - $gapicClient->updateSource($request); - // If the $gapicClient method call did not throw, fail the test - $this->fail('Expected an ApiException, but no exception was thrown.'); - } catch (ApiException $ex) { - $this->assertEquals($status->code, $ex->getCode()); - $this->assertEquals($expectedExceptionMessage, $ex->getMessage()); - } - // Call popReceivedCalls to ensure the stub is exhausted - $transport->popReceivedCalls(); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function batchCreateResourceValueConfigsAsyncTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new BatchCreateResourceValueConfigsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->organizationLocationName('[ORGANIZATION]', '[LOCATION]'); - $requests = []; - $request = (new BatchCreateResourceValueConfigsRequest()) - ->setParent($formattedParent) - ->setRequests($requests); - $response = $gapicClient->batchCreateResourceValueConfigsAsync($request)->wait(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.securitycenter.v2.SecurityCenter/BatchCreateResourceValueConfigs', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getRequests(); - $this->assertProtobufEquals($requests, $actualValue); - $this->assertTrue($transport->isExhausted()); - } -}